diff --git a/README.md b/README.md index 81b6e60d..17f22ff7 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@ Add this dependency to your project's POM: one.talon talon-one-client - 15.0.0 + 16.0.0 compile ``` @@ -50,7 +50,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "one.talon:talon-one-client:15.0.0" +compile "one.talon:talon-one-client:16.0.0" ``` ### Others @@ -212,6 +212,7 @@ Class | Method | HTTP request | Description *IntegrationApi* | [**getCustomerAchievements**](docs/IntegrationApi.md#getCustomerAchievements) | **GET** /v1/customer_profiles/{integrationId}/achievements | List customer's available achievements *IntegrationApi* | [**getCustomerInventory**](docs/IntegrationApi.md#getCustomerInventory) | **GET** /v1/customer_profiles/{integrationId}/inventory | List customer data *IntegrationApi* | [**getCustomerSession**](docs/IntegrationApi.md#getCustomerSession) | **GET** /v2/customer_sessions/{customerSessionId} | Get customer session +*IntegrationApi* | [**getEventV3**](docs/IntegrationApi.md#getEventV3) | **GET** /v3/events/{integrationId} | Get advanced event *IntegrationApi* | [**getLoyaltyBalances**](docs/IntegrationApi.md#getLoyaltyBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/balances | Get customer's loyalty balances *IntegrationApi* | [**getLoyaltyCardBalances**](docs/IntegrationApi.md#getLoyaltyCardBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/balances | Get card's point balances *IntegrationApi* | [**getLoyaltyCardPoints**](docs/IntegrationApi.md#getLoyaltyCardPoints) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/points | List card's unused loyalty points @@ -220,12 +221,16 @@ Class | Method | HTTP request | Description *IntegrationApi* | [**getLoyaltyProgramProfileTransactions**](docs/IntegrationApi.md#getLoyaltyProgramProfileTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/transactions | List customer's loyalty transactions *IntegrationApi* | [**getReservedCustomers**](docs/IntegrationApi.md#getReservedCustomers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | List customers that have this coupon reserved *IntegrationApi* | [**integrationGetAllCampaigns**](docs/IntegrationApi.md#integrationGetAllCampaigns) | **GET** /v1/integration/campaigns | List all running campaigns +*IntegrationApi* | [**integrationRewardsCatalog**](docs/IntegrationApi.md#integrationRewardsCatalog) | **GET** /v1/rewards/catalog | List rewards in the catalog +*IntegrationApi* | [**joinLoyaltyProgram**](docs/IntegrationApi.md#joinLoyaltyProgram) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join | Join customer profile to loyalty program *IntegrationApi* | [**linkLoyaltyCardToProfile**](docs/IntegrationApi.md#linkLoyaltyCardToProfile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile | Link customer profile to card *IntegrationApi* | [**reopenCustomerSession**](docs/IntegrationApi.md#reopenCustomerSession) | **PUT** /v2/customer_sessions/{customerSessionId}/reopen | Reopen customer session *IntegrationApi* | [**returnCartItems**](docs/IntegrationApi.md#returnCartItems) | **POST** /v2/customer_sessions/{customerSessionId}/returns | Return cart items *IntegrationApi* | [**syncCatalog**](docs/IntegrationApi.md#syncCatalog) | **PUT** /v1/catalogs/{catalogId}/sync | Sync cart item catalog *IntegrationApi* | [**trackEventV2**](docs/IntegrationApi.md#trackEventV2) | **POST** /v2/events | Track event +*IntegrationApi* | [**trackEventV3**](docs/IntegrationApi.md#trackEventV3) | **POST** /v3/events | Track advanced event *IntegrationApi* | [**unlinkLoyaltyCardFromProfile**](docs/IntegrationApi.md#unlinkLoyaltyCardFromProfile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/unlink_profile | Unlink customer profile from a loyalty card +*IntegrationApi* | [**unlockReward**](docs/IntegrationApi.md#unlockReward) | **POST** /v1/rewards/{rewardId}/unlock | Unlock a reward *IntegrationApi* | [**updateAudienceCustomersAttributes**](docs/IntegrationApi.md#updateAudienceCustomersAttributes) | **PUT** /v2/audience_customers/{audienceId}/attributes | Update profile attributes for all customers in audience *IntegrationApi* | [**updateAudienceV2**](docs/IntegrationApi.md#updateAudienceV2) | **PUT** /v2/audiences/{audienceId} | Update audience name *IntegrationApi* | [**updateCustomerProfileAudiences**](docs/IntegrationApi.md#updateCustomerProfileAudiences) | **POST** /v2/customer_audiences | Update multiple customer profiles' audiences @@ -238,6 +243,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**copyCampaignToApplications**](docs/ManagementApi.md#copyCampaignToApplications) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/copy | Copy the campaign into the specified Application *ManagementApi* | [**createAccountCollection**](docs/ManagementApi.md#createAccountCollection) | **POST** /v1/collections | Create account-level collection *ManagementApi* | [**createAchievement**](docs/ManagementApi.md#createAchievement) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements | Create achievement +*ManagementApi* | [**createAchievementV2**](docs/ManagementApi.md#createAchievementV2) | **POST** /v2/achievements | Create achievement *ManagementApi* | [**createAdditionalCost**](docs/ManagementApi.md#createAdditionalCost) | **POST** /v1/additional_costs | Create additional cost *ManagementApi* | [**createAttribute**](docs/ManagementApi.md#createAttribute) | **POST** /v1/attributes | Create custom attribute *ManagementApi* | [**createBatchLoyaltyCards**](docs/ManagementApi.md#createBatchLoyaltyCards) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/cards/batch | Create loyalty cards @@ -251,12 +257,14 @@ Class | Method | HTTP request | Description *ManagementApi* | [**createInviteEmail**](docs/ManagementApi.md#createInviteEmail) | **POST** /v1/invite_emails | Resend invitation email *ManagementApi* | [**createInviteV2**](docs/ManagementApi.md#createInviteV2) | **POST** /v2/invites | Invite user *ManagementApi* | [**createPasswordRecoveryEmail**](docs/ManagementApi.md#createPasswordRecoveryEmail) | **POST** /v1/password_recovery_emails | Request a password reset +*ManagementApi* | [**createRulesetV2**](docs/ManagementApi.md#createRulesetV2) | **POST** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets | Create ruleset (V2) *ManagementApi* | [**createSession**](docs/ManagementApi.md#createSession) | **POST** /v1/sessions | Create session *ManagementApi* | [**createStore**](docs/ManagementApi.md#createStore) | **POST** /v1/applications/{applicationId}/stores | Create store *ManagementApi* | [**deactivateUserByEmail**](docs/ManagementApi.md#deactivateUserByEmail) | **POST** /v1/users/deactivate | Disable user by email address *ManagementApi* | [**deductLoyaltyCardPoints**](docs/ManagementApi.md#deductLoyaltyCardPoints) | **PUT** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/deduct_points | Deduct points from card *ManagementApi* | [**deleteAccountCollection**](docs/ManagementApi.md#deleteAccountCollection) | **DELETE** /v1/collections/{collectionId} | Delete account-level collection *ManagementApi* | [**deleteAchievement**](docs/ManagementApi.md#deleteAchievement) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Delete achievement +*ManagementApi* | [**deleteAchievementV2**](docs/ManagementApi.md#deleteAchievementV2) | **DELETE** /v2/achievements/{achievementId} | Delete achievement *ManagementApi* | [**deleteCampaign**](docs/ManagementApi.md#deleteCampaign) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId} | Delete campaign *ManagementApi* | [**deleteCampaignStoreBudgets**](docs/ManagementApi.md#deleteCampaignStoreBudgets) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/stores/budgets | Delete campaign store budgets *ManagementApi* | [**deleteCollection**](docs/ManagementApi.md#deleteCollection) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/collections/{collectionId} | Delete campaign-level collection @@ -269,7 +277,9 @@ Class | Method | HTTP request | Description *ManagementApi* | [**deleteUserByEmail**](docs/ManagementApi.md#deleteUserByEmail) | **POST** /v1/users/delete | Delete user by email address *ManagementApi* | [**destroySession**](docs/ManagementApi.md#destroySession) | **DELETE** /v1/sessions | Destroy session *ManagementApi* | [**disconnectCampaignStores**](docs/ManagementApi.md#disconnectCampaignStores) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/stores | Disconnect stores +*ManagementApi* | [**excludePriceHistory**](docs/ManagementApi.md#excludePriceHistory) | **POST** /v1/applications/{applicationId}/price_history/exclusions | Exclude price records from price history *ManagementApi* | [**exportAccountCollectionItems**](docs/ManagementApi.md#exportAccountCollectionItems) | **GET** /v1/collections/{collectionId}/export | Export account-level collection's items +*ManagementApi* | [**exportAchievementV2**](docs/ManagementApi.md#exportAchievementV2) | **GET** /v2/achievements/{achievementId}/export | Export achievement customer data *ManagementApi* | [**exportAchievements**](docs/ManagementApi.md#exportAchievements) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}/export | Export achievement customer data *ManagementApi* | [**exportApplicationCampaignAnalytics**](docs/ManagementApi.md#exportApplicationCampaignAnalytics) | **GET** /v1/applications/{applicationId}/campaign_analytics/export | Export Application analytics aggregated by campaign *ManagementApi* | [**exportAudiencesMemberships**](docs/ManagementApi.md#exportAudiencesMemberships) | **GET** /v1/audiences/{audienceId}/memberships/export | Export audience members @@ -296,6 +306,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getAccountAnalytics**](docs/ManagementApi.md#getAccountAnalytics) | **GET** /v1/accounts/{accountId}/analytics | Get account analytics *ManagementApi* | [**getAccountCollection**](docs/ManagementApi.md#getAccountCollection) | **GET** /v1/collections/{collectionId} | Get account-level collection *ManagementApi* | [**getAchievement**](docs/ManagementApi.md#getAchievement) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Get achievement +*ManagementApi* | [**getAchievementV2**](docs/ManagementApi.md#getAchievementV2) | **GET** /v2/achievements/{achievementId} | Get achievement *ManagementApi* | [**getAdditionalCost**](docs/ManagementApi.md#getAdditionalCost) | **GET** /v1/additional_costs/{additionalCostId} | Get additional cost *ManagementApi* | [**getAdditionalCosts**](docs/ManagementApi.md#getAdditionalCosts) | **GET** /v1/additional_costs | List additional costs *ManagementApi* | [**getApplication**](docs/ManagementApi.md#getApplication) | **GET** /v1/applications/{applicationId} | Get Application @@ -309,6 +320,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getApplicationEventsWithoutTotalCount**](docs/ManagementApi.md#getApplicationEventsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/events/no_total | List Applications events *ManagementApi* | [**getApplicationSession**](docs/ManagementApi.md#getApplicationSession) | **GET** /v1/applications/{applicationId}/sessions/{sessionId} | Get Application session *ManagementApi* | [**getApplicationSessions**](docs/ManagementApi.md#getApplicationSessions) | **GET** /v1/applications/{applicationId}/sessions | List Application sessions +*ManagementApi* | [**getApplicationSessionsByCustomerAttributes**](docs/ManagementApi.md#getApplicationSessionsByCustomerAttributes) | **POST** /v1/applications/{applicationId}/sessions_search | List Application sessions matching the given customer attributes *ManagementApi* | [**getApplications**](docs/ManagementApi.md#getApplications) | **GET** /v1/applications | List Applications *ManagementApi* | [**getAttribute**](docs/ManagementApi.md#getAttribute) | **GET** /v1/attributes/{attributeId} | Get custom attribute *ManagementApi* | [**getAttributes**](docs/ManagementApi.md#getAttributes) | **GET** /v1/attributes | List custom attributes @@ -338,12 +350,12 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getExperiment**](docs/ManagementApi.md#getExperiment) | **GET** /v1/applications/{applicationId}/experiments/{experimentId} | Get experiment in Application *ManagementApi* | [**getExports**](docs/ManagementApi.md#getExports) | **GET** /v1/exports | Get exports *ManagementApi* | [**getLoyaltyCard**](docs/ManagementApi.md#getLoyaltyCard) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId} | Get loyalty card -*ManagementApi* | [**getLoyaltyCardTransactionLogs**](docs/ManagementApi.md#getLoyaltyCardTransactionLogs) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/logs | List card's transactions +*ManagementApi* | [**getLoyaltyCardTransactionLogs**](docs/ManagementApi.md#getLoyaltyCardTransactionLogs) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/logs | List card's transactions (Management API) *ManagementApi* | [**getLoyaltyCards**](docs/ManagementApi.md#getLoyaltyCards) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards | List loyalty cards -*ManagementApi* | [**getLoyaltyLedgerBalances**](docs/ManagementApi.md#getLoyaltyLedgerBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_balances | Get customer's loyalty balances +*ManagementApi* | [**getLoyaltyLedgerBalances**](docs/ManagementApi.md#getLoyaltyLedgerBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_balances | Get customer's loyalty balances (Management API) *ManagementApi* | [**getLoyaltyPoints**](docs/ManagementApi.md#getLoyaltyPoints) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId} | Get customer's full loyalty ledger *ManagementApi* | [**getLoyaltyProgram**](docs/ManagementApi.md#getLoyaltyProgram) | **GET** /v1/loyalty_programs/{loyaltyProgramId} | Get loyalty program -*ManagementApi* | [**getLoyaltyProgramProfileLedgerTransactions**](docs/ManagementApi.md#getLoyaltyProgramProfileLedgerTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_transactions | List customer's loyalty transactions +*ManagementApi* | [**getLoyaltyProgramProfileLedgerTransactions**](docs/ManagementApi.md#getLoyaltyProgramProfileLedgerTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_transactions | List customer's loyalty transactions (Management API) *ManagementApi* | [**getLoyaltyProgramTransactions**](docs/ManagementApi.md#getLoyaltyProgramTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/transactions | List loyalty program transactions *ManagementApi* | [**getLoyaltyPrograms**](docs/ManagementApi.md#getLoyaltyPrograms) | **GET** /v1/loyalty_programs | List loyalty programs *ManagementApi* | [**getLoyaltyStatistics**](docs/ManagementApi.md#getLoyaltyStatistics) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/statistics | Get loyalty program statistics @@ -351,6 +363,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getReferralsWithoutTotalCount**](docs/ManagementApi.md#getReferralsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/referrals/no_total | List referrals *ManagementApi* | [**getRoleV2**](docs/ManagementApi.md#getRoleV2) | **GET** /v2/roles/{roleId} | Get role *ManagementApi* | [**getRuleset**](docs/ManagementApi.md#getRuleset) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset +*ManagementApi* | [**getRulesetV2**](docs/ManagementApi.md#getRulesetV2) | **GET** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset (V2) *ManagementApi* | [**getRulesets**](docs/ManagementApi.md#getRulesets) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets | List campaign rulesets *ManagementApi* | [**getStore**](docs/ManagementApi.md#getStore) | **GET** /v1/applications/{applicationId}/stores/{storeId} | Get store *ManagementApi* | [**getUser**](docs/ManagementApi.md#getUser) | **GET** /v1/users/{userId} | Get user @@ -366,12 +379,14 @@ Class | Method | HTTP request | Description *ManagementApi* | [**importCoupons**](docs/ManagementApi.md#importCoupons) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/import_coupons | Import coupons *ManagementApi* | [**importLoyaltyCards**](docs/ManagementApi.md#importLoyaltyCards) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_cards | Import loyalty cards *ManagementApi* | [**importLoyaltyCustomersTiers**](docs/ManagementApi.md#importLoyaltyCustomersTiers) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_customers_tiers | Import customers into loyalty tiers +*ManagementApi* | [**importLoyaltyJoinDates**](docs/ManagementApi.md#importLoyaltyJoinDates) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_join_dates | Import join dates for a loyalty program *ManagementApi* | [**importLoyaltyPoints**](docs/ManagementApi.md#importLoyaltyPoints) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_points | Import loyalty points *ManagementApi* | [**importPoolGiveaways**](docs/ManagementApi.md#importPoolGiveaways) | **POST** /v1/giveaways/pools/{poolId}/import | Import giveaway codes into a giveaway pool *ManagementApi* | [**importReferrals**](docs/ManagementApi.md#importReferrals) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/import_referrals | Import referrals *ManagementApi* | [**inviteUserExternal**](docs/ManagementApi.md#inviteUserExternal) | **POST** /v1/users/invite | Invite user from identity provider *ManagementApi* | [**listAccountCollections**](docs/ManagementApi.md#listAccountCollections) | **GET** /v1/collections | List collections in account *ManagementApi* | [**listAchievements**](docs/ManagementApi.md#listAchievements) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements | List achievements +*ManagementApi* | [**listAchievementsV2**](docs/ManagementApi.md#listAchievementsV2) | **GET** /v2/achievements | List achievements *ManagementApi* | [**listAllRolesV2**](docs/ManagementApi.md#listAllRolesV2) | **GET** /v2/roles | List roles *ManagementApi* | [**listApplicationCartItemFilters**](docs/ManagementApi.md#listApplicationCartItemFilters) | **GET** /v1/applications/{applicationId}/cart_item_filters | List Application cart item filters *ManagementApi* | [**listCampaignStoreBudgetLimits**](docs/ManagementApi.md#listCampaignStoreBudgetLimits) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/stores/budgets | List campaign store budget limits @@ -405,6 +420,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**transferLoyaltyCard**](docs/ManagementApi.md#transferLoyaltyCard) | **PUT** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/transfer | Transfer card data *ManagementApi* | [**updateAccountCollection**](docs/ManagementApi.md#updateAccountCollection) | **PUT** /v1/collections/{collectionId} | Update account-level collection *ManagementApi* | [**updateAchievement**](docs/ManagementApi.md#updateAchievement) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Update achievement +*ManagementApi* | [**updateAchievementV2**](docs/ManagementApi.md#updateAchievementV2) | **PUT** /v2/achievements/{achievementId} | Update achievement *ManagementApi* | [**updateAdditionalCost**](docs/ManagementApi.md#updateAdditionalCost) | **PUT** /v1/additional_costs/{additionalCostId} | Update additional cost *ManagementApi* | [**updateAttribute**](docs/ManagementApi.md#updateAttribute) | **PUT** /v1/attributes/{attributeId} | Update custom attribute *ManagementApi* | [**updateCampaign**](docs/ManagementApi.md#updateCampaign) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId} | Update campaign @@ -450,6 +466,7 @@ Class | Method | HTTP request | Description - [AddItemCatalogAction](docs/AddItemCatalogAction.md) - [AddLoyaltyPoints](docs/AddLoyaltyPoints.md) - [AddLoyaltyPointsEffectProps](docs/AddLoyaltyPointsEffectProps.md) +- [AddLoyaltyPointsSupport](docs/AddLoyaltyPointsSupport.md) - [AddPriceAdjustmentCatalogAction](docs/AddPriceAdjustmentCatalogAction.md) - [AddToAudienceEffectProps](docs/AddToAudienceEffectProps.md) - [AddedDeductedPointsBalancesAction](docs/AddedDeductedPointsBalancesAction.md) @@ -459,6 +476,7 @@ Class | Method | HTTP request | Description - [AddedDeductedPointsNotificationPolicy](docs/AddedDeductedPointsNotificationPolicy.md) - [AdditionalCampaignProperties](docs/AdditionalCampaignProperties.md) - [AdditionalCost](docs/AdditionalCost.md) +- [AdditionalCostReference](docs/AdditionalCostReference.md) - [AdjustmentDetails](docs/AdjustmentDetails.md) - [AnalyticsDataPoint](docs/AnalyticsDataPoint.md) - [AnalyticsDataPointWithTrend](docs/AnalyticsDataPointWithTrend.md) @@ -479,6 +497,7 @@ Class | Method | HTTP request | Description - [ApplicationCustomerEntity](docs/ApplicationCustomerEntity.md) - [ApplicationEntity](docs/ApplicationEntity.md) - [ApplicationEvent](docs/ApplicationEvent.md) +- [ApplicationMembership](docs/ApplicationMembership.md) - [ApplicationNotification](docs/ApplicationNotification.md) - [ApplicationReferee](docs/ApplicationReferee.md) - [ApplicationSession](docs/ApplicationSession.md) @@ -496,7 +515,19 @@ Class | Method | HTTP request | Description - [AudienceIntegrationID](docs/AudienceIntegrationID.md) - [AudienceMembership](docs/AudienceMembership.md) - [AudienceReference](docs/AudienceReference.md) +- [AwardDiscountAdditionalCostTarget](docs/AwardDiscountAdditionalCostTarget.md) +- [AwardDiscountAllItemsTarget](docs/AwardDiscountAllItemsTarget.md) +- [AwardDiscountBlock](docs/AwardDiscountBlock.md) +- [AwardDiscountBundleItemByAttribute](docs/AwardDiscountBundleItemByAttribute.md) +- [AwardDiscountBundleItemByIndex](docs/AwardDiscountBundleItemByIndex.md) +- [AwardDiscountBundleTarget](docs/AwardDiscountBundleTarget.md) +- [AwardDiscountCartTarget](docs/AwardDiscountCartTarget.md) +- [AwardDiscountGlobalFilterTarget](docs/AwardDiscountGlobalFilterTarget.md) +- [AwardDiscountSelectorTarget](docs/AwardDiscountSelectorTarget.md) +- [AwardGiveawayBlock](docs/AwardGiveawayBlock.md) - [AwardGiveawayEffectProps](docs/AwardGiveawayEffectProps.md) +- [AwardItemBlock](docs/AwardItemBlock.md) +- [BaseBlock](docs/BaseBlock.md) - [BaseCampaign](docs/BaseCampaign.md) - [BaseLoyaltyProgram](docs/BaseLoyaltyProgram.md) - [BaseNotification](docs/BaseNotification.md) @@ -507,11 +538,14 @@ Class | Method | HTTP request | Description - [BestPriorPrice](docs/BestPriorPrice.md) - [BestPriorPriceMetadata](docs/BestPriorPriceMetadata.md) - [BestPriorPriceRequest](docs/BestPriorPriceRequest.md) +- [BestPriorPriceSettings](docs/BestPriorPriceSettings.md) - [BestPriorTarget](docs/BestPriorTarget.md) +- [BetweenCheckAttributeBlock](docs/BetweenCheckAttributeBlock.md) - [Binding](docs/Binding.md) - [Blueprint](docs/Blueprint.md) - [BulkApplicationNotification](docs/BulkApplicationNotification.md) - [BulkOperationOnCampaigns](docs/BulkOperationOnCampaigns.md) +- [Bundle](docs/Bundle.md) - [Campaign](docs/Campaign.md) - [CampaignActivationRequest](docs/CampaignActivationRequest.md) - [CampaignAnalytics](docs/CampaignAnalytics.md) @@ -529,6 +563,10 @@ Class | Method | HTTP request | Description - [CampaignDetail](docs/CampaignDetail.md) - [CampaignEditedNotification](docs/CampaignEditedNotification.md) - [CampaignEditedNotificationItem](docs/CampaignEditedNotificationItem.md) +- [CampaignEligibility](docs/CampaignEligibility.md) +- [CampaignEligibilityDetails](docs/CampaignEligibilityDetails.md) +- [CampaignEligibilityExperiment](docs/CampaignEligibilityExperiment.md) +- [CampaignEligibilityFailureDetails](docs/CampaignEligibilityFailureDetails.md) - [CampaignEntity](docs/CampaignEntity.md) - [CampaignEvaluationGroup](docs/CampaignEvaluationGroup.md) - [CampaignEvaluationPosition](docs/CampaignEvaluationPosition.md) @@ -537,10 +575,12 @@ Class | Method | HTTP request | Description - [CampaignGroup](docs/CampaignGroup.md) - [CampaignGroupEntity](docs/CampaignGroupEntity.md) - [CampaignLogSummary](docs/CampaignLogSummary.md) +- [CampaignLoyaltyProgram](docs/CampaignLoyaltyProgram.md) - [CampaignNotificationBase](docs/CampaignNotificationBase.md) - [CampaignNotificationGeneric](docs/CampaignNotificationGeneric.md) - [CampaignNotificationItemBase](docs/CampaignNotificationItemBase.md) - [CampaignNotificationPolicy](docs/CampaignNotificationPolicy.md) +- [CampaignReference](docs/CampaignReference.md) - [CampaignRulesetChangedNotification](docs/CampaignRulesetChangedNotification.md) - [CampaignRulesetChangedNotificationItem](docs/CampaignRulesetChangedNotificationItem.md) - [CampaignSearch](docs/CampaignSearch.md) @@ -570,7 +610,13 @@ Class | Method | HTTP request | Description - [CartItemFilterTemplate](docs/CartItemFilterTemplate.md) - [Catalog](docs/Catalog.md) - [CatalogAction](docs/CatalogAction.md) +- [CatalogActionAdd](docs/CatalogActionAdd.md) +- [CatalogActionAddPriceAdjustment](docs/CatalogActionAddPriceAdjustment.md) - [CatalogActionFilter](docs/CatalogActionFilter.md) +- [CatalogActionPatch](docs/CatalogActionPatch.md) +- [CatalogActionPatchMany](docs/CatalogActionPatchMany.md) +- [CatalogActionRemove](docs/CatalogActionRemove.md) +- [CatalogActionRemoveMany](docs/CatalogActionRemoveMany.md) - [CatalogItem](docs/CatalogItem.md) - [CatalogRule](docs/CatalogRule.md) - [CatalogSyncRequest](docs/CatalogSyncRequest.md) @@ -578,16 +624,33 @@ Class | Method | HTTP request | Description - [Change](docs/Change.md) - [ChangeLoyaltyTierLevelEffectProps](docs/ChangeLoyaltyTierLevelEffectProps.md) - [ChangeProfilePassword](docs/ChangeProfilePassword.md) +- [CheckAchievementBlock](docs/CheckAchievementBlock.md) +- [CheckAchievementBlockAchievement](docs/CheckAchievementBlockAchievement.md) +- [CheckAttributeBlock](docs/CheckAttributeBlock.md) +- [CheckAttributeBlockBase](docs/CheckAttributeBlockBase.md) +- [CheckAudienceBlock](docs/CheckAudienceBlock.md) +- [CheckAudienceBlockAudience](docs/CheckAudienceBlockAudience.md) +- [CheckBudgetBlock](docs/CheckBudgetBlock.md) +- [CheckCouponBlock](docs/CheckCouponBlock.md) +- [CheckEventBlock](docs/CheckEventBlock.md) +- [CheckLoyaltyBalanceBlock](docs/CheckLoyaltyBalanceBlock.md) +- [CheckLoyaltyBalanceBlockProgram](docs/CheckLoyaltyBalanceBlockProgram.md) +- [CheckLoyaltyCardBlock](docs/CheckLoyaltyCardBlock.md) +- [CheckReferralBlock](docs/CheckReferralBlock.md) +- [CheckTierBlock](docs/CheckTierBlock.md) +- [CheckTierBlockTier](docs/CheckTierBlockTier.md) - [CodeGeneratorSettings](docs/CodeGeneratorSettings.md) - [Collection](docs/Collection.md) - [CollectionItem](docs/CollectionItem.md) - [CollectionWithoutPayload](docs/CollectionWithoutPayload.md) +- [ConfirmRisksRequest](docs/ConfirmRisksRequest.md) - [Coupon](docs/Coupon.md) - [CouponConstraints](docs/CouponConstraints.md) - [CouponCreatedEffectProps](docs/CouponCreatedEffectProps.md) - [CouponCreationJob](docs/CouponCreationJob.md) - [CouponDeletionFilters](docs/CouponDeletionFilters.md) - [CouponDeletionJob](docs/CouponDeletionJob.md) +- [CouponEligibilityInfo](docs/CouponEligibilityInfo.md) - [CouponEntity](docs/CouponEntity.md) - [CouponFailureSummary](docs/CouponFailureSummary.md) - [CouponLimitConfigs](docs/CouponLimitConfigs.md) @@ -601,13 +664,16 @@ Class | Method | HTTP request | Description - [CreateAchievement](docs/CreateAchievement.md) - [CreateAchievementV2](docs/CreateAchievementV2.md) - [CreateApplicationAPIKey](docs/CreateApplicationAPIKey.md) +- [CreateCouponBlock](docs/CreateCouponBlock.md) - [CreateCouponData](docs/CreateCouponData.md) - [CreateMCPKey](docs/CreateMCPKey.md) - [CreateManagementKey](docs/CreateManagementKey.md) +- [CreateReferralBlock](docs/CreateReferralBlock.md) - [CreateTemplateCampaign](docs/CreateTemplateCampaign.md) - [CreateTemplateCampaignResponse](docs/CreateTemplateCampaignResponse.md) - [CustomEffect](docs/CustomEffect.md) - [CustomEffectProps](docs/CustomEffectProps.md) +- [CustomerAchievement](docs/CustomerAchievement.md) - [CustomerActivityReport](docs/CustomerActivityReport.md) - [CustomerAnalytics](docs/CustomerAnalytics.md) - [CustomerInventory](docs/CustomerInventory.md) @@ -617,8 +683,10 @@ Class | Method | HTTP request | Description - [CustomerProfileEntity](docs/CustomerProfileEntity.md) - [CustomerProfileIntegrationRequestV2](docs/CustomerProfileIntegrationRequestV2.md) - [CustomerProfileIntegrationResponseV2](docs/CustomerProfileIntegrationResponseV2.md) +- [CustomerProfileReward](docs/CustomerProfileReward.md) - [CustomerProfileSearchQuery](docs/CustomerProfileSearchQuery.md) - [CustomerProfileUpdateV2Response](docs/CustomerProfileUpdateV2Response.md) +- [CustomerReward](docs/CustomerReward.md) - [CustomerSession](docs/CustomerSession.md) - [CustomerSessionV2](docs/CustomerSessionV2.md) - [DeductLoyaltyPoints](docs/DeductLoyaltyPoints.md) @@ -626,6 +694,8 @@ Class | Method | HTTP request | Description - [DeleteCouponsData](docs/DeleteCouponsData.md) - [DeleteLoyaltyTransactionsRequest](docs/DeleteLoyaltyTransactionsRequest.md) - [DeleteUserRequest](docs/DeleteUserRequest.md) +- [DigitalPass](docs/DigitalPass.md) +- [DiscardRisksRequest](docs/DiscardRisksRequest.md) - [Effect](docs/Effect.md) - [EffectEntity](docs/EffectEntity.md) - [EmailEntity](docs/EmailEntity.md) @@ -646,8 +716,15 @@ Class | Method | HTTP request | Description - [EventType](docs/EventType.md) - [EventV2](docs/EventV2.md) - [EventV3](docs/EventV3.md) +- [EventV3Connections](docs/EventV3Connections.md) +- [EventV3Entity](docs/EventV3Entity.md) +- [EventV3ReferralEntity](docs/EventV3ReferralEntity.md) +- [EventV3RequestEntity](docs/EventV3RequestEntity.md) +- [ExcludePriceObservationsRequest](docs/ExcludePriceObservationsRequest.md) - [Experiment](docs/Experiment.md) - [ExperimentCampaignCopy](docs/ExperimentCampaignCopy.md) +- [ExperimentConfidenceTimeline](docs/ExperimentConfidenceTimeline.md) +- [ExperimentConfidenceTimelineDataPoint](docs/ExperimentConfidenceTimelineDataPoint.md) - [ExperimentCopy](docs/ExperimentCopy.md) - [ExperimentCopyExperiment](docs/ExperimentCopyExperiment.md) - [ExperimentListResults](docs/ExperimentListResults.md) @@ -678,7 +755,10 @@ Class | Method | HTTP request | Description - [ExtendLoyaltyPointsExpiryDateEffectProps](docs/ExtendLoyaltyPointsExpiryDateEffectProps.md) - [ExtendedCoupon](docs/ExtendedCoupon.md) - [FeatureFlag](docs/FeatureFlag.md) +- [FeatureFlagUpdate](docs/FeatureFlagUpdate.md) - [FeaturesFeed](docs/FeaturesFeed.md) +- [FilterAndMapValuesSelectorStep](docs/FilterAndMapValuesSelectorStep.md) +- [FilterSelectorStep](docs/FilterSelectorStep.md) - [FuncArgDef](docs/FuncArgDef.md) - [FunctionDef](docs/FunctionDef.md) - [GenerateAuditLogSummary](docs/GenerateAuditLogSummary.md) @@ -692,11 +772,17 @@ Class | Method | HTTP request | Description - [GenerateRuleTitle](docs/GenerateRuleTitle.md) - [GenerateRuleTitleRule](docs/GenerateRuleTitleRule.md) - [GenerateUserSessionSummary](docs/GenerateUserSessionSummary.md) +- [GeoJSONGeometryCollection](docs/GeoJSONGeometryCollection.md) +- [GeoJSONMultiPolygon](docs/GeoJSONMultiPolygon.md) +- [GeoJSONPoint](docs/GeoJSONPoint.md) +- [GeoJSONPolygon](docs/GeoJSONPolygon.md) - [GetIntegrationCouponRequest](docs/GetIntegrationCouponRequest.md) - [Giveaway](docs/Giveaway.md) - [GiveawayPoolNotification](docs/GiveawayPoolNotification.md) - [GiveawayPoolNotificationData](docs/GiveawayPoolNotificationData.md) +- [GiveawayPoolReference](docs/GiveawayPoolReference.md) - [GiveawaysPool](docs/GiveawaysPool.md) +- [GroupBlock](docs/GroupBlock.md) - [HiddenConditionsEffects](docs/HiddenConditionsEffects.md) - [History](docs/History.md) - [IdentifiableEntity](docs/IdentifiableEntity.md) @@ -753,12 +839,17 @@ Class | Method | HTTP request | Description - [InlineResponse20051](docs/InlineResponse20051.md) - [InlineResponse20052](docs/InlineResponse20052.md) - [InlineResponse20053](docs/InlineResponse20053.md) +- [InlineResponse20054](docs/InlineResponse20054.md) +- [InlineResponse20055](docs/InlineResponse20055.md) +- [InlineResponse20056](docs/InlineResponse20056.md) +- [InlineResponse20056Catalog](docs/InlineResponse20056Catalog.md) - [InlineResponse2006](docs/InlineResponse2006.md) - [InlineResponse2007](docs/InlineResponse2007.md) - [InlineResponse2008](docs/InlineResponse2008.md) - [InlineResponse2009](docs/InlineResponse2009.md) - [InlineResponse201](docs/InlineResponse201.md) - [IntegrationCampaign](docs/IntegrationCampaign.md) +- [IntegrationCampaignBase](docs/IntegrationCampaignBase.md) - [IntegrationCoupon](docs/IntegrationCoupon.md) - [IntegrationCustomerProfileAudienceRequest](docs/IntegrationCustomerProfileAudienceRequest.md) - [IntegrationCustomerProfileAudienceRequestItem](docs/IntegrationCustomerProfileAudienceRequestItem.md) @@ -772,17 +863,19 @@ Class | Method | HTTP request | Description - [IntegrationHubConfig](docs/IntegrationHubConfig.md) - [IntegrationHubEventPayloadCouponBasedNotifications](docs/IntegrationHubEventPayloadCouponBasedNotifications.md) - [IntegrationHubEventPayloadCouponBasedNotificationsLimits](docs/IntegrationHubEventPayloadCouponBasedNotificationsLimits.md) -- [IntegrationHubEventPayloadLoyaltyProfileBasedNotification](docs/IntegrationHubEventPayloadLoyaltyProfileBasedNotification.md) - [IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification](docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md) - [IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction](docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction.md) - [IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification](docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.md) - [IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification](docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.md) - [IntegrationHubEventRecord](docs/IntegrationHubEventRecord.md) +- [IntegrationHubEventStatusUpdate](docs/IntegrationHubEventStatusUpdate.md) +- [IntegrationHubEventType](docs/IntegrationHubEventType.md) - [IntegrationHubFlow](docs/IntegrationHubFlow.md) - [IntegrationHubFlowConfig](docs/IntegrationHubFlowConfig.md) - [IntegrationHubFlowConfigResponse](docs/IntegrationHubFlowConfigResponse.md) - [IntegrationHubFlowResponse](docs/IntegrationHubFlowResponse.md) - [IntegrationHubFlowWithConfig](docs/IntegrationHubFlowWithConfig.md) +- [IntegrationHubInstance](docs/IntegrationHubInstance.md) - [IntegrationHubPaginatedEventPayload](docs/IntegrationHubPaginatedEventPayload.md) - [IntegrationProfileEntity](docs/IntegrationProfileEntity.md) - [IntegrationProfileEntityV3](docs/IntegrationProfileEntityV3.md) @@ -791,9 +884,11 @@ Class | Method | HTTP request | Description - [IntegrationState](docs/IntegrationState.md) - [IntegrationStateV2](docs/IntegrationStateV2.md) - [IntegrationStoreEntity](docs/IntegrationStoreEntity.md) +- [IntegrationUnlockRewardRequest](docs/IntegrationUnlockRewardRequest.md) - [InventoryCoupon](docs/InventoryCoupon.md) - [InventoryReferral](docs/InventoryReferral.md) - [ItemAttribute](docs/ItemAttribute.md) +- [JoinLoyaltyProgramEffectProps](docs/JoinLoyaltyProgramEffectProps.md) - [LabelTargetAudience](docs/LabelTargetAudience.md) - [LabelTargetNone](docs/LabelTargetNone.md) - [LedgerEntry](docs/LedgerEntry.md) @@ -805,6 +900,9 @@ Class | Method | HTTP request | Description - [LimitCounter](docs/LimitCounter.md) - [ListCampaignStoreBudgets](docs/ListCampaignStoreBudgets.md) - [ListCampaignStoreBudgetsStore](docs/ListCampaignStoreBudgetsStore.md) +- [ListCheckAttributeBlock](docs/ListCheckAttributeBlock.md) +- [ListWithCountCheckAttributeBlock](docs/ListWithCountCheckAttributeBlock.md) +- [LocationCheckAttributeBlock](docs/LocationCheckAttributeBlock.md) - [LoginParams](docs/LoginParams.md) - [Loyalty](docs/Loyalty.md) - [LoyaltyBalance](docs/LoyaltyBalance.md) @@ -832,9 +930,19 @@ Class | Method | HTTP request | Description - [LoyaltyProgramTransaction](docs/LoyaltyProgramTransaction.md) - [LoyaltySubLedger](docs/LoyaltySubLedger.md) - [LoyaltyTier](docs/LoyaltyTier.md) +- [MCPCompleteOAuthSession](docs/MCPCompleteOAuthSession.md) - [MCPKey](docs/MCPKey.md) +- [MCPOAuthClient](docs/MCPOAuthClient.md) +- [MCPOAuthCompleteResult](docs/MCPOAuthCompleteResult.md) +- [MCPOAuthProtectedResource](docs/MCPOAuthProtectedResource.md) +- [MCPOAuthServerMetadata](docs/MCPOAuthServerMetadata.md) +- [MCPOAuthSessionInfo](docs/MCPOAuthSessionInfo.md) +- [MCPOAuthToken](docs/MCPOAuthToken.md) +- [MCPOAuthTokenError](docs/MCPOAuthTokenError.md) +- [MCPOAuthTokenRequest](docs/MCPOAuthTokenRequest.md) - [ManagementKey](docs/ManagementKey.md) - [ManagerConfig](docs/ManagerConfig.md) +- [MapSelectorStep](docs/MapSelectorStep.md) - [MessageLogEntries](docs/MessageLogEntries.md) - [MessageLogEntry](docs/MessageLogEntry.md) - [MessageLogRequest](docs/MessageLogRequest.md) @@ -883,19 +991,23 @@ Class | Method | HTTP request | Description - [NewCustomerProfile](docs/NewCustomerProfile.md) - [NewCustomerSession](docs/NewCustomerSession.md) - [NewCustomerSessionV2](docs/NewCustomerSessionV2.md) +- [NewDigitalPass](docs/NewDigitalPass.md) - [NewEvent](docs/NewEvent.md) - [NewEventType](docs/NewEventType.md) +- [NewEventV3Entity](docs/NewEventV3Entity.md) - [NewExperiment](docs/NewExperiment.md) - [NewExperimentVariant](docs/NewExperimentVariant.md) - [NewExperimentVariantArray](docs/NewExperimentVariantArray.md) - [NewExternalInvitation](docs/NewExternalInvitation.md) - [NewGiveawaysPool](docs/NewGiveawaysPool.md) +- [NewIntegrationHubCoupons](docs/NewIntegrationHubCoupons.md) - [NewInternalAudience](docs/NewInternalAudience.md) - [NewInvitation](docs/NewInvitation.md) - [NewInviteEmail](docs/NewInviteEmail.md) - [NewLoyaltyProgram](docs/NewLoyaltyProgram.md) - [NewLoyaltyTier](docs/NewLoyaltyTier.md) - [NewMCPKey](docs/NewMCPKey.md) +- [NewMCPOAuthClient](docs/NewMCPOAuthClient.md) - [NewManagementKey](docs/NewManagementKey.md) - [NewMessageTest](docs/NewMessageTest.md) - [NewMultipleAudiencesItem](docs/NewMultipleAudiencesItem.md) @@ -911,6 +1023,7 @@ Class | Method | HTTP request | Description - [NewReturn](docs/NewReturn.md) - [NewRevisionVersion](docs/NewRevisionVersion.md) - [NewReward](docs/NewReward.md) +- [NewRiskNotification](docs/NewRiskNotification.md) - [NewRole](docs/NewRole.md) - [NewRoleV2](docs/NewRoleV2.md) - [NewRuleset](docs/NewRuleset.md) @@ -938,6 +1051,7 @@ Class | Method | HTTP request | Description - [OutgoingIntegrationTemplates](docs/OutgoingIntegrationTemplates.md) - [OutgoingIntegrationType](docs/OutgoingIntegrationType.md) - [OutgoingIntegrationTypes](docs/OutgoingIntegrationTypes.md) +- [PassthroughBlock](docs/PassthroughBlock.md) - [PatchItemCatalogAction](docs/PatchItemCatalogAction.md) - [PatchManyItemsCatalogAction](docs/PatchManyItemsCatalogAction.md) - [PendingActivePointsData](docs/PendingActivePointsData.md) @@ -959,7 +1073,11 @@ Class | Method | HTTP request | Description - [ProfileAudiencesChanges](docs/ProfileAudiencesChanges.md) - [ProjectedTier](docs/ProjectedTier.md) - [PromoteExperiment](docs/PromoteExperiment.md) +- [RedeemLoyaltyPointsBlock](docs/RedeemLoyaltyPointsBlock.md) +- [RedeemLoyaltyPointsBlockProgram](docs/RedeemLoyaltyPointsBlockProgram.md) - [RedeemReferralEffectProps](docs/RedeemReferralEffectProps.md) +- [RedeemableCoupon](docs/RedeemableCoupon.md) +- [ReduceSelectorStep](docs/ReduceSelectorStep.md) - [Referral](docs/Referral.md) - [ReferralConstraints](docs/ReferralConstraints.md) - [ReferralCreatedEffectProps](docs/ReferralCreatedEffectProps.md) @@ -970,15 +1088,29 @@ Class | Method | HTTP request | Description - [RemoveItemCatalogAction](docs/RemoveItemCatalogAction.md) - [RemoveManyItemsCatalogAction](docs/RemoveManyItemsCatalogAction.md) - [ReopenSessionResponse](docs/ReopenSessionResponse.md) +- [ReserveCouponBlock](docs/ReserveCouponBlock.md) - [ReserveCouponEffectProps](docs/ReserveCouponEffectProps.md) - [ResponseContentObject](docs/ResponseContentObject.md) - [ReturnIntegrationRequest](docs/ReturnIntegrationRequest.md) - [ReturnedCartItem](docs/ReturnedCartItem.md) +- [ReverseSelectorStep](docs/ReverseSelectorStep.md) +- [ReviewRisksRequest](docs/ReviewRisksRequest.md) - [Revision](docs/Revision.md) - [RevisionActivation](docs/RevisionActivation.md) - [RevisionActivationRequest](docs/RevisionActivationRequest.md) - [RevisionVersion](docs/RevisionVersion.md) - [Reward](docs/Reward.md) +- [RewardCatalogItem](docs/RewardCatalogItem.md) +- [RewardEligibility](docs/RewardEligibility.md) +- [RewardEligibilityFailureDetails](docs/RewardEligibilityFailureDetails.md) +- [RewardPointsRequired](docs/RewardPointsRequired.md) +- [RewardUnlockRejection](docs/RewardUnlockRejection.md) +- [RewardWithUnlocks](docs/RewardWithUnlocks.md) +- [Risk](docs/Risk.md) +- [RiskAffectedEntityItem](docs/RiskAffectedEntityItem.md) +- [RiskCriticalityUpdate](docs/RiskCriticalityUpdate.md) +- [RiskDetail](docs/RiskDetail.md) +- [RiskNotification](docs/RiskNotification.md) - [Role](docs/Role.md) - [RoleAssign](docs/RoleAssign.md) - [RoleMembership](docs/RoleMembership.md) @@ -996,15 +1128,22 @@ Class | Method | HTTP request | Description - [RollbackDiscountEffectProps](docs/RollbackDiscountEffectProps.md) - [RollbackIncreasedAchievementProgressEffectProps](docs/RollbackIncreasedAchievementProgressEffectProps.md) - [RollbackReferralEffectProps](docs/RollbackReferralEffectProps.md) +- [RollbackUseRewardEffectProps](docs/RollbackUseRewardEffectProps.md) - [Rule](docs/Rule.md) +- [RuleEligibility](docs/RuleEligibility.md) +- [RuleEligibilityFailureDetails](docs/RuleEligibilityFailureDetails.md) - [RuleFailureReason](docs/RuleFailureReason.md) - [RuleMetadata](docs/RuleMetadata.md) +- [RuleMetadataEligibility](docs/RuleMetadataEligibility.md) +- [RuleV2](docs/RuleV2.md) - [Ruleset](docs/Ruleset.md) +- [RulesetV2](docs/RulesetV2.md) - [SSOConfig](docs/SSOConfig.md) - [SamlConnection](docs/SamlConnection.md) - [SamlConnectionInternal](docs/SamlConnectionInternal.md) - [SamlConnectionMetadata](docs/SamlConnectionMetadata.md) - [SamlLoginEndpoint](docs/SamlLoginEndpoint.md) +- [ScalarCheckAttributeBlock](docs/ScalarCheckAttributeBlock.md) - [ScimBaseGroup](docs/ScimBaseGroup.md) - [ScimBaseUser](docs/ScimBaseUser.md) - [ScimBaseUserName](docs/ScimBaseUserName.md) @@ -1027,6 +1166,9 @@ Class | Method | HTTP request | Description - [ScimUser](docs/ScimUser.md) - [ScimUsersListResponse](docs/ScimUsersListResponse.md) - [SecondaryDeployment](docs/SecondaryDeployment.md) +- [SelectSelectorStep](docs/SelectSelectorStep.md) +- [Selector](docs/Selector.md) +- [SelectorValueMapRef](docs/SelectorValueMapRef.md) - [Session](docs/Session.md) - [SetDiscountEffectProps](docs/SetDiscountEffectProps.md) - [SetDiscountPerAdditionalCostEffectProps](docs/SetDiscountPerAdditionalCostEffectProps.md) @@ -1034,10 +1176,14 @@ Class | Method | HTTP request | Description - [SetDiscountPerItemEffectProps](docs/SetDiscountPerItemEffectProps.md) - [SetLoyaltyPointsExpiryDateEffectProps](docs/SetLoyaltyPointsExpiryDateEffectProps.md) - [ShowBundleMetadataEffectProps](docs/ShowBundleMetadataEffectProps.md) +- [ShowNotificationBlock](docs/ShowNotificationBlock.md) - [ShowNotificationEffectProps](docs/ShowNotificationEffectProps.md) - [SkuUnitAnalytics](docs/SkuUnitAnalytics.md) - [SkuUnitAnalyticsDataPoint](docs/SkuUnitAnalyticsDataPoint.md) - [SlotDef](docs/SlotDef.md) +- [SortSelectorStep](docs/SortSelectorStep.md) +- [SortSelectorStepField](docs/SortSelectorStepField.md) +- [StartAchievementProgressEffectProps](docs/StartAchievementProgressEffectProps.md) - [Store](docs/Store.md) - [StrikethroughChangedItem](docs/StrikethroughChangedItem.md) - [StrikethroughCustomEffectPerItemProps](docs/StrikethroughCustomEffectPerItemProps.md) @@ -1048,11 +1194,15 @@ Class | Method | HTTP request | Description - [StrikethroughSetDiscountPerItemMemberEffectProps](docs/StrikethroughSetDiscountPerItemMemberEffectProps.md) - [StrikethroughTrigger](docs/StrikethroughTrigger.md) - [SummaryCampaignStoreBudget](docs/SummaryCampaignStoreBudget.md) +- [SupportCustomerProfile](docs/SupportCustomerProfile.md) +- [SupportRequest](docs/SupportRequest.md) +- [SupportRequestInput](docs/SupportRequestInput.md) - [TalangAttribute](docs/TalangAttribute.md) - [TalangAttributeVisibility](docs/TalangAttributeVisibility.md) - [TemplateArgDef](docs/TemplateArgDef.md) - [TemplateDef](docs/TemplateDef.md) - [TemplateLimitConfig](docs/TemplateLimitConfig.md) +- [TemplateParameter](docs/TemplateParameter.md) - [Tier](docs/Tier.md) - [TierDowngradeData](docs/TierDowngradeData.md) - [TierDowngradeNotification](docs/TierDowngradeNotification.md) @@ -1066,16 +1216,30 @@ Class | Method | HTTP request | Description - [TierWillDowngradeNotificationTrigger](docs/TierWillDowngradeNotificationTrigger.md) - [TimePoint](docs/TimePoint.md) - [TransferLoyaltyCard](docs/TransferLoyaltyCard.md) +- [TriggerCustomEffectBlock](docs/TriggerCustomEffectBlock.md) +- [TriggerCustomEffectBlockCustomEffect](docs/TriggerCustomEffectBlockCustomEffect.md) +- [TriggerCustomEffectBlockTarget](docs/TriggerCustomEffectBlockTarget.md) +- [TriggerWebhookBlock](docs/TriggerWebhookBlock.md) +- [TriggerWebhookBlockWebhook](docs/TriggerWebhookBlockWebhook.md) - [TriggerWebhookEffectProps](docs/TriggerWebhookEffectProps.md) - [TwoFAConfig](docs/TwoFAConfig.md) +- [UnaryCheckAttributeBlock](docs/UnaryCheckAttributeBlock.md) +- [UnlockRewardEffectProps](docs/UnlockRewardEffectProps.md) - [UpdateAccount](docs/UpdateAccount.md) - [UpdateAchievement](docs/UpdateAchievement.md) +- [UpdateAchievementProgressBlock](docs/UpdateAchievementProgressBlock.md) +- [UpdateAchievementProgressBlockAchievement](docs/UpdateAchievementProgressBlockAchievement.md) - [UpdateAchievementV2](docs/UpdateAchievementV2.md) - [UpdateApplication](docs/UpdateApplication.md) - [UpdateApplicationAPIKey](docs/UpdateApplicationAPIKey.md) - [UpdateApplicationCIF](docs/UpdateApplicationCIF.md) - [UpdateAttributeEffectProps](docs/UpdateAttributeEffectProps.md) +- [UpdateAttributeValueBlock](docs/UpdateAttributeValueBlock.md) +- [UpdateAttributeValueBlockAttribute](docs/UpdateAttributeValueBlockAttribute.md) +- [UpdateAttributeValueBlockTarget](docs/UpdateAttributeValueBlockTarget.md) - [UpdateAudience](docs/UpdateAudience.md) +- [UpdateAudienceMembershipBlock](docs/UpdateAudienceMembershipBlock.md) +- [UpdateAudienceMembershipBlockAudience](docs/UpdateAudienceMembershipBlockAudience.md) - [UpdateBlueprint](docs/UpdateBlueprint.md) - [UpdateCampaign](docs/UpdateCampaign.md) - [UpdateCampaignCollection](docs/UpdateCampaignCollection.md) @@ -1099,19 +1263,26 @@ Class | Method | HTTP request | Description - [UpdatePriceType](docs/UpdatePriceType.md) - [UpdateReferral](docs/UpdateReferral.md) - [UpdateReferralBatch](docs/UpdateReferralBatch.md) +- [UpdateReward](docs/UpdateReward.md) +- [UpdateRiskNotification](docs/UpdateRiskNotification.md) - [UpdateRole](docs/UpdateRole.md) - [UpdateStore](docs/UpdateStore.md) +- [UpdateSupportRequest](docs/UpdateSupportRequest.md) - [UpdateUser](docs/UpdateUser.md) +- [UseRewardEffectProps](docs/UseRewardEffectProps.md) - [User](docs/User.md) - [UserEntity](docs/UserEntity.md) - [ValueMap](docs/ValueMap.md) - [Webhook](docs/Webhook.md) - [WebhookAuthentication](docs/WebhookAuthentication.md) +- [WebhookAuthenticationBaseBasic](docs/WebhookAuthenticationBaseBasic.md) +- [WebhookAuthenticationBaseCustom](docs/WebhookAuthenticationBaseCustom.md) - [WebhookAuthenticationDataBasic](docs/WebhookAuthenticationDataBasic.md) - [WebhookAuthenticationDataCustom](docs/WebhookAuthenticationDataCustom.md) - [WebhookAuthenticationWebhookRef](docs/WebhookAuthenticationWebhookRef.md) - [WebhookWithOutgoingIntegrationDetails](docs/WebhookWithOutgoingIntegrationDetails.md) - [WillAwardGiveawayEffectProps](docs/WillAwardGiveawayEffectProps.md) +- [WithinCheckAttributeBlock](docs/WithinCheckAttributeBlock.md) ## Authorization diff --git a/api/openapi.yaml b/api/openapi.yaml index d7750232..b1b480ba 100644 --- a/api/openapi.yaml +++ b/api/openapi.yaml @@ -26,73 +26,60 @@ security: - management_key: [] tags: - description: | - Operations for updating account information such as billing email addresses, inviting users, etc. + Represents account and user management, including billing email addresses and user invitations. name: Accounts and users - description: | - Achievements allow you to reward a customer profile for performing a number of specific actions or reaching a transactional milestone within a defined period. - + Represents achievements that reward a customer profile for performing a number of specific actions or reaching a transactional milestone within a defined period. For example, you can use achievements to award your customers when they purchase five cups of coffee in one week or when they purchase items worth $3000 in three months. + See the [docs](https://docs.talon.one/docs/product/achievements/overview) for more information. name: Achievements - description: | - An extra fee applied to the cart. For example, shipping fees or processing fees. - - See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-additional-costs). + Represents an extra fee applied to the cart, for example, shipping fees or processing fees. + See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-additional-costs) for more information. name: Additional costs - description: | - Analytics are used to retrieve statistical data about the performance of campaigns within an Application. + Represents analytics used to retrieve statistical data about the performance of campaigns within an Application. name: Analytics - description: | Represents an Application in the Campaign Manager. An Application is the target of every Integration API request to Talon.One. - One Application can hold various API keys used for Integration API requests. - - You may have multiple Applications within one account, - for example staging and production, or different international markets. - - See the [docs](https://docs.talon.one/docs/product/applications/overview). + You may have multiple Applications within one account, for example staging and production, or different international markets. + See the [docs](https://docs.talon.one/docs/product/applications/overview) for more information. name: Applications - description: | - Represents a piece of information related to one of the entities avaialbe in the Campaign Manager. Use - them to create highly customized rules. - - See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes). + Represents a piece of information related to one of the entities available in the Campaign Manager. Use them to create highly customized rules. + See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) for more information. name: Attributes - description: | Represents lists of customer profiles that allow you to target specific groups of customers in your campaigns. Audiences can be synced from customer data platforms or created directly in Talon.One. - - See the [docs](https://docs.talon.one/docs/product/audiences/overview). + See the [docs](https://docs.talon.one/docs/product/audiences/overview) for more information. name: Audiences - description: | Represents the campaign access groups you can create in your Applications to organize your campaigns based on the type of campaign or the team in charge. - See the [docs](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups). + See the [docs](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups) for more information. name: Campaign access groups - description: | Represents templates used to generate campaigns from. name: Campaign templates - description: | - Represents the primary resource used to control the behavior of the Talon.One Rule Engine. - They combine rulesets, coupons, and limits into a single unit. - - See the [docs](https://docs.talon.one/docs/product/campaigns/overview). + Represents the primary resource used to control the behavior of the Talon.One Rule Engine. They combine rulesets, coupons, and limits into a single unit. + See the [docs](https://docs.talon.one/docs/product/campaigns/overview) for more information. name: Campaigns - description: | Represents a catalog of cart items with unique SKUs. Cart item catalogs allow you to synchronize your entire inventory with Talon.One. - - See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). + See the [docs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs) for more information. name: Catalogs - description: | Represents a collection of arbitrary values that you can use inside rules. For example, a list of SKUs. - - See the [docs](https://docs.talon.one/docs/product/campaigns/managing-collections). + See the [docs](https://docs.talon.one/docs/product/campaigns/managing-collections) for more information. name: Collections - description: | - Coupons are unique codes belonging to a particular campaign. They don't define any behavior on their own. + Represents unique codes belonging to a particular campaign. Coupons don't define any behavior on their own. Instead the campaign ruleset can include rules that validate coupons and carry out particular effects. - - See the [docs](https://docs.talon.one/docs/product/campaigns/coupons/coupon-page-overview). + See the [docs](https://docs.talon.one/docs/product/campaigns/coupons/coupon-page-overview) for more information. name: Coupons - description: | Represents the data of a customer, including sessions and events used for reporting and debugging in the Campaign Manager. @@ -102,45 +89,39 @@ tags: name: Customer profiles - description: | Represents the data related to a customer session. Typically, a customer session is the value and content of the customer's cart. - Sessions can be anonymous or linked to a customer profile and they have a life cycle from `open` to `closed`. In general, a session is closed when the customer completes the checkout step. - - Sessions are a key concept of Talon.One. We strongly recommend you read the [documentation about customer sessions](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + Sessions are a key concept of Talon.One. We strongly recommend you read the [docs](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions) for more information. name: Customer sessions - description: | Represents a single occurrence of a specific customer action, for example, updating the cart or signing up for a newsletter. - - There are 2 types of events: - - **Built-in events:** They are triggered by various endpoints, such as the [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint. [Learn more](https://docs.talon.one/docs/dev/concepts/entities/events). - - **Custom events:** They are triggered by the [Track event](https://docs.talon.one/integration-api#tag/Events/operation/trackEventV2) endpoint. + There are 2 types of [events](https://docs.talon.one/docs/dev/concepts/entities/events): + - **Built-in events:** They are triggered by various endpoints, such as + the [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) + endpoint. [Learn more](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events). + - **Custom events:** They are triggered by the [Track advanced event](https://docs.talon.one/integration-api#tag/Events/operation/trackEventV3) endpoint. [Learn more](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). name: Events - description: | Represents an A/B testing configuration within a campaign that splits customer sessions across multiple variants to compare rule effects against each other. name: Experiments - description: | Represents a program that rewards customers with giveaways, such as free gift cards. - - See the [docs](https://docs.talon.one/docs/product/giveaways/overview). + See the [docs](https://docs.talon.one/docs/product/giveaways/overview) for more information. name: Giveaways - description: | - Operations to query the Talon.One logs. They contain all incoming and outgoing requests. + Represents the Talon.One logs, which contain all incoming and outgoing requests. name: Logs - description: | Represents loyalty programs or concepts related to them. - - Loyalty programs can be _profile-based_ or _card-based_, depending on whether loyalty points are linked - to [customer profiles](https://docs.talon.one/docs/product/applications/displaying-customer-profiles) or [loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview). - - See [the Product docs](https://docs.talon.one/docs/product/loyalty-programs/overview) for more information. + Loyalty programs can be _profile-based_ or _card-based_, depending on whether loyalty points are linked to [customer profiles](https://docs.talon.one/docs/product/applications/displaying-customer-profiles) or [loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview). + See [the docs](https://docs.talon.one/docs/product/loyalty-programs/overview) for more information. name: Loyalty - description: | - Represents loyalty cards. - - [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow your customers to collect and spend loyalty points within a card-based loyalty program. + Represents loyalty cards, which allow your customers to collect and spend loyalty points within a card-based loyalty program. + See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) for more information. name: Loyalty cards - description: | - A referral is a code shared between a customer and a prospect. + Represents a referral code shared between a customer (advocate) and a prospect (friend). A referral is defined by: - an advocate: person who invited their friend via referral program. @@ -149,6 +130,10 @@ tags: See the [docs](https://docs.talon.one/docs/product/campaigns/referrals/referral-overview). name: Referrals +- description: | + Represents rewards. You can create a reward and manage its configuration to make it available for customers. + See the [docs](https://docs.talon.one/docs/product/rewards/overview) for more information. + name: Rewards - description: | Represents a set of permissions assigned to a user. @@ -168,9 +153,9 @@ tags: ruleset. name: Value maps - description: | - A way to send information from Talon.One to the URI of your choice. + Represents webhooks, which send information from Talon.One to the URI of your choice. - See the [docs](https://docs.talon.one/docs/dev/getting-started/webhooks). + See the [docs](https://docs.talon.one/docs/dev/getting-started/webhooks) for more information. name: Webhooks paths: /v2/customer_sessions/{customerSessionId}: @@ -189,6 +174,7 @@ paths: 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). in: path name: customerSessionId required: true @@ -218,6 +204,15 @@ paths: summary: Get customer session tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full details of a specific customer session by its integration ID, including cart items, applied effects, profile data, and session state. + Use this when the user wants to inspect what happened during a specific session — what coupons or referrals were used, what effects were triggered, and what the cart looked like. + Do not use this tool to list sessions; use list_application_sessions to search and browse sessions first; use get_application_session to retrieve a session by its internal numeric ID. + - applicationId is required; call get_applications first if it is unknown. + - customerSessionId is required; this is the integration ID set when the session was created, visible in the Campaign Manager's Sessions menu or via list_application_sessions. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json put: description: | @@ -286,6 +281,7 @@ paths: 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). in: path name: customerSessionId required: true @@ -346,6 +342,7 @@ paths: summary: Update customer session tags: - integration + x-idempotent: true x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -361,11 +358,6 @@ paths: > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). - - > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: - > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. - > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. - > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. operationId: returnCartItems parameters: - description: | @@ -421,6 +413,7 @@ paths: summary: Return cart items tags: - integration + x-idempotent: true x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -506,6 +499,7 @@ paths: summary: Reopen customer session tags: - integration + x-idempotent: true x-accepts: application/json /v2/customer_profiles/{integrationId}: put: @@ -520,6 +514,9 @@ paths: > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. + > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and + > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions + > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. @@ -533,6 +530,7 @@ paths: - 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). in: path name: integrationId required: true @@ -600,6 +598,7 @@ paths: summary: Update customer profile tags: - integration + x-idempotent: true x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -645,6 +644,12 @@ paths: schema: $ref: '#/components/schemas/MultipleCustomerProfileIntegrationResponseV2' description: OK + "204": + content: + application/json: + schema: + type: string + description: No content "400": content: application/json: @@ -662,6 +667,7 @@ paths: summary: Update multiple customer profiles tags: - integration + x-idempotent: true x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -735,13 +741,17 @@ paths: /v2/audiences/{audienceId}: delete: description: | - Delete an audience created by a third-party integration. + Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). + + The audience isn't deleted if any experiment variant uses it. + The response identifies each blocking experiment by its Campaign + Manager path. operationId: deleteAudienceV2 parameters: - description: The ID of the audience. @@ -773,6 +783,24 @@ paths: schema: $ref: '#/components/schemas/ErrorResponseWithStatus' description: Not found + "409": + content: + application/json: + example: + message: Audience 'VIP customers' is used by the following experiments + and cannot be deleted. + errors: + - title: Experiment + details: Experiment 7 uses audience 10 + source: + resource: /applications/42/experiments/7 + StatusCode: 409 + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: | + Conflict. The audience is used by one or more experiments. + Each `errors[].source.resource` value contains the Campaign Manager path + of a blocking experiment. security: - api_key_v1: [] summary: Delete audience @@ -1195,6 +1223,19 @@ paths: schema: format: date-time type: string + - description: Filter results to campaigns linked to the specified store ID. + in: query + name: storeId + schema: + format: int64 + type: integer + - description: Filter results to campaigns linked to the specified audience + ID. + in: query + name: audienceId + schema: + format: int64 + type: integer responses: "200": content: @@ -1229,31 +1270,24 @@ paths: /v2/events: post: description: | - Triggers a custom event. + Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: - 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) - in the Campaign Manager. - 1. Update or create a rule to check for this event. - 1. Trigger the event with this endpoint. After you have successfully sent an - event to Talon.One, you can list the received events in the **Events** view - in the Campaign Manager. + 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. + 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. + 1. Trigger the event with this endpoint. - Talon.One also offers a set of [built-in - events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure - you do not create a custom event when you can use a built-in event. + You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. - For example, use this endpoint to trigger an event when a customer shares a - link to a product. - - See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). + For example, you can use this endpoint to trigger an event when a customer shares a + link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. - > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). - > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. + > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). + > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. operationId: trackEventV2 parameters: - description: | @@ -1292,6 +1326,12 @@ paths: schema: $ref: '#/components/schemas/IntegrationEventV2Response' description: OK + "204": + content: + application/json: + schema: + type: string + description: No content "400": content: application/json: @@ -1310,12 +1350,13 @@ paths: schema: type: object description: Too many requests or limit reached - Avoid parallel requests. - See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). + See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). security: - api_key_v1: [] summary: Track event tags: - integration + x-idempotent: true x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -1621,10 +1662,12 @@ paths: Return all customers that have this coupon marked as reserved. This includes hard and soft reservations. operationId: getReservedCustomers parameters: - - description: "The code of the coupon.\n\n**Important:** The coupon code requires\ - \ [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) \nif\ - \ it contains special characters.\nFor example, you must encode `SUMMER25%OFF`\ - \ as `SUMMER25%25OFF`.\n" + - description: | + The code of the coupon. + + **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) + if it contains special characters. + For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. in: path name: couponValue required: true @@ -1660,6 +1703,15 @@ paths: summary: List customers that have this coupon reserved tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all customer profiles that have a specific coupon code marked as reserved, including both hard and soft reservations. + Use this when the user wants to know which customers have reserved a given coupon, or to audit reservation status before taking action on a coupon code. + Do not use this tool to check whether a coupon is valid or redeemable; use check_coupon_status for that purpose. + - applicationId is required; call get_applications first if it is unknown. + - couponValue is required; URL-encode the coupon code if it contains special characters (e.g., encode 'SUMMER25%OFF' as 'SUMMER25%25OFF'). + - If a 404 error occurs, inform the user that no reservations were found for the given coupon code and suggest verifying the code value. x-accepts: application/json /v1/customer_profiles/{integrationId}/inventory: get: @@ -1710,6 +1762,12 @@ paths: name: achievements schema: type: boolean + - description: Set to `true` to include `unlocked` rewards that have not been + `used` in the response. + in: query + name: unlockedRewards + schema: + type: boolean responses: "200": content: @@ -1734,6 +1792,16 @@ paths: summary: List customer data tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a comprehensive inventory of all entities associated with a customer profile by their integration ID, including profile data, referral codes, loyalty points, loyalty cards, reserved coupons, giveaways, and achievements. + Use this when the user wants a full picture of what a customer has — their loyalty balances, reserved or redeemed coupons, referral codes, and achievement progress — all in a single call identified by the customer's integration ID. + Do not use this tool to retrieve paginated transaction histories; use get_loyalty_balances or get_loyalty_ledger for detailed loyalty data, or get_customer_achievements for paginated achievement progress. + - applicationId is required; call get_applications first if it is unknown. + - integrationId is required; this is the external identifier set in your integration (not the internal numeric customer ID used by get_application_customer). + - All section flags (profile, referrals, coupons, loyalty, giveaways, achievements) default to false; set the relevant ones to true to include those sections in the response — omitting all flags returns a minimal response. + - If a 404 error occurs, inform the user the customer profile was not found and suggest verifying the integration ID with list_application_customers. x-accepts: application/json /v1/customer_profiles/{integrationId}/achievements: get: @@ -1851,6 +1919,17 @@ paths: summary: List customer's available achievements tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all achievements available to a specific customer profile and their current progress in each, with optional filtering by campaign, achievement ID, achievement status, or customer progress status. + Use this when the user wants to see which achievements a customer is working toward, what their progress is, or which ones they have completed. + Do not use this tool to retrieve the configuration of an achievement (rules, targets, periods); use get_achievement for that purpose; use get_customer_achievement_history for the detailed history of a specific achievement. + - applicationId is required; call get_applications first if it is unknown. + - integrationId is required; this is the external integration identifier for the customer, not the internal numeric ID. + - If no campaign or achievement filters are provided, data for all active achievements in the application is returned. + - Comma-separated filter parameters (campaignIds, achievementIds, achievementStatus, currentProgressStatus) accept multiple values separated by commas (e.g., '11,20'). + - If a 404 error occurs, inform the user the customer profile was not found and suggest verifying the integration ID. x-accepts: application/json /v1/customer_profiles/{integrationId}/achievements/{achievementId}: get: @@ -1951,6 +2030,17 @@ paths: summary: List customer's achievement history tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full progress history of a specific customer in a specific achievement, including all progress periods with their status, start dates, completion dates, and expiry dates. + Use this when the user wants to audit a customer's full history within one achievement — for example to see how many times they completed it, whether any attempts expired, or what their progress looked like over time. + Do not use this tool to list all achievements available to a customer; use get_customer_achievements for an overview of all achievement progress; use get_achievement for the achievement configuration itself. + - applicationId is required; call get_applications first if it is unknown. + - Both integrationId and achievementId are required; call get_customer_achievements to find achievement IDs if unknown. + - progressStatus accepts comma-separated values (e.g., 'inprogress,completed') to filter by multiple statuses at once. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 404 error occurs, inform the user the customer profile or achievement was not found and suggest verifying both IDs. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/balances: get: @@ -2037,6 +2127,17 @@ paths: summary: Get card's point balances tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves point balances for a specific loyalty card within a card-based loyalty program, including active, pending, and expired totals, with optional date and subledger filtering. + Use this when the user wants to check the current balance on a loyalty card, verify its point totals by subledger, or inspect balances up to a specific date. + Do not use this tool for profile-based loyalty programs; use get_loyalty_balances for profile-based balance lookups; use get_loyalty_card_points for paginated individual point entries on a card. + - Both loyaltyProgramId and loyaltyCardId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is card-based only; it does not apply to profile-based loyalty programs. + - If no filters are applied, all current balances for the given loyalty card are returned. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/balances: get: @@ -2147,6 +2248,17 @@ paths: summary: Get customer's loyalty balances tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves loyalty ledger balances for a specific customer profile within a loyalty program, including active, pending, and expired point totals, with optional tier and subledger filtering. + Use this when the user wants to check how many points a customer has, verify their tier status, or inspect balances up to a specific date. + Do not use this tool to retrieve the full transaction history for a profile; use get_loyalty_profile_transactions for the ledger log. + - Both loyaltyProgramId and integrationId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is profile-based only; it does not apply to card-based loyalty programs. + - If no filters are applied, all current balances for the integration ID are returned. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_balances: get: @@ -2157,8 +2269,10 @@ paths: You can filter balances by date and subledger ID, and include tier-related information in the response. - > [!note] If no filtering options are applied, you retrieve all loyalty - > balances on the current date for the given integration ID. + > [!note] **Note** + > - For most use cases, especially real-time integrations, use the Integration API endpoint: + [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). + > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances @@ -2257,7 +2371,7 @@ paths: schema: $ref: '#/components/schemas/ErrorResponseWithStatus' description: Not found - summary: Get customer's loyalty balances + summary: Get customer's loyalty balances (Management API) tags: - management x-accepts: application/json @@ -2426,6 +2540,18 @@ paths: summary: List card's transactions tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a paginated, chronological log of loyalty transactions for a specific loyalty card within a card-based loyalty program, with optional filtering by transaction type, date range, or activation status. + Use this when the user wants a complete audit trail of point movements for a card — earned, redeemed, expired, and manually adjusted entries — rather than a snapshot of current balances. + Do not use this tool to view aggregate point balances; use get_loyalty_card_balances for summarized totals; use get_loyalty_card_points for a list of individual unused point entries on a card. + - Both loyaltyProgramId and loyaltyCardId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is card-based only; it does not apply to profile-based loyalty programs. + - If no filters are applied, the last 50 transactions for the given loyalty card are returned. + - Array-valued parameters (subledgerId, customerSessionIDs, transactionUUIDs) are not supported in this tool; use the management API directly if multi-value filtering is required. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/transactions: get: @@ -2491,11 +2617,21 @@ paths: type: string type: array style: form - - description: The ID of the subledger by which we filter the data. + - description: | + Filter the results by a list of subledger IDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?subledgerId=id1&subledgerId=id2`. + + The response contains only data associated with the specified subledgers. + explode: true in: query name: subledgerId schema: - type: string + items: + type: string + type: array + style: form - description: | Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. @@ -2589,6 +2725,17 @@ paths: summary: List customer's loyalty transactions tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves paginated loyalty transaction logs for a specific customer profile within a profile-based loyalty program, with filtering by date range, transaction type, subledger, and activation status. + Use this when the user wants to audit the full transaction history for a customer — for example to trace when points were earned, spent, or expired, or to filter by a specific session or date window. + Do not use this tool to view aggregate balances; use get_loyalty_balances for summarized point totals, or list_loyalty_program_transactions to audit transactions across all profiles in a program. + - Both loyaltyProgramId and integrationId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is profile-based only; it does not apply to card-based loyalty programs. + - If no filters are applied, the last 50 transactions for the integration ID are returned. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_transactions: get: @@ -2599,9 +2746,11 @@ paths: You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. - > [!note] To retrieve all loyalty program transaction logs in a given - > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) - > endpoint. + > [!note] **Note** + > - For most use cases, especially real-time integrations, use the Integration API endpoint: + > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). + > - To retrieve all loyalty program transaction logs in a given loyalty program, use the + > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. operationId: getLoyaltyProgramProfileLedgerTransactions parameters: - description: | @@ -2748,7 +2897,7 @@ paths: schema: $ref: '#/components/schemas/ErrorResponseWithStatus' description: Not found - summary: List customer's loyalty transactions + summary: List customer's loyalty transactions (Management API) tags: - management x-accepts: application/json @@ -2816,166 +2965,21 @@ paths: x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json - /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/points: - get: + /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join: + post: description: | - Get paginated results of loyalty points for a given loyalty card identifier in a card-based loyalty program. This endpoint returns only the balances of unused points on a loyalty card. - - You can filter points by status: - - `active`: Points ready to be redeemed. - - `pending`: Points with a start date in the future. - - `expired`: Points with an expiration date in the past. - operationId: getLoyaltyCardPoints - parameters: - - description: | - Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with - the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. - in: path - name: loyaltyProgramId - required: true - schema: - format: int64 - type: integer - - description: | - Identifier of the loyalty card. You can get the identifier with - the [List loyalty - cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) - endpoint. - - **Important**: The loyalty card ID requires [URL - encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it - contains special characters. For example, you must encode `NewCard2026%` - as `NewCard2026%25`. - in: path - name: loyaltyCardId - required: true - schema: - maxLength: 108 - minLength: 4 - type: string - - description: Filter points based on their status. - in: query - name: status - schema: - default: active - enum: - - active - - pending - - expired - type: string - - description: Filter results by one or more subledger IDs. Must be exact match. - explode: true - in: query - name: subledgerId - schema: - items: - type: string - type: array - style: form - - description: | - Filter the results by a list of customer session IDs. - - To include multiple IDs, repeat the parameter for each one, for example, - `?customerSessionIDs=id1&customerSessionIDs=id2`. - - The response contains only data associated with the specified sessions. - explode: true - in: query - name: customerSessionIDs - schema: - items: - type: string - type: array - style: form - - description: | - Filter the results by a list of transaction UUIDs. - - To include multiple IDs, repeat the parameter for each one, for example, - `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. - - The response contains only data associated with the specified transactions. - explode: true - in: query - name: transactionUUIDs - schema: - items: - type: string - type: array - style: form - - description: The number of items in the response. - in: query - name: pageSize - schema: - default: 50 - format: int64 - maximum: 1000 - minimum: 1 - type: integer - - description: The number of items to skip when paging through large result - sets. - in: query - name: skip - schema: - format: int64 - type: integer - - description: | - The field by which results should be sorted. You can enter one of the following values: + Join a customer profile to the specified loyalty program. - - `startDate`: Sorts the results by the start date of the points. - - `expiryDate`: Sorts the results by the expiry date of the points. + If the customer profile does not exist, it will be created first using the + provided `integrationId`, then joined to the loyalty program. - By default, results are sorted in ascending order. - To sort them in descending order, prefix the field name with `-`. - - **Note:** You can only sort by one field at a time. - in: query - name: sort - schema: - enum: - - startDate - - expiryDate - type: string - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/inline_response_200_6' - description: OK - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponseWithStatus' - description: Bad request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponseWithStatus' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponseWithStatus' - description: Not found - security: - - api_key_v1: [] - summary: List card's unused loyalty points - tags: - - integration - x-accepts: application/json - /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/points: - get: - description: | - Get paginated results of loyalty points for a given Integration ID in the specified profile-based loyalty program. This endpoint returns only the balances of unused points linked to a customer profile. + > [!note] This endpoint only works with profile-based loyalty programs. - You can filter points by status: - - `active`: Points ready to be redeemed. - - `pending`: Points with a start date in the future. - - `expired`: Points with an expiration date in the past. - operationId: getLoyaltyProgramProfilePoints + **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. + operationId: joinLoyaltyProgram parameters: - description: | Identifier of the profile-based loyalty program. You can get the ID with @@ -2987,89 +2991,328 @@ paths: format: int64 type: integer - description: | - 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. + 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. in: path name: integrationId required: true schema: type: string - - description: Filter points based on their status. - in: query - name: status - schema: - default: active - enum: - - active - - pending - - expired - type: string - - description: The ID of the subledger by which we filter the data. - in: query - name: subledgerId - schema: - type: string - - description: "Filter the results by a list of customer session IDs. \n\nTo\ - \ include multiple IDs, repeat the parameter for each one, for example,\ - \ \n`?customerSessionIDs=id1&customerSessionIDs=id2`.\n\nThe response contains\ - \ only data associated with the specified sessions.\n" - explode: true - in: query - name: customerSessionIDs - schema: - items: - type: string - type: array - style: form - - description: "Filter the results by a list of transaction UUIDs.\n\nTo include\ - \ multiple IDs, repeat the parameter for each one, for example, \n`?transactionUUIDs=uuid1&transactionUUIDs=uuid2`.\n\ - \nThe response contains only data associated with the specified transactions.\n" - explode: true - in: query - name: transactionUUIDs - schema: - items: - type: string - type: array - style: form - - description: The number of items in the response. - in: query - name: pageSize - schema: - default: 50 - format: int64 - maximum: 1000 - minimum: 1 - type: integer - - description: The number of items to skip when paging through large result - sets. - in: query - name: skip - schema: - format: int64 - type: integer - - description: "The field by which results should be sorted. You can enter one\ - \ of the following values:\n\n- `startDate`: Sorts the results by the start\ - \ date of the points.\n- `expiryDate`: Sorts the results by the expiry date\ - \ of the points.\n\nBy default, results are sorted in ascending order. \n\ - To sort them in descending order, prefix the field name with `-`.\n\n**Note:**\ - \ You can only sort by one field at a time.\n" - in: query - name: sort - schema: - enum: - - startDate - - expiryDate - type: string responses: "200": - content: - application/json: - schema: - $ref: '#/components/schemas/inline_response_200_7' + content: {} + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + security: + - api_key_v1: [] + summary: Join customer profile to loyalty program + tags: + - integration + x-accepts: application/json + /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/points: + get: + description: | + Get paginated results of loyalty points for a given loyalty card identifier in a card-based loyalty program. This endpoint returns only the balances of unused points on a loyalty card. + + You can filter points by status: + - `active`: Points ready to be redeemed. + - `pending`: Points with a start date in the future. + - `expired`: Points with an expiration date in the past. + operationId: getLoyaltyCardPoints + parameters: + - description: | + Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with + the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. + in: path + name: loyaltyProgramId + required: true + schema: + format: int64 + type: integer + - description: | + Identifier of the loyalty card. You can get the identifier with + the [List loyalty + cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) + endpoint. + + **Important**: The loyalty card ID requires [URL + encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it + contains special characters. For example, you must encode `NewCard2026%` + as `NewCard2026%25`. + in: path + name: loyaltyCardId + required: true + schema: + maxLength: 108 + minLength: 4 + type: string + - description: Filter points based on their status. + in: query + name: status + schema: + default: active + enum: + - active + - pending + - expired + type: string + - description: Filter results by one or more subledger IDs. Must be exact match. + explode: true + in: query + name: subledgerId + schema: + items: + type: string + type: array + style: form + - description: | + Filter the results by a list of customer session IDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?customerSessionIDs=id1&customerSessionIDs=id2`. + + The response contains only data associated with the specified sessions. + explode: true + in: query + name: customerSessionIDs + schema: + items: + type: string + type: array + style: form + - description: | + Filter the results by a list of transaction UUIDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. + + The response contains only data associated with the specified transactions. + explode: true + in: query + name: transactionUUIDs + schema: + items: + type: string + type: array + style: form + - description: The number of items in the response. + in: query + name: pageSize + schema: + default: 50 + format: int64 + maximum: 1000 + minimum: 1 + type: integer + - description: The number of items to skip when paging through large result + sets. + in: query + name: skip + schema: + format: int64 + type: integer + - description: | + The field by which results should be sorted. You can enter one of the following values: + + - `startDate`: Sorts the results by the start date of the points. + - `expiryDate`: Sorts the results by the expiry date of the points. + + By default, results are sorted in ascending order. + To sort them in descending order, prefix the field name with `-`. + + **Note:** You can only sort by one field at a time. + in: query + name: sort + schema: + enum: + - startDate + - expiryDate + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/inline_response_200_6' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + security: + - api_key_v1: [] + summary: List card's unused loyalty points + tags: + - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a paginated list of unused loyalty point entries for a specific loyalty card within a card-based loyalty program, with optional filtering by status, subledger, or sorting by date. + Use this when the user wants to inspect individual point entries on a card — for example, to see which points are active, pending, or expired — rather than viewing aggregate totals. + Do not use this tool to retrieve aggregate point balances; use get_loyalty_card_balances for summarized balance totals; use get_loyalty_card_transactions for a chronological transaction history on a card. + - Both loyaltyProgramId and loyaltyCardId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is card-based only; it does not apply to profile-based loyalty programs. + - Array-valued parameters (subledgerId, customerSessionIDs, transactionUUIDs) are not supported in this tool; use the management API directly if multi-value filtering is required. + - Convert any relative date phrases into RFC3339 strings before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. + x-accepts: application/json + /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/points: + get: + description: | + Get paginated results of loyalty points for a given Integration ID in the specified profile-based loyalty program. This endpoint returns only the balances of unused points linked to a customer profile. + + You can filter points by status: + - `active`: Points ready to be redeemed. + - `pending`: Points with a start date in the future. + - `expired`: Points with an expiration date in the past. + operationId: getLoyaltyProgramProfilePoints + parameters: + - description: | + 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. + in: path + name: loyaltyProgramId + required: true + schema: + format: int64 + type: integer + - description: | + 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. + in: path + name: integrationId + required: true + schema: + type: string + - description: Filter points based on their status. + in: query + name: status + schema: + default: active + enum: + - active + - pending + - expired + type: string + - description: | + Filter the results by a list of subledger IDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?subledgerId=id1&subledgerId=id2`. + + The response contains only data associated with the specified subledgers. + explode: true + in: query + name: subledgerId + schema: + items: + type: string + type: array + style: form + - description: | + Filter the results by a list of customer session IDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?customerSessionIDs=id1&customerSessionIDs=id2`. + + The response contains only data associated with the specified sessions. + explode: true + in: query + name: customerSessionIDs + schema: + items: + type: string + type: array + style: form + - description: | + Filter the results by a list of transaction UUIDs. + + To include multiple IDs, repeat the parameter for each one, for example, + `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. + + The response contains only data associated with the specified transactions. + explode: true + in: query + name: transactionUUIDs + schema: + items: + type: string + type: array + style: form + - description: The number of items in the response. + in: query + name: pageSize + schema: + default: 50 + format: int64 + maximum: 1000 + minimum: 1 + type: integer + - description: The number of items to skip when paging through large result + sets. + in: query + name: skip + schema: + format: int64 + type: integer + - description: | + The field by which results should be sorted. You can enter one of the following values: + + - `startDate`: Sorts the results by the start date of the points. + - `expiryDate`: Sorts the results by the expiry date of the points. + + By default, results are sorted in ascending order. + To sort them in descending order, prefix the field name with `-`. + + **Note:** You can only sort by one field at a time. + in: query + name: sort + schema: + enum: + - startDate + - expiryDate + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/inline_response_200_7' description: OK "400": content: @@ -3094,6 +3337,15 @@ paths: summary: List customer's unused loyalty points tags: - integration + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves paginated unused loyalty point entries for a specific customer profile within a profile-based loyalty program, filterable by point status, subledger, and sort order. + Use this when the user wants to inspect individual point records for a customer — for example to see which points are active, which are pending, or which have expired. + Do not use this tool to retrieve aggregate balance totals; use get_loyalty_balances for summarized point counts. + - Both loyaltyProgramId and integrationId are required; call list_loyalty_programs first if the program ID is unknown. + - This endpoint is profile-based only; it does not apply to card-based loyalty programs. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications: get: @@ -3134,6 +3386,15 @@ paths: summary: List Applications tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all applications configured in the current account, including their names, IDs, timezone, and currency settings. + Use this as the first step in any workflow that requires an applicationId, or when the user asks to see, find, or browse their applications. + Do not use this tool to create, update, or delete applications; it is a read-only listing endpoint. + - If the user refers to an application by name, call this tool first to resolve the correct applicationId before proceeding. + - Use pageSize and skip to paginate through large account portfolios; default ordering is by creation date. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}: get: @@ -3158,6 +3419,14 @@ paths: summary: Get Application tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a single application by its unique numeric ID, returning its full configuration including name, timezone, currency, and feature settings. + Use this when you already have an applicationId and need the complete details of that specific application. + Do not use this tool to browse or search applications; use get_applications for discovery and to resolve names to IDs. + - If the user refers to an application by name, call get_applications first to resolve the correct applicationId, then call this tool. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/campaigns: get: @@ -3224,11 +3493,15 @@ paths: schema: type: string - description: | - Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the "name" query parameter, a logical OR will be performed to search both tags and name for the provided values + Filter results performing case-insensitive matching against the tags of the campaign. + explode: true in: query name: tags schema: - type: string + items: + type: string + type: array + style: form - description: Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. @@ -3312,6 +3585,17 @@ paths: summary: List campaigns tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all campaigns for an application including status, schedules, and budget counters. + Use this to check live eligibility for customers or to audit campaign configurations. + Do not use this tool for creating campaigns or pulling deep analytics. + - Provide applicationId first; if missing, use the search tool to find it. + - Use running for live campaigns and disabled for paused ones. + - Combining name and tags triggers a logical OR search. + - Convert all relative dates to RFC3339 format before calling. + - If a 400 error occurs, use the source field to identify the culprit and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}: delete: @@ -3372,6 +3656,15 @@ paths: summary: Get campaign tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full configuration of a single campaign by its ID, including its name, state, schedule, budget counters, tags, and ruleset references. + Use this when you already have a campaignId and need the complete details of that specific campaign. + Do not use this tool to browse or search campaigns; use list_campaigns for discovery and to resolve campaign names to IDs. + - If the applicationId is unknown, call get_applications first to resolve the correct ID. + - If the campaignId is unknown, call list_campaigns first to resolve the correct ID. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json put: description: | @@ -3595,6 +3888,15 @@ paths: summary: List campaign rulesets tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all rulesets for a specific campaign — each ruleset is a revision of the campaign's rules, including deleted rules across all revisions. + Use this when the user wants to inspect the rule history of a campaign, audit past configurations, or retrieve a ruleset ID for use with get_ruleset. + Do not use this tool to view the current active rules in detail; use get_ruleset with the latest revision for that purpose. + - Both applicationId and campaignId are required; call get_applications first if the application ID is unknown, then list_campaigns to find the campaign ID. + - The response includes deleted rules — consider only the latest revision for the current active configuration. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId}: get: @@ -3634,6 +3936,113 @@ paths: summary: Get ruleset tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a specific ruleset revision for a campaign, including the full rule definitions, conditions, and effects configured at that point in time. + Use this when the user wants to inspect the exact rules of a specific ruleset revision; call list_rulesets first to discover available rulesetIds and identify the latest revision. + Do not use this tool to list all rulesets or browse history; use list_rulesets to enumerate revisions and find the IDs you need. + - applicationId, campaignId, and rulesetId are all required; call get_applications and list_campaigns first if the IDs are unknown, then list_rulesets to get the rulesetId. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. + x-accepts: application/json + /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets: + post: + description: |- + Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. + + Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + operationId: createRulesetV2 + parameters: + - description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + in: path + name: applicationId + required: true + schema: + format: int64 + type: integer + - description: The ID of the campaign. It is displayed in your Talon.One deployment + URL. + in: path + name: campaignId + required: true + schema: + format: int64 + type: integer + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RulesetV2' + description: body + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/RulesetV2' + description: Created + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + summary: Create ruleset (V2) + tags: + - management + x-scalar-stability: experimental + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json + /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId}: + get: + description: Retrieve the specified ruleset as a JSON object. + operationId: getRulesetV2 + parameters: + - description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + in: path + name: applicationId + required: true + schema: + format: int64 + type: integer + - description: The ID of the campaign. It is displayed in your Talon.One deployment + URL. + in: path + name: campaignId + required: true + schema: + format: int64 + type: integer + - description: The ID of the ruleset. + in: path + name: rulesetId + required: true + schema: + format: int64 + type: integer + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/RulesetV2' + description: OK + summary: Get ruleset (V2) + tags: + - management + x-mcp: true + x-mcp-description: | + Retrieves a single ruleset revision for a campaign as a structured JSON object, decomposing each rule into explicit conditions and effects instead of the raw Talang expressions returned by get_ruleset. + Use this when the Talang output of get_ruleset or list_rulesets is unclear or hard to interpret, and you need a precise, machine-readable breakdown of a specific ruleset's rules; call list_rulesets first to discover available rulesetIds and identify the latest revision. + Do not use this tool to list all rulesets or browse history; use list_rulesets to enumerate revisions, and prefer get_ruleset only when you specifically need the original Talang expressions. + - applicationId, campaignId, and rulesetId are all required; call get_applications and list_campaigns first if the IDs are unknown, then list_rulesets to get the rulesetId. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. + x-mcp-hint-readonly: true + x-scalar-stability: experimental x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/coupons: delete: @@ -4181,6 +4590,16 @@ paths: summary: List coupons tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Lists all coupons within a specific campaign with hasMore-based pagination, supporting the same filtering options as list_coupons but without the overhead of a total result count query. + Use this instead of list_coupons when the user does not need to know the exact total number of results and performance matters — for example when paging through large coupon batches or polling for new codes. + Do not use this tool when the user explicitly asks for the total count of matching coupons; use list_coupons instead in that case. + - Both applicationId and campaignId are required; call get_applications and list_campaigns first if either is unknown. + - The usable and redeemed filters are mutually exclusive; do not send both in the same request. + - Convert any relative date phrases (e.g., 'last 30 days') into RFC3339 strings such as '2024-01-01T00:00:00Z' before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId}: delete: @@ -4559,6 +4978,15 @@ paths: summary: List coupons that match the given attributes (without total count) tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Looks up a single coupon by its exact code within an application, returning its current status, usage counter, validity window, batch ID, and recipient information. + Use this when the user wants to verify whether a specific coupon code exists, check how many times it has been used, confirm its expiration date, or identify who it was assigned to. + Do not use this tool to list or search multiple coupons; use list_coupons for bulk listing within a specific campaign. + - If the applicationId is unknown, call get_applications first to resolve the correct ID. + - If the result data array is empty, the coupon code does not exist in any campaign within that application. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json @@ -5009,6 +5437,14 @@ paths: summary: List loyalty programs tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Lists all loyalty programs belonging to the account, returning their IDs, names, tier configurations, and point settings. + Use this when the user wants to see which loyalty programs exist, retrieve a program ID to use in subsequent loyalty tool calls, or audit program configurations. + Do not use this tool to fetch balances, transactions, or point details for a specific profile; use the loyalty balance and transaction tools for that purpose. + - No parameters are required; the account is resolved from the authenticated session automatically. + - Always call this tool first when a loyaltyProgramId is unknown. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}: get: @@ -5042,6 +5478,14 @@ paths: summary: Get loyalty program tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full configuration of a single loyalty program by its ID, including tier definitions, point settings, and program metadata. + Use this when the user wants to inspect the details of a specific loyalty program, verify its tier structure, or confirm its configuration before referencing it in other operations. + Do not use this tool to retrieve a customer's balance or transaction history; use get_loyalty_balances or get_loyalty_profile_transactions for that purpose. + - loyaltyProgramId is required; call list_loyalty_programs first if the ID is unknown. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/activate_points: post: @@ -5265,7 +5709,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -5298,7 +5742,7 @@ paths: - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - - `expirydate`: The expiration date of the tier when the tier is + - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: @@ -5306,9 +5750,11 @@ paths: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, - only the expiration date is updated. + only the expiry date is updated. - > [!note] We recommend not using this endpoint to update the tier of a customer. + > [!note] We recommend importing customers into the tier that matches their + > current balance. If a customer is imported into a lower tier, any session + > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or @@ -5345,7 +5791,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -5378,6 +5824,85 @@ paths: - management x-contentType: multipart/form-data x-accepts: application/json + /v1/loyalty_programs/{loyaltyProgramId}/import_join_dates: + post: + description: | + Upload a CSV file containing customer profile IDs and their join dates for the + specified loyalty program. Send the file as multipart data. + + > [!important] This endpoint only works with profile-based loyalty programs. + + The CSV file **must** contain the following columns: + + - `customerprofileid`: The integration ID of the customer profile whose join + date you want to update. + - `newjoindate`: The new join date for the customer in RFC3339 format. You + can use the time zone of your choice. It is converted to UTC internally + by Talon.One. + + **Note**: + - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. + - If a join date already exists for a profile, the uploaded date replaces it. + + > [!note] We recommend limiting your file size to 500 MB. + + ## Example + + ```csv + customerprofileid,newjoindate + customer1,2024-03-21T07:32:14Z + customer2,2025-04-16T21:12:37Z + customer3,2026-05-03T11:47:01Z + ``` + operationId: importLoyaltyJoinDates + parameters: + - description: | + 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. + in: path + name: loyaltyProgramId + required: true + schema: + format: int64 + type: integer + requestBody: + content: + multipart/form-data: + schema: + properties: + upFile: + description: The CSV file containing the data that is being imported. + format: csv + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/Import' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + summary: Import join dates for a loyalty program + tags: + - management + x-contentType: multipart/form-data + x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}: get: deprecated: true @@ -5745,7 +6270,7 @@ paths: get: deprecated: true description: | - > [warning] This endpoint is deprecated. + > [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) @@ -5774,6 +6299,14 @@ paths: summary: Get loyalty program statistics tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves aggregate statistics for a loyalty program including total active points, pending points, spent points, and expired points. + Use this when the user wants a high-level overview of point activity across an entire loyalty program. + Do not use this tool to retrieve a specific customer's balance or transaction ledger; use get_loyalty_balances or get_loyalty_profile_transactions for individual profile data. + - loyaltyProgramId is required; call list_loyalty_programs first if the ID is unknown. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/export_customer_balances: get: @@ -5816,6 +6349,25 @@ paths: schema: format: date-time type: string + - description: | + Filters which balance fields are included in the CSV export. `currentBalance` + is always returned. + + By default, all balance fields are included. When this parameter is provided, only the + listed fields contain values and the rest are returned empty. + + Accepted values: + - `currentBalance` + - `pendingBalance` + - `expiredBalance` + - `spentBalance` + - `negativeBalance` + + Multiple values must be provided as a comma-separated list. + in: query + name: balances + schema: + type: string responses: "200": content: @@ -5873,6 +6425,25 @@ paths: schema: format: date-time type: string + - description: | + Filters which balance fields are included in the CSV export. `currentBalance` + is always returned. + + By default, all balance fields are included. When this parameter is provided, only the + listed fields contain values and the rest are returned empty. + + Accepted values: + - `currentBalance` + - `pendingBalance` + - `expiredBalance` + - `spentBalance` + - `negativeBalance` + + Multiple values must be provided as a comma-separated list. + in: query + name: balances + schema: + type: string responses: "200": content: @@ -6046,6 +6617,16 @@ paths: summary: List loyalty program transactions tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Lists transaction logs for a loyalty program including manual, session-based, and imported transactions, with filtering by type, subledger, date range, and activation status. + Use this when the user wants to audit point activity across an entire loyalty program, trace transactions within a date window, or filter by pending activation status. + Do not use this tool to retrieve transactions for a specific customer profile; use get_loyalty_profile_transactions for per-profile ledger data. + - loyaltyProgramId is required; call list_loyalty_programs first if the ID is unknown. + - If no filters are applied, the last 50 transactions are returned by default. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/loyalty_programs/{loyaltyProgramId}/import_cards: post: @@ -6064,14 +6645,17 @@ paths: - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). + - `attributes` (optional): A JSON object that contains the loyalty card's custom + attributes and their values. These attributes must be created and connected to this + loyalty program before they can be assigned to the cards through this endpoint. - > [!note] We recommend limiting your file size to 500MB. + > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv - identifier,state,customerprofileids - 123-456-789AT,active,Alexa001;UserA + identifier,state,customerprofileids,attributes + 123-456-789AT,active,Alexa001;UserA,'{""my_attributes"": ""10_off""}" ``` operationId: importLoyaltyCards parameters: @@ -6090,7 +6674,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -6223,6 +6807,27 @@ paths: schema: format: date-time type: string + - description: | + Filters which balance fields are included in the CSV export. By default, + all balance fields are included. When this parameter is provided, only the + listed fields contain values and the rest are returned empty. + + Accepted values: + - `currentBalance` + - `pendingBalance` + - `expiredBalance` + - `spentBalance` + - `negativeBalance` + + Multiple values must be provided as a comma-separated list. + + **Note:** + - The `negativeBalance` value is not supported for card balance exports. + - Providing an unsupported or invalid value returns a `400 Bad Request` error. + in: query + name: balances + schema: + type: string responses: "200": content: @@ -6412,7 +7017,7 @@ paths: - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. + - `attributes`: The custom attributes of this loyalty card. operationId: exportLoyaltyCards parameters: - description: | @@ -6890,8 +7495,14 @@ paths: get: description: | Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) - within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. - If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. + within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) + with filtering options applied. + + > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: + > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). + + If no filtering options are applied, the last 50 loyalty transactions for + the given loyalty card are returned. operationId: getLoyaltyCardTransactionLogs parameters: - description: | @@ -7016,7 +7627,7 @@ paths: schema: $ref: '#/components/schemas/ErrorResponseWithStatus' description: Not found - summary: List card's transactions + summary: List card's transactions (Management API) tags: - management x-accepts: application/json @@ -7146,7 +7757,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -7870,7 +8481,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -7957,7 +8568,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -8105,6 +8716,13 @@ paths: summary: Get Application health tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the current API health status of an application, reporting whether recent integration requests succeeded, failed, or have not been recorded, along with the timestamp of the most recent request. + Use this when the user wants to verify that an application is actively processing integration traffic or to diagnose connection issues with the integration layer. + Do not use this tool to view campaign configurations or application settings; it is a read-only integration health check that covers only the last 5 minutes of activity. + If the applicationId is unknown, call get_applications first to resolve the correct ID before calling this tool. x-accepts: application/json /v1/applications/{applicationId}/access_logs/no_total: get: @@ -8206,6 +8824,15 @@ paths: summary: Get access logs for Application tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the list of integration API calls sent to an application within a time window, including request paths, methods, HTTP status codes, and full request and response payloads. + Use this when the user wants to audit recent integration activity, debug a failing integration call, or verify that a specific session or event request was received. + Do not use this tool to check the overall health status of an application; use get_application_health for a high-level summary of recent request success rates. + - Both rangeStart and rangeEnd are required; convert any relative date phrases (e.g., 'last 7 days') into RFC3339 strings such as '2024-01-01T00:00:00Z' before calling. + - If the applicationId is unknown, call get_applications first to resolve the correct ID. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/analytics: get: @@ -8330,6 +8957,15 @@ paths: summary: List application's customers tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Lists all customer profiles associated with a specific application, with optional filtering by integration ID and pagination controls. + Use this when the user wants to browse or audit customer profiles in an application, look up a specific customer by their integration ID, or confirm whether a customer profile exists. + Do not use this tool to retrieve a single customer's full details or inventory; use get_application_customer for individual lookups. + - applicationId is required; call get_applications first if it is unknown. + - Use the integrationId filter to perform an exact match against a customer's profile integration identifier. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/customer_search: post: @@ -8545,6 +9181,14 @@ paths: summary: Get application's customer tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a single customer record within a specific application by their internal numeric customer ID, returning profile data, integration ID, and associated attributes. + Use this when the user knows the internal customer ID (not the integration ID) and wants the full customer record within a specific application context; call list_application_customers first to find the customer ID if it is unknown. + Do not use this tool to look up a customer by their integration ID; use get_customer_profile for that purpose. + - Both applicationId and customerId are required; call get_applications first if the application ID is unknown, then list_application_customers to find the customerId. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/customer_activity_reports/no_total: get: @@ -8892,6 +9536,79 @@ paths: summary: List Application sessions tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all customer sessions for a specific application as a paginated list, with optional filtering by profile integration ID, session state, coupon, referral, store, or date range. + Use this when the user wants to browse or search customer sessions within an application — for example to find all open sessions, sessions that used a specific coupon, or sessions for a given customer profile. + Do not use this tool to retrieve the full detail of a single session; use get_application_session or get_session_details for that purpose. + - applicationId is required; call get_applications first if the ID is unknown. + - Set partialMatch=true to enable substring matching on integrationId, profile, coupon, referral, or storeIntegrationId (minimum 3 characters); without it all text filters require exact matches. + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. + x-accepts: application/json + /v1/applications/{applicationId}/sessions_search: + post: + description: | + Get a list of the Application sessions matching the provided customer profile + attributes. + + The match is successful if all the attributes of the request are found in a + profile, even if the profile has more attributes that are not present on the + request. + operationId: getApplicationSessionsByCustomerAttributes + parameters: + - description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + in: path + name: applicationId + required: true + schema: + format: int64 + type: integer + - description: The number of items in the response. + in: query + name: pageSize + schema: + default: 1000 + format: int64 + maximum: 1000 + minimum: 1 + type: integer + - description: The number of items to skip when paging through large result + sets. + in: query + name: skip + schema: + format: int64 + type: integer + - description: | + When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. + - When `true`: `totalResultSize` contains the total number of results for this query. + - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. + in: query + name: withTotalResultSize + schema: + type: boolean + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CustomerProfileSearchQuery' + description: body + required: true + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/inline_response_200_32' + description: OK + summary: List Application sessions matching the given customer attributes + tags: + - management + x-codegen-request-body-name: body + x-contentType: application/json x-accepts: application/json /v1/applications/{applicationId}/sessions/{sessionId}: get: @@ -8926,6 +9643,15 @@ paths: summary: Get Application session tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the details of a specific application session by its internal numeric session ID, including cart items, state, profile, coupons used, and referral data. + Use this when the user has the internal session ID (from list_application_sessions) and wants the full management-API view of that session. + Do not use this tool to find sessions by integration ID or customer; use list_application_sessions to search first; use get_session_details to retrieve a session by its integration ID via the integration API. + - Both applicationId and sessionId are required; call list_application_sessions to find the internal sessionId if unknown. + - sessionId is the internal numeric ID, not the session integration ID set during session creation. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/events/no_total: get: @@ -9038,11 +9764,22 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_32' + $ref: '#/components/schemas/inline_response_200_33' description: OK summary: List Applications events tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all events recorded for a specific application as a paginated list, with optional filtering by event type, date range, session, profile, customer, coupon, referral, rule, campaign, or effect. + Use this when the user wants to browse or audit events that occurred within an application — for example to find events triggered by a specific coupon, events for a given customer, or events of a particular type. + Do not use this tool to retrieve events for all applications at once; applicationId is required to scope the results. + - applicationId is required; call get_applications first if the ID is unknown. + - The type parameter accepts a comma-separated list of event type names for exact matching (e.g., "talon_session_created,talon_session_updated"). + - Convert any relative date phrases into RFC3339 strings (e.g., '2024-01-01T00:00:00Z') before calling. + - customerName and customerEmail perform case-insensitive substring matching (minimum 2 characters); session and profile require exact matches. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/applications/{applicationId}/event_types: get: @@ -9089,11 +9826,19 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_33' + $ref: '#/components/schemas/inline_response_200_34' description: OK summary: List Applications event types tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all distinct event type names recorded for a specific application as a paginated list. + Use this to discover which event types are available for filtering when calling list_application_events — the returned strings are the exact values accepted by the type parameter of that tool. + Do not use this tool to retrieve the full event records; use list_application_events for that purpose. + - applicationId is required; call get_applications first if the ID is unknown. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/audiences: get: @@ -9139,11 +9884,19 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_34' + $ref: '#/components/schemas/inline_response_200_35' description: OK summary: List audiences tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all audiences created in the account as a paginated list, including their names, descriptions, and membership counts. + Use this when the user wants to browse available audiences, find a specific audience by name, or retrieve audience IDs for use in other operations. + Do not use this tool to modify audiences or manage memberships; use the management API directly for those operations. + - No required parameters; all filters are optional. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/audiences/analytics: get: @@ -9160,7 +9913,7 @@ paths: schema: type: string - description: The IDs of one or more audiences, separated by commas, by which - to filter results. + to filter results. Do not provide more than 1000 audience IDs. in: query name: audienceIds required: true @@ -9171,7 +9924,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_35' + $ref: '#/components/schemas/inline_response_200_36' description: OK summary: List audience analytics tags: @@ -9226,7 +9979,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_36' + $ref: '#/components/schemas/inline_response_200_37' description: OK "404": content: @@ -9275,7 +10028,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -9417,11 +10170,20 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_37' + $ref: '#/components/schemas/inline_response_200_38' description: OK summary: List friends referred by customer profile tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Lists the customer profiles referred by a specific advocate within an application, returning their profile data and referral details. + Use this when the user wants to see which customers were brought in by a specific advocate, verify the outcome of a referral program for a given profile, or audit referral activity for a particular integration ID. + Do not use this tool to list referral codes or referral objects; use list_referrals to enumerate referral codes within a campaign. + - Both applicationId and integrationId are required; call get_applications first if applicationId is unknown. + - If the result data array is empty, the advocate has not yet referred any friends within this application. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/best_prior_price: post: @@ -9484,6 +10246,38 @@ paths: x-codegen-request-body-name: body x-contentType: application/json x-accepts: application/json + /v1/applications/{applicationId}/price_history/exclusions: + post: + description: | + Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. + operationId: excludePriceHistory + parameters: + - description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + in: path + name: applicationId + required: true + schema: + format: int64 + type: integer + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ExcludePriceObservationsRequest' + description: body + required: true + responses: + "200": + content: {} + description: Ok + summary: Exclude price records from price history + tags: + - management + x-scalar-stability: experimental + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json /v1/attributes: get: description: | @@ -9525,6 +10319,13 @@ paths: name: applicationIds schema: type: string + - description: Returned attributes will be filtered by the specified loyalty + program ids, separated by commas. You can only use this parameter when `entity` + is `LoyaltyCard`. + in: query + name: loyaltyProgramIds + schema: + type: string - description: Returned attributes will be filtered by supplied type in: query name: type @@ -9552,11 +10353,19 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_38' + $ref: '#/components/schemas/inline_response_200_39' description: OK summary: List custom attributes tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all custom attributes defined in the account, with optional filtering by entity type, attribute type, kind, application, or a free-text search term. + Use this when the user wants to discover which custom attributes exist, find attributes for a specific entity (such as CustomerProfile or Campaign), or look up an attribute by name or description. + Do not use this tool to create or modify attributes; use the management API directly for write operations. + - No required parameters; all filters are optional and can be combined. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json post: description: | @@ -9618,6 +10427,14 @@ paths: summary: Get custom attribute tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves a single custom attribute by its numeric ID, returning its name, entity type, data type, description, and configuration. + Use this when the user wants the full details of a specific attribute they already know the ID of; call list_custom_attributes first to look up the ID if the user only knows the name. + Do not use this tool to list all attributes or filter by entity type; use list_custom_attributes for browsing and discovery. + - attributeId is required; you can find the ID by calling list_custom_attributes and matching on name. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json put: description: | @@ -9700,7 +10517,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -9795,7 +10612,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_39' + $ref: '#/components/schemas/inline_response_200_40' description: OK summary: List items in a catalog tags: @@ -9849,211 +10666,7 @@ paths: **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. - ### Payload examples - - Synchronization actions are sent as `PUT` requests. See the structure for - each action: - -
- Adding an item to the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "attributes": { - "color": "Navy blue", - "type": "shoes" - }, - "replaceIfExists": true, - "sku": "SKU1241028", - "price": 100, - "product": { - "name": "sneakers" - } - }, - "type": "ADD" - } - ] - } - ``` -
-
- -
- Adding multiple items to the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "attributes": { - "color": "Navy blue", - "type": "shoes" - }, - "replaceIfExists": true, - "sku": "SKU1241027", - "price": 100, - "product": { - "name": "sneakers" - } - }, - "type": "ADD" - }, - { - "payload": { - "attributes": { - "color": "Navy blue", - "type": "shoes" - }, - "replaceIfExists": true, - "sku": "SKU1241028", - "price": 100, - "product": { - "name": "sneakers" - } - }, - "type": "ADD" - } - ] - } - ``` -
-
- -
- Updating the attributes of an item in the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "attributes": { - "age": 11, - "origin": "germany" - }, - "createIfNotExists": false, - "sku": "SKU1241028", - "product": { - "name": "sneakers" - } - }, - "type": "PATCH" - } - ] - } - ``` -
-
- -
- Updating the attributes of multiple items in the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "attributes": { - "color": "red" - }, - "filters": [ - { - "attr": "color", - "op": "EQ", - "value": "blue" - } - ] - }, - "type": "PATCH_MANY" - } - ] - } - ``` - -
-
- -
- Removing an item from the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "sku": "SKU1241028" - }, - "type": "REMOVE" - } - ] - } - ``` - -
-
- -
- Removing multiple items from the catalog -
- - ```json - { - "actions": [ - { - "payload": { - "filters": [ - { - "attr": "color", - "op": "EQ", - "value": "blue" - } - ] - }, - "type": "REMOVE_MANY" - } - ] - } - ``` -
-
- -
- Removing shoes of sizes above 45 from the catalog -
-

- Let's imagine that we have a shoe store and we have decided to stop selling - shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 - with a single action:

- - ```json - { - "actions": [ - { - "payload": { - "filters": [ - { - "attr": "size", - "op": "GT", - "value": "45" - } - ] - }, - "type": "REMOVE_MANY" - } - ] - } - ``` -
-
+ For request examples of each action, see the **Request Body** examples. operationId: syncCatalog parameters: - description: The ID of the catalog. You can find the ID in the Campaign Manager @@ -10139,7 +10752,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_40' + $ref: '#/components/schemas/inline_response_200_41' description: OK summary: List additional costs tags: @@ -10299,11 +10912,20 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_41' + $ref: '#/components/schemas/inline_response_200_42' description: OK summary: List webhooks tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all webhooks configured in the authenticated Talon.One account as a paginated list, with optional filtering by application, creation type, visibility, outgoing integration type, or title. + Use this when the user wants to audit webhook configurations, find webhooks connected to a specific application, or locate a webhook by title before calling get_webhook. + Do not use this tool to retrieve the details of a single webhook; use get_webhook for that purpose. + - No required parameters; all filters are optional. + - applicationIds filters webhooks connected to the specified application ID; if omitted, webhooks for all applications are returned. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/webhooks/{webhookId}: get: @@ -10328,6 +10950,14 @@ paths: summary: Get webhook tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full configuration of a specific webhook by its numeric ID, including its URL, headers, payload template, and connected applications. + Use this when the user wants to inspect a webhook's settings after finding its ID via list_webhooks. + Do not use this tool to list webhooks; use list_webhooks to browse and find the webhookId first. + - webhookId is required; call list_webhooks to find the numeric ID if unknown — it is also visible in the Campaign Manager URL when viewing the webhook under Account > Webhooks. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/message_logs: get: @@ -10396,6 +11026,15 @@ paths: schema: format: byte type: string + - description: The maximum number of message log entries to return. + in: query + name: pageSize + schema: + default: 50 + format: int64 + maximum: 1000 + minimum: 1 + type: integer - description: | Filter results by time period. Choose between the available relative time frames. in: query @@ -10512,7 +11151,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_42' + $ref: '#/components/schemas/inline_response_200_43' description: OK summary: List event types tags: @@ -10584,7 +11223,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -10759,6 +11398,24 @@ paths: schema: default: false type: boolean + - description: |- + 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. + in: query + name: deletedBefore + schema: + format: date-time + type: string + - description: |- + 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. + in: query + name: deletedAfter + schema: + format: date-time + type: string responses: "200": content: @@ -11001,6 +11658,20 @@ paths: schema: format: date-time type: string + - description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string. + in: query + name: updatedBefore + schema: + format: date-time + type: string + - description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string. + in: query + name: updatedAfter + schema: + format: date-time + type: string - description: Only return sessions for the customer that matches this customer integration ID. in: query @@ -11099,7 +11770,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -11149,11 +11820,19 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_43' + $ref: '#/components/schemas/inline_response_200_44' description: OK summary: List users in account tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all users belonging to the authenticated Talon.One account as a paginated list, including their roles, email addresses, and status. + Use this when the user wants to see who has access to the account, audit team membership, or look up a specific user's details before calling get_user. + Do not use this tool to retrieve application or campaign details; use get_applications or list_campaigns for those purposes. + - No required parameters; all filters are optional. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/users/{userId}: delete: @@ -11197,6 +11876,15 @@ paths: summary: Get user tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full profile of a specific user by their numeric ID, including their roles, email address, status, and invitation code if applicable. + Use this when the user wants to inspect a specific team member's details after finding their ID via list_users. + Do not use this tool to list all users; use list_users to browse and find the userId first. + - userId is required; call list_users to find the numeric user ID if unknown. + - Non-admin users can only retrieve their own profile; admin users can retrieve any user in the account. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json put: description: Update the details of a specific user. @@ -11782,7 +12470,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_44' + $ref: '#/components/schemas/inline_response_200_45' description: OK summary: Get audit logs for an account tags: @@ -11926,6 +12614,15 @@ paths: summary: Get account details tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the full details of the authenticated Talon.One account, including subscription info, limits, and configuration. + Use this when the user wants to inspect their account settings or verify account-level information such as name, currency, timezone, or subscription status. + Do not use this tool to retrieve application or campaign details; use get_applications or list_campaigns for those purposes. + - accountId is required and must be the numeric ID of the authenticated account; it is visible in the Campaign Manager's Account menu or via the Talon.One API. + - You can only retrieve your own account; requests for a different account ID will be rejected. + - If a 400 error occurs, use the source field to identify the culprit parameter and explain the specific requirement to the user. x-accepts: application/json /v1/accounts/{accountId}/analytics: get: @@ -12055,7 +12752,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_45' + $ref: '#/components/schemas/inline_response_200_46' description: OK summary: Get exports tags: @@ -12070,11 +12767,18 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_46' + $ref: '#/components/schemas/inline_response_200_47' description: OK summary: List roles tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves all roles defined in the authenticated Talon.One account, including their names, permissions, and associated members. + Use this when the user wants to audit access control, understand what permissions are configured, or look up a role before assigning it to a user. + Do not use this tool to manage role assignments; it is read-only and returns the full list of available roles. + - No parameters are required; the endpoint always returns all roles for the authenticated account. x-accepts: application/json /v2/roles/{roleId}: get: @@ -12291,7 +12995,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_47' + $ref: '#/components/schemas/inline_response_200_48' description: OK summary: List stores tags: @@ -12557,9 +13261,9 @@ paths: - description: | Filter by the display name of the Application cart item filter in the Application. - **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. + **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. in: query - name: title + name: name schema: type: string responses: @@ -12567,7 +13271,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_48' + $ref: '#/components/schemas/inline_response_200_49' description: OK summary: List Application cart item filters tags: @@ -12695,7 +13399,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -12830,7 +13534,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_49' + $ref: '#/components/schemas/inline_response_200_50' description: OK "400": content: @@ -12929,7 +13633,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_50' + $ref: '#/components/schemas/inline_response_200_51' description: OK "400": content: @@ -13010,7 +13714,7 @@ paths: schema: properties: upFile: - description: The file containing the data that is being imported. + description: The CSV file containing the data that is being imported. format: csv type: string responses: @@ -13114,6 +13818,7 @@ paths: x-accepts: application/csv /v1/applications/{applicationId}/campaigns/{campaignId}/achievements: get: + deprecated: true description: List all the achievements for a specific campaign. operationId: listAchievements parameters: @@ -13162,13 +13867,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_51' + $ref: '#/components/schemas/inline_response_200_52' description: OK summary: List achievements tags: - management x-accepts: application/json post: + deprecated: true description: Create a new achievement in a specific campaign. operationId: createAchievement parameters: @@ -13225,6 +13931,7 @@ paths: x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}: delete: + deprecated: true description: Delete the specified achievement. operationId: deleteAchievement parameters: @@ -13274,6 +13981,7 @@ paths: - management x-accepts: application/json get: + deprecated: true description: Get the details of a specific achievement. operationId: getAchievement parameters: @@ -13324,8 +14032,17 @@ paths: summary: Get achievement tags: - management + x-mcp: true + x-mcp-hint-readonly: true + x-mcp-description: | + Retrieves the details of a specific achievement within a campaign, including its name, description, progress target, period, and recurrence settings. + Use this when the user wants to inspect the full configuration of a specific achievement; call list_campaigns first if the campaign ID is unknown, and use get_customer_achievements to see a customer's progress toward achievements. + Do not use this tool to list all achievements in a campaign; use the management API's listAchievements endpoint for that purpose. + - applicationId, campaignId, and achievementId are all required; call get_applications and list_campaigns to find the application and campaign IDs. + - If a 404 error occurs, inform the user the achievement was not found and suggest verifying the IDs. x-accepts: application/json put: + deprecated: true description: Update the details of a specific achievement. operationId: updateAchievement parameters: @@ -13394,6 +14111,7 @@ paths: x-accepts: application/json /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}/export: get: + deprecated: true description: | Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. @@ -13463,6 +14181,283 @@ paths: tags: - management x-accepts: application/csv + /v2/achievements: + get: + description: | + List all achievements. + operationId: listAchievementsV2 + parameters: + - description: The number of items in the response. + in: query + name: pageSize + schema: + default: 50 + format: int64 + maximum: 1000 + minimum: 1 + type: integer + - description: The number of items to skip when paging through large result + sets. + in: query + name: skip + schema: + format: int64 + type: integer + - description: | + 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. + in: query + name: sort + schema: + type: string + - description: Filter by the display name of the achievement. + in: query + name: title + schema: + type: string + - description: Filter by the ID of an Application connected to the achievement. + in: query + name: applicationId + schema: + format: int64 + type: integer + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/inline_response_200_53' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + summary: List achievements + tags: + - management + x-accepts: application/json + post: + description: Create a new account-level achievement. + operationId: createAchievementV2 + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CreateAchievementV2' + description: body + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/AchievementV2' + description: Created + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "409": + content: {} + description: Conflict. An achievement with this name already exists. + summary: Create achievement + tags: + - management + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json + /v2/achievements/{achievementId}: + delete: + description: Delete a specific achievement. + operationId: deleteAchievementV2 + parameters: + - description: The ID of the achievement. You can get this ID with the [List + achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) + endpoint. + in: path + name: achievementId + required: true + schema: + format: int64 + type: integer + responses: + "204": + content: {} + description: No Content + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + summary: Delete achievement + tags: + - management + x-accepts: application/json + get: + description: Retrieve the details of a specific achievement. + operationId: getAchievementV2 + parameters: + - description: | + The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. + in: path + name: achievementId + required: true + schema: + format: int64 + type: integer + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/AchievementV2' + description: OK + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + summary: Get achievement + tags: + - management + x-accepts: application/json + put: + description: Update the details of a specific achievement. + operationId: updateAchievementV2 + parameters: + - description: The ID of the achievement. You can get this ID with the [List + achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) + endpoint. + in: path + name: achievementId + required: true + schema: + format: int64 + type: integer + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateAchievementV2' + description: body + required: true + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/AchievementV2' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + summary: Update achievement + tags: + - management + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json + /v2/achievements/{achievementId}/export: + get: + description: | + Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. + + The CSV file contains the following columns: + - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. + - `title`: The display name of the achievement in the Campaign Manager. + - `target`: The required number of actions or the transactional milestone to complete the achievement. + - `progress`: The current progress of the customer in the achievement. + - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. + - `startDate`: The date on which the customer profile started the achievement in RFC3339. + - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. + - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. + operationId: exportAchievementV2 + parameters: + - description: The ID of the achievement. You can get this ID with the [List + achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) + endpoint. + in: path + name: achievementId + required: true + schema: + format: int64 + type: integer + responses: + "200": + content: + application/csv: + schema: + format: csv + type: string + description: OK + "400": + content: + application/csv: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/csv: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/csv: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + summary: Export achievement customer data + tags: + - management + x-accepts: application/csv /v1/applications/{applicationId}/campaign_analytics/export: get: description: | @@ -13603,7 +14598,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_52' + $ref: '#/components/schemas/inline_response_200_54' description: OK "400": content: @@ -13655,12 +14650,322 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/inline_response_200_53' + $ref: '#/components/schemas/inline_response_200_55' description: OK summary: Summarize coupon redemption failures in session tags: - management x-accepts: application/json + /v1/rewards/catalog: + get: + description: | + Retrieve the rewards catalog for the Application. + Returns a paginated list of rewards. + operationId: integrationRewardsCatalog + parameters: + - description: The number of items in the response. + in: query + name: pageSize + schema: + default: 1000 + format: int64 + maximum: 1000 + minimum: 1 + type: integer + - description: The number of items to skip when paging through large result + sets. + in: query + name: skip + schema: + format: int64 + type: integer + - description: Return only rewards whose points required is greater than or + equal to this value. + in: query + name: pointsFrom + schema: + type: number + - description: Return only rewards whose points required is less than or equal + to this value. + in: query + name: pointsTo + schema: + type: number + - description: | + Whether to include rewards that have no `pointsRequired`. These rewards are + treated as free and available to all customers. + in: query + name: includeFree + schema: + default: true + type: boolean + - description: | + Return only rewards available in this loyalty program. + in: query + name: loyaltyProgramId + schema: + format: int64 + type: integer + - description: | + Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. + To specify the main ledger, provide an empty string (""). + in: query + name: subledgerId + schema: + type: string + - description: | + The integration ID of the customer profile whose loyalty balances to + include in the response. Balances are returned only when + `loyaltyProgramId` is also provided. + + **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. + in: query + name: profileIntegrationId + schema: + type: string + - description: | + The identifier of the loyalty card whose loyalty balances to include + in the response. Balances are returned only when `loyaltyProgramId` + is also provided. + + **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. + in: query + name: loyaltyCardId + schema: + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/inline_response_200_56' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + security: + - api_key_v1: [] + summary: List rewards in the catalog + tags: + - integration + x-scalar-stability: experimental + x-accepts: application/json + /v1/rewards/{rewardId}/unlock: + post: + description: | + Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. + + To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + operationId: unlockReward + parameters: + - description: The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) + endpoint. + in: path + name: rewardId + required: true + schema: + format: int64 + type: integer + - description: When set to `true`, the rule evaluation is performed but no changes + are persisted. Use this to preview the outcome of an unlocking. + in: query + name: dry + schema: + type: boolean + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IntegrationUnlockRewardRequest' + required: true + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/IntegrationStateV2' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized + "403": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Forbidden + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + "409": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Conflict. A reward unlock with this integration ID already + exists. + "422": + content: + application/json: + schema: + $ref: '#/components/schemas/RewardUnlockRejection' + description: | + Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. + security: + - api_key_v1: [] + summary: Unlock a reward + tags: + - integration + x-scalar-stability: experimental + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json + /v3/events: + post: + description: | + Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). + + Advanced events are idempotent, uniquely identifiable events. They can also + reference a previously closed session to add more context for rule evaluation. + + To use this endpoint: + + 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. + 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. + 1. Trigger the event with this endpoint. + + You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. + + For example, you can use this endpoint to award loyalty points after an order is delivered. + See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). + + > [!note] **Note** + > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. + > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). + > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + operationId: trackEventV3 + parameters: + - description: | + Possible values: `yes` or `no`. + - `yes`: Increases the performance of the API call by returning a 204 response. + - `no`: Returns a 200 response that contains the updated customer profiles. + in: query + name: silent + schema: + default: "yes" + type: string + - description: | + Indicates whether to persist the changes. Changes are ignored when `dry=true`. + in: query + name: dry + schema: + type: boolean + - description: | + Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. + in: query + name: forceCompleteEvaluation + schema: + default: false + type: boolean + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IntegrationEventV3Request' + description: body + required: true + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/IntegrationEventV3Response' + description: OK + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Bad request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Unauthorized - Invalid API key + "409": + content: + application/json: + schema: + type: object + description: An advanced event already exists, too many requests, or limit + reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). + security: + - api_key_v1: [] + summary: Track advanced event + tags: + - integration + x-codegen-request-body-name: body + x-contentType: application/json + x-accepts: application/json + /v3/events/{integrationId}: + get: + description: | + Retrieve an advanced event by its identifier. + operationId: getEventV3 + parameters: + - description: The unique ID of the advanced event. + in: path + name: integrationId + required: true + schema: + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/EventV3' + description: OK + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponseWithStatus' + description: Not found + security: + - api_key_v1: [] + summary: Get advanced event + tags: + - integration + x-accepts: application/json components: schemas: ApplicationNotification: @@ -14261,7 +15566,8 @@ components: description: The strikethrough labels notification for an application. properties: version: - description: The version of the strikethrough pricing notification. + description: | + The version of the strikethrough pricing notification. Set for **scheduled** strikethrough pricing updates only. enum: - v2 type: string @@ -14402,15 +15708,7 @@ components: format: date-time type: string EventType: - enum: - - LoyaltyPointsChanged - - LoyaltyTierDowngrade - - LoyaltyTierUpgrade - - CouponCreated - - CouponUpdated - - CouponDeleted - type: string - x-generate-enum-go: IntegrationHubEventType + $ref: '#/components/schemas/IntegrationHubEventType' Data: items: type: object @@ -14763,6 +16061,13 @@ components: example: couponCodes: - XMAS-20-2021 + identifiers: + - d41306257915f83fe01e54092ae470f631161ea16fcf4415842eed41470386ea + experimentVariantAllocations: + - experimentID: 1 + variantID: 2 + - experimentID: 1 + variantID: 2 loyaltyCards: - loyalty-card-1 additionalCosts: @@ -14770,8 +16075,6 @@ components: price: 9 storeIntegrationId: STORE-001 profileId: URNGV8294NV - identifiers: - - d41306257915f83fe01e54092ae470f631161ea16fcf4415842eed41470386ea evaluableCampaignIds: - 10 - 12 @@ -14846,11 +16149,8 @@ components: base: price: 100 height: 0.8008281904610115 - experimentVariantAllocations: - - experimentID: 1 - variantID: 2 - - experimentID: 1 - variantID: 2 + rewardIntegrationIds: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 properties: profileId: description: | @@ -14914,18 +16214,27 @@ components: type: string maxItems: 1 type: array + rewardIntegrationIds: + description: | + The integration IDs of the unlocked rewards that can be used in this session. + example: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + items: + type: string + title: Customer reward integration IDs + type: array state: default: open description: | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: - 1. `open` → `closed` - 2. `open` → `cancelled` + 1. `open` -> `closed` + 2. `open` -> `cancelled` 3. Either: - - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) - 4. `partially_returned` → `cancelled` + - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or + - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) + - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) + 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). enum: @@ -14998,6 +16307,7 @@ components: example: couponCodes: - XMAS-20-2021 + cartItemAdditionalCostTotal: 15.0 updateCount: 3 created: 2020-02-07T08:15:22Z identifiers: @@ -15008,7 +16318,7 @@ components: variantID: 2 - experimentID: 1 variantID: 2 - total: 119.99 + total: 134.99 loyaltyCards: - loyalty-card-1 additionalCosts: @@ -15094,6 +16404,8 @@ components: price: 100 height: 0.8008281904610115 updated: 2020-02-08T14:15:22Z + rewardIntegrationIds: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 firstSession: true cartItemTotal: 99.99 properties: @@ -15180,18 +16492,27 @@ components: type: string maxItems: 1 type: array + rewardIntegrationIds: + description: | + The integration IDs of the unlocked rewards that can be used in this session. + example: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + items: + type: string + title: Customer reward integration IDs + type: array state: default: open description: | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: - 1. `open` → `closed` - 2. `open` → `cancelled` + 1. `open` -> `closed` + 2. `open` -> `cancelled` 3. Either: - - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) - 4. `partially_returned` → `cancelled` + - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or + - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) + - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) + 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). enum: @@ -15274,7 +16595,7 @@ components: total: description: The total value of cart items and additional costs in the session, before any discounts are applied. - example: 119.99 + example: 134.99 title: Session Total type: number cartItemTotal: @@ -15288,6 +16609,13 @@ components: example: 20.0 title: Additional Costs Total type: number + cartItemAdditionalCostTotal: + description: The total value of additional costs applied to individual items, + before any discounts are applied. + example: 15.0 + readOnly: true + title: Cart Item Additional Cost Total + type: number updated: description: Timestamp of the most recent event received on this session. example: 2020-02-08T14:15:22Z @@ -15298,6 +16626,7 @@ components: - additionalCostTotal - applicationId - attributes + - cartItemAdditionalCostTotal - cartItemTotal - cartItems - created @@ -15400,6 +16729,12 @@ components: example: 68851723-e6fa-488f-ace9-112581e6c19b format: uuid type: string + rewardId: + description: The ID of the reward that was being evaluated when this effect + was triggered. + example: 7 + format: int64 + type: integer required: - campaignId - effectType @@ -15408,31 +16743,50 @@ components: - rulesetId type: object AcceptCouponEffectProps: - description: The properties specific to the "acceptCoupon" effect. This gets - triggered whenever the coupon is valid and all other conditions in the rules - of its campaign are met. + description: |- + This effect indicates that the coupon code supplied was valid. + + You should handle this effect by clearing any messages from previous `rejectCoupon` effects and informing the user that the coupon is valid. + + The code is automatically redeemed when you close the session. + + Other effects, such as [setDiscount](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscount), provide more information about the actual rewards received. + example: + value: COUP-XYZ789 properties: value: description: The coupon code that was accepted. type: string required: - value + title: acceptCoupon type: object AcceptReferralEffectProps: - description: The properties specific to the "acceptReferral" effect. TThis gets - triggered whenever the referral code is valid and all other conditions in - the rules of its campaign are met. + description: |- + This effect indicates that the referral code supplied is valid. + + You should handle this effect by informing the user that the referral code is valid. + + The code is automatically redeemed when you close the session. + + Other effects will provide more information about the actual reward. + example: + value: REF-ABC123 properties: value: - description: The referral code that was accepted. + description: The referral code provided in the session. type: string required: - value + title: acceptReferral type: object RedeemReferralEffectProps: description: | - This effect is **deprecated**. The properties specific to the "redeemReferral" effect. - This gets triggered whenever the referral code is valid, and a rule was triggered that contains a "redeem referral" effect. + This effect is **deprecated**. It has been replaced by the `acceptReferral` effect. + This effect indicates that the referral code is valid and has been redeemed. + example: + id: 12 + value: REF-ABC123 properties: id: description: The id of the referral code that was redeemed. @@ -15444,17 +16798,42 @@ components: required: - id - value + title: redeemReferral type: object + x-deprecated: true RejectCouponEffectProps: - description: The properties specific to the "rejectCoupon" effect. This gets - triggered whenever the coupon was rejected. See rejectionReason for more info - on why. + description: |- + This effect indicates that the coupon code supplied couldn't be used. + + You should handle this effect by informing their user the coupon code is invalid. + example: + value: COUP-XYZ789 + rejectionReason: CouponRejectedCondition + conditionIndex: 2 + effectIndex: 0 + details: Coupon usage limit reached + campaignExclusionReason: CampaignGaveLowerDiscount properties: value: description: The coupon code that was rejected. type: string rejectionReason: - description: The reason why this coupon was rejected. + description: |- + The reason why the code was rejected. + + - `CampaignLimitReached`: The campaign-wide coupon code redemption limit has been reached. + - `CouponExpired`: The coupon is expired. + - `CouponLimitReached`: The coupon redemption limit or a campaign budget was reached. + - `CouponNotFound`: The coupon code is incorrect. + - `CouponPartOfNotRunningCampaign`: The campaign the coupon belongs to is currently not active. The campaignId field contains the ID of that campaign. + - `CouponRecipientDoesNotMatch`: The given coupon value does not match the recipient or the coupon is linked to a `recipientIntegrationID` but there is no profile in the session. + - `CouponRejectedByCondition`: Other conditions failed in the rule or all conditions passed but the `Coupon code is valid` condition is not present. + - `CouponStartDateInFuture`: The coupon isn't active yet. + - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` cannot be applied because a discount limit is reached). + - `ProfileLimitReached`: The profile-specific coupon redemption limit has been reached. + - `CouponPartOfNotTriggeredCampaign`: The campaign the coupon belongs to was not triggered during evaluation (an exclusive or stackable campaign). The `campaignId` field contains the ID of that campaign. + - `CouponReservationRequired`: The coupon's `isReservationMandatory` property is `true`, but the profile does not have a reservation. + - `ProfileRequired`: The coupon's `isReservationMandatory` property is `true` or a [campaign profile budget](https://docs.talon.one/docs/product/campaigns/settings/manage-campaign-budgets) was set, but no profile exists in the session. type: string conditionIndex: description: The index of the condition that caused the rejection of the @@ -15469,23 +16848,51 @@ components: description: More details about the failure. type: string campaignExclusionReason: - description: The reason why the campaign was not applied. + description: |- + The reason why the campaign the coupon belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. + Its possible values are: + + - `CampaignGaveLowerDiscount`: The required campaign and coupon conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. + - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. + - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the coupon is part of an archived campaign. example: CampaignGaveLowerDiscount type: string required: - rejectionReason - value + title: rejectCoupon type: object RejectReferralEffectProps: - description: The properties specific to the "rejectReferral" effect. This gets - triggered whenever the referral code was rejected. See rejectionReason for - more info on why. + description: This effect indicates that the provided referral code is invalid. + example: + value: REF-ABC123 + rejectionReason: ReferralRejectedCondition + conditionIndex: 1 + effectIndex: 0 + details: Referral code already used + campaignExclusionReason: CampaignGaveLowerDiscount properties: value: - description: The referral code that was rejected. + description: The referral code that was rejected type: string rejectionReason: - description: The reason why this referral code was rejected. + description: |- + The reason why the code was rejected. + + - `AdvocateNotFound`: The advocate was not found. + - `CampaignLimitReached`: The campaign-wide referral code redemption limit has been reached. + - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` can not be applied because a discount limit is reached). + - `ProfileLimitReached`: The profile-specific referral code redemption limit has been reached. + - `ReferralCustomerAlreadyReferred`: The friend is already referred. + - `ReferralExpired`: The transferred referral code is expired. + - `ReferralLimitReached`: The referral code redemption limit has been reached. + - `ReferralNotFound`: The transferred referral code is wrong. + - `ReferralPartOfNotRunningCampaign`: The campaign the referral code belongs to is currently not active. The campaign ID field shows the ID of that campaign. + - `ReferralRecipientDoesNotMatch`: The given referral code value does not match the recipient. + - `ReferralRecipientIdSameAsAdvocate`: The recipient (friend) has the same id as the advocate. + - `ReferralRejectedByCondition`: The referral code is valid and in an active campaign, but there were other conditions in that campaign's rules that were not met. + - `ReferralStartDateInFuture`: The transferred referral code isn't active yet. + - `ReferralPartOfNotTriggeredCampaign`: The campaign the referral code belongs to was not triggered during evaluation (an exclusive or stackable campaign). The campaign ID field shows the ID of that campaign. type: string conditionIndex: description: The index of the condition that caused the rejection of the @@ -15500,18 +16907,30 @@ components: description: More details about the failure. type: string campaignExclusionReason: - description: The reason why the campaign was not applied. + description: |- + The reason why the campaign the referral belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. + Its possible values are: + + - `CampaignGaveLowerDiscount`: The required campaign and referral conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. + - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. + - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the referral is part of an archived campaign. example: CampaignGaveLowerDiscount type: string required: - rejectionReason - value + title: rejectReferral type: object CouponCreatedEffectProps: - description: The properties specific to the "couponCreated" effect. This gets - triggered whenever a validated rule contained a "create coupon" effect, and - a coupon was created for a customer. See "createdCoupons" on the response - for all details of this coupon. + description: |- + This effect indicates that a coupon was created. + + For referrals and retention marketing, a common use case is to generate a coupon that can only be redeemed by one specific customer. + + Handle this effect by notifying the recipient about their new coupon code. + example: + value: COUP-NEW123 + profileId: customer_profile_id_1 properties: value: description: The coupon code that was created. @@ -15523,97 +16942,136 @@ components: required: - profileId - value + title: couponCreated type: object ReferralCreatedEffectProps: - description: The properties specific to the "referralCreated" effect. This gets - triggered whenever a validated rule contained a "create referral" effect, - and a referral code was created for a customer. See "createdReferrals" on - the response for all details of this referral code. + description: The `referralCreated` effect behaves similarly to [couponCreated](https://docs.talon.one/docs/dev/integration-api/api-effects#couponcreated). + If the `friendProfileIntegrationId` parameter is empty, the referral code + can be redeemed by anyone. + example: + value: REF-NEW456 properties: value: - description: The referral code that was created. + description: The referral code provided in the session. type: string required: - value + title: referralCreated type: object SetDiscountEffectProps: - description: The properties specific to the "setDiscount" effect. This gets - triggered whenever a validated rule contained a "set discount" effect. This - is a discount that should be applied on the scope of defined with it. + description: |- + This effect indicates that a discount should be set on the total shopping cart value of the current order with the given label and amount. + + The discount should overwrite any existing discount with the same name. The most recent integration state update always returns the latest values for **all** effects, effectively overwriting any previous effects. + + Enabling [partial discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches `0`. Use the `desiredValue` property to identify the original value of the discount. + example: + name: 10% Off + value: 2.5 + scope: sessionTotal + desiredValue: 2.5 properties: name: - description: The name / description of this discount + description: The name or description of this discount. type: string value: - description: The total monetary value of the discount. + description: The monetary value of the effective discount. type: number scope: - description: The scope which the discount was applied on, can be one of - (cartItems,additionalCosts,sessionTotal). + description: |- + What the discount applies to. Possible values: + + - `cartItems`: Discount on the price of the items. + - `additionalCosts`: Discount on the [additional costs](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the items. + - `sessionTotal`: Discount on the total value of the customer session. + + **Note:** [Cascading discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#cascading-discounts) must be enabled for this property to be returned. type: string desiredValue: - description: The original value of the discount. + description: _(Partial discounts enabled only)_ The monetary value of the + discount to be applied without considering budget limitations. type: number required: - name - value + title: setDiscount type: object SetDiscountPerItemEffectProps: - description: | - The properties specific to the `setDiscountPerItem` effect, triggered whenever a validated rule contained a - "set per item discount" effect. - This is a discount that will be applied either on a specific item, on a specific item + additional cost or on all additional costs per item. - This depends on the chosen scope. + description: |- + This effect schema is returned when you use the **Discount individual items**, **Discount individual items pro rata**, or **Discount individual item in bundles** effect in a rule. + + It indicates that a discount per item should be applied on the specific item specified in the effect. + + The properties it contains depends on: + + - Whether you used a pro rata effect or not. + - Whether you used an effect with bundles or not. + - Whether the partial discount feature is enabled. + example: + name: 'Discount on item #1' + value: 1.5 + position: 1 + subPosition: 1 + desiredValue: 1.5 + scope: price + totalDiscount: 1.5 + desiredTotalDiscount: 1.5 + bundleIndex: 1 + bundleName: my_bundle + targetedItemPosition: 1 + targetedItemSubPosition: 1 + excludedFromPriceHistory: false properties: name: - description: | - The name of the discount. Contains a hashtag character indicating the index of the position of the item the discount applies - to. It is identical to the value of the `position` property. + description: The description of this discount. `#number` is equal to the + `position` property. type: string value: - description: The total monetary value of the discount. + description: The monetary value of the effective discount applied to the + item. type: number position: - description: The index of the item in the cart items list on which this + description: The index of the item in the `cartItem` object on which this discount should be applied. type: number subPosition: - description: | - For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. + description: The index of the item unit in its line item. type: number desiredValue: - description: The original value of the discount. + description: _(Partial discounts enabled only)_ The monetary value of the + discount to be applied to the item without considering budget limitations. type: number scope: - description: | - The scope of the discount: - - `additionalCosts`: The discount applies to all the additional costs of the item. - - `itemTotal`: The discount applies to the price of the item + the additional costs of the item. - - `price`: The discount applies to the price of the item. + description: |- + What the discount applies to. Possible values: + + - `price`: discount on the price of the item. + - `additionalCosts`: discount on the [additional cost](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the item. + - `itemTotal`: discount on the sum of price + additional cost of the item. type: string totalDiscount: - description: The total discount given if this effect is a result of a prorated - discount. + description: _(Pro rata discounts only)_ The monetary value of the total + effective discount type: number desiredTotalDiscount: - description: The original total discount to give if this effect is a result - of a prorated discount. + description: _(Pro rata discounts only)_ The monetary value of the total + discount to be applied without considering budget limitations type: number bundleIndex: - description: The position of the bundle in a list of item bundles created - from the same bundle definition. + description: _(Discounts with bundles only)_ The position of the specific + item bundle in the list of bundles created from the same bundle definition. format: int64 type: integer bundleName: - description: The name of the bundle definition. + description: _(Discounts with bundles only)_ The name of the bundle definition. type: string targetedItemPosition: - description: The index of the targeted bundle item on which the applied - discount is based. + description: _(Discounting individual item in bundles only)_ The index of + the targeted bundle item on which the applied discount is based. type: number targetedItemSubPosition: - description: | - The sub-position of the targeted bundle item on which the applied discount is based. + description: _(Discounting individual item in bundles only)_ The sub-position + of the targeted bundle item on which the applied discount is based. type: number excludedFromPriceHistory: description: When set to `true`, the applied discount is excluded from the @@ -15623,50 +17081,62 @@ components: - name - position - value + title: setDiscountPerItem type: object SetDiscountPerAdditionalCostEffectProps: - description: The properties specific to the "setDiscountPerAdditionalCost" effect. - This gets triggered whenever a validated rule contained a "set per additional - cost discount" effect. This is a discount that should be applied on a specific - additional cost. + description: |- + This effect indicates that a discount that should be applied on a specific additional cost. It is triggered whenever a rule containing a **Discount additional cost** effect is validated. + + Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. + example: + name: Shipping discount + additionalCostId: 1 + additionalCost: shipping + value: 4.99 + desiredValue: 4.99 properties: name: - description: The name / description of this discount + description: The name of the discount. type: string additionalCostId: - description: The ID of the additional cost. + description: The identifier of the additional cost. format: int64 type: integer additionalCost: - description: The name of the additional cost. + description: The API name of the additional cost. type: string value: - description: The total monetary value of the discount. + description: The monetary value of the discount to apply. type: number desiredValue: - description: The original value of the discount. + description: _(Partial discounts enabled only)_ The monetary value of the + discount to be applied without considering budget limitations. type: number required: - additionalCost - additionalCostId - name - value + title: setDiscountPerAdditionalCost type: object TriggerWebhookEffectProps: - description: The properties specific to the "triggerWebhook" effect. This gets - triggered whenever a validated rule contained a "trigger webhook" effect. - This is communicated as an FYI and should usually not require action on your - side. + description: This effect is triggered when a rule containing a [webhook effect](https://docs.talon.one/docs/product/rules/effects/available-effects#webhooks) + is validated. The details are shared with you for your information only. It + usually doesn't require an action on your side. + example: + webhookId: 7 + webhookName: My Webhook properties: webhookId: - description: The ID of the webhook that was triggered. + description: The internal ID of the webhook. type: number webhookName: - description: The name of the webhook that was triggered. + description: The name of the webhook. type: string required: - webhookId - webhookName + title: triggerWebhook type: object LoyaltyCardIdentifier: description: | @@ -15677,11 +17147,42 @@ components: pattern: ^[A-Za-z0-9._%+@-]+$ type: string AddLoyaltyPointsEffectProps: - description: | - The properties specific to the "addLoyaltyPoints" effect. This gets triggered whenever a validated rule contained an "add loyalty" effect. These points are automatically stored and managed inside Talon.One. + description: |- + This effect indicates that a defined amount of loyalty points was successfully added to the customer's profile or to a loyalty card. + + If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which item to add the loyalty points for. + + Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. + + If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. See the example below for more information. + + If your list of cart items is a [bundle definition](https://docs.talon.one/docs/product/rules/create-and-manage-bundles), use the `bundleIndex` and `bundleName` properties to identify the bundle containing the items for which loyalty points are added. + + If you have set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. + + If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card on which these points are added. + + The points only persist when the session is closed. + example: + name: Points for purchase + programId: 5 + subLedgerId: main + value: 100 + desiredValue: 100 + recipientIntegrationId: URNGV8294NV + startDate: 2024-01-01T00:00:00Z + expiryDate: 2025-01-01T00:00:00Z + transactionUUID: 8c2d3670-6ea5-4e9e-b5c6-e7e7b4a10111 + cartItemPosition: 1 + cartItemSubPosition: 1 + cardIdentifier: loyalty-card-001 + bundleIndex: 1 + bundleName: my_bundle + awaitsActivation: false + validityDuration: 12M properties: name: - description: The name / description of this loyalty point addition. + description: The reason of this loyalty point addition. type: string programId: description: The ID of the loyalty program where these points were added. @@ -15695,7 +17196,8 @@ components: description: The amount of points that were added. type: number desiredValue: - description: The original amount of loyalty points to be awarded. + description: (Partial rewards enabled only) The amount of loyalty points + to be awarded without considering budget limitations. type: number recipientIntegrationId: description: The user for whom these points were added. @@ -15703,23 +17205,23 @@ components: maxLength: 1000 type: string startDate: - description: Date after which points will be valid. + description: The date after which the added points will be valid. format: date-time type: string expiryDate: - description: Date after which points will expire. + description: The date after which the added points will expire. format: date-time type: string transactionUUID: - description: The identifier of this addition in the loyalty ledger. + description: The identifier of this loyalty point transaction. type: string cartItemPosition: - description: The index of the item in the cart items list on which the loyal - points addition should be applied. + description: (_Add points per cart item_ only.) The index of the item in + the `cartItem` object for which these points were added. type: number cartItemSubPosition: - description: | - For cart items with `quantity` > 1, the sub position indicates to which item the loyalty points addition is applied. + description: (_Add points per cart item_ ) The index of the item unit in + its line item. type: number cardIdentifier: description: | @@ -15730,21 +17232,21 @@ components: pattern: ^[A-Za-z0-9._%+@-]+$ type: string bundleIndex: - description: The position of the bundle in a list of item bundles created - from the same bundle definition. + description: _(With bundles only)_ The position of the specific bundle in + the list of bundles created from the same bundle definition. format: int64 type: integer bundleName: - description: The name of the bundle definition. + description: _(With bundles only)_ The name of the bundle definition. type: string awaitsActivation: - description: | - If `true`, the loyalty points remain pending until a specific action is complete. The `startDate` parameter automatically sets to `on_action`. + description: Indicates whether the points have an action-based start date. + This property is returned only for point transactions with an action-based + start date. type: boolean validityDuration: - description: "The duration for which the points remain active, calculated\ - \ relative to the \nactivation date. \n\n**Note**: This value is returned\ - \ only if `awaitsActivation` is `true` \nand `expiryDate` is not set.\n" + description: The duration for which the points remain active, calculated + relative to their start date. type: string required: - name @@ -15753,34 +17255,51 @@ components: - subLedgerId - transactionUUID - value + title: addLoyaltyPoints type: object DeductLoyaltyPointsEffectProps: - description: The properties specific to the "deductLoyaltyPoints" effect. This - gets triggered whenever a validated rule contained a condition to only trigger - when the given number of loyalty points could be deduced. These points are - automatically stored and managed inside Talon.One. + description: |- + This effect is triggered when a customer redeems loyalty points. The points are deducted from their active point balance. + + If the loyalty program is card-based, use the `cardIdentifier` property to identify the loyalty card from which these points are deducted. + + The Rule Engine deducts points in this order: + + - Points with the earliest expiry date are deducted first, regardless of when they were added. + - Points with an unlimited expiry date are deducted last. + - For points with an unlimited expiry date, the points awarded first are deducted first. + + The points only persist when the session is closed. + example: + ruleTitle: Deduct points on return + programId: 5 + subLedgerId: main + value: 50 + transactionUUID: 9f3e4781-7fb6-5f0f-c6d7-f8f8c5b21222 + name: Points deducted for return + cardIdentifier: loyalty-card-001 properties: ruleTitle: description: The title of the rule that contained triggered this points deduction. type: string programId: - description: The ID of the loyalty program where these points were added. + description: The ID of the loyalty program from which these points were + deducted. format: int64 type: integer subLedgerId: - description: The ID of the subledger within the loyalty program where these - points were added. + description: The ID of the subledger within the loyalty program from which + these points were deducted. type: string value: description: The amount of points that were deducted. type: number transactionUUID: - description: The identifier of this deduction in the loyalty ledger. + description: The identifier of this loyalty point transaction. type: string name: - description: | - The name property gets one of the following two values. It can be the loyalty program name or it can represent a reason for the respective deduction of loyalty points. The latter is an optional value defined in a deduction rule. + description: The reason of this loyalty points deduction. type: string cardIdentifier: description: | @@ -15797,21 +17316,30 @@ components: - subLedgerId - transactionUUID - value + title: deductLoyaltyPoints type: object ChangeLoyaltyTierLevelEffectProps: - description: | - The properties specific to the "changeLoyaltyTierLevel" effect. - This is triggered whenever the user's loyalty tier is upgraded due to a validated rule that contained an "addLoyaltyPoints" effect. + description: |- + This effect indicates that a customer's loyalty tier has been upgraded. + + This effect is generated only when the [Add loyalty points](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points) and the [Add loyalty points per cart item](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points-per-cart-item) effects are triggered for a particular customer, and, as a result, the customer's loyalty tier is upgraded. + example: + ruleTitle: Tier upgrade on purchase + programId: 5 + subLedgerId: main + previousTierName: Silver + newTierName: Gold + expiryDate: 2025-12-31T23:59:59Z properties: ruleTitle: description: The title of the rule that triggered the tier upgrade. type: string programId: - description: The ID of the loyalty program where these points were added. + description: The ID of the loyalty program where the points were added. format: int64 type: integer subLedgerId: - description: The ID of the subledger within the loyalty program where these + description: The ID of the subledger within the loyalty program where the points were added. type: string previousTierName: @@ -15829,17 +17357,24 @@ components: - programId - ruleTitle - subLedgerId + title: changeLoyaltyTierLevel type: object AddFreeItemEffectProps: - description: The properties specific to the "addFreeItem" effect. This gets - triggered whenever a validated rule contained an "add free item" effect. + description: |- + This effect indicates that a free item should be added to the shopping cart in the current session. In this example, add the SKU to the shopping cart and set its price to `0`. + + The effect of a successful referral can mean a free item for someone else, such as the referrer. + example: + sku: SKU1241028 + name: Free Gift Item + desiredQuantity: 1 properties: sku: description: SKU of the item that needs to be added. example: SKU1241028 type: string name: - description: The name / description of the effect + description: Description of the effect. type: string desiredQuantity: description: The original quantity in case a partial reward was applied. @@ -15848,138 +17383,191 @@ components: required: - name - sku + title: addFreeItem type: object ShowNotificationEffectProps: - description: The properties specific to the "showNotification" effect. This - gets triggered whenever a validated rule contained a "show notification" effect. + description: |- + You can use notifications to inform customers of certain events. There are four types of notification messages: + + - `Info` + - `Offer` + - `Error` + - `Misc` + + It is up to you to use the Rule Builder to decide why and when to show notifications. Notifications can be used as both rule effects and failure effects. + + A common use case is to display the notification at the top of the cart view in your web app. You can use the notification type to vary the styling of the notification message. + example: + notificationType: info + title: Discount applied + body: You have received a 10% discount on your order. properties: notificationType: - description: The type of notification that should be shown (e.g. error/warning/info). + description: The type of notification. type: string title: - description: Title of the notification. + description: The title of the notification. type: string body: - description: Body of the notification. + description: The body of the notification. type: string required: - body - notificationType - title + title: showNotification type: object UpdateAttributeEffectProps: - description: The properties specific to the "updateAttribute" effect. This gets - triggered whenever a validated rule contained an "update an attribute" effect. + description: This effect indicates that a rule containing an [Update attribute + value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) + or [Update cart item attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) + was validated. You should update the value of the attribute in your system + based on the content of the returned effect. + example: + path: Session.Attributes.loyaltyTier + value: Gold properties: path: - description: The exact path of the attribute that was updated. + description: The entity type and the attribute name. type: string value: - description: | - The new value of this attribute. The value can be of the following types: - - boolean - - location - - number - - string - - time - - list of any of those types + description: The new value of the attribute. type: object required: - path - value + title: updateAttribute type: object RollbackCouponEffectProps: - description: The properties specific to the "rollbackCoupon" effect. This gets - triggered whenever previously closed session is now cancelled and a coupon - redemption was cancelled on our internal usage limit counters. + description: |- + This effect indicates that a coupon code redemption has been rolled back. The coupon becomes redeemable again. + + The effect is triggered when you [cancel](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state) a session where a coupon was accepted. See an example of use in the [cancelling a session tutorial](https://docs.talon.one/docs/dev/tutorials/roll-back-effects). + example: + value: COUP-XYZ789 properties: value: - description: The coupon code whose usage has been rolled back. + description: The coupon code whose redemption has been rolled back. type: string required: - value + title: rollbackCoupon type: object RollbackReferralEffectProps: - description: The properties specific to the "rollbackReferral" effect. This - gets triggered whenever previously closed session is now cancelled and a referral - redemption was cancelled on our internal usage limit counters. + description: |- + This effect indicates that the redemption of the referral code has been rolled back. It triggers when a closed session that redeemed a referral is gets cancelled. The code becomes redeemable again. + + For more information about session states, see [Managing states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). + example: + value: REF-ABC123 properties: value: - description: The referral code whose usage has been rolled back. + description: The referral code to be rolled back. type: string required: - value + title: rollbackReferral type: object RollbackDiscountEffectProps: - description: The properties specific to the "rollbackDiscount" effect. This - gets triggered whenever previously closed session is now cancelled or partially - returned and a setDiscount effect was cancelled on our internal discount limit - counters. + description: |- + This effect indicates that a discounted session, cart item, or additional cost has been cancelled or partially returned. This effect can only happen when you set the status of a session to `cancel` or the status changes to `partially_returned`. + + If the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the specific item unit in its line item. See the example below. + example: + name: 10% Off + value: 2.5 + cartItemPosition: 1 + cartItemSubPosition: 1 + additionalCostId: 1 + additionalCost: shipping + scope: sessionTotal properties: name: - description: The name of the "setDiscount" effect that was rolled back. + description: The name of the discount effect that was rolled back. type: string value: - description: The value of the discount that was rolled back. + description: The monetary value of the discount that was rolled back. type: number cartItemPosition: - description: The index of the item in the cart items for which the discount + description: The index of the item in the `cartItem` object whose discount + was rolled back, or the unit containing the additional cost whose discount was rolled back. type: number cartItemSubPosition: - description: | - For cart items with `quantity` > 1, the subposition returns the index of the item unit in its line item. + description: The index of the item unit in its line item for which the discount + was rolled back. type: number additionalCostId: - description: The ID of the additional cost that was rolled back. + description: _Only when rolling back [setDiscountPerAdditionalCost](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcost) + and [setDiscountPerAdditionalCostPerItem](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcostperitem)_ + The ID of the additional cost to be discounted. format: int64 type: integer additionalCost: - description: The name of the additional cost that was rolled back. + description: The API name of the additional cost whose discount was rolled + back. type: string scope: - description: | - The scope of the rolled back discount + description: |- + The scope of the rolled back discount. + - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` type: string required: - name - value + title: rollbackDiscount type: object RollbackAddedLoyaltyPointsEffectProps: - description: The properties specific to the "rollbackAddedLoyaltyPoints" effect. - This gets triggered whenever previously a closed session with an addLoyaltyPoints - effect is cancelled. + description: |- + This effect is triggered in the following cases: + + - A session was cancelled in which loyalty points have been added. + - A session was partially returned and loyalty point were added by the returned items. See [returning items](https://docs.talon.one/docs/dev/tutorials/partially-return-a-session). + + If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which items the loyalty points were rolled back for. + + If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. + + If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user for whom the loyalty points are rolled back. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points were originally added. + example: + programId: 5 + subLedgerId: main + value: 100 + recipientIntegrationId: URNGV8294NV + transactionUUID: 8c2d3670-6ea5-4e9e-b5c6-e7e7b4a10111 + cartItemPosition: 1 + cartItemSubPosition: 1 + cardIdentifier: loyalty-card-001 properties: programId: - description: The ID of the loyalty program where the points were originally - added. + description: The ID of the loyalty program where these points were rolled + back. format: int64 type: integer subLedgerId: description: The ID of the subledger within the loyalty program where these - points were originally added. + points were rolled back. type: string value: description: The amount of points that were rolled back. type: number recipientIntegrationId: - description: The user for whom these points were originally added. + description: The user for whom these points were rolled back. example: URNGV8294NV maxLength: 1000 type: string transactionUUID: - description: The identifier of 'deduction' entry added to the ledger as - the `addLoyaltyPoints` effect is rolled back. + description: The identifier of this loyalty point transaction. type: string cartItemPosition: - description: The index of the item in the cart items for which the loyalty - points were rolled back. + description: (_Add points per cart item_ only.) The index of the item in + the `cartItem` object for which these points were rolled back. type: number cartItemSubPosition: - description: | - For cart items with `quantity` > 1, the sub-position indicates to which item the loyalty points were rolled back. + description: (_Add points per cart item_ ) The index of the item unit in + its line item. type: number cardIdentifier: description: | @@ -15995,11 +17583,30 @@ components: - subLedgerId - transactionUUID - value + title: rollbackAddedLoyaltyPoints type: object RollbackDeductedLoyaltyPointsEffectProps: - description: The properties specific to the "rollbackDeductedLoyaltyPoints" - effect. This effect is triggered whenever a previously closed session is cancelled - and a deductLoyaltyPoints effect was revoked. + description: |- + This effect is triggered in the following cases: + + - A session is _cancelled_ and this session deducted loyalty points. The rollback action returns the redeemed loyalty points to the customer. + - A session is impacted by a _partial return_. Only added loyalty points that are still **pending** are rolled back. + - A session in which loyalty points were spent is reopened. + + See the [session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). + + If you set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. + + If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/profile-based/profile-based-overview), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points are reimbursed. + example: + programId: 5 + subLedgerId: main + value: 50 + recipientIntegrationId: URNGV8294NV + startDate: 2024-01-01T00:00:00Z + expiryDate: 2025-01-01T00:00:00Z + transactionUUID: 9f3e4781-7fb6-5f0f-c6d7-f8f8c5b21222 + cardIdentifier: loyalty-card-001 properties: programId: description: The ID of the loyalty program where these points were reimbursed. @@ -16010,7 +17617,7 @@ components: points were reimbursed. type: string value: - description: The amount of reimbursed points that were added. + description: The amount of points that were reimbursed. type: number recipientIntegrationId: description: The user for whom these points were reimbursed. @@ -16018,16 +17625,15 @@ components: maxLength: 1000 type: string startDate: - description: Date after which the reimbursed points will be valid. + description: The date after which the reimbursed points will be valid. format: date-time type: string expiryDate: - description: Date after which the reimbursed points will expire. + description: The date after which the reimbursed points will expire. format: date-time type: string transactionUUID: - description: The identifier of 'addition' entries added to the ledger as - the `deductLoyaltyPoints` effect is rolled back. + description: The identifier of this loyalty point transaction. type: string cardIdentifier: description: | @@ -16043,11 +17649,24 @@ components: - subLedgerId - transactionUUID - value + title: rollbackDeductedLoyaltyPoints type: object ShowBundleMetadataEffectProps: - description: | + description: |- This effect is **deprecated**. - The properties specific to the "ShowBundleMetadata" effect. This effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from "normal" discounts that were not the result of a product bundle. + + The `ShowBundleMetadata` effect contains information that allows you to associate + the discounts from a rule in a bundle campaign with specific cart items. + This way you can distinguish from "normal" discounts that were not the result of a product bundle. + example: + description: Buy 2 get 1 free bundle + bundleAttributes: + - category + - brand + itemsIndices: + - 0 + - 1 + - 2 properties: description: description: Description of the product bundle. @@ -16067,33 +17686,40 @@ components: - bundleAttributes - description - itemsIndices + title: showBundleMetadata type: object + x-deprecated: true AwardGiveawayEffectProps: - description: The properties specific to the "awardGiveaway" effect. This effect - contains information on the giveaway item, and which profile it was awarded - to. + description: This effect indicates the awarded giveaway item and to which profile + the item was awarded. Learn more about [giveaways](https://docs.talon.one/docs/product/giveaways/overview). + example: + poolId: 2 + poolName: My pool + recipientIntegrationId: URNGV8294NV + giveawayId: 5 + code: 57638t-67439hty properties: poolId: - description: The ID of the giveaways pool the code was taken from. + description: The internal ID of the giveaway pool. example: 2 format: int64 type: integer poolName: - description: The name of the giveaways pool the code was taken from. + description: The name of the giveaway pool. example: My pool type: string recipientIntegrationId: - description: The integration ID of the profile that was awarded the giveaway. + description: The integration ID of the customer that receives the giveaway. example: URNGV8294NV maxLength: 1000 type: string giveawayId: - description: The internal ID for the giveaway that was awarded. + description: The internal ID of the giveaway. example: 5 format: int64 type: integer code: - description: The giveaway code that was awarded. + description: The giveaway code to be rewarded. example: 57638t-67439hty type: string required: @@ -16102,25 +17728,29 @@ components: - poolId - poolName - recipientIntegrationId + title: awardGiveaway type: object WillAwardGiveawayEffectProps: - description: The properties specific to the "awardGiveaway" effect when the - session is not closed yet. This effect replaces "awardGiveaway" only when - updating a session with any state other than "closed". This is to ensure no - giveaway codes are leaked when they are still not guaranteed to be awarded. + description: |- + The equivalent of the `awardGiveaway` effect but returned when updating a session with any state other than `closed`. This ensures no giveaway codes are leaked when they are still not guaranteed to be awarded. + + For more information about session states, see [Manage the session's state](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state). + example: + poolId: 2 + poolName: My pool + recipientIntegrationId: URNGV8294NV properties: poolId: - description: The ID of the giveaways pool the code will be taken from. + description: The internal ID of the giveaway pool. example: 2 format: int64 type: integer poolName: - description: The name of the giveaways pool the code will be taken from. + description: The name of the giveaway pool. example: My pool type: string recipientIntegrationId: - description: The integration ID of the profile that will be awarded the - giveaway. + description: The integration ID of the customer that receives the giveaway. example: URNGV8294NV maxLength: 1000 type: string @@ -16128,19 +17758,37 @@ components: - poolId - poolName - recipientIntegrationId + title: willAwardGiveaway type: object ErrorEffectProps: - description: Whenever an error occurred during evaluation, we return an error - effect. This should never happen for rules created in the rule builder. + description: This effect is triggered whenever an error occurs during rule evaluation. + This effect only provides information about what the error is. + example: + message: An unexpected error occurred during rule evaluation. properties: message: description: The error message. type: string required: - message + title: error type: object CustomEffectProps: - description: Effect containing custom payload. + description: |- + If you want to return data as an effect but no effect matches your use case, you can [create a custom effect](https://docs.talon.one/docs/dev/tutorials/create-custom-effects). + + Custom effects can be used as both rule effects and failure effects. + + The structure of a custom effect depends on your specifications but is always named `customEffect`. + example: + effectId: 1 + name: my_custom_effect + cartItemPosition: 1 + cartItemSubPosition: 2 + bundleIndex: 1 + bundleName: my_bundle + payload: + key: value properties: effectId: description: The ID of the custom effect that was triggered. @@ -16180,38 +17828,48 @@ components: - effectId - name - payload + title: customEffect type: object SetDiscountPerAdditionalCostPerItemEffectProps: - description: The properties specific to the "setDiscountPerAdditionalCostPerItem" - effect. This gets triggered whenever a validated rule contained a "set discount - per additional cost per item" effect. This is a discount that should be applied - on a specific additional cost in a specific item. + description: |- + This effect indicates that a discount of a specific additional cost within a specific item should be applied. It gets triggered whenever a rule containing a **Discount additional cost per item** effect is validated. + + Use this effect when **all** items in the cart have an additional cost. If one of more items do not have an additional cost, the rule will fail. + example: + name: 'Shipping discount on item #1' + additionalCostId: 1 + value: 4.99 + position: 1 + subPosition: 1 + additionalCost: shipping + desiredValue: 4.99 properties: name: - description: The name / description of this discount + description: The description of this discount. `#number` is appended to + the name. It is equal to the `position` property. type: string additionalCostId: - description: The ID of the additional cost. + description: The identifier of the additional cost to be discounted. format: int64 type: integer value: - description: The total monetary value of the discount. + description: The monetary value of the effective discount applied to the + item's additional cost. type: number position: - description: The index of the item in the cart item list containing the - additional cost to be discounted. + description: The index of the item in the `cartItem` object containing the + additional cost that this discount applies to. type: number subPosition: - description: | - For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. + description: The index of the item unit in its line item. type: number additionalCost: - description: The name of the additional cost. + description: The API name of the additional cost to be discounted. type: string desiredValue: - description: | - Only with [partial discounts enabled](https://docs.talon.one/docs/product/campaigns/campaign-evaluation/#partial-discounts). - Represents the monetary value of the discount to be applied to additional discount without considering budget limitations. + description: _[(Partial discounts enabled only)](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts)_. + The monetary value of the discount to be applied to the additional cost + without considering budget limitations. type: number required: - additionalCost @@ -16219,17 +17877,24 @@ components: - name - position - value + title: setDiscountPerAdditionalCostPerItem type: object ReserveCouponEffectProps: - description: The properties specific to the "reserveCoupon" effect. This gets - triggered whenever a validated rule contained a "reserve coupon" effect. This - reserves the coupon currently on scope to the profile on scope. + description: |- + This effect indicates that the given coupon code was reserved for the given customer. + + Talon.One provides soft and hard reservations. For more information, see [Reserve a coupon code](https://docs.talon.one/docs/product/rules/effects/use-effects#reserve-a-coupon-code). + example: + couponValue: COUP-XYZ789 + profileIntegrationId: customer_profile_id_1 + isNewReservation: true properties: couponValue: - description: The value of the coupon currently on scope. + description: The coupon code that was created. type: string profileIntegrationId: - description: The ID of this customer profile in the third-party integration. + description: The integration identifier of the customer for whom this coupon + was reserved. type: string isNewReservation: description: Indicates whether this is a new coupon reservation or not. @@ -16238,10 +17903,18 @@ components: - couponValue - isNewReservation - profileIntegrationId + title: reserveCoupon type: object AddToAudienceEffectProps: - description: The properties specific to the "addToAudience" effect. This gets - triggered whenever a validated rule contains an "addToAudience" effect. + description: This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) + effect with **Add customer to an audience** selected is validated. It indicates + that a customer was added to an audience and is returned when a customer session + is opened, updated, or closed. + example: + audienceId: 10 + audienceName: My audience + profileIntegrationId: URNGV8294NV + profileId: 150 properties: audienceId: description: The internal ID of the audience. @@ -16262,10 +17935,18 @@ components: example: 150 format: int64 type: integer + title: addToAudience type: object RemoveFromAudienceEffectProps: - description: The properties specific to the "removeFromAudience" effect. This - gets triggered whenever a validated rule contains a "removeFromAudience" effect. + description: This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) + effect with **Remove customer from an audience** selected is validated. It + indicates that a customer was removed from an audience and is returned when + a customer session is opened, updated, or closed. + example: + audienceId: 10 + audienceName: My audience + profileIntegrationId: URNGV8294NV + profileId: 150 properties: audienceId: description: The internal ID of the audience. @@ -16286,11 +17967,21 @@ components: example: 150 format: int64 type: integer + title: removeFromAudience type: object IncreaseAchievementProgressEffectProps: - description: The properties specific to the "increaseAchievementProgress" effect. - This gets triggered whenever a validated rule contained an "increase customer - progress" effect. + description: |- + This effect indicates that the customer's progress in an achievement was updated during the current session. It is triggered when a rule using the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect is successfully validated. + + For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), any customer progress exceeding the target automatically starts a new iteration. This generates a new `progressTrackerId` for each iteration, and there can be multiple progress updates for the same achievement from a single validation of this effect. + example: + achievementId: 10 + achievementName: FreeCoffee10Orders + progressTrackerId: 42 + delta: 1 + value: 7 + target: 10 + isJustCompleted: false properties: achievementId: description: The internal ID of the achievement. @@ -16302,12 +17993,14 @@ components: example: FreeCoffee10Orders type: string progressTrackerId: - description: The internal ID of the achievement progress tracker. + description: |- + The internal ID of the customer progress tracker. + For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. format: int64 type: integer delta: description: The value by which the customer's current progress in the achievement - is increased. + has increased. type: number value: description: The current progress of the customer in the achievement. @@ -16326,12 +18019,22 @@ components: - isJustCompleted - target - value + title: increaseAchievementProgress type: object RollbackIncreasedAchievementProgressEffectProps: - description: The properties specific to the "rollbackIncreasedAchievementProgress" - effect. This gets triggered whenever a closed session where the `increaseAchievementProgress` - effect was triggered is cancelled. This is applicable only when the customer - has not completed the achievement. + description: |- + This effect indicates that the customer's progress in an achievement was rolled back. + + The Rule Engine triggers this effect when you cancel or [reopen a customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession) that previously validated the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect and triggered the [increaseAchievementProgress](https://docs.talon.one/docs/dev/integration-api/api-effects#increaseachievementprogress) API effect. + + The effect is also triggered for completed achievements if the **Allow progress rollback for completed achievements** setting is enabled. You can enable this through the [Campaign Manager](https://docs.talon.one/docs/product/achievements/manage-achievements) or the [Management API](https://docs.talon.one/management-api#tag/Achievements/operation/createAchievement) by setting the `achievementAllowRollbackAfterCompletion` property to `true`. This setting only applies to one-time and recurring on expiration achievements. + example: + achievementId: 10 + achievementName: FreeCoffee10Orders + progressTrackerId: 42 + decreaseProgressBy: 1 + currentProgress: 6 + target: 10 properties: achievementId: description: The internal ID of the achievement. @@ -16348,7 +18051,7 @@ components: type: integer decreaseProgressBy: description: The value by which the customer's current progress in the achievement - is decreased. + has decreased. type: number currentProgress: description: The current progress of the customer in the achievement. @@ -16363,6 +18066,7 @@ components: - decreaseProgressBy - progressTrackerId - target + title: rollbackIncreasedAchievementProgress type: object LoyaltyLedgerEntryExpiryDateChange: description: The properties specific to effects for changing the expiry dates @@ -16389,7 +18093,12 @@ components: type: object ExtendLoyaltyPointsExpiryDateEffectProps: description: | - The properties specific to the "extendLoyaltyPointsExpiryDate" effect. This gets triggered when a validated rule contains the "extend expiry date" effect. The current expiry date gets extended by the time frame given in the effect. + If loyalty points have an expiry date, this effect extends the expiry of all active and pending point transactions by a selected duration. + example: + programId: 5 + subLedgerId: main + extensionDuration: 12h + affectedTransactions: [] properties: programId: description: ID of the loyalty program that contains these points. @@ -16397,7 +18106,7 @@ components: type: integer subLedgerId: description: API name of the loyalty program subledger that contains these - points. added. + points. type: string extensionDuration: description: | @@ -16433,6 +18142,217 @@ components: - extensionDuration - programId - subLedgerId + title: extendLoyaltyPointsExpiryDate + type: object + SetLoyaltyPointsExpiryDateEffectProps: + description: | + This effect updates the expiry date of all active, pending, and unlimited point transactions to a specific date. + example: + programId: 5 + subLedgerId: main + newExpiryDate: 2024-07-24T14:15:22Z + affectedTransactions: [] + properties: + programId: + description: ID of the loyalty program that contains these points. + format: int64 + type: integer + subLedgerId: + description: API name of the loyalty program subledger that contains these + points. + type: string + newExpiryDate: + description: The specified expiry date and time for all active and pending + point transactions in the loyalty program subledger. + example: 2024-07-24T14:15:22Z + format: date-time + type: string + affectedTransactions: + description: List of transactions affected by the expiry date update. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntryExpiryDateChange' + type: array + required: + - newExpiryDate + - programId + - subLedgerId + title: setLoyaltyPointsExpiryDate + type: object + JoinLoyaltyProgramEffectProps: + description: | + This effect indicates that a customer profile was joined to a profile-based loyalty program with the specified join date. + + > [!note] **Note** + > - This effect requires a customer profile. It does not work for anonymous sessions. + > - The effect fails if the customer profile has already joined the loyalty program. + example: + programId: 5 + joinDate: 2026-01-02T03:04:05Z + properties: + programId: + description: The ID of the loyalty program the customer profile is joined + to. + example: 5 + format: int64 + type: integer + joinDate: + description: The date and time when the customer profile joined the loyalty + program. + example: 2026-01-02T03:04:05Z + format: date-time + type: string + required: + - joinDate + - programId + title: joinLoyaltyProgram + type: object + StartAchievementProgressEffectProps: + description: | + This effect indicates that the customer's progress in an achievement was started during the current session. The progress value is set to 0. It is triggered when a rule using the [Start achievement progress](https://docs.talon.one/docs/product/rules/effects/use-effects#start-achievement-progress) effect is successfully validated. + + This effect only marks the start of progress tracking. It can fire together with `increaseAchievementProgress` when progress starts and increases at the same time. In that case, both effects share the same `progressTrackerId`, `startDate`, and `endDate`. + + For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), each iteration also gets its own `startDate` and `endDate`. + example: + achievementId: 10 + achievementName: FreeCoffee10Orders + progressTrackerId: 42 + target: 10 + startDate: 2026-04-16T15:25:37Z + endDate: 2026-04-30T11:24:59Z + properties: + achievementId: + description: The ID of the achievement. + example: 10 + format: int64 + type: integer + achievementName: + description: The name of the achievement. + example: FreeCoffee10Orders + type: string + progressTrackerId: + description: |- + The ID of the customer's progress tracker for this achievement. + + For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. + example: 42 + format: int64 + type: integer + target: + description: The target value to complete the achievement. + example: 10.0 + type: number + startDate: + description: Timestamp at which the customer's progress started. + example: 2026-04-16T15:25:37Z + format: date-time + type: string + endDate: + description: |- + Timestamp at which this progress period ends. + + Only returned for achievements that have a fixed end date. [On-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements) have no end date. + example: 2026-04-30T11:24:59Z + format: date-time + type: string + required: + - achievementId + - achievementName + - startDate + - target + title: startAchievementProgress + type: object + UnlockRewardEffectProps: + description: The properties specific to the "unlockReward" effect. This gets + triggered whenever a validated rule unlocks a reward for a customer profile. + properties: + integrationId: + description: The integration ID assigned to the customer reward unlock. + example: reward-unlock-123 + type: string + rewardId: + description: The internal ID of the reward that was unlocked. + example: 5 + format: int64 + type: integer + applicationId: + description: The internal ID of the application the reward belongs to. + example: 1 + format: int64 + type: integer + profileIntegrationId: + description: The integration ID of the customer profile that unlocked the + reward. + example: customer1 + type: string + unlockedAt: + description: The time the reward was unlocked. + example: 2024-05-29T15:04:05Z + format: date-time + type: string + cardIdentifier: + description: | + The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + example: summer-loyalty-card-0543 + maxLength: 108 + minLength: 4 + pattern: ^[A-Za-z0-9._%+@-]+$ + type: string + required: + - applicationId + - integrationId + - profileIntegrationId + - rewardId + - unlockedAt + title: unlockReward + type: object + UseRewardEffectProps: + description: This effect is triggered when a rule that uses a customer's unlocked + reward is validated during session evaluation. + properties: + integrationId: + description: The integration ID of the customer reward that was used. + example: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + type: string + rewardId: + description: The ID of the reward that was used. + example: 5 + format: int64 + type: integer + applicationId: + description: The ID of the Application the reward belongs to. + example: 1 + format: int64 + type: integer + required: + - applicationId + - integrationId + - rewardId + title: useReward + type: object + RollbackUseRewardEffectProps: + description: This effect is triggered when a reward usage has been rolled back + by a session cancellation. + properties: + integrationId: + description: The integration ID of the customer reward that was rolled back. + example: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + type: string + rewardId: + description: The ID of the reward that was rolled back. + example: 5 + format: int64 + type: integer + applicationId: + description: The ID of the Application the reward belongs to. + example: 1 + format: int64 + type: integer + required: + - applicationId + - integrationId + - rewardId + title: RollbackUseReward type: object Effect: description: A generic effect that is fired by a triggered campaign. The props @@ -16447,6 +18367,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -16542,6 +18463,12 @@ components: example: 68851723-e6fa-488f-ace9-112581e6c19b format: uuid type: string + rewardId: + description: The ID of the reward that was being evaluated when this effect + was triggered. + example: 7 + format: int64 + type: integer props: type: object required: @@ -16564,6 +18491,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -16581,6 +18509,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -16592,6 +18521,7 @@ components: customerSession: couponCodes: - XMAS-20-2021 + cartItemAdditionalCostTotal: 15.0 updateCount: 3 created: 2020-02-07T08:15:22Z identifiers: @@ -16602,7 +18532,7 @@ components: variantID: 2 - experimentID: 1 variantID: 2 - total: 119.99 + total: 134.99 loyaltyCards: - loyalty-card-1 additionalCosts: @@ -16688,6 +18618,8 @@ components: price: 100 height: 0.8008281904610115 updated: 2020-02-08T14:15:22Z + rewardIntegrationIds: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 firstSession: true cartItemTotal: 99.99 properties: @@ -16769,6 +18701,13 @@ components: customerSession: couponCodes: - XMAS-20-2021 + identifiers: + - d41306257915f83fe01e54092ae470f631161ea16fcf4415842eed41470386ea + experimentVariantAllocations: + - experimentID: 1 + variantID: 2 + - experimentID: 1 + variantID: 2 loyaltyCards: - loyalty-card-1 additionalCosts: @@ -16776,8 +18715,6 @@ components: price: 9 storeIntegrationId: STORE-001 profileId: URNGV8294NV - identifiers: - - d41306257915f83fe01e54092ae470f631161ea16fcf4415842eed41470386ea evaluableCampaignIds: - 10 - 12 @@ -16852,11 +18789,8 @@ components: base: price: 100 height: 0.8008281904610115 - experimentVariantAllocations: - - experimentID: 1 - variantID: 2 - - experimentID: 1 - variantID: 2 + rewardIntegrationIds: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 responseContent: - customerSession - customerProfile @@ -16884,6 +18818,9 @@ components: - awardedGiveaways - ruleFailureReasons - previousReturns + - campaignEligibility + - achievements + - unlockedRewards type: string type: array required: @@ -17032,6 +18969,7 @@ components: $ref: '#/components/schemas/LoyaltyMembership' title: Loyalty programed joined type: array + x-deprecated: true audienceMemberships: description: The audiences the customer belongs to. items: @@ -17145,12 +19083,14 @@ components: example: 0.0 title: Expired balance type: number + x-deprecated: true spentBalance: description: | **DEPRECATED** Value is shown as 0. example: 0.0 title: Spent balance type: number + x-deprecated: true tentativeCurrentBalance: description: | The tentative points balance, reflecting the `currentBalance` and all point additions and deductions within the current open customer session. When the session is closed, the effects are applied and the `currentBalance` is updated to this value. @@ -17264,12 +19204,14 @@ components: example: 0.0 title: Expired balance type: number + x-deprecated: true spentBalance: description: | **DEPRECATED** Value is shown as 0. example: 0.0 title: Spent balance type: number + x-deprecated: true tentativeCurrentBalance: description: | The tentative points balance, reflecting the `currentBalance` and all point additions and deductions within the current open customer session. When the session is closed, the effects are applied and the `currentBalance` is updated to this value. @@ -17537,6 +19479,7 @@ components: additionalProperties: $ref: '#/components/schemas/LedgerInfo' description: A map containing information about each loyalty subledger. + Subledgers for which all balances are zero are excluded from the response. type: object required: - id @@ -17957,6 +19900,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponSettings: @@ -18066,6 +20010,7 @@ components: example: 163 format: int64 type: integer + x-deprecated: true referralRedemptionCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18073,12 +20018,14 @@ components: example: 3 format: int64 type: integer + x-deprecated: true discountCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total amount of discounts redeemed in the campaign. example: 288.0 type: number + x-deprecated: true discountEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18086,6 +20033,7 @@ components: example: 343 format: int64 type: integer + x-deprecated: true couponCreationCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18093,6 +20041,7 @@ components: example: 16 format: int64 type: integer + x-deprecated: true customEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18100,6 +20049,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true referralCreationCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18107,6 +20057,7 @@ components: example: 8 format: int64 type: integer + x-deprecated: true addFreeItemEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18114,6 +20065,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true awardedGiveawaysCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18121,12 +20073,14 @@ components: example: 9 format: int64 type: integer + x-deprecated: true createdLoyaltyPointsCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total number of loyalty points created by rules in this campaign. example: 9.0 type: number + x-deprecated: true createdLoyaltyPointsEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18134,12 +20088,14 @@ components: example: 2 format: int64 type: integer + x-deprecated: true redeemedLoyaltyPointsCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total number of loyalty points redeemed by rules in this campaign. example: 8.0 type: number + x-deprecated: true redeemedLoyaltyPointsEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18147,6 +20103,7 @@ components: example: 9 format: int64 type: integer + x-deprecated: true callApiEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18154,6 +20111,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true reservecouponEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18161,6 +20119,7 @@ components: example: 9 format: int64 type: integer + x-deprecated: true lastActivity: description: Timestamp of the most recent event received by this campaign. example: 2022-11-10T23:00:00Z @@ -18170,6 +20129,7 @@ components: description: | Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. + example: 2022-10-27T15:00:00Z format: date-time type: string createdBy: @@ -18347,7 +20307,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -18514,6 +20474,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponSettings: @@ -18583,6 +20544,7 @@ components: example: 163 format: int64 type: integer + x-deprecated: true referralRedemptionCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18590,12 +20552,14 @@ components: example: 3 format: int64 type: integer + x-deprecated: true discountCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total amount of discounts redeemed in the campaign. example: 288.0 type: number + x-deprecated: true discountEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18603,6 +20567,7 @@ components: example: 343 format: int64 type: integer + x-deprecated: true couponCreationCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18610,6 +20575,7 @@ components: example: 16 format: int64 type: integer + x-deprecated: true customEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18617,6 +20583,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true referralCreationCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18624,6 +20591,7 @@ components: example: 8 format: int64 type: integer + x-deprecated: true addFreeItemEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18631,6 +20599,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true awardedGiveawaysCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18638,12 +20607,14 @@ components: example: 9 format: int64 type: integer + x-deprecated: true createdLoyaltyPointsCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total number of loyalty points created by rules in this campaign. example: 9.0 type: number + x-deprecated: true createdLoyaltyPointsEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18651,12 +20622,14 @@ components: example: 2 format: int64 type: integer + x-deprecated: true redeemedLoyaltyPointsCount: description: | This property is **deprecated**. The count should be available under *budgets* property. Total number of loyalty points redeemed by rules in this campaign. example: 8.0 type: number + x-deprecated: true redeemedLoyaltyPointsEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18664,6 +20637,7 @@ components: example: 9 format: int64 type: integer + x-deprecated: true callApiEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18671,6 +20645,7 @@ components: example: 0 format: int64 type: integer + x-deprecated: true reservecouponEffectCount: description: | This property is **deprecated**. The count should be available under *budgets* property. @@ -18678,6 +20653,7 @@ components: example: 9 format: int64 type: integer + x-deprecated: true lastActivity: description: Timestamp of the most recent event received by this campaign. example: 2022-11-10T23:00:00Z @@ -18687,6 +20663,7 @@ components: description: | Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. + example: 2022-10-27T15:00:00Z format: date-time type: string createdBy: @@ -18791,19 +20768,517 @@ components: - type - userId type: object + IntegrationCampaignBase: + properties: + applicationId: + description: The ID of the Application that owns this entity. + example: 322 + format: int64 + type: integer + id: + description: Unique ID of Campaign. + example: 4 + format: int64 + type: integer + name: + description: The name of the campaign. + example: Summer promotions + minLength: 1 + title: Campaign Name + type: string + description: + description: A detailed description of the campaign. + example: Campaign for all summer 2021 promotions + title: Campaign Description + type: string + startTime: + description: Timestamp when the campaign will become active. + example: 2021-07-20T22:00:00Z + format: date-time + type: string + endTime: + description: Timestamp when the campaign will become inactive. + example: 2021-09-22T22:00:00Z + format: date-time + type: string + attributes: + description: Arbitrary properties associated with this campaign. + properties: {} + type: object + state: + default: enabled + description: | + The state of the campaign. + enum: + - enabled + example: enabled + type: string + tags: + description: A list of tags for the campaign. + example: + - summer + items: + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 + type: array + features: + description: The features enabled in this campaign. + example: + - coupons + - referrals + items: + enum: + - coupons + - referrals + - loyalty + - giveaways + - strikethrough + - achievements + - advancedEvents + type: string + type: array + required: + - applicationId + - features + - id + - name + - state + - tags + type: object + CampaignEligibilityFailureDetails: + description: The details about why the customer was not eligible for the campaign + in the current session. + example: + failureCode: ALL_RULES_FAILED + properties: + failureCode: + description: A code identifying why the customer was not eligible for the + campaign. + enum: + - ALL_RULES_FAILED + - SKIPPED + - AUDIENCE_NOT_MATCHED + type: string + required: + - failureCode + type: object + CampaignEligibilityDetails: + example: + details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + properties: + passed: + description: Indicates whether the customer was eligible for the campaign + in the current session. + type: boolean + couponCode: + description: The coupon code used to check a customer's eligibility for + the campaign in the current session, if applicable. + type: string + details: + $ref: '#/components/schemas/CampaignEligibilityFailureDetails' + required: + - passed + type: object + RuleMetadata: + example: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! Offer + valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + properties: + title: + description: A short description of the rule. + example: Give discount via coupon + type: string + displayName: + description: A customer-facing name for the rule. + example: 20% off all shoes! + type: string + displayDescription: + description: "A customer-facing description that explains the details of\ + \ the rule. \n\nFor example, this property can contain details about eligibility\ + \ requirements, reward timelines, or terms and conditions.\n" + example: Get a 20% discount on all shoes during Thanksgiving! Offer valid + till Dec 5 only. + type: string + relatedData: + description: | + Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. + example: https://example.com/discounts/20-off-shoes.png + type: string + required: + - title + type: object + RuleEligibilityFailureDetails: + description: The details about why the customer was not eligible for the rule + in the current session. + example: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + properties: + failureCode: + description: A code identifying why the customer was not eligible for the + rule in the current session. + enum: + - CONDITION_NOT_MET + - EFFECT_FAILED + type: string + couponID: + description: | + The ID of the coupon that was being evaluated when the rule failed. + example: 4928 + format: int64 + type: integer + couponValue: + description: | + The coupon code that was being evaluated when the rule failed. + type: string + referralID: + description: | + The ID of the referral that was being evaluated when the rule failed. + format: int64 + type: integer + referralValue: + description: | + The referral code that was being evaluated when the rule failed. + type: string + conditionIndex: + description: The index of the condition that caused the rule to fail. + format: int64 + type: integer + effectIndex: + description: The index of the effect that caused the rule to fail. + format: int64 + type: integer + details: + description: Additional details about the failure. + type: string + required: + - details + - failureCode + type: object + RuleEligibility: + description: The customer's eligibility for a rule in the current session, based + on whether all of the rule's conditions were met. + example: + details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + properties: + passed: + description: Indicates whether the customer was eligible for the rule in + the current session, based on whether all of the rule's conditions were + met. + example: true + type: boolean + couponCode: + description: The coupon code used to check a customer's eligibility for + the rule in the current session, if applicable. + type: string + details: + $ref: '#/components/schemas/RuleEligibilityFailureDetails' + required: + - passed + type: object + RuleMetadataEligibility: + example: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! Offer + valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + properties: + title: + description: A short description of the rule. + example: Give discount via coupon + type: string + displayName: + description: A customer-facing name for the rule. + example: 20% off all shoes! + type: string + displayDescription: + description: "A customer-facing description that explains the details of\ + \ the rule. \n\nFor example, this property can contain details about eligibility\ + \ requirements, reward timelines, or terms and conditions.\n" + example: Get a 20% discount on all shoes during Thanksgiving! Offer valid + till Dec 5 only. + type: string + relatedData: + description: | + Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. + example: https://example.com/discounts/20-off-shoes.png + type: string + eligibility: + items: + $ref: '#/components/schemas/RuleEligibility' + type: array + required: + - eligibility + - title + type: object + CampaignEligibilityExperiment: + description: | + The identifiers for the [experiment](https://docs.talon.one/management-api#tag/Experiments) and the variant assigned to the customer profile. + Only returned when the customer profile has been assigned to a variant in an experiment campaign. + example: + id: 5 + variantId: 5 + properties: + id: + description: The ID of the experiment. + format: int64 + type: integer + variantId: + description: The ID of the variant assigned to the customer profile. + format: int64 + type: integer + required: + - id + - variantId + type: object + CampaignEligibility: + description: "A list of campaigns and their evaluation status for the current\ + \ customer session.\n\nFor experiment campaigns, the experiment and variant\ + \ assigned to the customer profile are\nreturned through the `experiment`\ + \ field. Customer profiles with no variant assignment are not included.\n\n\ + **Note**:\n\n- This response can **only** be included if the `dry` parameter\ + \ in the query is set to `true`. \n- Do not include `triggeredCampaigns` or\ + \ `ruleFailureReasons` in `responseContent` to avoid duplicate results.\n" + example: + description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + properties: + applicationId: + description: The ID of the Application that owns this entity. + example: 322 + format: int64 + type: integer + id: + description: Unique ID of Campaign. + example: 4 + format: int64 + type: integer + name: + description: The name of the campaign. + example: Summer promotions + minLength: 1 + title: Campaign Name + type: string + description: + description: A detailed description of the campaign. + example: Campaign for all summer 2021 promotions + title: Campaign Description + type: string + startTime: + description: Timestamp when the campaign will become active. + example: 2021-07-20T22:00:00Z + format: date-time + type: string + endTime: + description: Timestamp when the campaign will become inactive. + example: 2021-09-22T22:00:00Z + format: date-time + type: string + attributes: + description: Arbitrary properties associated with this campaign. + properties: {} + type: object + state: + default: enabled + description: | + The state of the campaign. + enum: + - enabled + example: enabled + type: string + tags: + description: A list of tags for the campaign. + example: + - summer + items: + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 + type: array + features: + description: The features enabled in this campaign. + example: + - coupons + - referrals + items: + enum: + - coupons + - referrals + - loyalty + - giveaways + - strikethrough + - achievements + - advancedEvents + type: string + type: array + eligibility: + description: The customer's eligibility for each campaign in the current + customer session. + items: + $ref: '#/components/schemas/CampaignEligibilityDetails' + type: array + rules: + description: A list of rules containing customer-facing details of the rewards + defined in the campaign. + items: + $ref: '#/components/schemas/RuleMetadataEligibility' + type: array + experiment: + $ref: '#/components/schemas/CampaignEligibilityExperiment' + required: + - applicationId + - eligibility + - features + - id + - name + - rules + - state + - tags + type: object RuleFailureReason: description: Details about why a rule failed. example: - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details @@ -18839,6 +21314,17 @@ components: description: The code of the referral that was being evaluated at the time of the rule failure. type: string + rewardId: + description: The ID of the reward that was being evaluated at the time of + the rule failure. + example: 7 + format: int64 + type: integer + rewardIntegrationId: + description: The integration ID of the reward that was being evaluated at + the time of the rule failure. + example: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + type: string ruleIndex: description: The index of the rule that failed within the ruleset. format: int64 @@ -19414,6 +21900,303 @@ components: - id - poolId type: object + CampaignReference: + example: + id: 1 + applicationId: 2 + properties: + id: + description: The ID of the campaign that references this achievement. + example: 1 + format: int64 + type: integer + applicationId: + description: The ID of the Application the campaign belongs to. + example: 2 + format: int64 + type: integer + required: + - applicationId + - id + type: object + AchievementProgress: + description: The current progress of the customer in the achievement. + example: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + properties: + status: + description: The status of the achievement. + enum: + - inprogress + - completed + - expired + - not_started + example: completed + type: string + progress: + description: The current progress of the customer in the achievement. + example: 10.0 + type: number + startDate: + description: Timestamp at which the customer started the achievement. + format: date-time + type: string + completionDate: + description: Timestamp at which point the customer completed the achievement. + format: date-time + type: string + endDate: + description: Timestamp at which point the achievement ends and resets for + the customer. + format: date-time + type: string + required: + - progress + - status + type: object + CustomerAchievement: + description: A customer's progress in an achievement, together with the achievement + definition. + example: + currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: + - 1 + - 14 + - 27 + recurrencePolicy: no_recurrence + properties: + id: + description: The internal ID of the achievement. + example: 3 + format: int64 + type: integer + name: + description: | + The internal name of the achievement used in API requests. + example: FreeCoffee10Orders + maxLength: 1000 + minLength: 1 + pattern: ^[a-zA-Z]\w+$ + type: string + title: + description: The display name of the achievement in the Campaign Manager. + example: 50% off on 50th purchase. + type: string + description: + description: The description of the achievement in the Campaign Manager. + example: 50% off for every 50th purchase in a year. + format: string + type: string + target: + description: The required number of actions or the transactional milestone + to complete the achievement. + example: 10.0 + type: number + recurrencePolicy: + description: | + 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. + enum: + - no_recurrence + - on_expiration + - on_completion + example: no_recurrence + type: string + activationPolicy: + description: | + 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. + enum: + - user_action + - fixed_schedule + example: fixed_schedule + type: string + fixedStartDate: + description: | + The achievement's start date when `activationPolicy` is equal to `fixed_schedule`. + + **Note:** It is an RFC3339 timestamp string. + format: date-time + type: string + endDate: + description: | + The achievement's end date. If defined, customers cannot participate in the achievement after this date. + + **Note:** It is an RFC3339 timestamp string. + format: date-time + type: string + allowRollbackAfterCompletion: + description: When `true`, customer progress can be rolled back in completed + achievements. + example: false + type: boolean + campaignId: + description: This property is **deprecated**. Use `referencedByCampaigns` + instead. This field contains the first campaign ID from the related `referencedByCampaigns`, + and is omitted when `referencedByCampaigns` is empty. + example: 3 + format: int64 + type: integer + x-deprecated: true + campaignIds: + description: The IDs of the campaigns that reference this achievement, in + ascending order. + example: + - 1 + - 14 + - 27 + items: + format: int64 + type: integer + type: array + referencedByCampaigns: + description: The campaigns that reference this achievement. They are sorted + in ascending order by their `id`. + items: + $ref: '#/components/schemas/CampaignReference' + type: array + currentProgress: + $ref: '#/components/schemas/AchievementProgress' + required: + - activationPolicy + - allowRollbackAfterCompletion + - campaignIds + - description + - id + - name + - recurrencePolicy + - referencedByCampaigns + - target + - title + type: object + CustomerReward: + description: A reward unlocked by a customer profile. + example: + profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + properties: + applicationId: + description: The ID of the Application in which the reward was unlocked. + example: 3 + format: int64 + type: integer + profileIntegrationId: + description: The integration ID of the customer profile that unlocked this + reward. + example: customer1 + type: string + integrationId: + description: The integration ID assigned to this reward unlock. + example: reward-unlock-123 + type: string + unlockedAt: + description: The date and time when the reward was unlocked. + example: 2024-01-01T00:00:00Z + format: date-time + type: string + usedAt: + description: The date and time when the reward was used. + example: 2024-01-02T00:00:00Z + format: date-time + type: string + required: + - applicationId + - integrationId + - profileIntegrationId + - unlockedAt + type: object + RewardWithUnlocks: + description: A reward and details of each time a customer profile has unlocked + it. + example: + name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + properties: + id: + description: The unique ID of the reward. + example: 42 + format: int64 + type: integer + integrationId: + description: A unique identifier used to reference the reward in API integrations. + example: free-coffee + type: string + name: + description: The customer-facing name of the reward. + example: 10% Off Coupon + type: string + description: + description: Customer-facing description of the reward. + example: Applies to next order + type: string + rule: + $ref: '#/components/schemas/RuleMetadata' + unlocked: + description: The customer profile's unlocks of this reward that are not + yet `used`. + items: + $ref: '#/components/schemas/CustomerReward' + type: array + required: + - id + - integrationId + - name + - rule + type: object + Rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array IntegrationResponse: description: | Contains entities that might be valuable in Talon.One integrations. @@ -19428,6 +22211,15 @@ components: items: $ref: '#/components/schemas/Campaign' type: array + campaignEligibility: + description: "A list of campaigns and their evaluation status for the current\ + \ customer session.\n\n**Note**:\n\n- This response can **only** be included\ + \ if the `dry` parameter in the query is set to `true`. \n- Do not include\ + \ `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to\ + \ avoid duplicate results.\n" + items: + $ref: '#/components/schemas/CampaignEligibility' + type: array effects: description: The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). @@ -19456,6 +22248,16 @@ components: items: $ref: '#/components/schemas/Giveaway' type: array + achievements: + description: The achievements progress of the customer. + items: + $ref: '#/components/schemas/CustomerAchievement' + type: array + rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array required: - createdCoupons - createdReferrals @@ -19783,8 +22585,8 @@ components: minLength: 1 type: string type: - description: A string representing the event. Must not be a reserved event - name. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -19799,6 +22601,15 @@ components: - attributes - type type: object + EventV3Entity: + properties: + integrationId: + description: | + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 + type: string + type: object LedgerEntry: description: Entry in the point ledger. example: @@ -19811,7 +22622,7 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 properties: id: description: The internal ID of this entity. @@ -19917,8 +22728,8 @@ components: a 'rejectReferral' effect. example: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 properties: campaignId: format: int64 @@ -19953,8 +22764,8 @@ components: coupons: '{}' referralRejectionReason: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 warnings: '{}' couponRejectionReason: reason: CouponNotFound @@ -19992,8 +22803,8 @@ components: coupons: '{}' referralRejectionReason: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 warnings: '{}' couponRejectionReason: reason: CouponNotFound @@ -20009,7 +22820,7 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 - expiryDate: 2022-04-26T11:02:38Z accountId: 7 eventId: 3 @@ -20019,7 +22830,8 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 + integrationId: 175KJPS947296 attributes: myAttribute: myValue id: 6 @@ -20057,8 +22869,8 @@ components: minLength: 1 type: string type: - description: A string representing the event. Must not be a reserved event - name. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -20069,6 +22881,12 @@ components: myAttribute: myValue properties: {} type: object + integrationId: + description: | + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 + type: string sessionId: description: The ID of the session that this event occurred in. example: 175KJPS947296 @@ -20098,32 +22916,62 @@ components: - id - type type: object - IntegrationProfileEntityV3: + EventV3Connections: properties: - profileId: + connectedSessionId: + description: The ID of the session to reference. The session must be in + `closed` state. Otherwise, the API call will fail. + example: 175KJPS947296 + minLength: 1 + type: string + type: object + EventV3ReferralEntity: + properties: + referralCode: description: | - ID of the customer profile set by your integration layer. - - **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. - example: URNGV8294NV + The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the "Referral code is valid" condition in the Rule Builder to validate and redeem the code, or "Referral code is valid (without redemption)" to validate without redeeming. + example: NT2K54D9 + maxLength: 100 type: string - required: - - profileId type: object EventV3: example: - connectedSessionID: 175KJPS947296 + connectedSessionId: 175KJPS947296 + effects: + - '{}' + - '{}' storeIntegrationId: STORE-001 + created: 2020-06-10T09:05:27.993483Z profileId: URNGV8294NV - evaluableCampaignIds: - - 10 - - 12 - previousEventID: 175KJPS947296 + referralCode: NT2K54D9 integrationId: 175KJPS947296 attributes: myAttribute: myValue + id: 6 + applicationId: 322 type: pageViewed properties: + connectedSessionId: + description: The ID of the session to reference. The session must be in + `closed` state. Otherwise, the API call will fail. + example: 175KJPS947296 + minLength: 1 + type: string + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + applicationId: + description: The ID of the Application that owns this entity. + example: 322 + format: int64 + type: integer profileId: description: | ID of the customer profile set by your integration layer. @@ -20138,53 +22986,46 @@ components: maxLength: 1000 minLength: 1 type: string - evaluableCampaignIds: - description: | - When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. - - These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. - example: - - 10 - - 12 - items: - format: int64 - type: integer - title: Campaigns to evaluate - type: array - integrationId: - description: | - The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. - example: 175KJPS947296 - minLength: 1 - type: string type: - description: | - A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type type: string attributes: - description: Arbitrary additional JSON properties associated with the event. - They must be created in the Campaign Manager before setting them with - this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). + description: Arbitrary additional JSON data associated with the event. example: myAttribute: myValue properties: {} type: object - connectedSessionID: - description: The ID of the session that happened in the past. + integrationId: + description: | + The unique ID of the event. Only one event with this ID can be registered. example: 175KJPS947296 minLength: 1 type: string - previousEventID: - description: The unique identifier of the event that happened in the past. - example: 175KJPS947296 - minLength: 1 + referralCode: + description: | + The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the "Referral code is valid" condition in the Rule Builder to validate and redeem the code, or "Referral code is valid (without redemption)" to validate without redeeming. + example: NT2K54D9 + maxLength: 100 type: string + effects: + description: | + An array of effects generated by the rules of the enabled campaigns of the Application. + + You decide how to apply them in your system. See the list of [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). + items: + properties: {} + type: object + type: array required: - - integrationId - - profileId + - applicationId + - attributes + - created + - effects + - id - type type: object AccountEntity: @@ -20337,6 +23178,59 @@ components: description: | Contains all entities that might interest Talon.One integrations. example: + achievements: + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: + - 1 + - 14 + - 27 + recurrencePolicy: no_recurrence + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: + - 1 + - 14 + - 27 + recurrencePolicy: no_recurrence customerProfile: accountId: 31 closedSessions: 3 @@ -20635,6 +23529,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -20652,6 +23547,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -20759,7 +23655,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -20914,7 +23810,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -21059,6 +23955,7 @@ components: customerSession: couponCodes: - XMAS-20-2021 + cartItemAdditionalCostTotal: 15.0 updateCount: 3 created: 2020-02-07T08:15:22Z identifiers: @@ -21069,7 +23966,7 @@ components: variantID: 2 - experimentID: 1 variantID: 2 - total: 119.99 + total: 134.99 loyaltyCards: - loyalty-card-1 additionalCosts: @@ -21155,6 +24052,8 @@ components: price: 100 height: 0.8008281904610115 updated: 2020-02-08T14:15:22Z + rewardIntegrationIds: + - 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 firstSession: true cartItemTotal: 99.99 previousReturns: @@ -21192,17 +24091,185 @@ components: id: 6 sessionId: 123 applicationId: 322 + campaignEligibility: + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 advancedEvent: - connectedSessionID: 175KJPS947296 + connectedSessionId: 175KJPS947296 + effects: + - '{}' + - '{}' storeIntegrationId: STORE-001 + created: 2020-06-10T09:05:27.993483Z profileId: URNGV8294NV - evaluableCampaignIds: - - 10 - - 12 - previousEventID: 175KJPS947296 + referralCode: NT2K54D9 integrationId: 175KJPS947296 attributes: myAttribute: myValue + id: 6 + applicationId: 322 type: pageViewed event: effects: @@ -21216,8 +24283,8 @@ components: coupons: '{}' referralRejectionReason: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 warnings: '{}' couponRejectionReason: reason: CouponNotFound @@ -21233,7 +24300,7 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 - expiryDate: 2022-04-26T11:02:38Z accountId: 7 eventId: 3 @@ -21243,7 +24310,8 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 + integrationId: 175KJPS947296 attributes: myAttribute: myValue id: 6 @@ -21251,34 +24319,81 @@ components: applicationId: 322 type: pageViewed ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName + rewards: + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 return: returnedCartItems: - quantity: 1 @@ -21308,6 +24423,15 @@ components: items: $ref: '#/components/schemas/Campaign' type: array + campaignEligibility: + description: "A list of campaigns and their evaluation status for the current\ + \ customer session.\n\n**Note**:\n\n- This response can **only** be included\ + \ if the `dry` parameter in the query is set to `true`. \n- Do not include\ + \ `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to\ + \ avoid duplicate results.\n" + items: + $ref: '#/components/schemas/CampaignEligibility' + type: array effects: description: The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). @@ -21336,6 +24460,16 @@ components: items: $ref: '#/components/schemas/Giveaway' type: array + achievements: + description: The achievements progress of the customer. + items: + $ref: '#/components/schemas/CustomerAchievement' + type: array + rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array referral: $ref: '#/components/schemas/InventoryReferral' coupons: @@ -21416,6 +24550,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -21433,6 +24568,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -21467,8 +24603,13 @@ components: - event - awardedGiveaways - ruleFailureReasons + - campaignEligibility + - achievements + - unlockedRewards type: string type: array + x-internal-enum-values: + - campaignEligibility type: object ProfileAudiencesChanges: example: @@ -21556,8 +24697,13 @@ components: - event - awardedGiveaways - ruleFailureReasons + - campaignEligibility + - achievements + - unlockedRewards type: string type: array + x-internal-enum-values: + - campaignEligibility audiencesChanges: $ref: '#/components/schemas/ProfileAudiencesChanges' type: object @@ -21575,6 +24721,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -21592,6 +24739,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -21681,7 +24829,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -21836,7 +24984,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -22082,6 +25230,171 @@ components: name: program1 id: 5 title: My loyalty program + campaignEligibility: + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 awardedGiveaways: - profileIntegrationId: R195412 code: GIVEAWAY1 @@ -22117,8 +25430,8 @@ components: coupons: '{}' referralRejectionReason: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 warnings: '{}' couponRejectionReason: reason: CouponNotFound @@ -22134,7 +25447,7 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 - expiryDate: 2022-04-26T11:02:38Z accountId: 7 eventId: 3 @@ -22144,7 +25457,8 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 + integrationId: 175KJPS947296 attributes: myAttribute: myValue id: 6 @@ -22217,34 +25531,81 @@ components: discountRemainder: 5.0 isReservationMandatory: false ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName + rewards: + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 createdReferrals: - code: 27G47Y54VH9L created: 2020-06-10T09:05:27.993483Z @@ -22289,10 +25650,19 @@ components: items: $ref: '#/components/schemas/RuleFailureReason' type: array + campaignEligibility: + items: + $ref: '#/components/schemas/CampaignEligibility' + type: array awardedGiveaways: items: $ref: '#/components/schemas/Giveaway' type: array + rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array effects: description: The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). @@ -22458,6 +25828,17 @@ components: description: A description of the audience. example: Travel audience 18-27 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true required: - name type: object @@ -22466,6 +25847,9 @@ components: lastUpdate: 2022-04-26T11:02:38Z name: Travel audience sandbox: true + subscribedApplicationsIds: + - 3 + - 13 integration: mparticle description: Travel audience 18-27 integrationId: 382370BKDB946 @@ -22484,6 +25868,17 @@ components: description: A description of the audience. example: Travel audience 18-27 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true integration: description: | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. @@ -22521,6 +25916,9 @@ components: lastUpdate: 2022-04-26T11:02:38Z name: Travel audience sandbox: true + subscribedApplicationsIds: + - 3 + - 13 integration: mparticle description: Travel audience 18-27 integrationId: 382370BKDB946 @@ -22555,6 +25953,17 @@ components: description: A description of the audience. example: Travel audience 18-27 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true integration: description: | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. @@ -22591,12 +26000,26 @@ components: UpdateAudience: example: name: Travel audience + subscribedApplicationsIds: + - 3 + - 13 properties: name: description: The human-friendly display name for this audience. example: Travel audience minLength: 1 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true required: - name type: object @@ -22706,59 +26129,51 @@ components: $ref: '#/components/schemas/IntegrationCustomerProfileAudienceRequestItem' type: array type: object - RuleMetadata: - properties: - title: - description: A short description of the rule. - example: Give discount via coupon - type: string - displayName: - description: A customer-facing name for the rule. - example: 20% off all shoes! - type: string - displayDescription: - description: "A customer-facing description that explains the details of\ - \ the rule. \n\nFor example, this property can contain details about eligibility\ - \ requirements, reward timelines, or terms and conditions.\n" - example: Get a 20% discount on all shoes during Thanksgiving! Offer valid - till Dec 5 only. - type: string - relatedData: - description: | - Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. - example: https://example.com/discounts/20-off-shoes.png - type: string - required: - - title - type: object IntegrationCampaign: example: + description: Campaign for all summer 2021 promotions + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + linkedAudienceIds: + - 3 + - 4 features: - coupons - referrals + linkedStoreIds: + - 1 + - 2 name: Summer promotions - description: Campaign for all summer 2021 promotions startTime: 2021-07-20T22:00:00Z attributes: '{}' id: 4 endTime: 2021-09-22T22:00:00Z state: enabled applicationId: 322 - tags: - - summer properties: - id: - description: Unique ID of Campaign. - example: 4 - format: int64 - type: integer applicationId: description: The ID of the Application that owns this entity. example: 322 format: int64 type: integer + id: + description: Unique ID of Campaign. + example: 4 + format: int64 + type: integer name: - description: A user-facing name for this campaign. + description: The name of the campaign. example: Summer promotions minLength: 1 title: Campaign Name @@ -22813,13 +26228,39 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array + rules: + description: A list of rules containing customer-facing details of the rewards + defined in the campaign. + items: + $ref: '#/components/schemas/RuleMetadata' + type: array + linkedStoreIds: + description: A list of store IDs linked to this campaign. + example: + - 1 + - 2 + items: + format: int64 + type: integer + type: array + linkedAudienceIds: + description: A list of audience IDs linked to this campaign. + example: + - 3 + - 4 + items: + format: int64 + type: integer + type: array required: - applicationId - features - id - name + - rules - state - tags type: object @@ -23385,8 +26826,8 @@ components: EventAttributesEntity: properties: type: - description: | - A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -23432,8 +26873,8 @@ components: title: Campaigns to evaluate type: array type: - description: | - A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -23493,8 +26934,8 @@ components: title: Campaigns to evaluate type: array type: - description: | - A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -23521,8 +26962,13 @@ components: - event - awardedGiveaways - ruleFailureReasons + - campaignEligibility + - achievements + - unlockedRewards type: string type: array + x-internal-enum-values: + - campaignEligibility loyaltyCards: description: Identifiers of the loyalty cards used during this event. example: @@ -23680,6 +27126,18 @@ components: mandatory: $ref: '#/components/schemas/AttributesMandatory' type: object + BestPriorPriceSettings: + description: The best prior price settings for this Application. + example: + enableBestPriorPrice: true + properties: + enableBestPriorPrice: + description: When set to `true`, the best prior price feature is enabled + in this Application and its [price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory) + is recorded. + example: true + type: boolean + type: object UpdateApplication: properties: name: @@ -23775,6 +27233,8 @@ components: **Important:** After this feature is enabled, it cannot be disabled. example: false type: boolean + bestPriorPriceSettings: + $ref: '#/components/schemas/BestPriorPriceSettings' required: - currency - name @@ -24284,6 +27744,8 @@ components: type: object Application: example: + bestPriorPriceSettings: + enableBestPriorPrice: true enableFlattenedCartItems: true created: 2020-06-10T09:05:27.993483Z timezone: Europe/Berlin @@ -24599,6 +28061,8 @@ components: **Important:** After this feature is enabled, it cannot be disabled. example: false type: boolean + bestPriorPriceSettings: + $ref: '#/components/schemas/BestPriorPriceSettings' loyaltyPrograms: description: An array containing all the loyalty programs to which this application is subscribed. @@ -24645,6 +28109,17 @@ components: example: Travel audience minLength: 1 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true integrationId: description: The ID of this audience in the third-party integration. example: 382370BKDB946 @@ -24680,6 +28155,17 @@ components: example: Travel audience minLength: 1 type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications that are connected to + this audience. + example: + - 3 + - 13 + items: + format: int64 + type: integer + type: array + uniqueItems: true integrationId: description: The ID of this audience in the third-party integration. example: 382370BKDB946 @@ -24743,10 +28229,10 @@ components: description: | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: - 1. `open` → `closed` - 2. `open` → `cancelled` - 3. `closed` → `cancelled` or `partially_returned` - 4. `partially_returned` → `cancelled` + 1. `open` -> `closed` + 2. `open` -> `cancelled` + 3. `closed` -> `cancelled` or `partially_returned` + 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). enum: @@ -24828,10 +28314,10 @@ components: description: | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: - 1. `open` → `closed` - 2. `open` → `cancelled` - 3. `closed` → `cancelled` or `partially_returned` - 4. `partially_returned` → `cancelled` + 1. `open` -> `closed` + 2. `open` -> `cancelled` + 3. `closed` -> `cancelled` or `partially_returned` + 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). enum: @@ -24931,6 +28417,83 @@ components: - profile - session type: object + NewDigitalPass: + properties: + loyaltyProgramId: + description: The ID of the associated loyalty program. + example: 42 + format: int64 + minimum: 1 + type: integer + passTemplateId: + description: | + The ID of the digital pass template used to generate the pass. + example: tmpl_summer_loyalty + minLength: 1 + type: string + profileId: + description: The integration ID of the customer profile the pass is issued + for. + example: "12412412421" + minLength: 1 + type: string + loyaltyCardId: + description: | + The identifier of the loyalty card the pass is issued for. + + **Note**: Only applicable for card-based loyalty programs. + example: summer-loyalty-0e2f + type: string + platform: + description: The wallet platform the pass is generated for. + enum: + - apple + - google + example: google + type: string + attributes: + additionalProperties: + type: string + description: | + A map of placeholder values that you provide to fill in the pass template. + These values are not validated against the template. + example: + hm_member_name: Jane Doe + type: object + required: + - loyaltyProgramId + - passTemplateId + - platform + - profileId + type: object + DigitalPass: + properties: + passId: + description: The ID of the generated digital pass. + example: pass_9c3f1a2b + type: string + passTemplateId: + description: The ID of the digital pass template used to generate the pass. + example: tmpl_summer_loyalty + type: string + status: + description: The status of the digital pass. + enum: + - created + example: created + type: string + passUrl: + description: The URL you can use to let the customer add the digital pass + to their wallet. + example: https://wallet.example.com/passes/pass_9c3f1a2b + format: uri + type: string + required: + - passId + - passTemplateId + - passUrl + - status + type: object NewEvent: properties: profileId: @@ -24948,8 +28511,8 @@ components: minLength: 1 type: string type: - description: A string representing the event. Must not be a reserved event - name. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. example: pageViewed minLength: 1 title: Event Type @@ -24984,6 +28547,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -25001,6 +28565,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -25009,162 +28574,60 @@ components: ruleName: Give 20% discount experimentId: 12 triggeredByCoupon: 4928 - triggeredCampaigns: - - type: advanced - templateId: 3 - customEffectCount: 0 - activeRevisionId: 6 - features: - - coupons - - referrals - createdLoyaltyPointsCount: 9.0 - storesImported: true - couponSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - experimentId: 1 - id: 4 - state: enabled - couponAttributes: '{}' - reservecouponEffectCount: 9 - updatedBy: Jane Doe - frontendState: running - created: 2020-06-10T09:05:27.993483Z - referralCreationCount: 8 - stageRevision: false - couponRedemptionCount: 163 - couponCreationCount: 16 - version: 6 - campaignGroups: + achievements: + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: - 1 - - 3 - tags: - - summer - discountEffectCount: 343 - budgets: - - limit: 1000.0 - action: createCoupon - counter: 42.0 - - limit: 1000.0 - action: createCoupon - counter: 42.0 - redeemedLoyaltyPointsCount: 8.0 - name: Summer promotions - valueMapsIds: - - 100 - - 215 - applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 - callApiEffectCount: 0 - createdLoyaltyPointsEffectCount: 2 - discountCount: 288.0 - revisionFrontendState: revised - description: Campaign for all summer 2021 promotions - activeRevisionVersionId: 6 - currentRevisionVersionId: 6 - startTime: 2021-07-20T22:00:00Z - currentRevisionId: 6 - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - activeRulesetId: 6 - reevaluateOnReturn: true - userId: 388 - awardedGiveawaysCount: 9 - redeemedLoyaltyPointsEffectCount: 9 - linkedStoreIds: + - 14 + - 27 + recurrencePolicy: no_recurrence + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: - 1 - - 2 - - 3 - createdBy: John Doe - addFreeItemEffectCount: 0 - referralSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - attributes: '{}' - lastActivity: 2022-11-10T23:00:00Z - endTime: 2021-09-22T22:00:00Z - referralRedemptionCount: 3 + - 14 + - 27 + recurrencePolicy: no_recurrence + triggeredCampaigns: - type: advanced templateId: 3 customEffectCount: 0 @@ -25245,7 +28708,162 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z + callApiEffectCount: 0 + createdLoyaltyPointsEffectCount: 2 + discountCount: 288.0 + revisionFrontendState: revised + description: Campaign for all summer 2021 promotions + activeRevisionVersionId: 6 + currentRevisionVersionId: 6 + startTime: 2021-07-20T22:00:00Z + currentRevisionId: 6 + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 6 + reevaluateOnReturn: true + userId: 388 + awardedGiveawaysCount: 9 + redeemedLoyaltyPointsEffectCount: 9 + linkedStoreIds: + - 1 + - 2 + - 3 + createdBy: John Doe + addFreeItemEffectCount: 0 + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + lastActivity: 2022-11-10T23:00:00Z + endTime: 2021-09-22T22:00:00Z + referralRedemptionCount: 3 + - type: advanced + templateId: 3 + customEffectCount: 0 + activeRevisionId: 6 + features: + - coupons + - referrals + createdLoyaltyPointsCount: 9.0 + storesImported: true + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + experimentId: 1 + id: 4 + state: enabled + couponAttributes: '{}' + reservecouponEffectCount: 9 + updatedBy: Jane Doe + frontendState: running + created: 2020-06-10T09:05:27.993483Z + referralCreationCount: 8 + stageRevision: false + couponRedemptionCount: 163 + couponCreationCount: 16 + version: 6 + campaignGroups: + - 1 + - 3 + tags: + - summer + discountEffectCount: 343 + budgets: + - limit: 1000.0 + action: createCoupon + counter: 42.0 + - limit: 1000.0 + action: createCoupon + counter: 42.0 + redeemedLoyaltyPointsCount: 8.0 + name: Summer promotions + valueMapsIds: + - 100 + - 215 + applicationId: 322 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -25491,6 +29109,171 @@ components: name: program1 id: 5 title: My loyalty program + campaignEligibility: + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 awardedGiveaways: - profileIntegrationId: R195412 code: GIVEAWAY1 @@ -25591,8 +29374,8 @@ components: coupons: '{}' referralRejectionReason: reason: ReferralNotFound - campaignId: 3 - referralId: 2 + campaignId: 1 + referralId: 1 warnings: '{}' couponRejectionReason: reason: CouponNotFound @@ -25608,7 +29391,7 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 - expiryDate: 2022-04-26T11:02:38Z accountId: 7 eventId: 3 @@ -25618,7 +29401,8 @@ components: profileId: URNGV8294NV loyaltyProgramId: 323414846 id: 6 - referenceId: 9 + referenceId: 1 + integrationId: 175KJPS947296 attributes: myAttribute: myValue id: 6 @@ -25626,30 +29410,34 @@ components: applicationId: 322 type: pageViewed ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details @@ -25683,6 +29471,49 @@ components: channel: web id: 6 startDate: 2020-11-10T23:00:00Z + rewards: + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 properties: customerProfile: $ref: '#/components/schemas/CustomerProfile' @@ -25694,6 +29525,15 @@ components: items: $ref: '#/components/schemas/Campaign' type: array + campaignEligibility: + description: "A list of campaigns and their evaluation status for the current\ + \ customer session.\n\n**Note**:\n\n- This response can **only** be included\ + \ if the `dry` parameter in the query is set to `true`. \n- Do not include\ + \ `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to\ + \ avoid duplicate results.\n" + items: + $ref: '#/components/schemas/CampaignEligibility' + type: array effects: description: The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). @@ -25722,6 +29562,16 @@ components: items: $ref: '#/components/schemas/Giveaway' type: array + achievements: + description: The achievements progress of the customer. + items: + $ref: '#/components/schemas/CustomerAchievement' + type: array + rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array event: $ref: '#/components/schemas/Event' required: @@ -25879,48 +29729,14 @@ components: required: - integrationIDs type: object - AchievementProgress: - description: The current progress of the customer in the achievement. - example: - endDate: 2000-01-23T04:56:07.000+00:00 - progress: 10.0 - completionDate: 2000-01-23T04:56:07.000+00:00 - startDate: 2000-01-23T04:56:07.000+00:00 - status: completed - properties: - status: - description: The status of the achievement. - enum: - - inprogress - - completed - - expired - - not_started - example: completed - type: string - progress: - description: The current progress of the customer in the achievement. - example: 10.0 - type: number - startDate: - description: Timestamp at which the customer started the achievement. - format: date-time - type: string - completionDate: - description: Timestamp at which point the customer completed the achievement. - format: date-time - type: string - endDate: - description: Timestamp at which point the achievement ends and resets for - the customer. - format: date-time - type: string - required: - - progress - - status - type: object AchievementProgressWithDefinition: description: The current progress of the customer in the achievement. example: + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 endDate: 2000-01-23T04:56:07.000+00:00 achievementAllowRollbackAfterCompletion: false campaignId: 3 @@ -25935,6 +29751,10 @@ components: achievementEndDate: 2000-01-23T04:56:07.000+00:00 progress: 10.0 completionDate: 2000-01-23T04:56:07.000+00:00 + campaignIds: + - 1 + - 14 + - 27 startDate: 2000-01-23T04:56:07.000+00:00 status: completed properties: @@ -25987,10 +29807,31 @@ components: format: string type: string campaignId: - description: The ID of the campaign the achievement belongs to. + description: This property is **deprecated**. Use `campaignIds` (Integration + API) or `referencedByCampaigns` (Management API) instead. This field contains + the first campaign ID from the related `campaignIds`, and is omitted when + `campaignIds` is empty. example: 3 format: int64 type: integer + x-deprecated: true + campaignIds: + description: The IDs of the campaigns that reference this achievement, in + ascending order. + example: + - 1 + - 14 + - 27 + items: + format: int64 + type: integer + type: array + referencedByCampaigns: + description: The campaigns that reference this achievement, in ascending + order of their `id`. + items: + $ref: '#/components/schemas/CampaignReference' + type: array target: description: The required number of actions or the transactional milestone to complete the achievement. @@ -26041,17 +29882,23 @@ components: - achievementActivationPolicy - achievementId - achievementRecurrencePolicy - - campaignId + - campaignIds - description - name - progress + - referencedByCampaigns - status - title type: object CustomerInventory: example: achievements: - - endDate: 2000-01-23T04:56:07.000+00:00 + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 achievementAllowRollbackAfterCompletion: false campaignId: 3 achievementId: 3 @@ -26065,9 +29912,18 @@ components: achievementEndDate: 2000-01-23T04:56:07.000+00:00 progress: 10.0 completionDate: 2000-01-23T04:56:07.000+00:00 + campaignIds: + - 1 + - 14 + - 27 startDate: 2000-01-23T04:56:07.000+00:00 status: completed - - endDate: 2000-01-23T04:56:07.000+00:00 + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 achievementAllowRollbackAfterCompletion: false campaignId: 3 achievementId: 3 @@ -26081,6 +29937,10 @@ components: achievementEndDate: 2000-01-23T04:56:07.000+00:00 progress: 10.0 completionDate: 2000-01-23T04:56:07.000+00:00 + campaignIds: + - 1 + - 14 + - 27 startDate: 2000-01-23T04:56:07.000+00:00 status: completed coupons: @@ -26358,6 +30218,49 @@ components: name: program1 id: 5 title: My loyalty program + rewards: + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 giveaways: - profileIntegrationId: R195412 code: GIVEAWAY1 @@ -26404,6 +30307,11 @@ components: items: $ref: '#/components/schemas/AchievementProgressWithDefinition' type: array + rewards: + description: The customer rewards that are `unlocked` and not yet `used`. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array type: object TimePoint: description: | @@ -26712,6 +30620,10 @@ components: minute: 59 second: 59 id: 6 + campaignIds: + - 1 + - 14 + - 27 recurrencePolicy: no_recurrence status: active properties: @@ -26822,10 +30734,24 @@ components: example: false type: boolean campaignId: - description: The ID of the campaign the achievement belongs to. + description: This property is **deprecated**. Use `referencedByCampaigns` + instead. This field contains the first campaign ID from the related `referencedByCampaigns`, + and is omitted when `referencedByCampaigns` is empty. example: 1 format: int64 type: integer + x-deprecated: true + campaignIds: + description: The IDs of the campaigns that reference this achievement, in + ascending order. + example: + - 1 + - 14 + - 27 + items: + format: int64 + type: integer + type: array status: description: The status of the achievement. enum: @@ -26843,6 +30769,94 @@ components: - target - title type: object + CustomerProfileReward: + description: A reward instance held by a customer profile. + properties: + id: + description: The ID of the customer reward instance. A customer profile + can have multiple instances of the same reward. + example: 6 + format: int64 + type: integer + integrationId: + description: The integration ID of the customer reward instance. + example: reward-unlock-123 + type: string + rewardId: + description: The ID of the reward this instance belongs to. + example: 12 + format: int64 + type: integer + rewardIntegrationId: + description: The integration ID of the reward this instance belongs to. + example: free-coffee + type: string + rewardName: + description: The name of the reward. + example: Free coffee + type: string + description: + description: The customer-facing description of the reward. + example: One free coffee of any size + type: string + rule: + $ref: '#/components/schemas/RuleMetadata' + status: + description: | + The status of the customer reward: + - `unlocked`: The reward is available for use. + - `used`: The reward has been used. + enum: + - unlocked + - used + example: unlocked + type: string + unlockedAt: + description: The date and time when the reward was unlocked. + example: 2026-07-01T09:00:00Z + format: date-time + type: string + unlockedByProfileIntegrationId: + description: "The integration ID of the customer profile that unlocked the\ + \ reward. \n\nFor rewards unlocked with a loyalty card, this can be any\ + \ customer profile \nlinked to that loyalty card.\n" + example: customer2839 + type: string + usedAt: + description: The date and time when the reward was used. + example: 2026-07-02T10:30:00Z + format: date-time + type: string + usedByProfileIntegrationId: + description: "The integration ID of the customer profile that used the reward.\ + \ \n\nFor rewards unlocked with a loyalty card, this can be any customer\ + \ profile \nlinked to that loyalty card. \n\nOnly returned when the reward\ + \ has been used.\n" + example: customer2840 + type: string + loyaltyProgramId: + description: The ID of the loyalty program that the loyalty card belongs + to. Only returned for rewards unlocked with a loyalty card. + example: 9 + format: int64 + type: integer + loyaltyCardIdentifier: + description: | + The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + example: summer-loyalty-card-0543 + maxLength: 108 + minLength: 4 + pattern: ^[A-Za-z0-9._%+@-]+$ + type: string + required: + - id + - integrationId + - rewardId + - rewardIntegrationId + - rewardName + - status + - unlockedAt + type: object LoyaltyBalance: description: Point balance of a ledger in the Loyalty Program. example: @@ -26884,6 +30898,20 @@ components: type: object LoyaltyBalances: description: List of loyalty balances for a ledger and its subledgers. + example: + balance: + negativePoints: 286.0 + activePoints: 286.0 + spentPoints: 150.0 + expiredPoints: 286.0 + pendingPoints: 50.0 + subledgerBalances: + mysubledger: + activePoints: 286 + pendingPoints: 50 + spentPoints: 150 + expiredPoints: 25 + negativePoints: 0 properties: balance: $ref: '#/components/schemas/LoyaltyBalance' @@ -27182,7 +31210,7 @@ components: type: string validityDuration: description: | - The duration for which the points remain active, relative to the activation date. + The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. example: 30D @@ -27231,6 +31259,7 @@ components: type: addition expiryDate: 2022-08-02T15:04:05Z07:00 transactionUUID: ce59f12a-f53b-4014-a745-636d93f2bd3f + storeIntegrationId: STORE-001 subledgerId: sub-123 name: Reward 10% points of a purchase's current total validityDuration: 30D @@ -27257,6 +31286,14 @@ components: example: 05c2da0d-48fa-4aa1-b629-898f58f1584d maxLength: 255 type: string + storeIntegrationId: + description: The integration ID of the store where the transaction occurred. + Only set for transactions created by a customer session or event that + referenced a store. + example: STORE-001 + maxLength: 1000 + minLength: 1 + type: string type: description: | Type of transaction. Possible values: @@ -27317,7 +31354,7 @@ components: $ref: '#/components/schemas/LoyaltyLedgerEntryFlags' validityDuration: description: | - The duration for which the points remain active, relative to the activation date. + The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. example: 30D @@ -27625,6 +31662,8 @@ components: **Important:** After this feature is enabled, it cannot be disabled. example: false type: boolean + bestPriorPriceSettings: + $ref: '#/components/schemas/BestPriorPriceSettings' required: - currency - name @@ -27703,6 +31742,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponSettings: @@ -27855,6 +31895,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponAttributes: @@ -27957,6 +31998,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponAttributes: @@ -28510,6 +32552,7 @@ components: - giveaways - strikethrough - achievements + - advancedEvents type: string type: array couponSettings: @@ -29848,14 +33891,16 @@ components: description: setDiscountPerItem effect in strikethrough pricing payload. properties: name: - description: effect name. + description: The effect name. example: 1EuroOff type: string value: - description: discount value. + description: The discount value. example: "1" type: object excludedFromPriceHistory: + description: When set to `true`, the applied discount is excluded from the + item's price history. type: boolean required: - name @@ -29887,11 +33932,11 @@ components: description: setDiscountPerItem member effect in strikethrough pricing payload. properties: name: - description: effect name. + description: The effect name. example: 10% off members only type: string value: - description: discount value. + description: The discount value. example: "9" type: object required: @@ -30282,17 +34327,17 @@ components: attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter properties: name: description: A descriptive name for the value to be bound. - example: my property + example: Discount percentage type: string type: description: | @@ -30304,21 +34349,26 @@ components: example: templateParameter type: string expression: - description: A Talang expression that will be evaluated and its result attached - to the name of the binding. + description: | + A Talang expression that is evaluated, and its result is bound to the name of + the binding. The first element must be one of the functions or operators supported + by Talang, followed by its arguments. The arguments can be strings, numbers, or + nested expressions. For example: + - `["list", "10014", "10015"]` calls the `list` function to build a list of strings. + - `["+", 2, 0]` uses the `+` operator to add two numbers. example: - - string1 - - string2 + - identity + - 10 items: type: object type: array valueType: description: | - Can be one of the following: + The data type of the value. One of the following: - `string` - `number` - `boolean` - example: string + example: number type: string minValue: description: The minimum value allowed for this placeholder. @@ -30329,15 +34379,15 @@ components: example: 19.9 type: number attributeId: - description: Id of the attribute attached to the placeholder. + description: Identifier of the attribute attached to the placeholder. example: 100 format: int64 title: Attribute ID type: integer description: - description: Describes the placeholder field and value in the template. - This description can be used when creating campaigns from this template. - example: This is a template parameter of type `number`. + description: Description of the placeholder field and its value in the template. + This text can be shown when creating campaigns from this template. + example: The percentage discount applied to the cart total. type: string required: - expression @@ -30364,22 +34414,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -30508,22 +34558,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -30548,22 +34598,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -30590,22 +34640,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -30630,22 +34680,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -30720,2950 +34770,3212 @@ components: - rules - userId type: object - UpdateCouponBatch: - example: - expiryDate: 2023-08-24T14:15:22Z - usageLimit: 100 - reservationLimit: 45 - attributes: '{}' - batchID: batchID - discountLimit: 30.0 - startDate: 2020-01-24T14:15:22Z + BaseBlock: + description: Common properties shared by all block types. properties: - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - discountLimit: - description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time - type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - attributes: - description: | - Optional property to set the value of custom coupon attributes. They are defined in the Campaign Manager, - see [Managing attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes). - - Coupon attributes can also be set to _mandatory_ in your Application [settings](https://docs.talon.one/docs/product/applications/using-attributes#making-attributes-mandatory). - If your Application uses mandatory attributes, you must use this property to set their value. - properties: {} - type: object - batchID: - description: The ID of the batch the coupon(s) belong to. - title: Batch ID + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + required: + - type + title: BaseBlock type: object - NewCoupons: - example: - recipientIntegrationId: URNGV8294NV - uniquePrefix: "" - implicitlyReserved: false - usageLimit: 100 - numberOfCoupons: 1 - expiryDate: 2023-08-24T14:15:22Z - couponPattern: SUMMER-##### - validCharacters: - - A - - B - - G - - "Y" - reservationLimit: 45 - attributes: - venueId: 12 - discountLimit: 30.0 - startDate: 2020-01-24T14:15:22Z - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - isReservationMandatory: false + Block: + description: Describes a part of the logic of the rule. + discriminator: + propertyName: type + type: object + GroupBlock: + description: A structural combinator block that groups child blocks using a + logical operator. Evaluates to true when its operator condition is satisfied + across all child blocks. properties: - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - discountLimit: - description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - limits: - description: | - Limits configuration for a coupon. These limits will override the limits - set from the campaign. - - **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. - Only per-profile limits are allowed to be configured. + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/LimitConfig' + type: string + readOnly: true type: array - numberOfCoupons: - description: The number of new coupon codes to generate for the campaign. - Must be at least 1. - example: 1 - format: int64 - type: integer - uniquePrefix: - description: | - **DEPRECATED** To create more than 20,000 coupons in one request, use [Create coupons asynchronously](https://docs.talon.one/management-api#tag/Coupons/operation/createCouponsAsync) endpoint. - example: "" - title: Coupon code unique prefix - type: string - attributes: - description: Arbitrary properties associated with this item. - example: - venueId: 12 - properties: {} - type: object - recipientIntegrationId: - description: The integration ID for this coupon's beneficiary's profile. - example: URNGV8294NV - maxLength: 1000 - title: Receiving customer profile integration ID + operator: + description: Logical operator applied across child blocks. `all` requires + every child to pass, `atLeastOne` requires at least one, `none` requires + all to fail. + enum: + - all + - atLeastOne + - none type: string - validCharacters: - description: | - List of characters used to generate the random parts of a code. By default, - the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. - example: - - A - - B - - G - - "Y" + blocks: + description: Child blocks evaluated according to the operator. items: - type: string + $ref: '#/components/schemas/Block' type: array - couponPattern: - description: | - The pattern used to generate coupon codes. - The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. - example: SUMMER-##### - maxLength: 100 - minLength: 3 + onFailure: + description: Blocks evaluated when this block fails or returns false. + items: + $ref: '#/components/schemas/Block' + type: array + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object + required: + - blocks + - operator + - type + title: GroupBlock + type: object + x-discriminator-value: group + x-ms-discriminator-value: group + AwardDiscountCartTarget: + description: Applies the discount to the entire cart as a single unit. + properties: + type: + description: A target discriminator of type `cart`. + enum: + - cart type: string - isReservationMandatory: - default: false - description: An indication of whether the code can be redeemed only if it - has been reserved first. + required: + - type + title: AwardDiscountCartTarget + type: object + x-discriminator-value: cart + x-ms-discriminator-value: cart + AwardDiscountAllItemsTarget: + description: Applies the discount across all cart items. + properties: + type: + description: A target discriminator of type `allItems`. + enum: + - allItems + type: string + prorated: + description: Whether to distribute the discount proportionally across the + targeted items. + example: true + type: boolean + required: + - type + title: AwardDiscountAllItemsTarget + type: object + x-discriminator-value: allItems + x-ms-discriminator-value: allItems + AwardDiscountGlobalFilterTarget: + description: Applies the discount to items matched by a named Application-level + cart-item filter. + properties: + type: + description: A target discriminator of type `globalFilter`. + enum: + - globalFilter + type: string + name: + description: The name of the Application-level cart-item filter the discount + targets. + example: PremiumItems + type: string + prorated: + description: Whether to distribute the discount proportionally across the + matched items. example: false - title: Is reservation mandatory type: boolean - implicitlyReserved: - description: An indication of whether the coupon is implicitly reserved - for all customers. + required: + - name + - type + title: AwardDiscountGlobalFilterTarget + type: object + x-discriminator-value: globalFilter + x-ms-discriminator-value: globalFilter + AwardDiscountSelectorTarget: + description: Applies the discount to items matched by a named selector binding. + properties: + type: + description: A target discriminator of type `selector`. + enum: + - selector + type: string + name: + description: The name of the selector binding the discount targets. + example: ElectronicsItems + type: string + prorated: + description: Whether to distribute the discount proportionally across the + selected items. example: false - title: Is coupon implicitly reserved for all customers type: boolean required: - - numberOfCoupons - - usageLimit + - name + - type + title: AwardDiscountSelectorTarget type: object - NewCouponsForMultipleRecipients: - example: - expiryDate: 2023-08-24T14:15:22Z - couponPattern: SUMMER-##### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - usageLimit: 100 - reservationLimit: 45 - recipientsIntegrationIds: - - URNGV8294NV - - BZGGC2454PA - attributes: - venueId: 12 - discountLimit: 30.0 - startDate: 2020-01-24T14:15:22Z + x-discriminator-value: selector + x-ms-discriminator-value: selector + AwardDiscountBundleItemByIndex: + description: Identifies a bundle slot by its zero-based index within the bundle. properties: - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 + type: + description: A bundle-item selector of type `byIndex`. + enum: + - byIndex + type: string + value: + description: The zero-based index of the slot within the bundle. + example: 0 format: int64 - maximum: 999999 - minimum: 0 type: integer - discountLimit: - description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 + required: + - type + - value + title: AwardDiscountBundleItemByIndex + type: object + x-discriminator-value: byIndex + x-ms-discriminator-value: byIndex + AwardDiscountBundleItemByAttribute: + description: Identifies a bundle slot by ranking items by a per-item attribute + expression and picking the highest- or lowest-ranked one. + properties: + type: + description: A bundle-item selector of type `byAttribute`. + enum: + - byAttribute + type: string + attribute: + description: A per-item attribute expression used to rank bundle items. + example: '{{$Item.Price}}' + type: string + direction: + description: Ranking direction. `highest` picks the item with the largest + attribute value, `lowest` the smallest. + enum: + - highest + - lowest + example: highest + type: string + required: + - attribute + - direction + - type + title: AwardDiscountBundleItemByAttribute + type: object + x-discriminator-value: byAttribute + x-ms-discriminator-value: byAttribute + AwardDiscountBundleItem: + description: Selects which slot inside a bundle a discount applies to. The `type` + field picks the selection mode. + discriminator: + propertyName: type + type: object + AwardDiscountBundleTarget: + description: Applies the discount to items belonging to a named bundle. + properties: + type: + description: A target discriminator of type `bundle`. + enum: + - bundle + type: string + name: + description: Name of the bundle binding the discount targets. + example: BogoBundle + type: string + item: + description: Selects which slot inside a bundle a discount applies to. The + `type` field picks the selection mode. + discriminator: + propertyName: type + type: object + prorated: + description: Whether to distribute the discount proportionally across the + bundle's items. + example: false + type: boolean + required: + - name + - type + title: AwardDiscountBundleTarget + type: object + x-discriminator-value: bundle + x-ms-discriminator-value: bundle + AdditionalCostReference: + description: Identifies an additional cost referenced from a rule. + properties: + id: + description: The internal identifier of the additional cost. + example: 42 format: int64 - maximum: 999999 - minimum: 0 type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time + name: + description: The additional cost name as used in API requests. + example: shipping type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + title: + description: The human-readable title of the additional cost. + example: Shipping type: string - attributes: - description: Arbitrary properties associated with this item. - example: - venueId: 12 - properties: {} + required: + - id + - name + title: AdditionalCostReference + type: object + AwardDiscountAdditionalCostTarget: + description: Applies the discount to an additional cost. The `target` field + determines which subset of cart items the additional cost contribution is + applied to. + properties: + type: + description: A target discriminator of type `additionalCost`. + enum: + - additionalCost + type: string + additionalCost: + $ref: '#/components/schemas/AdditionalCostReference' + target: + description: A subset of cart items whose additional cost the discount applies + to. Cannot be another `additionalCost` target. type: object - recipientsIntegrationIds: - description: The integration IDs for recipients. - example: - - URNGV8294NV - - BZGGC2454PA + required: + - additionalCost + - target + - type + title: AwardDiscountAdditionalCostTarget + type: object + x-discriminator-value: additionalCost + x-ms-discriminator-value: additionalCost + AwardDiscountTarget: + description: Identifies the scope a discount applies to. The `type` field selects + the concrete target variant. + discriminator: + propertyName: type + type: object + AwardDiscountBlock: + description: A block that grants a discount when its rule conditions evaluate + to `true`. The `target` field determines what the discount applies to (the + whole cart, a subset of items, a bundle, an additional cost, etc.); the `value` + field is the discount amount. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: type: string - maxItems: 1000 - minItems: 1 - title: Receiving customer profiles integration IDs + readOnly: true type: array - validCharacters: - description: | - List of characters used to generate the random parts of a code. By default, the list of - characters is equivalent to the `[A-Z, 0-9]` regular expression. - example: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - items: - type: string - type: array - couponPattern: - description: | - The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. - example: SUMMER-##### - maxLength: 100 - minLength: 3 - type: string - required: - - recipientsIntegrationIds - - usageLimit - type: object - NewCouponCreationJob: - example: - expiryDate: 2023-08-24T14:15:22Z - usageLimit: 100 - reservationLimit: 45 - numberOfCoupons: 200000 - couponSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - attributes: '{}' - discountLimit: 30.0 - startDate: 2020-01-24T14:15:22Z - isReservationMandatory: false - properties: - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - discountLimit: - description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time - type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + name: + description: The human-readable label attached to the discount. + example: 10% Off type: string - numberOfCoupons: - description: The number of new coupon codes to generate for the campaign. - example: 200000 - format: int64 - maximum: 5E+6 - minimum: 1 - type: integer - couponSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - attributes: - description: Arbitrary properties associated with coupons. - properties: {} + value: + description: Discount amount. Either a numeric scalar or a `{{expression}}` + string that resolves to a number at evaluation time. type: object - isReservationMandatory: - default: false - description: An indication of whether the code can be redeemed only if it - has been reserved first. + partial: + description: Whether to apply a partial discount when the requested value + exceeds the configured budget. example: false type: boolean + target: + description: Identifies the scope a discount applies to. The `type` field + selects the concrete target variant. + discriminator: + propertyName: type + type: object required: - - attributes - - numberOfCoupons - - usageLimit + - name + - partial + - target + - type + - value + title: AwardDiscountBlock type: object - AsyncCouponCreationResponse: - example: - batchId: tqyrgahe + x-discriminator-value: awardDiscount + x-ms-discriminator-value: awardDiscount + PassthroughBlock: + description: A block representing a Talang expression that could not be mapped + to a typed block. The expression is preserved in its raw Talang array form + for diagnostic and round-trip purposes. properties: - batchId: - description: The batch ID that all coupons created by the request will have. - example: tqyrgahe + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: The type discriminator for this block. + enum: + - passthrough type: string + expression: + description: The raw Talang expression as an array. For a function call, + the first element is the function name and subsequent elements are its + arguments. For any other expression (for example a bare attribute path + or a literal value), this is a single-element array containing that value. + items: + type: object + type: array required: - - batchId + - expression + - type + title: PassthroughBlock type: object - CouponDeletionFilters: - example: - startsAfter: 2000-01-23T04:56:07.000+00:00 - recipientIntegrationId: recipientIntegrationId - exactMatch: false - redeemed: true - referralId: 0 - createdAfter: 2000-01-23T04:56:07.000+00:00 - batchId: batchId - valid: expired - usable: true - expiresAfter: 2000-01-23T04:56:07.000+00:00 - expiresBefore: 2000-01-23T04:56:07.000+00:00 - createdBefore: 2000-01-23T04:56:07.000+00:00 - value: value - startsBefore: 2000-01-23T04:56:07.000+00:00 + x-discriminator-value: passthrough + x-ms-discriminator-value: passthrough + ShowNotificationBlock: + description: A block that displays a notification to the customer with a configurable + type, title, and optional body message. properties: - createdBefore: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - createdAfter: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - startsAfter: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + notificationType: + description: The type of notification to display. + example: Info type: string - startsBefore: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + title: + description: The notification heading shown to the customer. + example: You earned a reward! type: string - valid: - description: | - - `expired`: Matches coupons in which the expiration date is set and in the past. - - `validNow`: Matches coupons in which the start date is null or in the past and the expiration date is null or in the future. - - `validFuture`: Matches coupons in which the start date is set and in the future. - enum: - - expired - - validNow - - validFuture + body: + description: The notification body text. Supports template placeholders + (e.g. "{{$Session.Total}}") evaluated at rule execution time. + example: You saved $10 on your order. type: string - usable: - description: | - - `true`: only coupons where `usageCounter < usageLimit` will be returned. - - `false`: only coupons where `usageCounter >= usageLimit` will be returned. - - This field cannot be used in conjunction with the `usable` query parameter. - type: boolean - redeemed: - description: | - - `true`: only coupons where `usageCounter > 0` will be returned. - - `false`: only coupons where `usageCounter = 0` will be returned. - - **Note:** This field cannot be used in conjunction with the `usable` query parameter. - type: boolean - recipientIntegrationId: - description: | - Filter results by match with a profile id specified in the coupon's `RecipientIntegrationId` field. + onFailure: + description: Blocks evaluated when this block fails or returns false. + items: + $ref: '#/components/schemas/Block' + type: array + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object + required: + - notificationType + - title + - type + title: ShowNotificationBlock + type: object + x-discriminator-value: showNotification + x-ms-discriminator-value: showNotification + AwardItemBlock: + description: A block that awards a free cart item to the customer. The item + is identified by SKU and name and has a configurable quantity. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - exactMatch: - default: false - description: Filter results to an exact case-insensitive matching against - the coupon code - type: boolean - value: - description: Filter results by the coupon code + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - batchId: - description: Filter results by batches of coupons + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + sku: + description: The stock keeping unit of the item to award. + example: SKU1241028 type: string - referralId: - description: Filter the results by matching them with the ID of a referral. - This filter shows the coupons created by redeeming a referral code. - format: int64 - type: integer - expiresAfter: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + name: + description: The display name of the item to award. + example: Free Tote Bag type: string - expiresBefore: - description: Filter results comparing the parameter value, expected to be - an RFC3339 timestamp string, to the coupon creation timestamp. You can - use any time zone setting. Talon.One will convert to UTC internally. - format: date-time + quantity: + description: The number of items to award. Supports template placeholders + (e.g. "{{$Session.Total / 2}}") for dynamic quantities. + example: "1" type: string - type: object - NewCouponDeletionJob: - example: - filters: - startsAfter: 2000-01-23T04:56:07.000+00:00 - recipientIntegrationId: recipientIntegrationId - exactMatch: false - redeemed: true - referralId: 0 - createdAfter: 2000-01-23T04:56:07.000+00:00 - batchId: batchId - valid: expired - usable: true - expiresAfter: 2000-01-23T04:56:07.000+00:00 - expiresBefore: 2000-01-23T04:56:07.000+00:00 - createdBefore: 2000-01-23T04:56:07.000+00:00 - value: value - startsBefore: 2000-01-23T04:56:07.000+00:00 - properties: - filters: - $ref: '#/components/schemas/CouponDeletionFilters' + partial: + description: When set to `true`, applies a partial item reward if the remaining + budget is insufficient to award the full reward. + example: false + type: boolean + onFailure: + description: Blocks evaluated when this block fails or returns false. + items: + $ref: '#/components/schemas/Block' + type: array + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object required: - - filters + - name + - quantity + - sku + - type + title: AwardItemBlock type: object - AsyncCouponDeletionJobResponse: - example: - id: 6 + x-discriminator-value: awardItem + x-ms-discriminator-value: awardItem + GiveawayPoolReference: + description: The giveaway pool from which a giveaway is awarded. properties: id: - description: Unique ID for this entity. Not to be confused with the Integration - ID, which is set by your integration layer and used in most endpoints. - example: 6 + description: The unique identifier of the giveaway pool. + example: 42 format: int64 type: integer + name: + description: The display name of the giveaway pool. + example: Summer Campaign Pool + readOnly: true + type: string required: - id + - name type: object - NewAppWideCouponDeletionJob: + AwardGiveawayBlock: + description: A block that awards a giveaway item from a configured giveaway + pool to the specified customer profile. properties: - filters: - $ref: '#/components/schemas/CouponDeletionFilters' - campaignids: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - format: int64 - type: integer + type: string + readOnly: true + type: array + giveawayPool: + $ref: '#/components/schemas/GiveawayPoolReference' + profile: + description: The customer profile to award the giveaway to. `Current` targets + the customer in the current session; `Advocate` targets the person who + invited their friend via referral program. + enum: + - Current + - Advocate + example: Current + type: string + onFailure: + description: Blocks evaluated when this block fails or returns false. + items: + $ref: '#/components/schemas/Block' type: array + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object required: - - campaignids - - filters + - giveawayPool + - profile + - type + title: AwardGiveawayBlock type: object - UpdateCoupon: - example: - expiryDate: 2023-08-24T14:15:22Z - recipientIntegrationId: URNGV8294NV - implicitlyReserved: false - usageLimit: 100 - reservationLimit: 45 - attributes: '{}' - discountLimit: 30.0 - startDate: 2020-01-24T14:15:22Z - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - isReservationMandatory: false + x-discriminator-value: awardGiveaway + x-ms-discriminator-value: awardGiveaway + TriggerWebhookBlock: + description: A block that triggers a configured webhook and passes its required + parameters. properties: - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - discountLimit: - description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - limits: - description: | - Limits configuration for a coupon. These limits will override the limits - set from the campaign. - - **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. - Only per-profile limits are allowed to be configured. + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/LimitConfig' + type: string + readOnly: true type: array - recipientIntegrationId: - description: The integration ID for this coupon's beneficiary's profile. - example: URNGV8294NV - maxLength: 1000 - title: Receiving customer profile integration ID - type: string - attributes: - description: Arbitrary properties associated with this item. + webhook: + $ref: '#/components/schemas/TriggerWebhookBlock_webhook' + params: + description: The webhook's parameters, in configured order. Each property + name is the parameter's title, lowercased with spaces replaced by underscores + (for example, `Order ID` becomes `order_id`); falls back to `param_0`, + `param_1`, and so on if a title is blank or collides with another. + example: + order_id: ORD-10293 properties: {} type: object - isReservationMandatory: - default: false - description: An indication of whether the code can be redeemed only if it - has been reserved first. - example: false - title: Is reservation mandatory - type: boolean - implicitlyReserved: - description: An indication of whether the coupon is implicitly reserved - for all customers. - example: false - title: Is coupon implicitly reserved for all customers - type: boolean + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object + required: + - type + - webhook + title: TriggerWebhookBlock type: object - CouponSearch: + x-discriminator-value: triggerWebhook + x-ms-discriminator-value: triggerWebhook + ScalarCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for operators that compare an + attribute against a single value. properties: - attributes: - description: Properties to match against a coupon. All provided attributes - will be exactly matched against attributes. - properties: {} + operator: + description: The comparison operator applied to the attribute. + enum: + - equals + - not(equals) + - lessThan + - lessThanOrEqual + - greaterThan + - greaterThanOrEqual + - contains + - not(contains) + - matchesRegexp + - startsWith + - endsWith + - oneOf + - not(oneOf) + - inCollection + - not(inCollection) + - after + - before + type: string + value: + description: The comparison value for this operator. + example: "100" type: object required: - - attributes + - value + title: ScalarCheckAttributeBlock type: object - UpdateReferralBatch: + x-discriminator-value: before + x-ms-discriminator-value: before + BetweenCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for the `between` operator, which + requires both a minimum and maximum value. properties: - attributes: - description: Arbitrary properties associated with this item. - properties: {} - type: object - batchID: - description: The id of the batch the referral belongs to. - example: 32535-43255 - title: Batch ID + operator: + description: The range comparison operator. Must be `between`. + enum: + - between type: string - startDate: - description: Timestamp at which point the referral code becomes valid. - example: 2020-11-10T23:00:00Z - format: date-time - title: Referral code valid from + min: + description: The minimum value allowed for the `between` operator. + example: "10" + type: object + max: + description: The maximum value allowed for the `between` operator. + example: "100" + type: object + required: + - max + - min + title: BetweenCheckAttributeBlock + type: object + x-discriminator-value: between + x-ms-discriminator-value: between + ListCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for operators that test list membership + against a set of values. + properties: + operator: + description: The list membership operator applied to the attribute. + enum: + - containsOneOf + - containsNoneOf + - containsAllOf type: string - expiryDate: - description: Expiration date of the referral code. Referral never expires - if this is omitted. - example: 2021-11-10T23:00:00Z - format: date-time - title: Referral code valid until + values: + description: The set of values to match against. + type: object + required: + - values + title: ListCheckAttributeBlock + type: object + x-discriminator-value: containsAllOf + x-ms-discriminator-value: containsAllOf + ListWithCountCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for operators that test list membership + with a minimum or exact count threshold. + properties: + operator: + description: The list membership operator with a count threshold applied + to the attribute. + enum: + - containsAtLeast + - containsExactly type: string - usageLimit: - description: | - The number of times a referral code can be used. This can be set to 0 for no limit, but any campaign usage limits will still apply. - example: 1 - format: int64 - maximum: 999999 - minimum: 0 - title: Referral code Usage Limit - type: integer + values: + description: The set of values to match against. + type: object + count: + description: The count threshold for this operator. + example: "2" + type: object required: - - batchID + - count + - values + title: ListWithCountCheckAttributeBlock type: object - UpdateReferral: - example: - expiryDate: 2021-11-10T23:00:00Z - friendProfileIntegrationId: BZGGC2454PA - usageLimit: 1 - attributes: '{}' - startDate: 2020-11-10T23:00:00Z + x-discriminator-value: containsExactly + x-ms-discriminator-value: containsExactly + UnaryCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for operators that test a property + of the attribute itself with no comparison value. properties: - friendProfileIntegrationId: - description: An optional Integration ID of the Friend's Profile. - example: BZGGC2454PA - maxLength: 1000 - title: Friend's Profile ID + operator: + description: The unary operator applied to the attribute. These operators + require no comparison value. + enum: + - empty + - not(empty) + - exists + - not(exists) + - isTrue + - isFalse type: string - startDate: - description: Timestamp at which point the referral code becomes valid. - example: 2020-11-10T23:00:00Z - format: date-time - title: Referral code valid from + title: UnaryCheckAttributeBlock + type: object + x-discriminator-value: isFalse + x-ms-discriminator-value: isFalse + WithinCheckAttributeBlock: + description: Variant of `CheckAttributeBlock` for the `within` and `not(within)` + operators, which require both a start and end value. + properties: + operator: + description: The range comparison operator. Must be `within` or `not(within)`. + enum: + - within + - not(within) type: string - expiryDate: - description: Expiration date of the referral code. Referral never expires - if this is omitted. - example: 2021-11-10T23:00:00Z - format: date-time - title: Referral code valid until - type: string - usageLimit: - description: | - The number of times a referral code can be used. This can be set to 0 for no limit, but any campaign usage limits will still apply. - example: 1 - format: int64 - maximum: 999999 - minimum: 0 - title: Referral code Usage Limit - type: integer - attributes: - description: Arbitrary properties associated with this item. - properties: {} + start: + description: The start value for the `within` operator. + example: 2021-09-22T22:00:00Z + type: object + end: + description: The end value for the `within` operator. + example: 2021-09-22T22:00:00Z type: object + startInclusive: + description: When `true`, the `start` value is included in the range for + the `within` operator. + example: true + type: boolean + endInclusive: + description: When `true`, the `end` value is included in the range for the + `within` operator. + example: true + type: boolean + timezoneInsensitive: + description: Indicates whether the `within` operator ignores time zones + and compares the wall-clock time only. When `false`, time zones are taken + into account. + example: false + type: boolean + required: + - end + - start + title: WithinCheckAttributeBlock type: object - NewCampaignGroup: + x-discriminator-value: not(within) + x-ms-discriminator-value: not(within) + GeoJSONPoint: + description: A single point on a map, defined by its longitude and latitude + coordinates, following the GeoJSON format. properties: - name: - description: The name of the campaign access group. - example: Europe access group - minLength: 1 - type: string - description: - description: A longer description of the campaign access group. - example: A group that gives access to all the campaigns for the Europe market. + type: + description: The geometry type discriminator. + enum: + - Point type: string - subscribedApplicationsIds: - description: A list of IDs of the Applications that this campaign access - group is enabled for. + coordinates: + description: The longitude and latitude coordinates of the point, optionally + followed by altitude. example: - - 1 - - 2 - - 3 + - 13.405 + - 52.52 items: - format: int64 - type: integer + type: number + maxItems: 3 + minItems: 2 type: array - campaignIds: - description: A list of IDs of the campaigns that are part of the campaign - access group. + required: + - coordinates + - type + title: GeoJSONPoint + type: object + x-discriminator-value: Point + x-ms-discriminator-value: Point + GeoJSONPolygon: + description: A shape formed by one or more boundaries, following the GeoJSON + format. The first boundary defines the outer edge of the shape; any additional + boundaries define holes within the shape. + properties: + type: + description: The geometry type discriminator. + enum: + - Polygon + type: string + coordinates: + description: The boundaries that make up the shape. Each boundary is a closed + loop of longitude and latitude points, where the first and last point + are the same. example: - - 4 - - 6 - - 8 + - - - 13 + - 52.3 + - - 13.8 + - 52.3 + - - 13.8 + - 52.7 + - - 13 + - 52.7 + - - 13 + - 52.3 + items: + items: + items: + type: number + maxItems: 3 + minItems: 2 + type: array + type: array + type: array + required: + - coordinates + - type + title: GeoJSONPolygon + type: object + x-discriminator-value: Polygon + x-ms-discriminator-value: Polygon + GeoJSONMultiPolygon: + description: One or more separate shapes grouped together as a single location, + following the GeoJSON format. + properties: + type: + description: The geometry type discriminator. + enum: + - MultiPolygon + type: string + coordinates: + description: The shapes in this group. Each one follows the same boundary + structure as a polygon. + example: + - - - - 13 + - 52.3 + - - 13.8 + - 52.3 + - - 13.8 + - 52.7 + - - 13 + - 52.7 + - - 13 + - 52.3 + items: + items: + items: + items: + type: number + maxItems: 3 + minItems: 2 + type: array + type: array + type: array + type: array + required: + - coordinates + - type + title: GeoJSONMultiPolygon + type: object + x-discriminator-value: MultiPolygon + x-ms-discriminator-value: MultiPolygon + GeoJSONGeometry: + description: A shape used to represent a geographical location. The `type` field + determines the kind of shape. + discriminator: + propertyName: type + type: object + GeoJSONGeometryCollection: + description: A group of different shapes combined into a single location, following + the GeoJSON format. + properties: + type: + description: The geometry type discriminator. + enum: + - GeometryCollection + type: string + geometries: + description: The shapes contained in this group. items: - format: int64 - type: integer + $ref: '#/components/schemas/GeoJSONGeometry' type: array required: - - name + - geometries + - type + title: GeoJSONGeometryCollection type: object - CampaignGroup: - example: - accountId: 3886 - created: 2020-06-10T09:05:27.993483Z - name: Europe access group - subscribedApplicationsIds: - - 1 - - 2 - - 3 - modified: 2021-09-12T10:12:42Z - description: A group that gives access to all the campaigns for the Europe - market. - id: 6 - campaignIds: - - 4 - - 6 - - 8 + x-discriminator-value: GeometryCollection + x-ms-discriminator-value: GeometryCollection + LocationCheckAttributeBlock: + description: A block variant of `CheckAttributeBlock` for operators that check + whether a geographical location is inside a set of geometric areas. + properties: + operator: + description: The location membership operator applied to the attribute. + enum: + - in + - not(in) + type: string + values: + description: The geometric areas to check the location against. + type: object + required: + - values + title: LocationCheckAttributeBlock + type: object + x-discriminator-value: not(in) + x-ms-discriminator-value: not(in) + CheckAttributeBlockBase: + description: |- + Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. + The operator determines which additional fields are required: + - `scalar` requires `value`. + - `between` requires `min` and `max` values. + - `list` requires `values`. + - `list-with-count` requires `values` and `count`. + - `unary` requires no extra fields. properties: id: - description: The internal ID of this entity. - example: 6 - format: int64 - type: integer - created: - description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z - format: date-time + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - modified: - description: The time this entity was last modified. - example: 2021-09-12T10:12:42Z - format: date-time + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - accountId: - description: The ID of the account that owns this entity. - example: 3886 - format: int64 - type: integer - name: - description: The name of the campaign access group. - example: Europe access group - minLength: 1 + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + operator: + description: The comparison operator applied to the attribute. + enum: + - equals + - not(equals) + - lessThan + - lessThanOrEqual + - greaterThan + - greaterThanOrEqual + - between + - contains + - not(contains) + - matchesRegexp + - startsWith + - endsWith + - oneOf + - not(oneOf) + - inCollection + - not(inCollection) + - empty + - not(empty) + - exists + - not(exists) + - isTrue + - isFalse + - containsAtLeast + - containsExactly + - containsOneOf + - containsNoneOf + - containsAllOf + - after + - before + - within + - not(within) + - in + - not(in) + example: greaterThan + type: string + attribute: + description: The attribute path identifier (e.g. "$Session.Total"). + example: $Session.Total + type: object + value: + description: The comparison value for scalar operators. + example: "100" + type: object + min: + description: The minimum value allowed for the `between` operator. + example: "10" + type: object + max: + description: The maximum value allowed for the `between` operator. + example: "100" + type: object + start: + description: The start value for the `within` operator. + example: 2021-09-22T22:00:00Z + type: object + end: + description: The end value for the `within` operator. + example: 2021-09-22T22:00:00Z + type: object + startInclusive: + description: When `true`, the `start` value is included in the range for + the `within` operator. + example: true + type: boolean + endInclusive: + description: When `true`, the `end` value is included in the range for the + `within` operator. + example: true + type: boolean + timezoneInsensitive: + description: Indicates whether the `within` operator ignores time zones + and compares the wall-clock time only. When `false`, time zones are taken + into account. + example: false + type: boolean + values: + description: The set of values to match against for list operators. For + location operators (`in`, `not(in)`), an array of objects with a `geometry` + (see `GeoJSONGeometry`) and an optional `name`, or a string reference + to a list attribute. + example: "" + type: object + count: + description: The count threshold for `containsAtLeast` and `containsExactly` + operators. + example: "2" + type: object + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. + items: + $ref: '#/components/schemas/Block' + type: array + required: + - attribute + - operator + - type + title: CheckAttributeBlockBase + type: object + CheckAttributeBlock: + description: |- + Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. + The operator determines which additional fields are required: + - `scalar` requires `value`. + - `between` requires `min` and `max` values. + - `list` requires `values`. + - `list-with-count` requires `values` and `count`. + - `unary` requires no extra fields. + discriminator: + propertyName: operator + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - description: - description: A longer description of the campaign access group. - example: A group that gives access to all the campaigns for the Europe market. + type: + description: A block discriminator of type `checkAttribute`. + enum: + - checkAttribute + example: checkAttribute type: string - subscribedApplicationsIds: - description: A list of IDs of the Applications that this campaign access - group is enabled for. - example: - - 1 - - 2 - - 3 + tags: + description: Semantic labels attached to this block. items: - format: int64 - type: integer + type: string + readOnly: true type: array - campaignIds: - description: A list of IDs of the campaigns that are part of the campaign - access group. - example: - - 4 - - 6 - - 8 + operator: + description: The comparison operator applied to the attribute. + enum: + - equals + - not(equals) + - lessThan + - lessThanOrEqual + - greaterThan + - greaterThanOrEqual + - between + - contains + - not(contains) + - matchesRegexp + - startsWith + - endsWith + - oneOf + - not(oneOf) + - inCollection + - not(inCollection) + - empty + - not(empty) + - exists + - not(exists) + - isTrue + - isFalse + - containsAtLeast + - containsExactly + - containsOneOf + - containsNoneOf + - containsAllOf + - after + - before + - within + - not(within) + - in + - not(in) + example: greaterThan + type: string + attribute: + description: The attribute path identifier (e.g. "$Session.Total"). + example: $Session.Total + type: object + value: + description: The comparison value for scalar operators. + example: "100" + type: object + min: + description: The minimum value allowed for the `between` operator. + example: "10" + type: object + max: + description: The maximum value allowed for the `between` operator. + example: "100" + type: object + start: + description: The start value for the `within` operator. + example: 2021-09-22T22:00:00Z + type: object + end: + description: The end value for the `within` operator. + example: 2021-09-22T22:00:00Z + type: object + startInclusive: + description: When `true`, the `start` value is included in the range for + the `within` operator. + example: true + type: boolean + endInclusive: + description: When `true`, the `end` value is included in the range for the + `within` operator. + example: true + type: boolean + timezoneInsensitive: + description: Indicates whether the `within` operator ignores time zones + and compares the wall-clock time only. When `false`, time zones are taken + into account. + example: false + type: boolean + values: + description: The set of values to match against for list operators. For + location operators (`in`, `not(in)`), an array of objects with a `geometry` + (see `GeoJSONGeometry`) and an optional `name`, or a string reference + to a list attribute. + example: "" + type: object + count: + description: The count threshold for `containsAtLeast` and `containsExactly` + operators. + example: "2" + type: object + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - format: int64 - type: integer + $ref: '#/components/schemas/Block' type: array required: - - accountId - - created - - id - - modified - - name + - attribute + - operator + - type + title: CheckAttributeBlockBase type: object - UpdateCampaignGroup: + x-discriminator-value: checkAttribute + x-ms-discriminator-value: checkAttribute + CheckAudienceBlock: + description: A block that checks whether a given customer profile is a member + of an audience. properties: - name: - description: The name of the campaign access group. - example: Europe access group - minLength: 1 + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - description: - description: A longer description of the campaign access group. - example: A group that gives access to all the campaigns for the Europe market. + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - subscribedApplicationsIds: - description: A list of IDs of the Applications that this campaign access - group is enabled for. - example: - - 1 - - 2 - - 3 + tags: + description: Semantic labels attached to this block. items: - format: int64 - type: integer + type: string + readOnly: true type: array - campaignIds: - description: A list of IDs of the campaigns that are part of the campaign - access group. - example: - - 4 - - 6 - - 8 + operator: + description: An indicator of how the block compares its elements. + enum: + - member + - not(member) + - justJoined + - justLeft + example: member + type: string + profile: + description: The customer profile to check against the audience. `Current` + targets the customer in the current session; `Advocate` targets the person + who invited their friend via referral program. + enum: + - Current + - Advocate + example: Current + type: string + audience: + $ref: '#/components/schemas/CheckAudienceBlock_audience' + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - format: int64 - type: integer + $ref: '#/components/schemas/Block' type: array required: - - name + - audience + - operator + - profile + - type + title: CheckAudienceBlock type: object - Role: + x-discriminator-value: checkAudience + x-ms-discriminator-value: checkAudience + CheckLoyaltyBalanceBlock: + description: A block that checks a specific loyalty program's ledger or subledger + balance against a numeric value. properties: id: - description: The internal ID of this entity. - example: 6 - format: int64 - type: integer - created: - description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z - format: date-time + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - modified: - description: The time this entity was last modified. - example: 2021-09-12T10:12:42Z - format: date-time + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - accountId: - description: The ID of the account that owns this entity. - example: 3886 - format: int64 - type: integer - campaignGroupID: - description: | - The ID of the [Campaign Group](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups) - this role was created for. - example: 3 - format: int64 - type: integer - name: - description: Name of the role. - example: Campaign Reviewer + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + operator: + description: An indicator of how the block compares the balance to the value. + enum: + - equals + - not(equals) + - lessThan + - lessThanOrEqual + - greaterThan + - greaterThanOrEqual + example: greaterThanOrEqual + type: string + program: + $ref: '#/components/schemas/CheckLoyaltyBalanceBlock_program' + subledger: + description: The name of the subledger to check the balance of. Can be empty + if this block checks the loyalty program's main ledger balance instead + of a subledger. + example: "" type: string - description: - description: Description of the role. - example: Reviews the campaigns + balance: + description: |- + The type of balance to check: + - `current` is the sum of currently active points + - `pending` is the sum of pending points. + - `negative` is the sum of negative points. + - `tentativeCurrent` is the tentative points balance + within the current open customer session. + enum: + - current + - pending + - negative + - tentativeCurrent + example: current type: string - members: - description: A list of user identifiers assigned to this role. - example: - - 48 - - 562 - - 475 - - 18 + value: + description: The numeric value to compare the balance against. + example: 500.0 + type: number + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - format: int64 - type: integer + $ref: '#/components/schemas/Block' type: array - acl: - description: The `Access Control List` json defining the role of the user. - This represents the access control on the user level. - example: - Role: 127 - properties: {} - type: object required: - - accountId - - acl - - created - - id - - modified - - name + - balance + - operator + - program + - subledger + - type + - value + title: CheckLoyaltyBalanceBlock type: object - CampaignTemplateCouponReservationSettings: - example: - reservationLimit: 45 - isReservationMandatory: false + x-discriminator-value: checkLoyaltyBalance + x-ms-discriminator-value: checkLoyaltyBalance + CheckCouponBlock: + description: A block that validates the coupon code value and date. properties: - reservationLimit: - description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - isReservationMandatory: - default: false - description: An indication of whether the code can be redeemed only if it - has been reserved first. - example: false - title: Is reservation mandatory + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + redeem: + description: When `true`, the coupon code is redeemed. + example: true type: boolean + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. + items: + $ref: '#/components/schemas/Block' + type: array + required: + - redeem + - type + title: CheckCouponBlock type: object - TemplateLimitConfig: - example: - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon + x-discriminator-value: checkCoupon + x-ms-discriminator-value: checkCoupon + CheckReferralBlock: + description: A block that validates the referral code value and date. properties: - action: - description: | - The limitable action to which this limit applies. For example: - - `setDiscount` - - `setDiscountEffect` - - `redeemCoupon` - - `createCoupon` - example: createCoupon + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - limit: - description: The value to set for the limit. - example: 1000.0 - minimum: 0 - type: number - period: - description: The period on which the budget limit recurs. - enum: - - daily - - weekly - - monthly - - yearly - example: yearly + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - entities: - description: The entity that this limit applies to. - example: - - Coupon + tags: + description: Semantic labels attached to this block. items: - enum: - - Coupon - - Referral - - Profile - - Identifier - - Store - - Session type: string + readOnly: true + type: array + redeem: + description: When `true`, the referral code is redeemed. + example: true + type: boolean + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. + items: + $ref: '#/components/schemas/Block' type: array required: - - action - - entities - - limit + - redeem + - type + title: CheckReferralBlock type: object - CampaignTemplateParams: - example: - attributeId: 42 - name: discount_value - description: This is a template parameter of type `number`. - type: number + x-discriminator-value: checkReferral + x-ms-discriminator-value: checkReferral + UpdateAudienceMembershipBlock: + description: A block that adds a customer to or removes them from an audience. properties: - name: - description: Name of the campaign template parameter. - example: discount_value - minLength: 1 + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string type: - description: Defines the type of parameter value. + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + operator: + description: The action to perform. enum: - - string - - number - - boolean - - percent - - (list string) - - (list number) - - time - example: number + - add + - remove + example: add type: string - description: - description: Explains the meaning of this template parameter and the placeholder - value that will define it. It is used on campaign creation from this template. - example: This is a template parameter of type `number`. + profile: + description: The customer profile to add or remove from the audience. `Current` + targets the customer in the current session; `Advocate` targets the person + who invited their friend via referral program. + enum: + - Current + - Advocate + example: Current type: string - attributeId: - description: ID of the corresponding attribute. - example: 42 - format: int64 - type: integer + audience: + $ref: '#/components/schemas/UpdateAudienceMembershipBlock_audience' required: - - description - - name + - audience + - operator + - profile - type + title: UpdateAudienceMembershipBlock type: object - CampaignTemplateCollection: - example: - name: My collection - description: My collection of SKUs + x-discriminator-value: updateAudienceMembership + x-ms-discriminator-value: updateAudienceMembership + UpdateAchievementProgressBlock: + description: A block that updates the progress of a customer in an achievement. properties: - name: - description: The name of this collection. - example: My collection - minLength: 1 - pattern: ^[A-Za-z](\w|\s)*$ + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - description: - description: A short description of the purpose of this collection. - example: My collection of SKUs + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + operator: + enum: + - increaseBy + example: increaseBy + type: string + value: + description: The value to update the progress by. Supports template placeholders + (e.g. "{{$Session.Total / 2}}") for dynamic quantities. + example: "10" type: string + achievement: + $ref: '#/components/schemas/UpdateAchievementProgressBlock_achievement' required: - - name + - achievement + - operator + - type + - value + title: UpdateAchievementProgressBlock type: object - UpdateCampaignTemplate: + x-discriminator-value: updateAchievementProgress + x-ms-discriminator-value: updateAchievementProgress + UpdateAttributeValueBlock: + description: A block that sets or updates an attribute. The `type` may be empty + for [built-in attributes](https://docs.talon.one/docs/dev/concepts/attributes). properties: - name: - description: The campaign template name. - example: Discount campaign - minLength: 1 - type: string - description: - description: Customer-facing text that explains the objective of the template. - example: This is a template for a discount campaign. + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - instructions: - description: Customer-facing text that explains how to use the template. - For example, you can use this property to explain the available attributes - of this template, and how they can be modified when a user uses this template - to create a new campaign. - example: Use this template for discount campaigns. Set the campaign properties - according to the campaign goals, and don't forget to set an end date. + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - campaignAttributes: - description: The campaign attributes that campaigns created from this template - will have by default. - properties: {} + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + operator: + description: The update operation applied to the attribute. + enum: + - setTo + - increaseBy + - decreaseBy + - multiplyBy + - divideBy + - toggle + - laterBy + - earlierBy + example: setTo + type: string + attribute: + $ref: '#/components/schemas/UpdateAttributeValueBlock_attribute' + value: + description: The value of the attribute. Omitted when operator is set to + `toggle`. + example: "10" type: object - couponAttributes: - description: The campaign attributes that coupons created from this template - will have by default. + target: + $ref: '#/components/schemas/UpdateAttributeValueBlock_target' + required: + - attribute + - operator + - target + - type + title: UpdateAttributeValueBlock + type: object + x-discriminator-value: updateAttributeValue + x-ms-discriminator-value: updateAttributeValue + TriggerCustomEffectBlock: + description: A block that triggers a configured custom effect and passes its + required parameters. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + customEffect: + $ref: '#/components/schemas/TriggerCustomEffectBlock_customEffect' + params: + description: The custom effect's parameters, in configured order. Each property + name is the parameter's title, lowercased with spaces replaced by underscores + (for example, `Order ID` becomes `order_id`); falls back to `param_0`, + `param_1`, and so on if a title is blank or collides with another. + example: + template_id: TPL-10293 properties: {} type: object - state: - description: Only campaign templates in 'available' state may be used to - create campaigns. - enum: - - draft - - enabled - - disabled + target: + $ref: '#/components/schemas/TriggerCustomEffectBlock_target' + onError: + additionalProperties: + items: + $ref: '#/components/schemas/Block' + type: array + description: Named error handlers evaluated when a specific error occurs. + type: object + required: + - customEffect + - target + - type + title: TriggerCustomEffectBlock + type: object + x-discriminator-value: triggerCustomEffect + x-ms-discriminator-value: triggerCustomEffect + CheckEventBlock: + description: A block that validates the event type. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - activeRulesetId: - description: The ID of the ruleset this campaign template will use. - example: 5 - format: int64 - type: integer tags: - description: A list of tags for the campaign template. - example: - - discount + description: Semantic labels attached to this block. items: - maxLength: 50 - minLength: 1 type: string - maxItems: 50 + readOnly: true type: array - reevaluateOnReturn: - description: Indicates whether campaigns created from this template should - be reevaluated when a customer returns an item. - example: true - type: boolean - features: - description: A list of features for the campaign template. + eventType: + description: The event type to check against. + example: profileCreated + type: string + matchers: items: - enum: - - coupons - - referrals - - loyalty - - giveaways - - strikethrough - - achievements - type: string + $ref: '#/components/schemas/Block' type: array - couponSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - couponReservationSettings: - $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' - referralSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - limits: - description: The set of limits that operate for this campaign template. + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - $ref: '#/components/schemas/TemplateLimitConfig' + $ref: '#/components/schemas/Block' type: array - templateParams: - description: Fields which can be used to replace values in a rule. + required: + - eventType + - type + title: CheckEventBlock + type: object + x-discriminator-value: checkEvent + x-ms-discriminator-value: checkEvent + CheckAchievementBlock: + description: A block that checks the current customer's completion or progress + status in an achievement. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/CampaignTemplateParams' + type: string + readOnly: true type: array - applicationsIds: - description: A list of IDs of the Applications that are subscribed to this - campaign template. - example: - - 1 - - 2 - - 3 + operator: + description: The comparison operator applied to the achievement. + enum: + - justCompleted + - started + - not(started) + - inProgress + - not(inProgress) + - completed + - not(completed) + example: justCompleted + type: string + achievement: + $ref: '#/components/schemas/CheckAchievementBlock_achievement' + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - format: int64 - type: integer + $ref: '#/components/schemas/Block' type: array - campaignCollections: - description: The campaign collections from the blueprint campaign for the - template. + required: + - achievement + - operator + - type + title: CheckAchievementBlock + type: object + x-discriminator-value: checkAchievement + x-ms-discriminator-value: checkAchievement + CheckBudgetBlock: + description: A block that verifies if a specific budget has sufficient limit + available, and whether this limit meets or exceeds a specific value. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/CampaignTemplateCollection' + type: string + readOnly: true type: array - defaultCampaignGroupId: - description: The default campaign group ID. - example: 42 - format: int64 - type: integer - campaignType: - default: advanced - description: | - The campaign type. Possible type values: - - `cartItem`: Type of campaign that can apply effects only to cart items. - - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. + operator: + description: The comparison operator applied to the limit. `available` checks + if there is budget available for a given limitable action; `enoughFor` + checks if the available budget meets or exceeds a specific value limit. enum: - - cartItem - - advanced - example: advanced + - available + - enoughFor + example: available + type: string + action: + description: The limitable action to check. + enum: + - redeemCoupon + - redeemReferral + - setDiscount + - createCoupon + - createReferral + - setDiscountEffect + - createLoyaltyPoints + - createLoyaltyPointsEffect + - redeemLoyaltyPoints + - redeemLoyaltyPointsEffect + - awardGiveaway + - addFreeItemEffect + - customEffect + - callApi + example: setDiscount type: string + value: + description: The value to check against when using the `enoughFor` operator. + example: 5.0 + type: number + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. + items: + $ref: '#/components/schemas/Block' + type: array required: - - applicationsIds - - description - - instructions - - name - - state + - action + - operator + - type + title: CheckBudgetBlock type: object - CampaignTemplate: - example: - instructions: Use this template for discount campaigns. Set the campaign properties - according to the campaign goals, and don't forget to set an end date. - campaignCollections: - - name: My collection - description: My collection of SKUs - - name: My collection - description: My collection of SKUs - campaignsCount: 3 - defaultCampaignGroupId: 42 - description: This is a template for a discount campaign. - features: - - coupons - - coupons - couponReservationSettings: - reservationLimit: 45 - isReservationMandatory: false - couponSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - templateParams: - - attributeId: 42 - name: discount_value - description: This is a template parameter of type `number`. - type: number - - attributeId: 42 - name: discount_value - description: This is a template parameter of type `number`. - type: number - id: 6 - couponAttributes: '{}' - state: draft - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - activeRulesetId: 5 - campaignAttributes: '{}' - applicationsIds: - - 1 - - 2 - - 3 - - 1 - - 2 - - 3 - campaignType: advanced - updatedBy: Jane Doe - created: 2020-06-10T09:05:27.993483Z - isUserFavorite: false - reevaluateOnReturn: true - userId: 388 - tags: - - discount - accountId: 3886 - validApplicationIds: - - 1 - - 2 - - 3 - name: Discount campaign - referralSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - updated: 2022-08-24T14:15:22Z + x-discriminator-value: checkBudget + x-ms-discriminator-value: checkBudget + CreateCouponBlock: + description: A block that creates a coupon code. properties: id: - description: The internal ID of this entity. - example: 6 - format: int64 - type: integer - created: - description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z - format: date-time - type: string - accountId: - description: The ID of the account that owns this entity. - example: 3886 - format: int64 - type: integer - userId: - description: The ID of the user associated with this entity. - example: 388 - format: int64 - type: integer - name: - description: The campaign template name. - example: Discount campaign - minLength: 1 + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true type: string - description: - description: Customer-facing text that explains the objective of the template. - example: This is a template for a discount campaign. + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - instructions: - description: Customer-facing text that explains how to use the template. - For example, you can use this property to explain the available attributes - of this template, and how they can be modified when a user uses this template - to create a new campaign. - example: Use this template for discount campaigns. Set the campaign properties - according to the campaign goals, and don't forget to set an end date. + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + campaignId: + description: The ID of the campaign in which the coupon code is created. + type: object + recipientId: + description: The integration ID of the customer that is allowed to redeem + this coupon. + example: '{{$Profile.IntegrationId}}' type: string - campaignAttributes: - description: The campaign attributes that campaigns created from this template - will have by default. - properties: {} + storeInSession: + description: When `true`, the coupon is stored in the session. + example: true + type: boolean + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. type: object - couponAttributes: - description: The campaign attributes that coupons created from this template - will have by default. - properties: {} + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. type: object - state: - description: Only campaign templates in 'available' state may be used to - create campaigns. - enum: - - draft - - enabled - - disabled + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2024-12-24T14:15:22Z + type: object + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2024-12-24T14:15:22Z + type: object + attributes: + description: Custom attributes associated with this coupon code. + type: object + validCharacters: + description: Characters used to generate the random parts of a code. + example: ABC + type: string + pattern: + description: | + The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + example: SUMMER-####-#### + type: string + required: + - campaignId + - recipientId + - storeInSession + - type + title: CreateCouponBlock + type: object + x-discriminator-value: createCoupon + x-ms-discriminator-value: createCoupon + CreateReferralBlock: + description: A block that creates a referral code. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. type: string - activeRulesetId: - description: The ID of the ruleset this campaign template will use. - example: 5 - format: int64 - type: integer tags: - description: A list of tags for the campaign template. - example: - - discount + description: Semantic labels attached to this block. items: - maxLength: 50 - minLength: 1 type: string - maxItems: 50 + readOnly: true type: array - reevaluateOnReturn: - description: Indicates whether campaigns created from this template should - be reevaluated when a customer returns an item. + campaignId: + description: The ID of the campaign in which the referral code is created. + Either a numeric scalar or a `{{expression}}` string that resolves to + a number at evaluation time. + type: object + friendId: + description: An optional integration ID of the friend's profile. + example: '{{$Profile.IntegrationId}}' + type: string + storeInSession: + description: When `true`, the referral code is stored in the session. example: true type: boolean - features: - description: A list of features for the campaign template. + usageLimit: + description: | + The number of times the referral code code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + type: object + startDate: + description: Timestamp at which point the referral code becomes valid. + example: 2024-12-24T14:15:22Z + type: object + expiryDate: + description: Expiration date of the referral code. Referral code never expires + if this is omitted. + example: 2024-12-24T14:15:22Z + type: object + attributes: + description: Custom attributes associated with this referral code. + type: object + validCharacters: + description: Characters used to generate the random parts of a code. + example: ABC + type: string + pattern: + description: | + The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + example: SUMMER-####-#### + type: string + required: + - campaignId + - friendId + - storeInSession + - type + title: CreateReferralBlock + type: object + x-discriminator-value: createReferral + x-ms-discriminator-value: createReferral + ReserveCouponBlock: + description: A block that reserve a coupon during a customer session. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - enum: - - coupons - - referrals - - loyalty - - giveaways - - strikethrough - - achievements type: string + readOnly: true type: array - couponSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - couponReservationSettings: - $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' - referralSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - limits: - description: The set of limits that operate for this campaign template. + required: + - type + title: ReserveCouponBlock + type: object + x-discriminator-value: reserveCoupon + x-ms-discriminator-value: reserveCoupon + CheckLoyaltyCardBlock: + description: A block that verifies whether a loyalty card is linked to the user's + profile. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/TemplateLimitConfig' + type: string + readOnly: true type: array - templateParams: - description: Fields which can be used to replace values in a rule. + operator: + description: An indicator of how the block compares its elements. + enum: + - linked + - not(linked) + type: string + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - $ref: '#/components/schemas/CampaignTemplateParams' + $ref: '#/components/schemas/Block' type: array - applicationsIds: - description: A list of IDs of the Applications that are subscribed to this - campaign template. - example: - - 1 - - 2 - - 3 - - 1 - - 2 - - 3 - items: - format: int64 - type: integer - type: array - campaignCollections: - description: The campaign collections from the blueprint campaign for the - template. + required: + - operator + - type + title: CheckLoyaltyCardBlock + type: object + x-discriminator-value: checkLoyaltyCard + x-ms-discriminator-value: checkLoyaltyCard + CheckTierBlock: + description: A block that checks whether a user profile is a member of a specific + tier within a loyalty program. + properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. items: - $ref: '#/components/schemas/CampaignTemplateCollection' + type: string + readOnly: true type: array - defaultCampaignGroupId: - description: The default campaign group ID. - example: 42 - format: int64 - type: integer - campaignType: - default: advanced - description: | - The campaign type. Possible type values: - - `cartItem`: Type of campaign that can apply effects only to cart items. - - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. + operator: + description: An indicator of how the block compares its elements. enum: - - cartItem - - advanced - example: advanced - type: string - campaignsCount: - description: The number of Campaigns created from this template. - example: 3 - format: int64 - type: integer - updated: - description: Timestamp of the most recent update to the campaign template - or any of its elements. - example: 2022-08-24T14:15:22Z - format: date-time + - member + - not(member) + example: member type: string - updatedBy: - description: Name of the user who last updated this campaign template, if - available. - example: Jane Doe + subledger: + description: The name of the subledger to check the balance of. Can be empty + if this block checks the loyalty program's main ledger balance instead + of a subledger. + example: "" type: string - validApplicationIds: - description: The IDs of the Applications that are related to this entity. - example: - - 1 - - 2 - - 3 + tier: + $ref: '#/components/schemas/CheckTierBlock_tier' + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. items: - format: int64 - type: integer + $ref: '#/components/schemas/Block' type: array - isUserFavorite: - default: false - description: A flag indicating whether the user marked the template as a - favorite. - example: false - type: boolean required: - - accountId - - applicationsIds - - campaignType - - created - - description - - id - - instructions - - name - - reevaluateOnReturn - - state - - userId - - validApplicationIds + - operator + - subledger + - tier + - type + title: CheckTierBlock type: object - NewCampaignTemplate: + x-discriminator-value: checkTier + x-ms-discriminator-value: checkTier + RedeemLoyaltyPointsBlock: + description: A block that deducts a specified amount of points from a customer's + loyalty program balance, optionally from a named subledger. properties: + id: + description: Unique identifier for this block. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + readOnly: true + type: string + type: + description: Identifies the block variant and determines which additional + properties are present in it. + type: string + tags: + description: Semantic labels attached to this block. + items: + type: string + readOnly: true + type: array + program: + $ref: '#/components/schemas/RedeemLoyaltyPointsBlock_program' + subledger: + description: The name of the subledger to deduct points from. Can be empty + if this block deducts from the loyalty program's main ledger instead of + a subledger. + example: main + type: string + value: + description: Number of points to deduct. Either a numeric scalar or a `{{expression}}` + string that resolves to a number at evaluation time. + type: object name: - description: The campaign template name. - minLength: 1 + description: A custom description recorded as the reason for the point deduction. + example: Purchase Deduction + type: string + onFailure: + description: Promotion blocks evaluated when this block fails or returns + false. + items: + $ref: '#/components/schemas/Block' + type: array + required: + - program + - subledger + - type + - value + title: RedeemLoyaltyPointsBlock + type: object + x-discriminator-value: redeemLoyaltyPoints + x-ms-discriminator-value: redeemLoyaltyPoints + RuleV2: + description: Shared fields common to all V2 rule types. + example: + blocks: + - null + - null + description: description + id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + title: 10% off for loyalty members + parentId: parentId + properties: + id: + description: Unique identifier of the rule. + example: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + type: string + parentId: + description: ID of the parent rule, if any. + type: string + title: + description: A short description of the rule. + example: 10% off for loyalty members type: string description: - description: Customer-facing text that explains the objective of the template. + description: A longer description of the rule. type: string - instructions: - description: Customer-facing text that explains how to use the template. - For example, you can use this property to explain the available attributes - of this template, and how they can be modified when a user uses this template - to create a new campaign. + blocks: + description: The condition and effect blocks that make up this rule. + items: + $ref: '#/components/schemas/Block' + type: array + required: + - blocks + - title + title: RuleV2 + type: object + FilterSelectorStep: + description: Filters only items that match a predicate block. + properties: + type: + description: A step discriminator of type `filter`. + enum: + - filter + example: filter type: string - campaignAttributes: - description: The campaign attributes that campaigns created from this template - will have by default. - properties: {} - type: object - couponAttributes: - description: The campaign attributes that coupons created from this template - will have by default. - properties: {} + predicate: + description: Describes a part of the logic of the rule. + discriminator: + propertyName: type type: object - state: - description: Only Campaign Templates in 'available' state may be used to - create Campaigns. + required: + - predicate + - type + title: FilterSelectorStep + type: object + x-discriminator-value: filter + x-ms-discriminator-value: filter + SortSelectorStepField: + properties: + expression: + description: The attribute path the items are sorted by. + example: $Item.Price + type: string + direction: + description: The sort direction for this field. enum: - - draft - - enabled - - disabled + - asc + - desc + example: asc type: string - tags: - description: A list of tags for the campaign template. + required: + - direction + - expression + title: SortSelectorStepField + type: object + SortSelectorStep: + description: Sorts items by one or more field expressions. + properties: + type: + description: A step discriminator of type `sort`. + enum: + - sort + example: sort + type: string + fields: + description: One or more fields to sort by, applied in order. Each field + has its own direction. items: - maxLength: 50 - minLength: 1 - type: string - maxItems: 50 + $ref: '#/components/schemas/SortSelectorStepField' type: array - reevaluateOnReturn: - description: Indicates whether campaigns created from this template should - be reevaluated when a customer returns an item. + required: + - fields + - type + title: SortSelectorStep + type: object + x-discriminator-value: sort + x-ms-discriminator-value: sort + SelectSelectorStep: + description: 'Picks a subset of the items by count, range, or exact position. + The `operator` determines which additional fields are required: - `many` selects + items from `from` (`start` or `end`) and is limited by `count`. - `between` + selects items between integer indices `from` and `to`. - `one` selects the + single item at `index`.' + properties: + type: + description: A step discriminator of type `select`. + enum: + - select + example: select + type: string + operator: + description: The selection operator applied to the items. + enum: + - many + - between + - one + example: many + type: string + from: + description: The starting value of the selection. For the `many` operator + this is the string `start` or `end`; for the `between` operator this is + an integer start index. No discriminator is needed since the string and + integer branches are distinguishable by JSON type alone. + type: object + to: + description: The end index for the `between` operator. The item at this + index is not included. + example: 7 + format: int32 + type: integer + count: + description: The maximum number of items to select for the `many` operator. + example: 5 + format: int32 + type: integer + index: + description: The exact position of the item to select for the `one` operator. + example: 0 + format: int32 + type: integer + partial: + description: Indicates if the step returns fewer items than requested when + the source list is shorter than the range needs. Always `true` for the + `many` and `between` operators; not present for `one`, which fails instead + of returning a partial result. example: true type: boolean - features: - description: A list of features for the campaign template. + required: + - operator + - type + title: SelectSelectorStep + type: object + x-discriminator-value: select + x-ms-discriminator-value: select + MapSelectorStep: + description: Transforms each item using an expression. + properties: + type: + description: A step discriminator of type `map`. + enum: + - map + example: map + type: string + expression: + description: The attribute path each item is mapped to. + example: $Item.Price + type: string + required: + - expression + - type + title: MapSelectorStep + type: object + x-discriminator-value: map + x-ms-discriminator-value: map + ReduceSelectorStep: + description: Aggregates items into a single value. + properties: + type: + description: A step discriminator of type `reduce`. + enum: + - reduce + example: reduce + type: string + operator: + description: | + The aggregation operator applied to the items produced by the preceding step: + - `max`, `min`, and `sum` operate on numeric values. + - `count` returns the number of items. + - `empty` reports whether the list is empty. + enum: + - max + - min + - sum + - count + - empty + example: sum + type: string + required: + - operator + - type + title: ReduceSelectorStep + type: object + x-discriminator-value: reduce + x-ms-discriminator-value: reduce + ReverseSelectorStep: + description: Reverses the order of the items. + properties: + type: + description: A step discriminator of type `reverse`. + enum: + - reverse + example: reverse + type: string + required: + - type + title: ReverseSelectorStep + type: object + x-discriminator-value: reverse + x-ms-discriminator-value: reverse + SelectorValueMapRef: + description: A reference to a value map by its internal ID. + properties: + id: + description: The internal ID of the referenced value map. + example: 12 + format: int64 + type: integer + required: + - id + title: SelectorValueMapRef + type: object + FilterAndMapValuesSelectorStep: + description: Keeps items that exist in the value map, and attaches each kept + item's mapped value. + properties: + type: + description: A step discriminator of type `filterAndMapValues`. + enum: + - filterAndMapValues + example: filterAndMapValues + type: string + valueMap: + $ref: '#/components/schemas/SelectorValueMapRef' + required: + - type + - valueMap + title: FilterAndMapValuesSelectorStep + type: object + x-discriminator-value: filterAndMapValues + x-ms-discriminator-value: filterAndMapValues + SelectorStep: + description: A single step in a selector item pipeline. The `type` field determines + the step variant. + discriminator: + propertyName: type + type: object + Selector: + description: A named pipeline of steps (filter, sort, map, etc.) that filters + or transforms a list of cart items. Replaces `cartItemFilter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) + in V1 rulesets. + example: + name: discountedCartItems + source: $Session.CartItems + type: selector + steps: + - null + - null + properties: + name: + description: The name of the selector binding. + example: discountedCartItems + type: string + type: + description: A binding of type `selector`. + enum: + - selector + example: selector + type: string + source: + description: The attribute path the pipeline draws items from. + example: $Session.CartItems + type: string + steps: + description: Ordered pipeline steps applied to the source items. items: - enum: - - coupons - - referrals - - loyalty - - giveaways - - strikethrough - - achievements - type: string + $ref: '#/components/schemas/SelectorStep' type: array - couponSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - couponReservationSettings: - $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' - referralSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - limits: - description: The set of limits that will operate for this campaign template. + required: + - name + - source + - steps + - type + title: Selector + type: object + Bundle: + description: A named bundle definition consisting of selector sources with matching + constraints. Replaces `bundle` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) + in V1 rulesets. + example: + matchers: + - color + sources: + - '{{$mains}}' + - '{{$drinks}}' + counts: + - 1 + - 2 + name: meal_deal + id: 1b671a64-40d5-491e-99b0-da01ff1f3341 + type: bundle + properties: + id: + description: An identifier derived from the bundle content. + example: 1b671a64-40d5-491e-99b0-da01ff1f3341 + type: string + name: + description: The name of the bundle. + example: meal_deal + type: string + type: + description: A binding of type `bundle`. + enum: + - bundle + example: bundle + type: string + sources: + description: The selector sources of bundle items. Each source is expressed + as a `{{$selectorName}}` reference. + example: + - '{{$mains}}' + - '{{$drinks}}' items: - $ref: '#/components/schemas/TemplateLimitConfig' + type: string type: array - templateParams: - description: Fields which can be used to replace values in a rule. + counts: + description: The number of items to retrieve from each corresponding source + in `sources`. + example: + - 1 + - 2 items: - $ref: '#/components/schemas/CampaignTemplateParams' + format: int64 + type: integer type: array - campaignCollections: - description: The campaign collections from the blueprint campaign for the - template. + matchers: + description: Attribute names that the bundled items must share. + example: + - color items: - $ref: '#/components/schemas/CampaignTemplateCollection' + type: string type: array - defaultCampaignGroupId: - description: The default campaign group ID. + required: + - counts + - id + - name + - sources + - type + title: Bundle + type: object + TemplateParameter: + description: A named parameter definition that exposes a configurable value + in a campaign template. Replaces `templateParameter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) + in V1 rulesets. + example: + minValue: 0.0 + maxValue: 10000.0 + valueType: number + name: minCartTotal + description: Minimum cart total to trigger the campaign. + attribute: 42 + value: "50" + properties: + name: + description: The name of the template parameter. + example: minCartTotal + type: string + value: + description: The parameter's bound value. Its type depends on the `valueType`. + example: "50" + type: object + valueType: + description: The data type of the value, derived from the bound expression + (for example `number`, `string`, `boolean`, `percent`, `time`, `(list + string)`, or `(list number)`). + example: number + type: string + minValue: + description: The minimum value allowed for this parameter. + example: 0.0 + type: number + maxValue: + description: The maximum value allowed for this parameter. + example: 10000.0 + type: number + description: + description: A human-readable description of the parameter shown when creating + campaigns from the template. + example: Minimum cart total to trigger the campaign. + type: string + attribute: + description: The ID of the attribute linked to this parameter. Omitted when + the parameter is not linked to an attribute. example: 42 format: int64 type: integer - campaignType: - default: advanced - description: | - The campaign type. Possible type values: - - `cartItem`: Type of campaign that can apply effects only to cart items. - - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. - enum: - - cartItem - - advanced - example: advanced - type: string required: - - campaignType - description - - instructions - name - - state - type: object - ExperimentVariant: - example: - created: 2020-06-10T09:05:27.993483Z - isPrimary: true - name: Variant A - ruleset: - rbVersion: v2 - created: 2020-06-10T09:05:27.993483Z - campaignId: 320 - bindings: [] - activatedAt: 2000-01-23T04:56:07.000+00:00 - activate: true - rules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - id: 6 - strikethroughRules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - templateId: 3 - userId: 388 - weight: 12 - experimentId: 10 + - value + - valueType + title: TemplateParameter + type: object + RulesetV2: + description: Ruleset in the V2 JSON block format. + example: + promotionRules: + - blocks: + - null + - null + description: description + id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + title: 10% off for loyalty members + parentId: parentId + - blocks: + - null + - null + description: description + id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + title: 10% off for loyalty members + parentId: parentId + created: 2000-01-23T04:56:07.000+00:00 + campaignId: 320 + activatedAt: 2000-01-23T04:56:07.000+00:00 + bundles: + - matchers: + - color + sources: + - '{{$mains}}' + - '{{$drinks}}' + counts: + - 1 + - 2 + name: meal_deal + id: 1b671a64-40d5-491e-99b0-da01ff1f3341 + type: bundle + - matchers: + - color + sources: + - '{{$mains}}' + - '{{$drinks}}' + counts: + - 1 + - 2 + name: meal_deal + id: 1b671a64-40d5-491e-99b0-da01ff1f3341 + type: bundle id: 6 + strikethroughRules: + - blocks: + - null + - null + description: description + id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + title: 10% off for loyalty members + parentId: parentId + - blocks: + - null + - null + description: description + id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + title: 10% off for loyalty members + parentId: parentId + templateId: 3 + selectors: + - name: discountedCartItems + source: $Session.CartItems + type: selector + steps: + - null + - null + - name: discountedCartItems + source: $Session.CartItems + type: selector + steps: + - null + - null + userId: 385 + parameters: + - minValue: 0.0 + maxValue: 10000.0 + valueType: number + name: minCartTotal + description: Minimum cart total to trigger the campaign. + attribute: 42 + value: "50" + - minValue: 0.0 + maxValue: 10000.0 + valueType: number + name: minCartTotal + description: Minimum cart total to trigger the campaign. + attribute: 42 + value: "50" properties: id: - description: The internal ID of this entity. + description: Internal ID of this entity. example: 6 format: int64 + readOnly: true type: integer created: description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z format: date-time + readOnly: true type: string - name: - example: Variant A - type: string - experimentId: - example: 10 + userId: + description: The ID of the user that created this ruleset. + example: 385 format: int64 + readOnly: true type: integer - ruleset: - $ref: '#/components/schemas/Ruleset' - weight: - example: 12 + campaignId: + description: The ID of the campaign that owns this entity. + example: 320 format: int64 + readOnly: true type: integer - isPrimary: - example: true - type: boolean - required: - - created - - id - - isPrimary - - name - type: object - Experiment: - example: - deletedat: 2000-01-23T04:56:07.000+00:00 - created: 2020-06-10T09:05:27.993483Z - campaign: - type: advanced - templateId: 3 - customEffectCount: 0 - activeRevisionId: 6 - features: - - coupons - - referrals - createdLoyaltyPointsCount: 9.0 - storesImported: true - couponSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - experimentId: 1 - id: 4 - state: enabled - couponAttributes: '{}' - reservecouponEffectCount: 9 - updatedBy: Jane Doe - frontendState: running - created: 2020-06-10T09:05:27.993483Z - referralCreationCount: 8 - stageRevision: false - couponRedemptionCount: 163 - couponCreationCount: 16 - version: 6 - campaignGroups: - - 1 - - 3 - tags: - - summer - discountEffectCount: 343 - budgets: - - limit: 1000.0 - action: createCoupon - counter: 42.0 - - limit: 1000.0 - action: createCoupon - counter: 42.0 - redeemedLoyaltyPointsCount: 8.0 - name: Summer promotions - valueMapsIds: - - 100 - - 215 - applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 - callApiEffectCount: 0 - createdLoyaltyPointsEffectCount: 2 - discountCount: 288.0 - revisionFrontendState: revised - description: Campaign for all summer 2021 promotions - activeRevisionVersionId: 6 - currentRevisionVersionId: 6 - startTime: 2021-07-20T22:00:00Z - currentRevisionId: 6 - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - activeRulesetId: 6 - reevaluateOnReturn: true - userId: 388 - awardedGiveawaysCount: 9 - redeemedLoyaltyPointsEffectCount: 9 - linkedStoreIds: - - 1 - - 2 - - 3 - createdBy: John Doe - addFreeItemEffectCount: 0 - referralSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - attributes: '{}' - lastActivity: 2022-11-10T23:00:00Z - endTime: 2021-09-22T22:00:00Z - referralRedemptionCount: 3 - id: 6 - state: enabled - variants: - - created: 2020-06-10T09:05:27.993483Z - isPrimary: true - name: Variant A - ruleset: - rbVersion: v2 - created: 2020-06-10T09:05:27.993483Z - campaignId: 320 - bindings: [] - activatedAt: 2000-01-23T04:56:07.000+00:00 - activate: true - rules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - id: 6 - strikethroughRules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - templateId: 3 - userId: 388 - weight: 12 - experimentId: 10 - id: 6 - - created: 2020-06-10T09:05:27.993483Z - isPrimary: true - name: Variant A - ruleset: - rbVersion: v2 - created: 2020-06-10T09:05:27.993483Z - campaignId: 320 - bindings: [] - activatedAt: 2000-01-23T04:56:07.000+00:00 - activate: true - rules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - id: 6 - strikethroughRules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - templateId: 3 - userId: 388 - weight: 12 - experimentId: 10 - id: 6 - applicationId: 322 - isVariantAssignmentExternal: true - activated: 2000-01-23T04:56:07.000+00:00 - properties: - id: - description: The internal ID of this entity. - example: 6 + templateId: + description: The ID of the campaign template that owns this entity. + example: 3 format: int64 + readOnly: true type: integer - created: - description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z + activatedAt: + description: Timestamp indicating when this ruleset was activated. format: date-time + readOnly: true type: string - applicationId: - description: The ID of the Application that owns this entity. - example: 322 + promotionRules: + description: Set of promotion rules. + items: + $ref: '#/components/schemas/RuleV2' + type: array + strikethroughRules: + description: Set of strikethrough rules. + items: + $ref: '#/components/schemas/RuleV2' + type: array + selectors: + description: Variable bindings of type selector. + items: + $ref: '#/components/schemas/Selector' + readOnly: true + type: array + bundles: + description: Variable bindings of type bundle. + items: + $ref: '#/components/schemas/Bundle' + readOnly: true + type: array + parameters: + description: Variable bindings of type template parameter. + items: + $ref: '#/components/schemas/TemplateParameter' + readOnly: true + type: array + required: + - promotionRules + title: RulesetV2 + type: object + UpdateCouponBatch: + example: + expiryDate: 2023-08-24T14:15:22Z + usageLimit: 100 + reservationLimit: 45 + attributes: '{}' + batchID: batchID + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + properties: + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 format: int64 + maximum: 999999 + minimum: 0 type: integer - isVariantAssignmentExternal: + discountLimit: description: | - The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. - type: boolean - campaign: - $ref: '#/components/schemas/Campaign' - activated: + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: description: | - The date and time the experiment was activated. + The number of reservations that can be made with this coupon code. + example: 45 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z format: date-time type: string - state: - default: disabled - description: | - A disabled experiment is not evaluated for rules or coupons. - enum: - - enabled - - disabled - - archived - example: enabled + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z + format: date-time type: string - variants: - items: - $ref: '#/components/schemas/ExperimentVariant' - type: array - deletedat: + attributes: description: | - The date and time the experiment was deleted. - format: date-time + Optional property to set the value of custom coupon attributes. They are defined in the Campaign Manager, + see [Managing attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes). + + Coupon attributes can also be set to _mandatory_ in your Application [settings](https://docs.talon.one/docs/product/applications/using-attributes#making-attributes-mandatory). + If your Application uses mandatory attributes, you must use this property to set their value. + properties: {} + type: object + batchID: + description: The ID of the batch the coupon(s) belong to. + title: Batch ID type: string - required: - - applicationId - - created - - id - - state type: object - NewExperiment: + NewCoupons: + example: + recipientIntegrationId: URNGV8294NV + uniquePrefix: "" + implicitlyReserved: false + supportRequestNote: Approved as compensation for the delayed order. + usageLimit: 100 + supportRequestId: 42 + numberOfCoupons: 1 + batchId: 3rdparty_fjsieoaa + expiryDate: 2023-08-24T14:15:22Z + couponPattern: SUMMER-##### + validCharacters: + - A + - B + - G + - "Y" + reservationLimit: 45 + attributes: + venueId: 12 + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + isReservationMandatory: false properties: - isVariantAssignmentExternal: + usageLimit: description: | - The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. - type: boolean - campaign: - $ref: '#/components/schemas/NewCampaign' - required: - - campaign - - isVariantAssignmentExternal - type: object - ExperimentListResultsRequest: - properties: - experimentIds: - items: - format: int64 - type: integer - type: array - required: - - experimentIds - type: object - ExperimentVariantResult: - properties: - variantId: - description: The ID of the variant. - example: 1 - format: int64 - type: integer - variantName: - description: The name of the variant. - example: Variant A - type: string - variantWeight: - description: The weight of the variant. - example: 50 + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 format: int64 + maximum: 999999 + minimum: 0 type: integer - isWinner: - description: Calculated flag if the variant is the winner. - example: true - type: boolean - totalRevenue: - description: The total, pre-discount value of all items purchased in a customer - session. - example: 100.0 - type: number - sessionsCount: - description: The number of all closed sessions. - example: 100.0 - type: number - avgItemsPerSession: - description: The number of items from sessions divided by the number of - sessions. - example: 100.0 - type: number - avgSessionValue: - description: The average customer session value, calculated by dividing - the revenue value by the number of sessions. - example: 100.0 - type: number - avgDiscountedSessionValue: - description: The average customer session value, calculated by dividing - the revenue value by the number of sessions. - example: 100.0 - type: number - totalDiscounts: - description: The total value of discounts given for cart items in sessions. - example: 10.0 - type: number - couponsCount: - description: The number of times a coupon was successfully redeemed in sessions. - example: 12.0 - type: number - type: object - ExperimentVariantResultConfidence: - properties: - avgSessionValue: - description: The calculated confidence value of the average customer session - value. - example: 100.0 - type: number - avgDiscountedSessionValue: - description: The calculated confidence value of the average customer discounted - session value. - example: 100.0 - type: number - avgItemsPerSession: - description: The calculated confidence value of the number of items from - sessions value. - example: 100.0 + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 type: number - required: - - avgDiscountedSessionValue - - avgItemsPerSession - - avgSessionValue - type: object - ExperimentResults: - properties: - variants: - items: - $ref: '#/components/schemas/ExperimentVariantResult' - type: array - confidence: - $ref: '#/components/schemas/ExperimentVariantResultConfidence' - required: - - confidence - - variants - type: object - ExperimentResult: - properties: - variants: - items: - $ref: '#/components/schemas/ExperimentVariantResult' - type: array - confidence: - $ref: '#/components/schemas/ExperimentVariantResultConfidence' - experimentId: - example: 1 - format: int64 - type: integer - required: - - confidence - - experimentId - - variants - type: object - ExperimentListResults: - properties: - results: - items: - $ref: '#/components/schemas/ExperimentResult' - type: array - type: object - UpdateExperiment: - properties: - isVariantAssignmentExternal: + reservationLimit: description: | - The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. - type: boolean - campaign: - $ref: '#/components/schemas/UpdateCampaign' - required: - - campaign - - isVariantAssignmentExternal - type: object - UpdateExperimentVariant: - properties: - id: - example: 10 + The number of reservations that can be made with this coupon code. + example: 45 format: int64 + maximum: 999999 + minimum: 0 type: integer - name: - description: The name of this variant. - example: Variant A - maxLength: 255 - minLength: 1 + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z + format: date-time type: string - ruleset: - $ref: '#/components/schemas/NewRuleset' - weight: - description: The percentage split of this variant. The sum of all variant - percentages must be 100. - example: 13 - format: int64 - maximum: 99 - minimum: 1 - type: integer - required: - - id - - name - - ruleset - - weight - type: object - UpdateExperimentVariantArray: - properties: - variants: - description: Array of experiment variants to update + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z + format: date-time + type: string + limits: + description: | + Limits configuration for a coupon. These limits will override the limits + set from the campaign. + + **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. + Only per-profile limits are allowed to be configured. items: - $ref: '#/components/schemas/UpdateExperimentVariant' + $ref: '#/components/schemas/LimitConfig' type: array - required: - - variants - type: object - NewExperimentVariant: - properties: - name: - description: The name of this variant. - example: Variant A - maxLength: 255 - minLength: 1 - type: string - weight: - description: The percentage split of this variant. The sum of all variant - percentages must be 100. - example: 13 + numberOfCoupons: + description: The number of new coupon codes to generate for the campaign. + Must be at least 1. + example: 1 format: int64 - maximum: 99 - minimum: 1 type: integer - ruleset: - $ref: '#/components/schemas/NewRuleset' - isPrimary: - example: true - type: boolean - required: - - isPrimary - - name - - ruleset - - weight - type: object - NewExperimentVariantArray: - properties: - variants: - description: Array of experiment variants to create - items: - $ref: '#/components/schemas/NewExperimentVariant' - type: array - required: - - variants - type: object - UpdateExperimentVariantName: - properties: - name: - description: The name of the variant. - example: Variant A - maxLength: 255 - minLength: 1 - type: string - required: - - name - type: object - ExperimentCampaignCopy: - properties: - name: - description: Name of the copied campaign (Defaults to "Copy of original - campaign name"). - example: Copy of Summer promotions - type: string - description: - description: A detailed description of the campaign. - example: Campaign for all summer 2021 promotions - title: Campaign Description + batchId: + description: The batch ID that all coupons created by the request will bear. + If omitted, a batch ID is generated automatically. + example: 3rdparty_fjsieoaa type: string - startTime: - description: Timestamp when the campaign will become active. - example: 2021-06-01T09:00:27.993483Z - format: date-time + uniquePrefix: + description: | + **DEPRECATED** To create more than 20,000 coupons in one request, use [Create coupons asynchronously](https://docs.talon.one/management-api#tag/Coupons/operation/createCouponsAsync) endpoint. + example: "" + title: Coupon code unique prefix type: string - endTime: - description: Timestamp when the campaign will become inactive. - example: 2021-09-10T01:00:00.993483Z - format: date-time + x-deprecated: true + attributes: + description: Arbitrary properties associated with this item. + example: + venueId: 12 + properties: {} + type: object + recipientIntegrationId: + description: The integration ID for this coupon's beneficiary's profile. + example: URNGV8294NV + maxLength: 1000 + title: Receiving customer profile integration ID type: string - tags: - description: A list of tags for the campaign. + validCharacters: + description: | + List of characters used to generate the random parts of a code. By default, + the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. example: - - Summer - - Shoes + - A + - B + - G + - "Y" items: - maxLength: 50 - minLength: 1 type: string - maxItems: 50 type: array - evaluationGroupId: - description: The ID of the campaign evaluation group the campaign belongs - to. - example: 2 - format: int64 - type: integer - type: object - ExperimentCopy: - properties: - targetApplicationId: + couponPattern: description: | - The ID of the Application to copy the experiment. It is displayed in your Talon.One deployment URL. + The pattern used to generate coupon codes. + The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + example: SUMMER-##### + maxLength: 100 + minLength: 3 + type: string + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + title: Is reservation mandatory + type: boolean + implicitlyReserved: + description: An indication of whether the coupon is implicitly reserved + for all customers. + example: false + title: Is coupon implicitly reserved for all customers + type: boolean + supportRequestId: + description: The identifier of the support request to link to the coupon + creation. The request must exist and not yet be processed. + example: 42 format: int64 type: integer - experiment: - $ref: '#/components/schemas/ExperimentCopy_experiment' + supportRequestNote: + description: A note recorded when the linked support request is approved + or rejected. Applied when `supportRequestId` is provided. + example: Approved as compensation for the delayed order. + type: string required: - - experiment - - targetApplicationId + - numberOfCoupons + - usageLimit type: object - PromoteExperiment: + NewCouponsForMultipleRecipients: + example: + expiryDate: 2023-08-24T14:15:22Z + couponPattern: SUMMER-##### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + usageLimit: 100 + reservationLimit: 45 + recipientsIntegrationIds: + - URNGV8294NV + - BZGGC2454PA + attributes: + venueId: 12 + batchId: 3rdparty_fjsieoaa + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z properties: - targetApplicationId: + usageLimit: description: | - The ID of the Application to copy the experiment. It is displayed in your Talon.One deployment URL. + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 format: int64 + maximum: 999999 + minimum: 0 type: integer - variantId: + discountLimit: description: | - The ID of the Experiment Variant to build the new campaign. + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 format: int64 + maximum: 999999 + minimum: 0 type: integer - disableExperiment: - description: | - Force disable the experiment. - type: boolean - campaign: - $ref: '#/components/schemas/ExperimentCampaignCopy' - required: - - campaign - - targetApplicationId - - variantId - type: object - ExperimentVerdict: - properties: - winnerVariantName: - description: The name of the winning variant. If no variant shows a statistically - significant advantage on key business metrics, return 'Inconclusive'. + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z + format: date-time type: string - verdictSummary: - description: A one-sentence summary of the outcome, including the key metric - and confidence level that led to the decision. + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z + format: date-time type: string - keyFindings: - description: A bullet point stating the most important finding, including - the metric, the percentage change, and the confidence. + batchId: + description: The batch ID that all coupons created by the request will bear. + If omitted, a batch ID is generated automatically. + example: 3rdparty_fjsieoaa + type: string + attributes: + description: Arbitrary properties associated with this item. + example: + venueId: 12 + properties: {} + type: object + recipientsIntegrationIds: + description: The integration IDs for recipients. + example: + - URNGV8294NV + - BZGGC2454PA items: type: string + maxItems: 1000 + minItems: 1 + title: Receiving customer profiles integration IDs type: array - aiConfidenceLevel: - description: Your confidence in this overall verdict, from 0 to 100. - type: string - recommendation: - description: A short, actionable recommendation based on the findings. If - inconclusive, suggest running the test longer. If there is a clear winner, - recommend promoting it. + validCharacters: + description: | + List of characters used to generate the random parts of a code. By default, the list of + characters is equivalent to the `[A-Z, 0-9]` regular expression. + example: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + items: + type: string + type: array + couponPattern: + description: | + The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + example: SUMMER-##### + maxLength: 100 + minLength: 3 type: string required: - - aiConfidenceLevel - - keyFindings - - recommendation - - verdictSummary - - winnerVariantName + - recipientsIntegrationIds + - usageLimit type: object - ExperimentVerdictResponse: + NewCouponCreationJob: + example: + expiryDate: 2023-08-24T14:15:22Z + usageLimit: 100 + reservationLimit: 45 + numberOfCoupons: 200000 + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + isReservationMandatory: false properties: - verdict: - $ref: '#/components/schemas/ExperimentVerdict' - generated: - description: Timestamp of the moment when the verdict was generated. + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z + format: date-time + type: string + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z format: date-time type: string + numberOfCoupons: + description: The number of new coupon codes to generate for the campaign. + example: 200000 + format: int64 + maximum: 5E+6 + minimum: 1 + type: integer + couponSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + attributes: + description: Arbitrary properties associated with coupons. + properties: {} + type: object + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + type: boolean required: - - generated - - verdict + - attributes + - numberOfCoupons + - usageLimit type: object - ExperimentSegmentInsightVariant: + AsyncCouponCreationResponse: + example: + batchId: tqyrgahe properties: - variantId: - description: The ID of the experiment variant. - example: 41 - format: int64 - type: integer - variantName: - description: The name of the experiment variant. - example: Control + batchId: + description: The batch ID that all coupons created by the request will have. + example: tqyrgahe type: string - sessionsCount: - description: The number of sessions in this segment for this variant. - example: 161 - format: int64 - type: integer - value: - description: The metric value for this variant in the segment. - example: 13.13 - format: double - type: number required: - - sessionsCount - - value - - variantId - - variantName + - batchId type: object - ExperimentSegmentInsight: + CouponDeletionFilters: + example: + startsAfter: 2000-01-23T04:56:07.000+00:00 + recipientIntegrationId: recipientIntegrationId + exactMatch: false + redeemed: true + referralId: 0 + createdAfter: 2000-01-23T04:56:07.000+00:00 + batchId: batchId + valid: expired + usable: true + expiresAfter: 2000-01-23T04:56:07.000+00:00 + expiresBefore: 2000-01-23T04:56:07.000+00:00 + createdBefore: 2000-01-23T04:56:07.000+00:00 + value: value + startsBefore: 2000-01-23T04:56:07.000+00:00 properties: - dimension: - description: The segmentation dimension used to group customers or purchases - for analysis. - enum: - - cart_value - - item_count - - customer_type - example: cart_value + createdBefore: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time type: string - bucket: - description: The specific group within the segmentation dimension. + createdAfter: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time + type: string + startsAfter: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time + type: string + startsBefore: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time + type: string + valid: + description: | + - `expired`: Matches coupons in which the expiration date is set and in the past. + - `validNow`: Matches coupons in which the start date is null or in the past and the expiration date is null or in the future. + - `validFuture`: Matches coupons in which the start date is set and in the future. enum: - - low - - medium - - high - - new - - returning - - loyal - example: high + - expired + - validNow + - validFuture type: string - confidence: + usable: description: | - The raw (unadjusted) confidence score expressed as a percentage. Only segments with a confidence score greater than or equal to 95% are returned. - example: 99.2 - format: double - maximum: 1E+2 - minimum: 95 - type: number - winnerVariantId: - description: The ID of the variant that performed better in this segment. - example: 42 + - `true`: only coupons where `usageCounter < usageLimit` will be returned. + - `false`: only coupons where `usageCounter >= usageLimit` will be returned. + - This field cannot be used in conjunction with the `usable` query parameter. + type: boolean + redeemed: + description: | + - `true`: only coupons where `usageCounter > 0` will be returned. + - `false`: only coupons where `usageCounter = 0` will be returned. + + **Note:** This field cannot be used in conjunction with the `usable` query parameter. + type: boolean + recipientIntegrationId: + description: | + Filter results by match with a profile id specified in the coupon's `RecipientIntegrationId` field. + type: string + exactMatch: + default: false + description: Filter results to an exact case-insensitive matching against + the coupon code + type: boolean + value: + description: Filter results by the coupon code + type: string + batchId: + description: Filter results by batches of coupons + type: string + referralId: + description: Filter the results by matching them with the ID of a referral. + This filter shows the coupons created by redeeming a referral code. format: int64 type: integer - variants: - description: Per-variant metric values for this segment. - items: - $ref: '#/components/schemas/ExperimentSegmentInsightVariant' - type: array + expiresAfter: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time + type: string + expiresBefore: + description: Filter results comparing the parameter value, expected to be + an RFC3339 timestamp string, to the coupon creation timestamp. You can + use any time zone setting. Talon.One will convert to UTC internally. + format: date-time + type: string + type: object + NewCouponDeletionJob: + example: + filters: + startsAfter: 2000-01-23T04:56:07.000+00:00 + recipientIntegrationId: recipientIntegrationId + exactMatch: false + redeemed: true + referralId: 0 + createdAfter: 2000-01-23T04:56:07.000+00:00 + batchId: batchId + valid: expired + usable: true + expiresAfter: 2000-01-23T04:56:07.000+00:00 + expiresBefore: 2000-01-23T04:56:07.000+00:00 + createdBefore: 2000-01-23T04:56:07.000+00:00 + value: value + startsBefore: 2000-01-23T04:56:07.000+00:00 + properties: + filters: + $ref: '#/components/schemas/CouponDeletionFilters' required: - - bucket - - confidence - - dimension - - variants - - winnerVariantId + - filters type: object - ExperimentSegmentInsightMetric: + AsyncCouponDeletionJobResponse: + example: + id: 6 properties: - metric: - description: The metric being measured. - enum: - - avg_session_value - - avg_discounted_session_value - - avg_items_per_session - example: avg_session_value - type: string - segments: - description: | - Segments with statistically significant results for this metric. An empty array means no significant segments were found. Segments are sorted by confidence score from highest to lowest. - items: - $ref: '#/components/schemas/ExperimentSegmentInsight' - type: array + id: + description: Unique ID for this entity. Not to be confused with the Integration + ID, which is set by your integration layer and used in most endpoints. + example: 6 + format: int64 + type: integer required: - - metric - - segments + - id type: object - ExperimentSegmentInsights: + NewAppWideCouponDeletionJob: properties: - metrics: - description: | - Segment insights grouped by metric. This array always contains exactly three metric objects. Each metric includes a segments array, which is empty if no significant results were found. The metrics array itself is empty if the `reason` property is populated. + filters: + $ref: '#/components/schemas/CouponDeletionFilters' + campaignids: items: - $ref: '#/components/schemas/ExperimentSegmentInsightMetric' + format: int64 + type: integer type: array - totalSegmentsTested: - description: | - Total number of segment-metric combinations that were tested for statistical significance. - example: 24 - format: int64 - type: integer - dimensionsTested: - description: | - Number of segmentation dimensions that had sufficient data variance to test. Dimensions where all sessions fall into a single bucket are excluded. - example: 3 - format: int64 - type: integer - reason: - description: | - Empty string when segment insights are available. Contains a reason code when insights could not be computed (e.g., "insufficient_data" when the experiment has fewer than 100 sessions per variant). - example: "" - type: string required: - - dimensionsTested - - metrics - - reason - - totalSegmentsTested + - campaignids + - filters type: object - CreateTemplateCampaign: + UpdateCoupon: example: - campaignAttributesOverrides: '{}' - linkedStoreIds: - - 1 - - 2 - - 3 - evaluationGroupId: 2 - name: Discount campaign - description: This template is for discount campaigns. - limitOverrides: + expiryDate: 2023-08-24T14:15:22Z + recipientIntegrationId: URNGV8294NV + implicitlyReserved: false + usageLimit: 100 + reservationLimit: 45 + attributes: '{}' + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + limits: - period: yearly entities: - Coupon @@ -33674,129 +37986,177 @@ components: - Coupon limit: 1000.0 action: createCoupon - templateParamValues: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - templateId: 4 - campaignGroups: - - 1 - - 3 - tags: - - summer + isReservationMandatory: false properties: - name: - description: A user-facing name for this campaign. - example: Discount campaign - minLength: 1 - title: Campaign Name - type: string - description: - description: A detailed description of the campaign. - example: This template is for discount campaigns. - title: Campaign Description - type: string - templateId: - description: The ID of the Campaign Template which will be used in order - to create the Campaign. - example: 4 + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 format: int64 + maximum: 999999 + minimum: 0 type: integer - campaignAttributesOverrides: - description: Custom Campaign Attributes. If the Campaign Template defines - the same values, they will be overridden. - properties: {} - type: object - templateParamValues: - description: Actual values to replace the template placeholder values in - the Ruleset bindings. Values for all Template Parameters must be provided. - items: - $ref: '#/components/schemas/Binding' - type: array - limitOverrides: - description: Limits for this Campaign. If the Campaign Template or Application - define default values for the same limits, they will be overridden. + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z + format: date-time + type: string + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z + format: date-time + type: string + limits: + description: | + Limits configuration for a coupon. These limits will override the limits + set from the campaign. + + **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. + Only per-profile limits are allowed to be configured. items: $ref: '#/components/schemas/LimitConfig' type: array - campaignGroups: - description: | - The IDs of the [campaign groups](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups) this campaign belongs to. - example: - - 1 - - 3 - items: - format: int64 - type: integer - type: array - tags: - description: A list of tags for the campaign. If the campaign template has - tags, they will be overridden by this list. - example: - - summer - items: - maxLength: 50 - minLength: 1 - type: string - maxItems: 50 - type: array - evaluationGroupId: - description: The ID of the campaign evaluation group the campaign belongs - to. - example: 2 + recipientIntegrationId: + description: The integration ID for this coupon's beneficiary's profile. + example: URNGV8294NV + maxLength: 1000 + title: Receiving customer profile integration ID + type: string + attributes: + description: Arbitrary properties associated with this item. + properties: {} + type: object + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + title: Is reservation mandatory + type: boolean + implicitlyReserved: + description: An indication of whether the coupon is implicitly reserved + for all customers. + example: false + title: Is coupon implicitly reserved for all customers + type: boolean + type: object + CouponSearch: + properties: + attributes: + description: Properties to match against a coupon. All provided attributes + will be exactly matched against attributes. + properties: {} + type: object + required: + - attributes + type: object + UpdateReferralBatch: + properties: + attributes: + description: Arbitrary properties associated with this item. + properties: {} + type: object + batchID: + description: The id of the batch the referral belongs to. + example: 32535-43255 + title: Batch ID + type: string + startDate: + description: Timestamp at which point the referral code becomes valid. + example: 2020-11-10T23:00:00Z + format: date-time + title: Referral code valid from + type: string + expiryDate: + description: Expiration date of the referral code. Referral never expires + if this is omitted. + example: 2021-11-10T23:00:00Z + format: date-time + title: Referral code valid until + type: string + usageLimit: + description: | + The number of times a referral code can be used. This can be set to 0 for no limit, but any campaign usage limits will still apply. + example: 1 format: int64 + maximum: 999999 + minimum: 0 + title: Referral code Usage Limit type: integer - linkedStoreIds: - description: | - A list of store IDs that are linked to the campaign. - - **Note:** Campaigns with linked store IDs will only be evaluated when there is a - [customer session update](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) - that references a linked store. - example: - - 1 - - 2 - - 3 - items: - format: int64 - type: integer - type: array required: - - name - - templateId + - batchID type: object - UpdateCollection: + UpdateReferral: example: - subscribedApplicationsIds: - - 1 - - 2 - - 3 - description: My collection of SKUs + expiryDate: 2021-11-10T23:00:00Z + friendProfileIntegrationId: BZGGC2454PA + usageLimit: 1 + attributes: '{}' + startDate: 2020-11-10T23:00:00Z + properties: + friendProfileIntegrationId: + description: An optional Integration ID of the Friend's Profile. + example: BZGGC2454PA + maxLength: 1000 + title: Friend's Profile ID + type: string + startDate: + description: Timestamp at which point the referral code becomes valid. + example: 2020-11-10T23:00:00Z + format: date-time + title: Referral code valid from + type: string + expiryDate: + description: Expiration date of the referral code. Referral never expires + if this is omitted. + example: 2021-11-10T23:00:00Z + format: date-time + title: Referral code valid until + type: string + usageLimit: + description: | + The number of times a referral code can be used. This can be set to 0 for no limit, but any campaign usage limits will still apply. + example: 1 + format: int64 + maximum: 999999 + minimum: 0 + title: Referral code Usage Limit + type: integer + attributes: + description: Arbitrary properties associated with this item. + properties: {} + type: object + type: object + NewCampaignGroup: properties: + name: + description: The name of the campaign access group. + example: Europe access group + minLength: 1 + type: string description: - description: A short description of the purpose of this collection. - example: My collection of SKUs + description: A longer description of the campaign access group. + example: A group that gives access to all the campaigns for the Europe market. type: string subscribedApplicationsIds: - description: A list of the IDs of the Applications where this collection - is enabled. + description: A list of IDs of the Applications that this campaign access + group is enabled for. example: - 1 - 2 @@ -33805,56 +38165,37 @@ components: format: int64 type: integer type: array - type: object - NewCollection: - example: - subscribedApplicationsIds: - - 1 - - 2 - - 3 - name: My collection - description: My collection of SKUs - properties: - description: - description: A short description of the purpose of this collection. - example: My collection of SKUs - type: string - subscribedApplicationsIds: - description: A list of the IDs of the Applications where this collection - is enabled. + campaignIds: + description: A list of IDs of the campaigns that are part of the campaign + access group. example: - - 1 - - 2 - - 3 + - 4 + - 6 + - 8 items: format: int64 type: integer type: array - name: - description: The name of this collection. - example: My collection - minLength: 1 - pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ - type: string required: - name type: object - CollectionWithoutPayload: + CampaignGroup: example: accountId: 3886 - createdBy: 134 created: 2020-06-10T09:05:27.993483Z - campaignId: 7 + name: Europe access group subscribedApplicationsIds: - 1 - 2 - 3 - name: My collection modified: 2021-09-12T10:12:42Z - description: My collection of SKUs - modifiedBy: 48 + description: A group that gives access to all the campaigns for the Europe + market. id: 6 - applicationId: 1 + campaignIds: + - 4 + - 6 + - 8 properties: id: description: The internal ID of this entity. @@ -33866,23 +38207,28 @@ components: example: 2020-06-10T09:05:27.993483Z format: date-time type: string + modified: + description: The time this entity was last modified. + example: 2021-09-12T10:12:42Z + format: date-time + type: string accountId: description: The ID of the account that owns this entity. example: 3886 format: int64 type: integer - modified: - description: The time this entity was last modified. - example: 2021-09-12T10:12:42Z - format: date-time + name: + description: The name of the campaign access group. + example: Europe access group + minLength: 1 type: string description: - description: A short description of the purpose of this collection. - example: My collection of SKUs + description: A longer description of the campaign access group. + example: A group that gives access to all the campaigns for the Europe market. type: string subscribedApplicationsIds: - description: A list of the IDs of the Applications where this collection - is enabled. + description: A list of IDs of the Applications that this campaign access + group is enabled for. example: - 1 - 2 @@ -33891,59 +38237,61 @@ components: format: int64 type: integer type: array - name: - description: The name of this collection. - example: My collection - minLength: 1 - pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ - type: string - modifiedBy: - description: ID of the user who last updated this effect if available. - example: 48 - format: int64 - type: integer - createdBy: - description: ID of the user who created this effect. - example: 134 - format: int64 - type: integer - applicationId: - description: The ID of the Application that owns this entity. - example: 1 - format: int64 - type: integer - campaignId: - description: The ID of the campaign that owns this entity. - example: 7 - format: int64 - type: integer + campaignIds: + description: A list of IDs of the campaigns that are part of the campaign + access group. + example: + - 4 + - 6 + - 8 + items: + format: int64 + type: integer + type: array required: - accountId - created - - createdBy - id - modified - name type: object - Collection: - example: - accountId: 3886 - createdBy: 134 - payload: - - KTL-WH-ET-1 - - KTL-BL-ET-1 - created: 2020-06-10T09:05:27.993483Z - campaignId: 7 + UpdateCampaignGroup: + properties: + name: + description: The name of the campaign access group. + example: Europe access group + minLength: 1 + type: string + description: + description: A longer description of the campaign access group. + example: A group that gives access to all the campaigns for the Europe market. + type: string subscribedApplicationsIds: - - 1 - - 2 - - 3 - name: My collection - modified: 2021-09-12T10:12:42Z - description: My collection of SKUs - modifiedBy: 48 - id: 6 - applicationId: 1 + description: A list of IDs of the Applications that this campaign access + group is enabled for. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + campaignIds: + description: A list of IDs of the campaigns that are part of the campaign + access group. + example: + - 4 + - 6 + - 8 + items: + format: int64 + type: integer + type: array + required: + - name + type: object + Role: properties: id: description: The internal ID of this entity. @@ -33955,1050 +38303,925 @@ components: example: 2020-06-10T09:05:27.993483Z format: date-time type: string + modified: + description: The time this entity was last modified. + example: 2021-09-12T10:12:42Z + format: date-time + type: string accountId: description: The ID of the account that owns this entity. example: 3886 format: int64 type: integer - modified: - description: The time this entity was last modified. - example: 2021-09-12T10:12:42Z - format: date-time + campaignGroupID: + description: | + The ID of the [Campaign Group](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups) + this role was created for. + example: 3 + format: int64 + type: integer + name: + description: Name of the role. + example: Campaign Reviewer type: string description: - description: A short description of the purpose of this collection. - example: My collection of SKUs + description: Description of the role. + example: Reviews the campaigns type: string - subscribedApplicationsIds: - description: A list of the IDs of the Applications where this collection - is enabled. + members: + description: A list of user identifiers assigned to this role. example: - - 1 - - 2 - - 3 + - 48 + - 562 + - 475 + - 18 items: format: int64 type: integer type: array - name: - description: The name of this collection. - example: My collection - minLength: 1 - pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ - type: string - modifiedBy: - description: ID of the user who last updated this effect if available. - example: 48 - format: int64 - type: integer - createdBy: - description: ID of the user who created this effect. - example: 134 - format: int64 - type: integer - applicationId: - description: The ID of the Application that owns this entity. - example: 1 - format: int64 - type: integer - campaignId: - description: The ID of the campaign that owns this entity. - example: 7 + acl: + description: The `Access Control List` json defining the role of the user. + This represents the access control on the user level. + example: + Role: 127 + properties: {} + type: object + required: + - accountId + - acl + - created + - id + - modified + - name + type: object + CampaignTemplateCouponReservationSettings: + example: + reservationLimit: 45 + isReservationMandatory: false + properties: + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 format: int64 + maximum: 999999 + minimum: 0 type: integer - payload: - description: The content of the collection. + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + title: Is reservation mandatory + type: boolean + type: object + TemplateLimitConfig: + example: + period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + properties: + action: + description: | + The limitable action to which this limit applies. For example: + - `setDiscount` + - `setDiscountEffect` + - `redeemCoupon` + - `createCoupon` + example: createCoupon + type: string + limit: + description: The value to set for the limit. + example: 1000.0 + minimum: 0 + type: number + period: + description: The period on which the budget limit recurs. + enum: + - daily + - weekly + - monthly + - yearly + example: yearly + type: string + entities: + description: The entity that this limit applies to. example: - - KTL-WH-ET-1 - - KTL-BL-ET-1 + - Coupon items: + enum: + - Coupon + - Referral + - Profile + - Identifier + - Store + - Session type: string - maxItems: 50 type: array required: - - accountId - - created - - createdBy - - id - - modified + - action + - entities + - limit + type: object + CampaignTemplateParams: + example: + attributeId: 42 + name: discount_value + description: This is a template parameter of type `number`. + type: number + properties: + name: + description: Name of the campaign template parameter. + example: discount_value + minLength: 1 + type: string + type: + description: Defines the type of parameter value. + enum: + - string + - number + - boolean + - percent + - (list string) + - (list number) + - time + example: number + type: string + description: + description: Explains the meaning of this template parameter and the placeholder + value that will define it. It is used on campaign creation from this template. + example: This is a template parameter of type `number`. + type: string + attributeId: + description: ID of the corresponding attribute. + example: 42 + format: int64 + type: integer + required: + - description - name + - type type: object - CreateTemplateCampaignResponse: + CampaignTemplateCollection: example: - collections: - - accountId: 3886 - createdBy: 134 - payload: - - KTL-WH-ET-1 - - KTL-BL-ET-1 - created: 2020-06-10T09:05:27.993483Z - campaignId: 7 - subscribedApplicationsIds: - - 1 - - 2 - - 3 - name: My collection - modified: 2021-09-12T10:12:42Z - description: My collection of SKUs - modifiedBy: 48 - id: 6 - applicationId: 1 - - accountId: 3886 - createdBy: 134 - payload: - - KTL-WH-ET-1 - - KTL-BL-ET-1 - created: 2020-06-10T09:05:27.993483Z - campaignId: 7 - subscribedApplicationsIds: - - 1 - - 2 - - 3 - name: My collection - modified: 2021-09-12T10:12:42Z - description: My collection of SKUs - modifiedBy: 48 - id: 6 - applicationId: 1 - ruleset: - rbVersion: v2 - created: 2020-06-10T09:05:27.993483Z - campaignId: 320 - bindings: [] - activatedAt: 2000-01-23T04:56:07.000+00:00 - activate: true - rules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - id: 6 - strikethroughRules: - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - - condition: - - and - - - couponValid - effects: - - catch - - - noop - - - setDiscount - - 10% off - - - '*' - - - "." - - Session - - Total - - - / - - 10 - - 100 - bindings: - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - - attributeId: 100 - minValue: 0.0 - expression: - - string1 - - string2 - maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. - type: templateParameter - description: Creates a discount when a coupon is valid - id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - title: Give discount via coupon - parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 - templateId: 3 - userId: 388 - campaign: - type: advanced - templateId: 3 - customEffectCount: 0 - activeRevisionId: 6 - features: - - coupons - - referrals - createdLoyaltyPointsCount: 9.0 - storesImported: true - couponSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - experimentId: 1 - id: 4 - state: enabled - couponAttributes: '{}' - reservecouponEffectCount: 9 - updatedBy: Jane Doe - frontendState: running - created: 2020-06-10T09:05:27.993483Z - referralCreationCount: 8 - stageRevision: false - couponRedemptionCount: 163 - couponCreationCount: 16 - version: 6 - campaignGroups: - - 1 - - 3 - tags: - - summer - discountEffectCount: 343 - budgets: - - limit: 1000.0 - action: createCoupon - counter: 42.0 - - limit: 1000.0 - action: createCoupon - counter: 42.0 - redeemedLoyaltyPointsCount: 8.0 - name: Summer promotions - valueMapsIds: - - 100 - - 215 - applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 - callApiEffectCount: 0 - createdLoyaltyPointsEffectCount: 2 - discountCount: 288.0 - revisionFrontendState: revised - description: Campaign for all summer 2021 promotions - activeRevisionVersionId: 6 - currentRevisionVersionId: 6 - startTime: 2021-07-20T22:00:00Z - currentRevisionId: 6 - limits: - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - - period: yearly - entities: - - Coupon - limit: 1000.0 - action: createCoupon - activeRulesetId: 6 - reevaluateOnReturn: true - userId: 388 - awardedGiveawaysCount: 9 - redeemedLoyaltyPointsEffectCount: 9 - linkedStoreIds: - - 1 - - 2 - - 3 - createdBy: John Doe - addFreeItemEffectCount: 0 - referralSettings: - couponPattern: SUMMER-####-#### - validCharacters: - - A - - B - - C - - D - - E - - F - - G - - H - - I - - J - - K - - L - - M - - "N" - - O - - P - - Q - - R - - S - - T - - U - - V - - W - - X - - "Y" - - Z - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - attributes: '{}' - lastActivity: 2022-11-10T23:00:00Z - endTime: 2021-09-22T22:00:00Z - referralRedemptionCount: 3 + name: My collection + description: My collection of SKUs properties: - campaign: - $ref: '#/components/schemas/Campaign' - ruleset: - $ref: '#/components/schemas/Ruleset' - collections: - items: - $ref: '#/components/schemas/Collection' - type: array + name: + description: The name of this collection. + example: My collection + minLength: 1 + pattern: ^[A-Za-z](\w|\s)*$ + type: string + description: + description: A short description of the purpose of this collection. + example: My collection of SKUs + type: string required: - - campaign - - ruleset + - name type: object - NewLoyaltyProgram: - description: A new loyalty program + UpdateCampaignTemplate: properties: - title: - description: The display title for the Loyalty Program. - example: Point collection + name: + description: The campaign template name. + example: Discount campaign + minLength: 1 type: string description: - description: Description of our Loyalty Program. - example: Customers collect 10 points per 1$ spent + description: Customer-facing text that explains the objective of the template. + example: This is a template for a discount campaign. type: string - subscribedApplications: - description: A list containing the IDs of all applications that are subscribed - to this Loyalty Program. + instructions: + description: Customer-facing text that explains how to use the template. + For example, you can use this property to explain the available attributes + of this template, and how they can be modified when a user uses this template + to create a new campaign. + example: Use this template for discount campaigns. Set the campaign properties + according to the campaign goals, and don't forget to set an end date. + type: string + campaignAttributes: + description: The campaign attributes that campaigns created from this template + will have by default. + properties: {} + type: object + couponAttributes: + description: The campaign attributes that coupons created from this template + will have by default. + properties: {} + type: object + state: + description: Only campaign templates in 'available' state may be used to + create campaigns. + enum: + - draft + - enabled + - disabled + type: string + activeRulesetId: + description: The ID of the ruleset this campaign template will use. + example: 5 + format: int64 + type: integer + tags: + description: A list of tags for the campaign template. example: - - 132 - - 97 + - discount + items: + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 + type: array + reevaluateOnReturn: + description: Indicates whether campaigns created from this template should + be reevaluated when a customer returns an item. + example: true + type: boolean + features: + description: A list of features for the campaign template. + items: + enum: + - coupons + - referrals + - loyalty + - giveaways + - strikethrough + - achievements + - advancedEvents + type: string + type: array + couponSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + couponReservationSettings: + $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' + referralSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + limits: + description: The set of limits that operate for this campaign template. + items: + $ref: '#/components/schemas/TemplateLimitConfig' + type: array + templateParams: + description: Fields which can be used to replace values in a rule. + items: + $ref: '#/components/schemas/CampaignTemplateParams' + type: array + applicationsIds: + description: A list of IDs of the Applications that are subscribed to this + campaign template. + example: + - 1 + - 2 + - 3 items: format: int64 type: integer type: array - defaultValidity: - description: | - The default duration after which new loyalty points should expire. Can be 'unlimited' or a specific time. - The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: - - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. - - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. - example: 2W_U - type: string - defaultPending: - description: | - The default duration of the pending time after which points should be valid. Accepted values: 'immediate', 'on_action' or a specific time. - The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: - - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. - - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. - example: immediate - type: string - allowSubledger: - description: Indicates if this program supports subledgers inside the program. - example: false - type: boolean - usersPerCardLimit: - description: | - The max amount of user profiles with whom a card can be shared. This can be set to 0 for no limit. - This property is only used when `cardBased` is `true`. - example: 111 + campaignCollections: + description: The campaign collections from the blueprint campaign for the + template. + items: + $ref: '#/components/schemas/CampaignTemplateCollection' + type: array + defaultCampaignGroupId: + description: The default campaign group ID. + example: 42 format: int64 - minimum: 0 type: integer - sandbox: - description: Indicates if this program is a live or sandbox program. Programs - of a given type can only be connected to Applications of the same type. - example: true - title: Sandbox - type: boolean - programJoinPolicy: + campaignType: + default: advanced description: | - The policy that defines when the customer joins the loyalty program. - - `not_join`: The customer does not join the loyalty program but can still earn and spend loyalty points. - - **Note**: The customer does not have a program join date. - - `points_activated`: The customer joins the loyalty program only when their earned loyalty points become active for the first time. - - `points_earned`: The customer joins the loyalty program when they earn loyalty points for the first time. + The campaign type. Possible type values: + - `cartItem`: Type of campaign that can apply effects only to cart items. + - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. enum: - - not_join - - points_activated - - points_earned + - cartItem + - advanced + example: advanced type: string - tiersExpirationPolicy: - description: | - The policy that defines how tier expiration, used to reevaluate the customer's current tier, is determined. - - `tier_start_date`: The tier expiration is relative to when the customer joined the current tier. - - `program_join_date`: The tier expiration is relative to when the customer joined the loyalty program. - - `customer_attribute`: The tier expiration is determined by a custom customer attribute. - - `absolute_expiration`: The tier is reevaluated at the start of each tier cycle. For this policy, it is required to provide a `tierCycleStartDate`. - enum: - - tier_start_date - - program_join_date - - customer_attribute - - absolute_expiration - type: string - tierCycleStartDate: - description: | - Timestamp at which the tier cycle starts for all customers in the loyalty program. - - **Note**: This is only required when the tier expiration policy is set to `absolute_expiration`. - example: 2021-09-12T10:12:42Z + required: + - applicationsIds + - description + - instructions + - name + - state + type: object + CampaignTemplate: + example: + instructions: Use this template for discount campaigns. Set the campaign properties + according to the campaign goals, and don't forget to set an end date. + campaignCollections: + - name: My collection + description: My collection of SKUs + - name: My collection + description: My collection of SKUs + campaignsCount: 3 + defaultCampaignGroupId: 42 + description: This is a template for a discount campaign. + features: + - coupons + - coupons + couponReservationSettings: + reservationLimit: 45 + isReservationMandatory: false + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + templateParams: + - attributeId: 42 + name: discount_value + description: This is a template parameter of type `number`. + type: number + - attributeId: 42 + name: discount_value + description: This is a template parameter of type `number`. + type: number + id: 6 + couponAttributes: '{}' + state: draft + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 5 + campaignAttributes: '{}' + applicationsIds: + - 1 + - 2 + - 3 + - 1 + - 2 + - 3 + campaignType: advanced + updatedBy: Jane Doe + created: 2020-06-10T09:05:27.993483Z + isUserFavorite: false + reevaluateOnReturn: true + userId: 388 + tags: + - discount + accountId: 3886 + validApplicationIds: + - 1 + - 2 + - 3 + name: Discount campaign + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + updated: 2022-08-24T14:15:22Z + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z format: date-time type: string - tiersExpireIn: - description: | - The amount of time after which the tier expires and is reevaluated. - - The time format is an **integer** followed by one letter indicating the time unit. - Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. - - Available units: - - - `s`: seconds - - `m`: minutes - - `h`: hours - - `D`: days - - `W`: weeks - - `M`: months - - `Y`: years - - You can round certain units up or down: - - `_D` for rounding down days only. Signifies the start of the day. - - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. - example: 27W_U + accountId: + description: The ID of the account that owns this entity. + example: 3886 + format: int64 + type: integer + userId: + description: The ID of the user associated with this entity. + example: 388 + format: int64 + type: integer + name: + description: The campaign template name. + example: Discount campaign + minLength: 1 type: string - tiersDowngradePolicy: - description: | - The policy that defines how customer tiers are downgraded in the loyalty program after tier reevaluation. - - `one_down`: If the customer doesn't have enough points to stay in the current tier, they are downgraded by one tier. - - `balance_based`: The customer's tier is reevaluated based on the amount of active points they have at the moment. - enum: - - one_down - - balance_based + description: + description: Customer-facing text that explains the objective of the template. + example: This is a template for a discount campaign. type: string - cardCodeSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - returnPolicy: - description: | - The policy that defines the rollback of points in case of a partially returned, cancelled, or reopened [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). - - `only_pending`: Only pending points can be rolled back. - - `within_balance`: Available active points can be rolled back if there aren't enough pending points. The active balance of the customer cannot be negative. - - `unlimited`: Allows negative balance without any limit. - enum: - - only_pending - - within_balance - - unlimited + instructions: + description: Customer-facing text that explains how to use the template. + For example, you can use this property to explain the available attributes + of this template, and how they can be modified when a user uses this template + to create a new campaign. + example: Use this template for discount campaigns. Set the campaign properties + according to the campaign goals, and don't forget to set an end date. type: string - name: - description: The internal name for the Loyalty Program. This is an immutable - value. - example: GeneralPointCollection + campaignAttributes: + description: The campaign attributes that campaigns created from this template + will have by default. + properties: {} + type: object + couponAttributes: + description: The campaign attributes that coupons created from this template + will have by default. + properties: {} + type: object + state: + description: Only campaign templates in 'available' state may be used to + create campaigns. + enum: + - draft + - enabled + - disabled type: string - tiers: - description: The tiers in this loyalty program. + activeRulesetId: + description: The ID of the ruleset this campaign template will use. + example: 5 + format: int64 + type: integer + tags: + description: A list of tags for the campaign template. + example: + - discount items: - $ref: '#/components/schemas/NewLoyaltyTier' + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 type: array - timezone: - description: A string containing an IANA timezone descriptor. - minLength: 1 - type: string - cardBased: - default: false - description: | - Defines the type of loyalty program: - - `true`: the program is a card-based. - - `false`: the program is profile-based. + reevaluateOnReturn: + description: Indicates whether campaigns created from this template should + be reevaluated when a customer returns an item. example: true type: boolean - required: - - allowSubledger - - cardBased - - defaultPending - - defaultValidity - - name - - sandbox - - timezone - - title - type: object - UpdateLoyaltyProgram: - description: An updated loyalty program. - properties: - title: - description: The display title for the Loyalty Program. - example: Point collection - type: string - description: - description: Description of our Loyalty Program. - example: Customers collect 10 points per 1$ spent - type: string - subscribedApplications: - description: A list containing the IDs of all applications that are subscribed - to this Loyalty Program. + features: + description: A list of features for the campaign template. + items: + enum: + - coupons + - referrals + - loyalty + - giveaways + - strikethrough + - achievements + - advancedEvents + type: string + type: array + couponSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + couponReservationSettings: + $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' + referralSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + limits: + description: The set of limits that operate for this campaign template. + items: + $ref: '#/components/schemas/TemplateLimitConfig' + type: array + templateParams: + description: Fields which can be used to replace values in a rule. + items: + $ref: '#/components/schemas/CampaignTemplateParams' + type: array + applicationsIds: + description: A list of IDs of the Applications that are subscribed to this + campaign template. example: - - 132 - - 97 + - 1 + - 2 + - 3 + - 1 + - 2 + - 3 items: format: int64 type: integer type: array - defaultValidity: - description: | - The default duration after which new loyalty points should expire. Can be 'unlimited' or a specific time. - The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: - - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. - - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. - example: 2W_U - type: string - defaultPending: - description: | - The default duration of the pending time after which points should be valid. Accepted values: 'immediate', 'on_action' or a specific time. - The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: - - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. - - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. - example: immediate - type: string - allowSubledger: - description: Indicates if this program supports subledgers inside the program. - example: false - type: boolean - usersPerCardLimit: - description: | - The max amount of user profiles with whom a card can be shared. This can be set to 0 for no limit. - This property is only used when `cardBased` is `true`. - example: 111 + campaignCollections: + description: The campaign collections from the blueprint campaign for the + template. + items: + $ref: '#/components/schemas/CampaignTemplateCollection' + type: array + defaultCampaignGroupId: + description: The default campaign group ID. + example: 42 format: int64 - minimum: 0 type: integer - sandbox: - description: Indicates if this program is a live or sandbox program. Programs - of a given type can only be connected to Applications of the same type. - example: true - title: Sandbox - type: boolean - programJoinPolicy: - description: | - The policy that defines when the customer joins the loyalty program. - - `not_join`: The customer does not join the loyalty program but can still earn and spend loyalty points. - - **Note**: The customer does not have a program join date. - - `points_activated`: The customer joins the loyalty program only when their earned loyalty points become active for the first time. - - `points_earned`: The customer joins the loyalty program when they earn loyalty points for the first time. - enum: - - not_join - - points_activated - - points_earned - type: string - tiersExpirationPolicy: + campaignType: + default: advanced description: | - The policy that defines how tier expiration, used to reevaluate the customer's current tier, is determined. - - `tier_start_date`: The tier expiration is relative to when the customer joined the current tier. - - `program_join_date`: The tier expiration is relative to when the customer joined the loyalty program. - - `customer_attribute`: The tier expiration is determined by a custom customer attribute. - - `absolute_expiration`: The tier is reevaluated at the start of each tier cycle. For this policy, it is required to provide a `tierCycleStartDate`. + The campaign type. Possible type values: + - `cartItem`: Type of campaign that can apply effects only to cart items. + - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. enum: - - tier_start_date - - program_join_date - - customer_attribute - - absolute_expiration + - cartItem + - advanced + example: advanced type: string - tierCycleStartDate: - description: | - Timestamp at which the tier cycle starts for all customers in the loyalty program. - - **Note**: This is only required when the tier expiration policy is set to `absolute_expiration`. - example: 2021-09-12T10:12:42Z + campaignsCount: + description: The number of Campaigns created from this template. + example: 3 + format: int64 + type: integer + updated: + description: Timestamp of the most recent update to the campaign template + or any of its elements. + example: 2022-08-24T14:15:22Z format: date-time type: string - tiersExpireIn: - description: | - The amount of time after which the tier expires and is reevaluated. - - The time format is an **integer** followed by one letter indicating the time unit. - Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. - - Available units: - - - `s`: seconds - - `m`: minutes - - `h`: hours - - `D`: days - - `W`: weeks - - `M`: months - - `Y`: years - - You can round certain units up or down: - - `_D` for rounding down days only. Signifies the start of the day. - - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. - example: 27W_U - type: string - tiersDowngradePolicy: - description: | - The policy that defines how customer tiers are downgraded in the loyalty program after tier reevaluation. - - `one_down`: If the customer doesn't have enough points to stay in the current tier, they are downgraded by one tier. - - `balance_based`: The customer's tier is reevaluated based on the amount of active points they have at the moment. - enum: - - one_down - - balance_based - type: string - cardCodeSettings: - $ref: '#/components/schemas/CodeGeneratorSettings' - returnPolicy: - description: | - The policy that defines the rollback of points in case of a partially returned, cancelled, or reopened [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). - - `only_pending`: Only pending points can be rolled back. - - `within_balance`: Available active points can be rolled back if there aren't enough pending points. The active balance of the customer cannot be negative. - - `unlimited`: Allows negative balance without any limit. - enum: - - only_pending - - within_balance - - unlimited + updatedBy: + description: Name of the user who last updated this campaign template, if + available. + example: Jane Doe type: string - tiers: - description: The tiers in this loyalty program. - items: - $ref: '#/components/schemas/NewLoyaltyTier' - type: array - type: object - ActivateLoyaltyPoints: - description: Activate loyalty points - example: - transactionUUIDs: - - 8f1a8d7c-9c3e-4a5e-9f0d-2c5f7a3b1cde - sessionId: ac08cc3c43470426591ad75b2d685ec04_v2 - properties: - transactionUUIDs: - description: | - An array of transaction UUIDs used to activate specific pending point transactions. - - If provided, do not include the `sessionId` parameter. + validApplicationIds: + description: The IDs of the Applications that are related to this entity. example: - - 8f1a8d7c-9c3e-4a5e-9f0d-2c5f7a3b1cde + - 1 + - 2 + - 3 items: - format: uuid - type: string - maxItems: 50 - minItems: 1 + format: int64 + type: integer type: array - uniqueItems: true - sessionId: - description: | - The ID of the session containing the pending point transactions to activate. - - If provided, do not include the `transactionUUIDs` parameter. - example: ac08cc3c43470426591ad75b2d685ec04_v2 - minLength: 1 - type: string - type: object - LoyaltyLedgerEntry: - description: A single row of the ledger, describing one addition or deduction. - example: - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - properties: - created: - example: 2021-07-20T22:00:00Z - format: date-time - type: string - programID: - example: 5 - format: int64 - type: integer - customerProfileID: - example: URNGV8294NV - type: string - cardID: - example: 241 - format: int64 - type: integer - customerSessionID: - example: t2gy5s-47274 - type: string - eventID: - example: 5 - format: int64 - type: integer - type: - description: | - The type of the ledger transaction. Possible values are: - - `addition` - - `subtraction` - - `expire` - - `expiring` (for expiring points ledgers) - example: addition - type: string - amount: - example: 100.0 - type: number - startDate: - example: 2021-07-20T22:00:00Z - format: date-time - type: string - expiryDate: - example: 2022-07-20T22:00:00Z - format: date-time - type: string - name: - description: A name referencing the condition or effect that added this - entry, or the specific name provided in an API call. - example: Add points on purchase - type: string - subLedgerID: - description: This specifies if we are adding loyalty points to the main - ledger or a subledger. - example: mysubledger - type: string - userID: - description: This is the ID of the user who created this entry, if the addition - or subtraction was done manually. - example: 499 - format: int64 - type: integer - archived: - description: Indicates if the entry belongs to the archived session. + isUserFavorite: + default: false + description: A flag indicating whether the user marked the template as a + favorite. example: false type: boolean - flags: - $ref: '#/components/schemas/LoyaltyLedgerEntryFlags' - validityDuration: - description: | - The duration for which the points remain active, relative to the activation date. - - **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. - example: 30D - type: string required: - - amount + - accountId + - applicationsIds + - campaignType - created + - description + - id + - instructions - name - - programID - - subLedgerID - - type + - reevaluateOnReturn + - state + - userId + - validApplicationIds type: object - ActivateLoyaltyPointsResponse: - example: - ledgerEntries: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z + NewCampaignTemplate: properties: - ledgerEntries: - description: Updated ledger entries after activation. + name: + description: The campaign template name. + minLength: 1 + type: string + description: + description: Customer-facing text that explains the objective of the template. + type: string + instructions: + description: Customer-facing text that explains how to use the template. + For example, you can use this property to explain the available attributes + of this template, and how they can be modified when a user uses this template + to create a new campaign. + type: string + campaignAttributes: + description: The campaign attributes that campaigns created from this template + will have by default. + properties: {} + type: object + couponAttributes: + description: The campaign attributes that coupons created from this template + will have by default. + properties: {} + type: object + state: + description: Only Campaign Templates in 'available' state may be used to + create Campaigns. + enum: + - draft + - enabled + - disabled + type: string + tags: + description: A list of tags for the campaign template. items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 type: array - type: object - UpdateLoyaltyProgramTier: - description: Update a tier in a specified loyalty program. - properties: - id: - description: The internal ID of the tier. - example: 6 + reevaluateOnReturn: + description: Indicates whether campaigns created from this template should + be reevaluated when a customer returns an item. + example: true + type: boolean + features: + description: A list of features for the campaign template. + items: + enum: + - coupons + - referrals + - loyalty + - giveaways + - strikethrough + - achievements + - advancedEvents + type: string + type: array + couponSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + couponReservationSettings: + $ref: '#/components/schemas/CampaignTemplateCouponReservationSettings' + referralSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + limits: + description: The set of limits that will operate for this campaign template. + items: + $ref: '#/components/schemas/TemplateLimitConfig' + type: array + templateParams: + description: Fields which can be used to replace values in a rule. + items: + $ref: '#/components/schemas/CampaignTemplateParams' + type: array + campaignCollections: + description: The campaign collections from the blueprint campaign for the + template. + items: + $ref: '#/components/schemas/CampaignTemplateCollection' + type: array + defaultCampaignGroupId: + description: The default campaign group ID. + example: 42 format: int64 type: integer - name: - description: The name of the tier. - example: Gold - type: string - minPoints: - description: The minimum amount of points required to enter the tier. - example: 300.0 - maximum: 999999999999.99 - minimum: 0 - type: number - required: - - id - type: object - UpdateLoyaltyProgramTiers: - description: List of tiers that are updated by the request. - items: - $ref: '#/components/schemas/UpdateLoyaltyProgramTier' - type: array - LoyaltyTiers: - description: A list of the loyalty program's tiers. - items: - $ref: '#/components/schemas/LoyaltyTier' - type: array - LoyaltyDashboardPointsBreakdown: - example: - createdManually: 125.0 - createdViaRuleEngine: 9631.0 - properties: - createdManually: - example: 125.0 - type: number - createdViaRuleEngine: - example: 9631.0 - type: number - required: - - createdManually - - createdViaRuleEngine - type: object - LoyaltyDashboardData: - description: Datapoint for the graphs and cards on a loyalty program dashboard. - example: - date: 2000-01-23T04:56:07.000+00:00 - totalMembers: 2582.0 - totalSpentPoints: 25668.0 - spentPoints: - createdManually: 125.0 - createdViaRuleEngine: 9631.0 - totalActivePoints: 9756.0 - totalPendingPoints: 548.0 - totalExpiredPoints: 1156.0 - totalNegativePoints: 32.0 - newMembers: 3.0 - earnedPoints: - createdManually: 125.0 - createdViaRuleEngine: 9631.0 - properties: - date: - description: Date at which data point was collected. - format: date-time + campaignType: + default: advanced + description: | + The campaign type. Possible type values: + - `cartItem`: Type of campaign that can apply effects only to cart items. + - `advanced`: Type of campaign that can apply effects to customer sessions and cart items. + enum: + - cartItem + - advanced + example: advanced type: string - totalActivePoints: - description: Total of active points for this loyalty program. - example: 9756.0 - type: number - totalPendingPoints: - description: Total of pending points for this loyalty program. - example: 548.0 - type: number - totalSpentPoints: - description: Total of spent points for this loyalty program. - example: 25668.0 - type: number - totalExpiredPoints: - description: Total of expired points for this loyalty program. - example: 1156.0 - type: number - totalNegativePoints: - description: Total of negative points for this loyalty program. - example: 32.0 - type: number - totalMembers: - description: Number of loyalty program members. - example: 2582.0 - type: number - newMembers: - description: Number of members who joined on this day. - example: 3.0 - type: number - spentPoints: - $ref: '#/components/schemas/LoyaltyDashboardPointsBreakdown' - earnedPoints: - $ref: '#/components/schemas/LoyaltyDashboardPointsBreakdown' required: - - date - - earnedPoints - - newMembers - - spentPoints - - totalActivePoints - - totalExpiredPoints - - totalMembers - - totalNegativePoints - - totalPendingPoints - - totalSpentPoints + - campaignType + - description + - instructions + - name + - state type: object - Import: + ExperimentVariant: example: - accountId: 3886 - amount: 10 created: 2020-06-10T09:05:27.993483Z + isPrimary: true + name: Variant A + ruleset: + rbVersion: v2 + created: 2020-06-10T09:05:27.993483Z + campaignId: 320 + bindings: [] + activatedAt: 2000-01-23T04:56:07.000+00:00 + activate: true + rules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + id: 6 + strikethroughRules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + templateId: 3 + userId: 388 + weight: 12 + experimentId: 10 id: 6 - userId: 388 - entity: AttributeAllowedList properties: id: description: The internal ID of this entity. @@ -35010,514 +39233,3018 @@ components: example: 2020-06-10T09:05:27.993483Z format: date-time type: string - accountId: - description: The ID of the account that owns this entity. - example: 3886 - format: int64 - type: integer - userId: - description: The ID of the user associated with this entity. - example: 388 - format: int64 - type: integer - entity: - description: | - The name of the entity that was imported. - example: AttributeAllowedList + name: + example: Variant A type: string - amount: - description: The number of values that were imported. + experimentId: example: 10 format: int64 - minimum: 0 type: integer + ruleset: + $ref: '#/components/schemas/Ruleset' + weight: + example: 12 + format: int64 + type: integer + isPrimary: + example: true + type: boolean required: - - accountId - - amount - created - - entity - id - - userId - type: object - LoyaltySubLedger: - description: Ledger of Balance in Loyalty Program for a Customer. - example: - total: 0.8008281904610115 - totalSpentPoints: 5.962133916683182 - activePoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - expiringPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - totalActivePoints: 6.027456183070403 - totalPendingPoints: 1.4658129805029452 - totalExpiredPoints: 5.637376656633329 - totalNegativePoints: 2.3021358869347655 - transactions: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - expiredPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - currentTier: - expiryDate: 2000-01-23T04:56:07.000+00:00 - downgradePolicy: one_down - name: bronze - id: 11 - startDate: 2000-01-23T04:56:07.000+00:00 - pendingPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - properties: - total: - description: | - **DEPRECATED** Use `totalActivePoints` property instead. Total amount of currently active and available points in the customer's balance. - title: Current Balance (Deprecated) - type: number - totalActivePoints: - description: Total amount of currently active and available points in the - customer's balance. - title: Current Balance - type: number - totalPendingPoints: - description: Total amount of pending points, which are not active yet but - will become active in the future. - title: Total pending points - type: number - totalSpentPoints: - description: Total amount of points already spent by this customer. - title: Total spent points - type: number - totalExpiredPoints: - description: Total amount of points, that expired without ever being spent. - title: Total expired points - type: number - totalNegativePoints: - description: Total amount of negative points. This implies that `totalActivePoints` - is `0`. - title: Total negative points - type: number - transactions: - description: List of all events that have happened such as additions, subtractions - and expiries. - items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' - type: array - expiringPoints: - description: List of all points that will expire. - items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' - type: array - activePoints: - description: List of all currently active points. - items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' - type: array - pendingPoints: - description: List of all points pending activation. - items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' - type: array - expiredPoints: - description: List of expired points. - items: - $ref: '#/components/schemas/LoyaltyLedgerEntry' - type: array - currentTier: - $ref: '#/components/schemas/Tier' - required: - - total - - totalActivePoints - - totalExpiredPoints - - totalNegativePoints - - totalPendingPoints - - totalSpentPoints - type: object - LoyaltyLedger: - description: Ledger of Balance in Loyalty Program for a Customer. - example: - ledger: - total: 0.8008281904610115 - totalSpentPoints: 5.962133916683182 - activePoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - expiringPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - totalActivePoints: 6.027456183070403 - totalPendingPoints: 1.4658129805029452 - totalExpiredPoints: 5.637376656633329 - totalNegativePoints: 2.3021358869347655 - transactions: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - expiredPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - currentTier: - expiryDate: 2000-01-23T04:56:07.000+00:00 - downgradePolicy: one_down - name: bronze - id: 11 - startDate: 2000-01-23T04:56:07.000+00:00 - pendingPoints: - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - - eventID: 5 - amount: 100.0 - created: 2021-07-20T22:00:00Z - flags: - createsNegativeBalance: true - subLedgerID: mysubledger - customerSessionID: t2gy5s-47274 - type: addition - userID: 499 - expiryDate: 2022-07-20T22:00:00Z - archived: false - customerProfileID: URNGV8294NV - cardID: 241 - name: Add points on purchase - validityDuration: 30D - programID: 5 - startDate: 2021-07-20T22:00:00Z - subLedgers: - mysubledger: - total: 0 - totalActivePoints: 286 - totalPendingPoints: 50 - totalSpentPoints: 150 - totalExpiredPoints: 25 - totalNegativePoints: 0 - properties: - ledger: - $ref: '#/components/schemas/LoyaltySubLedger' - subLedgers: - additionalProperties: - $ref: '#/components/schemas/LoyaltySubLedger' - description: A map containing a list of all loyalty subledger balances. - example: - mysubledger: - total: 0 - totalActivePoints: 286 - totalPendingPoints: 50 - totalSpentPoints: 150 - totalExpiredPoints: 25 - totalNegativePoints: 0 - type: object - required: - - ledger + - isPrimary + - name type: object - DeductLoyaltyPoints: - description: Points to deduct. + Experiment: example: - subledgerId: sub-123 - name: Penalty - applicationId: 322 + goalType: other + goalDescription: Offering free shipping will increase average order revenue + more than a 10% discount + deletedat: 2000-01-23T04:56:07.000+00:00 + created: 2020-06-10T09:05:27.993483Z + campaign: + type: advanced + templateId: 3 + customEffectCount: 0 + activeRevisionId: 6 + features: + - coupons + - referrals + createdLoyaltyPointsCount: 9.0 + storesImported: true + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + experimentId: 1 + id: 4 + state: enabled + couponAttributes: '{}' + reservecouponEffectCount: 9 + updatedBy: Jane Doe + frontendState: running + created: 2020-06-10T09:05:27.993483Z + referralCreationCount: 8 + stageRevision: false + couponRedemptionCount: 163 + couponCreationCount: 16 + version: 6 + campaignGroups: + - 1 + - 3 + tags: + - summer + discountEffectCount: 343 + budgets: + - limit: 1000.0 + action: createCoupon + counter: 42.0 + - limit: 1000.0 + action: createCoupon + counter: 42.0 + redeemedLoyaltyPointsCount: 8.0 + name: Summer promotions + valueMapsIds: + - 100 + - 215 + applicationId: 322 + updated: 2022-10-27T15:00:00Z + callApiEffectCount: 0 + createdLoyaltyPointsEffectCount: 2 + discountCount: 288.0 + revisionFrontendState: revised + description: Campaign for all summer 2021 promotions + activeRevisionVersionId: 6 + currentRevisionVersionId: 6 + startTime: 2021-07-20T22:00:00Z + currentRevisionId: 6 + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 6 + reevaluateOnReturn: true + userId: 388 + awardedGiveawaysCount: 9 + redeemedLoyaltyPointsEffectCount: 9 + linkedStoreIds: + - 1 + - 2 + - 3 + createdBy: John Doe + addFreeItemEffectCount: 0 + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + lastActivity: 2022-11-10T23:00:00Z + endTime: 2021-09-22T22:00:00Z + referralRedemptionCount: 3 + id: 6 + state: enabled + variants: + - created: 2020-06-10T09:05:27.993483Z + isPrimary: true + name: Variant A + ruleset: + rbVersion: v2 + created: 2020-06-10T09:05:27.993483Z + campaignId: 320 + bindings: [] + activatedAt: 2000-01-23T04:56:07.000+00:00 + activate: true + rules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + id: 6 + strikethroughRules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + templateId: 3 + userId: 388 + weight: 12 + experimentId: 10 + id: 6 + - created: 2020-06-10T09:05:27.993483Z + isPrimary: true + name: Variant A + ruleset: + rbVersion: v2 + created: 2020-06-10T09:05:27.993483Z + campaignId: 320 + bindings: [] + activatedAt: 2000-01-23T04:56:07.000+00:00 + activate: true + rules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + id: 6 + strikethroughRules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + templateId: 3 + userId: 388 + weight: 12 + experimentId: 10 + id: 6 + applicationId: 322 + isVariantAssignmentExternal: true + activated: 2000-01-23T04:56:07.000+00:00 + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + applicationId: + description: The ID of the Application that owns this entity. + example: 322 + format: int64 + type: integer + isVariantAssignmentExternal: + description: | + The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. + type: boolean + campaign: + $ref: '#/components/schemas/Campaign' + activated: + description: | + The date and time the experiment was activated. + format: date-time + type: string + state: + default: disabled + description: | + A disabled experiment is not evaluated for rules or coupons. + enum: + - enabled + - disabled + - archived + example: enabled + type: string + variants: + items: + $ref: '#/components/schemas/ExperimentVariant' + type: array + goalType: + description: | + The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + enum: + - other + - maximize_revenue + - optimize_discount_efficiency + - maximize_items_sold + type: string + goalDescription: + description: | + A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. + example: Offering free shipping will increase average order revenue more + than a 10% discount + type: string + deletedat: + description: | + The date and time the experiment was deleted. + format: date-time + type: string + required: + - applicationId + - created + - goalType + - id + - state + type: object + NewExperiment: + properties: + isVariantAssignmentExternal: + description: | + The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. + type: boolean + campaign: + $ref: '#/components/schemas/NewCampaign' + goalType: + default: other + description: | + The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + enum: + - other + - maximize_revenue + - maximize_items_sold + - optimize_discount_efficiency + type: string + goalDescription: + description: | + A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. + example: Offering free shipping will increase average order revenue more + than a 10% discount + type: string + required: + - campaign + - goalType + - isVariantAssignmentExternal + type: object + ExperimentListResultsRequest: + properties: + experimentIds: + items: + format: int64 + type: integer + type: array + required: + - experimentIds + type: object + ExperimentVariantResult: + properties: + variantId: + description: The ID of the variant. + example: 1 + format: int64 + type: integer + variantName: + description: The name of the variant. + example: Variant A + type: string + variantWeight: + description: The weight of the variant. + example: 50 + format: int64 + type: integer + isWinner: + description: Calculated flag if the variant is the winner. + example: true + type: boolean + totalRevenue: + description: The total, pre-discount value of all items purchased in a customer + session. + example: 100.0 + type: number + sessionsCount: + description: The number of all closed sessions. + example: 100.0 + type: number + avgItemsPerSession: + description: The number of items from sessions divided by the number of + sessions. + example: 100.0 + type: number + avgSessionValue: + description: The average customer session value, calculated by dividing + the revenue value by the number of sessions. + example: 100.0 + type: number + avgDiscountedSessionValue: + description: The average customer session value, calculated by dividing + the revenue value by the number of sessions. + example: 100.0 + type: number + totalDiscounts: + description: The total value of discounts given for cart items in sessions. + example: 10.0 + type: number + couponsCount: + description: The number of times a coupon was successfully redeemed in sessions. + example: 12.0 + type: number + type: object + ExperimentVariantResultConfidence: + properties: + avgSessionValue: + description: The calculated confidence value of the average customer session + value. + example: 100.0 + type: number + avgDiscountedSessionValue: + description: The calculated confidence value of the average customer discounted + session value. + example: 100.0 + type: number + avgItemsPerSession: + description: The calculated confidence value of the number of items from + sessions value. + example: 100.0 + type: number + required: + - avgDiscountedSessionValue + - avgItemsPerSession + - avgSessionValue + type: object + ExperimentResults: + properties: + variants: + items: + $ref: '#/components/schemas/ExperimentVariantResult' + type: array + confidence: + $ref: '#/components/schemas/ExperimentVariantResultConfidence' + required: + - confidence + - variants + type: object + ExperimentResult: + properties: + variants: + items: + $ref: '#/components/schemas/ExperimentVariantResult' + type: array + confidence: + $ref: '#/components/schemas/ExperimentVariantResultConfidence' + experimentId: + example: 1 + format: int64 + type: integer + required: + - confidence + - experimentId + - variants + type: object + ExperimentListResults: + properties: + results: + items: + $ref: '#/components/schemas/ExperimentResult' + type: array + type: object + UpdateExperiment: + properties: + isVariantAssignmentExternal: + description: | + The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. + type: boolean + campaign: + $ref: '#/components/schemas/UpdateCampaign' + goalType: + description: | + The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the current value is preserved. + enum: + - other + - maximize_revenue + - maximize_items_sold + - optimize_discount_efficiency + type: string + goalDescription: + description: | + A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the current value is preserved. + example: Offering free shipping will increase average order revenue more + than a 10% discount + type: string + required: + - campaign + - isVariantAssignmentExternal + type: object + UpdateExperimentVariant: + properties: + id: + example: 10 + format: int64 + type: integer + name: + description: The name of this variant. + example: Variant A + maxLength: 255 + minLength: 1 + type: string + ruleset: + $ref: '#/components/schemas/NewRuleset' + weight: + description: The percentage split of this variant. The sum of all variant + percentages must be 100. + example: 13 + format: int64 + maximum: 99 + minimum: 1 + type: integer + required: + - id + - name + - ruleset + - weight + type: object + UpdateExperimentVariantArray: + properties: + variants: + description: Array of experiment variants to update + items: + $ref: '#/components/schemas/UpdateExperimentVariant' + type: array + required: + - variants + type: object + NewExperimentVariant: + properties: + name: + description: The name of this variant. + example: Variant A + maxLength: 255 + minLength: 1 + type: string + weight: + description: The percentage split of this variant. The sum of all variant + percentages must be 100. + example: 13 + format: int64 + maximum: 99 + minimum: 1 + type: integer + ruleset: + $ref: '#/components/schemas/NewRuleset' + isPrimary: + example: true + type: boolean + required: + - isPrimary + - name + - ruleset + - weight + type: object + NewExperimentVariantArray: + properties: + variants: + description: Array of experiment variants to create + items: + $ref: '#/components/schemas/NewExperimentVariant' + type: array + required: + - variants + type: object + UpdateExperimentVariantName: + properties: + name: + description: The name of the variant. + example: Variant A + maxLength: 255 + minLength: 1 + type: string + required: + - name + type: object + ExperimentCampaignCopy: + properties: + name: + description: Name of the copied campaign (Defaults to "Copy of original + campaign name"). + example: Copy of Summer promotions + type: string + description: + description: A detailed description of the campaign. + example: Campaign for all summer 2021 promotions + title: Campaign Description + type: string + startTime: + description: Timestamp when the campaign will become active. + example: 2021-06-01T09:00:27.993483Z + format: date-time + type: string + endTime: + description: Timestamp when the campaign will become inactive. + example: 2021-09-10T01:00:00.993483Z + format: date-time + type: string + tags: + description: A list of tags for the campaign. + example: + - Summer + - Shoes + items: + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 + type: array + evaluationGroupId: + description: The ID of the campaign evaluation group the campaign belongs + to. + example: 2 + format: int64 + type: integer + type: object + ExperimentCopy: + properties: + targetApplicationId: + description: | + The ID of the Application to copy the experiment. It is displayed in your Talon.One deployment URL. + format: int64 + type: integer + experiment: + $ref: '#/components/schemas/ExperimentCopy_experiment' + required: + - experiment + - targetApplicationId + type: object + PromoteExperiment: + properties: + targetApplicationId: + description: | + The ID of the Application to copy the experiment. It is displayed in your Talon.One deployment URL. + format: int64 + type: integer + variantId: + description: | + The ID of the Experiment Variant to build the new campaign. + format: int64 + type: integer + disableExperiment: + description: | + Force disable the experiment. + type: boolean + campaign: + $ref: '#/components/schemas/ExperimentCampaignCopy' + required: + - campaign + - targetApplicationId + - variantId + type: object + ExperimentVerdict: + properties: + winnerVariantName: + description: The name of the winning variant. If no variant shows a statistically + significant advantage on key business metrics, return 'Inconclusive'. + type: string + verdictSummary: + description: A one-sentence summary of the outcome, including the key metric + and confidence level that led to the decision. + type: string + keyFindings: + description: A bullet point stating the most important finding, including + the metric, the percentage change, and the confidence. + items: + type: string + type: array + aiConfidenceLevel: + description: Your confidence in this overall verdict, from 0 to 100. + type: string + recommendation: + description: A short, actionable recommendation based on the findings. If + inconclusive, suggest running the test longer. If there is a clear winner, + recommend promoting it. + type: string + required: + - aiConfidenceLevel + - keyFindings + - recommendation + - verdictSummary + - winnerVariantName + type: object + ExperimentVerdictResponse: + properties: + verdict: + $ref: '#/components/schemas/ExperimentVerdict' + generated: + description: Timestamp of the moment when the verdict was generated. + format: date-time + type: string + required: + - generated + - verdict + type: object + ExperimentSegmentInsightVariant: + properties: + variantId: + description: The ID of the experiment variant. + example: 41 + format: int64 + type: integer + variantName: + description: The name of the experiment variant. + example: Control + type: string + sessionsCount: + description: The number of sessions in this segment for this variant. + example: 161 + format: int64 + type: integer + value: + description: The metric value for this variant in the segment. + example: 13.13 + format: double + type: number + required: + - sessionsCount + - value + - variantId + - variantName + type: object + ExperimentSegmentInsight: + properties: + dimension: + description: The segmentation dimension used to group customers or purchases + for analysis. + enum: + - cart_value + - item_count + - customer_type + example: cart_value + type: string + bucket: + description: The specific group within the segmentation dimension. + enum: + - low + - medium + - high + - new + - returning + - loyal + example: high + type: string + confidence: + description: | + The raw (unadjusted) confidence score expressed as a percentage. Only segments with a confidence score greater than or equal to 95% are returned. + example: 99.2 + format: double + maximum: 1E+2 + minimum: 95 + type: number + winnerVariantId: + description: The ID of the variant that performed better in this segment. + example: 42 + format: int64 + type: integer + variants: + description: Per-variant metric values for this segment. + items: + $ref: '#/components/schemas/ExperimentSegmentInsightVariant' + type: array + required: + - bucket + - confidence + - dimension + - variants + - winnerVariantId + type: object + ExperimentSegmentInsightMetric: + properties: + metric: + description: The metric being measured. + enum: + - avg_session_value + - avg_discounted_session_value + - avg_items_per_session + example: avg_session_value + type: string + segments: + description: | + Segments with statistically significant results for this metric. An empty array means no significant segments were found. Segments are sorted by confidence score from highest to lowest. + items: + $ref: '#/components/schemas/ExperimentSegmentInsight' + type: array + required: + - metric + - segments + type: object + ExperimentSegmentInsights: + properties: + metrics: + description: | + Segment insights grouped by metric. This array always contains exactly three metric objects. Each metric includes a segments array, which is empty if no significant results were found. The metrics array itself is empty if the `reason` property is populated. + items: + $ref: '#/components/schemas/ExperimentSegmentInsightMetric' + type: array + totalSegmentsTested: + description: | + Total number of segment-metric combinations that were tested for statistical significance. + example: 24 + format: int64 + type: integer + dimensionsTested: + description: | + Number of segmentation dimensions that had sufficient data variance to test. Dimensions where all sessions fall into a single bucket are excluded. + example: 3 + format: int64 + type: integer + reason: + description: | + Empty string when segment insights are available. Contains a reason code when insights could not be computed (e.g., "insufficient_data" when the experiment has fewer than 100 sessions per variant). + example: "" + type: string + required: + - dimensionsTested + - metrics + - reason + - totalSegmentsTested + type: object + ExperimentConfidenceTimelineDataPoint: + properties: + date: + description: The date-time this data point represents. + example: 2024-01-15T00:00:00+07:00 + format: date-time + type: string + confidence: + $ref: '#/components/schemas/ExperimentVariantResultConfidence' + required: + - confidence + - date + type: object + ExperimentConfidenceTimeline: + properties: + data: + description: | + Daily cumulative confidence values ordered chronologically from experiment start to end, or to today if the experiment is still running. Empty if the experiment has no data yet. + items: + $ref: '#/components/schemas/ExperimentConfidenceTimelineDataPoint' + type: array + required: + - data + type: object + CreateTemplateCampaign: + example: + campaignAttributesOverrides: '{}' + linkedStoreIds: + - 1 + - 2 + - 3 + evaluationGroupId: 2 + name: Discount campaign + description: This template is for discount campaigns. + limitOverrides: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + templateParamValues: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + templateId: 4 + campaignGroups: + - 1 + - 3 + tags: + - summer + properties: + name: + description: A user-facing name for this campaign. + example: Discount campaign + minLength: 1 + title: Campaign Name + type: string + description: + description: A detailed description of the campaign. + example: This template is for discount campaigns. + title: Campaign Description + type: string + templateId: + description: The ID of the Campaign Template which will be used in order + to create the Campaign. + example: 4 + format: int64 + type: integer + campaignAttributesOverrides: + description: Custom Campaign Attributes. If the Campaign Template defines + the same values, they will be overridden. + properties: {} + type: object + templateParamValues: + description: Actual values to replace the template placeholder values in + the Ruleset bindings. Values for all Template Parameters must be provided. + items: + $ref: '#/components/schemas/Binding' + type: array + limitOverrides: + description: Limits for this Campaign. If the Campaign Template or Application + define default values for the same limits, they will be overridden. + items: + $ref: '#/components/schemas/LimitConfig' + type: array + campaignGroups: + description: | + The IDs of the [campaign groups](https://docs.talon.one/docs/product/account/account-settings/managing-campaign-groups) this campaign belongs to. + example: + - 1 + - 3 + items: + format: int64 + type: integer + type: array + tags: + description: A list of tags for the campaign. If the campaign template has + tags, they will be overridden by this list. + example: + - summer + items: + maxLength: 50 + minLength: 1 + type: string + maxItems: 50 + type: array + evaluationGroupId: + description: The ID of the campaign evaluation group the campaign belongs + to. + example: 2 + format: int64 + type: integer + linkedStoreIds: + description: | + A list of store IDs that are linked to the campaign. + + **Note:** Campaigns with linked store IDs will only be evaluated when there is a + [customer session update](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) + that references a linked store. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + required: + - name + - templateId + type: object + UpdateCollection: + example: + subscribedApplicationsIds: + - 1 + - 2 + - 3 + description: My collection of SKUs + properties: + description: + description: A short description of the purpose of this collection. + example: My collection of SKUs + type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications where this collection + is enabled. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + type: object + NewCollection: + example: + subscribedApplicationsIds: + - 1 + - 2 + - 3 + name: My collection + description: My collection of SKUs + properties: + description: + description: A short description of the purpose of this collection. + example: My collection of SKUs + type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications where this collection + is enabled. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + name: + description: The name of this collection. + example: My collection + minLength: 1 + pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ + type: string + required: + - name + type: object + CollectionWithoutPayload: + example: + accountId: 3886 + createdBy: 134 + created: 2020-06-10T09:05:27.993483Z + campaignId: 7 + subscribedApplicationsIds: + - 1 + - 2 + - 3 + name: My collection + modified: 2021-09-12T10:12:42Z + description: My collection of SKUs + modifiedBy: 48 + id: 6 + applicationId: 1 + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + accountId: + description: The ID of the account that owns this entity. + example: 3886 + format: int64 + type: integer + modified: + description: The time this entity was last modified. + example: 2021-09-12T10:12:42Z + format: date-time + type: string + description: + description: A short description of the purpose of this collection. + example: My collection of SKUs + type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications where this collection + is enabled. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + name: + description: The name of this collection. + example: My collection + minLength: 1 + pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ + type: string + modifiedBy: + description: ID of the user who last updated this effect if available. + example: 48 + format: int64 + type: integer + createdBy: + description: ID of the user who created this effect. + example: 134 + format: int64 + type: integer + applicationId: + description: The ID of the Application that owns this entity. + example: 1 + format: int64 + type: integer + campaignId: + description: The ID of the campaign that owns this entity. + example: 7 + format: int64 + type: integer + required: + - accountId + - created + - createdBy + - id + - modified + - name + type: object + Collection: + example: + accountId: 3886 + createdBy: 134 + payload: + - KTL-WH-ET-1 + - KTL-BL-ET-1 + created: 2020-06-10T09:05:27.993483Z + campaignId: 7 + subscribedApplicationsIds: + - 1 + - 2 + - 3 + name: My collection + modified: 2021-09-12T10:12:42Z + description: My collection of SKUs + modifiedBy: 48 + id: 6 + applicationId: 1 + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + accountId: + description: The ID of the account that owns this entity. + example: 3886 + format: int64 + type: integer + modified: + description: The time this entity was last modified. + example: 2021-09-12T10:12:42Z + format: date-time + type: string + description: + description: A short description of the purpose of this collection. + example: My collection of SKUs + type: string + subscribedApplicationsIds: + description: A list of the IDs of the Applications where this collection + is enabled. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + name: + description: The name of this collection. + example: My collection + minLength: 1 + pattern: ^[^[:cntrl:]\s][^[:cntrl:]]*$ + type: string + modifiedBy: + description: ID of the user who last updated this effect if available. + example: 48 + format: int64 + type: integer + createdBy: + description: ID of the user who created this effect. + example: 134 + format: int64 + type: integer + applicationId: + description: The ID of the Application that owns this entity. + example: 1 + format: int64 + type: integer + campaignId: + description: The ID of the campaign that owns this entity. + example: 7 + format: int64 + type: integer + payload: + description: The content of the collection. + example: + - KTL-WH-ET-1 + - KTL-BL-ET-1 + items: + type: string + maxItems: 50 + type: array + required: + - accountId + - created + - createdBy + - id + - modified + - name + type: object + CreateTemplateCampaignResponse: + example: + collections: + - accountId: 3886 + createdBy: 134 + payload: + - KTL-WH-ET-1 + - KTL-BL-ET-1 + created: 2020-06-10T09:05:27.993483Z + campaignId: 7 + subscribedApplicationsIds: + - 1 + - 2 + - 3 + name: My collection + modified: 2021-09-12T10:12:42Z + description: My collection of SKUs + modifiedBy: 48 + id: 6 + applicationId: 1 + - accountId: 3886 + createdBy: 134 + payload: + - KTL-WH-ET-1 + - KTL-BL-ET-1 + created: 2020-06-10T09:05:27.993483Z + campaignId: 7 + subscribedApplicationsIds: + - 1 + - 2 + - 3 + name: My collection + modified: 2021-09-12T10:12:42Z + description: My collection of SKUs + modifiedBy: 48 + id: 6 + applicationId: 1 + ruleset: + rbVersion: v2 + created: 2020-06-10T09:05:27.993483Z + campaignId: 320 + bindings: [] + activatedAt: 2000-01-23T04:56:07.000+00:00 + activate: true + rules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + id: 6 + strikethroughRules: + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + - condition: + - and + - - couponValid + effects: + - catch + - - noop + - - setDiscount + - 10% off + - - '*' + - - "." + - Session + - Total + - - / + - 10 + - 100 + bindings: + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + - attributeId: 100 + minValue: 0.0 + expression: + - identity + - 10 + maxValue: 19.9 + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. + type: templateParameter + description: Creates a discount when a coupon is valid + id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + title: Give discount via coupon + parentId: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 + templateId: 3 + userId: 388 + campaign: + type: advanced + templateId: 3 + customEffectCount: 0 + activeRevisionId: 6 + features: + - coupons + - referrals + createdLoyaltyPointsCount: 9.0 + storesImported: true + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + experimentId: 1 + id: 4 + state: enabled + couponAttributes: '{}' + reservecouponEffectCount: 9 + updatedBy: Jane Doe + frontendState: running + created: 2020-06-10T09:05:27.993483Z + referralCreationCount: 8 + stageRevision: false + couponRedemptionCount: 163 + couponCreationCount: 16 + version: 6 + campaignGroups: + - 1 + - 3 + tags: + - summer + discountEffectCount: 343 + budgets: + - limit: 1000.0 + action: createCoupon + counter: 42.0 + - limit: 1000.0 + action: createCoupon + counter: 42.0 + redeemedLoyaltyPointsCount: 8.0 + name: Summer promotions + valueMapsIds: + - 100 + - 215 + applicationId: 322 + updated: 2022-10-27T15:00:00Z + callApiEffectCount: 0 + createdLoyaltyPointsEffectCount: 2 + discountCount: 288.0 + revisionFrontendState: revised + description: Campaign for all summer 2021 promotions + activeRevisionVersionId: 6 + currentRevisionVersionId: 6 + startTime: 2021-07-20T22:00:00Z + currentRevisionId: 6 + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 6 + reevaluateOnReturn: true + userId: 388 + awardedGiveawaysCount: 9 + redeemedLoyaltyPointsEffectCount: 9 + linkedStoreIds: + - 1 + - 2 + - 3 + createdBy: John Doe + addFreeItemEffectCount: 0 + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + lastActivity: 2022-11-10T23:00:00Z + endTime: 2021-09-22T22:00:00Z + referralRedemptionCount: 3 + properties: + campaign: + $ref: '#/components/schemas/Campaign' + ruleset: + $ref: '#/components/schemas/Ruleset' + collections: + items: + $ref: '#/components/schemas/Collection' + type: array + required: + - campaign + - ruleset + type: object + NewLoyaltyProgram: + description: A new loyalty program + properties: + title: + description: The display title for the Loyalty Program. + example: Point collection + type: string + description: + description: Description of our Loyalty Program. + example: Customers collect 10 points per 1$ spent + type: string + subscribedApplications: + description: A list containing the IDs of all applications that are subscribed + to this Loyalty Program. + example: + - 132 + - 97 + items: + format: int64 + type: integer + type: array + defaultValidity: + description: | + The default duration after which new loyalty points should expire. Can be 'unlimited' or a specific time. + The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: + - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. + - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. + example: 2W_U + type: string + defaultPending: + description: | + The default duration of the pending time after which points should be valid. Accepted values: 'immediate', 'on_action' or a specific time. + The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: + - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. + - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. + example: immediate + type: string + allowSubledger: + description: Indicates if this program supports subledgers inside the program. + example: false + type: boolean + usersPerCardLimit: + description: | + The max amount of user profiles with whom a card can be shared. This can be set to 0 for no limit. + This property is only used when `cardBased` is `true`. + example: 111 + format: int64 + minimum: 0 + type: integer + sandbox: + description: Indicates if this program is a live or sandbox program. Programs + of a given type can only be connected to Applications of the same type. + example: true + title: Sandbox + type: boolean + programJoinPolicy: + description: | + The policy that defines when the customer joins the loyalty program. + - `not_join`: The customer does not join the loyalty program but can still earn and spend loyalty points. + + **Note**: The customer does not have a program join date. + - `points_activated`: The customer joins the loyalty program only when their earned loyalty points become active for the first time. + - `points_earned`: The customer joins the loyalty program when they earn loyalty points for the first time. + enum: + - not_join + - points_activated + - points_earned + type: string + tiersExpirationPolicy: + description: | + The policy that defines how tier expiration, used to reevaluate the customer's current tier, is determined. + - `tier_start_date`: The tier expiration is relative to when the customer joined the current tier. + - `program_join_date`: The tier expiration is relative to when the customer joined the loyalty program. + - `customer_attribute`: The tier expiration is determined by a custom customer attribute. + - `absolute_expiration`: The tier is reevaluated at the start of each tier cycle. For this policy, it is required to provide a `tierCycleStartDate`. + enum: + - tier_start_date + - program_join_date + - customer_attribute + - absolute_expiration + type: string + tierCycleStartDate: + description: | + Timestamp at which the tier cycle starts for all customers in the loyalty program. + + **Note**: This is only required when the tier expiration policy is set to `absolute_expiration`. + example: 2021-09-12T10:12:42Z + format: date-time + type: string + tiersExpireIn: + description: | + The amount of time after which the tier expires and is reevaluated. + + The time format is an **integer** followed by one letter indicating the time unit. + Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. + + Available units: + + - `s`: seconds + - `m`: minutes + - `h`: hours + - `D`: days + - `W`: weeks + - `M`: months + - `Y`: years + + You can round certain units up or down: + - `_D` for rounding down days only. Signifies the start of the day. + - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. + example: 27W_U + type: string + tiersDowngradePolicy: + description: | + The policy that defines how customer tiers are downgraded in the loyalty program after tier reevaluation. + - `one_down`: If the customer doesn't have enough points to stay in the current tier, they are downgraded by one tier. + - `balance_based`: The customer's tier is reevaluated based on the amount of active points they have at the moment. + enum: + - one_down + - balance_based + type: string + cardCodeSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + returnPolicy: + description: | + The policy that defines the rollback of points in case of a partially returned, cancelled, or reopened [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + - `only_pending`: Only pending points can be rolled back. + - `within_balance`: Available active points can be rolled back if there aren't enough pending points. The active balance of the customer cannot be negative. + - `unlimited`: Allows negative balance without any limit. + enum: + - only_pending + - within_balance + - unlimited + type: string + name: + description: The internal name for the Loyalty Program. This is an immutable + value. + example: GeneralPointCollection + type: string + tiers: + description: The tiers in this loyalty program. + items: + $ref: '#/components/schemas/NewLoyaltyTier' + type: array + timezone: + description: A string containing an IANA timezone descriptor. + minLength: 1 + type: string + cardBased: + default: false + description: | + Defines the type of loyalty program: + - `true`: the program is a card-based. + - `false`: the program is profile-based. + example: true + type: boolean + required: + - allowSubledger + - cardBased + - defaultPending + - defaultValidity + - name + - sandbox + - timezone + - title + type: object + UpdateLoyaltyProgram: + description: An updated loyalty program. + properties: + title: + description: The display title for the Loyalty Program. + example: Point collection + type: string + description: + description: Description of our Loyalty Program. + example: Customers collect 10 points per 1$ spent + type: string + subscribedApplications: + description: A list containing the IDs of all applications that are subscribed + to this Loyalty Program. + example: + - 132 + - 97 + items: + format: int64 + type: integer + type: array + defaultValidity: + description: | + The default duration after which new loyalty points should expire. Can be 'unlimited' or a specific time. + The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: + - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. + - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. + example: 2W_U + type: string + defaultPending: + description: | + The default duration of the pending time after which points should be valid. Accepted values: 'immediate', 'on_action' or a specific time. + The time format is a number followed by one letter indicating the time unit, like '30s', '40m', '1h', '5D', '7W', or 10M'. These rounding suffixes are also supported: + - '_D' for rounding down. Can be used as a suffix after 'D', and signifies the start of the day. + - '_U' for rounding up. Can be used as a suffix after 'D', 'W', and 'M', and signifies the end of the day, week, and month. + example: immediate + type: string + allowSubledger: + description: Indicates if this program supports subledgers inside the program. + example: false + type: boolean + usersPerCardLimit: + description: | + The max amount of user profiles with whom a card can be shared. This can be set to 0 for no limit. + This property is only used when `cardBased` is `true`. + example: 111 + format: int64 + minimum: 0 + type: integer + sandbox: + description: Indicates if this program is a live or sandbox program. Programs + of a given type can only be connected to Applications of the same type. + example: true + title: Sandbox + type: boolean + programJoinPolicy: + description: | + The policy that defines when the customer joins the loyalty program. + - `not_join`: The customer does not join the loyalty program but can still earn and spend loyalty points. + + **Note**: The customer does not have a program join date. + - `points_activated`: The customer joins the loyalty program only when their earned loyalty points become active for the first time. + - `points_earned`: The customer joins the loyalty program when they earn loyalty points for the first time. + enum: + - not_join + - points_activated + - points_earned + type: string + tiersExpirationPolicy: + description: | + The policy that defines how tier expiration, used to reevaluate the customer's current tier, is determined. + - `tier_start_date`: The tier expiration is relative to when the customer joined the current tier. + - `program_join_date`: The tier expiration is relative to when the customer joined the loyalty program. + - `customer_attribute`: The tier expiration is determined by a custom customer attribute. + - `absolute_expiration`: The tier is reevaluated at the start of each tier cycle. For this policy, it is required to provide a `tierCycleStartDate`. + enum: + - tier_start_date + - program_join_date + - customer_attribute + - absolute_expiration + type: string + tierCycleStartDate: + description: | + Timestamp at which the tier cycle starts for all customers in the loyalty program. + + **Note**: This is only required when the tier expiration policy is set to `absolute_expiration`. + example: 2021-09-12T10:12:42Z + format: date-time + type: string + tiersExpireIn: + description: | + The amount of time after which the tier expires and is reevaluated. + + The time format is an **integer** followed by one letter indicating the time unit. + Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. + + Available units: + + - `s`: seconds + - `m`: minutes + - `h`: hours + - `D`: days + - `W`: weeks + - `M`: months + - `Y`: years + + You can round certain units up or down: + - `_D` for rounding down days only. Signifies the start of the day. + - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. + example: 27W_U + type: string + tiersDowngradePolicy: + description: | + The policy that defines how customer tiers are downgraded in the loyalty program after tier reevaluation. + - `one_down`: If the customer doesn't have enough points to stay in the current tier, they are downgraded by one tier. + - `balance_based`: The customer's tier is reevaluated based on the amount of active points they have at the moment. + enum: + - one_down + - balance_based + type: string + cardCodeSettings: + $ref: '#/components/schemas/CodeGeneratorSettings' + returnPolicy: + description: | + The policy that defines the rollback of points in case of a partially returned, cancelled, or reopened [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + - `only_pending`: Only pending points can be rolled back. + - `within_balance`: Available active points can be rolled back if there aren't enough pending points. The active balance of the customer cannot be negative. + - `unlimited`: Allows negative balance without any limit. + enum: + - only_pending + - within_balance + - unlimited + type: string + tiers: + description: The tiers in this loyalty program. + items: + $ref: '#/components/schemas/NewLoyaltyTier' + type: array + type: object + ActivateLoyaltyPoints: + description: Activate loyalty points + example: + transactionUUIDs: + - 8f1a8d7c-9c3e-4a5e-9f0d-2c5f7a3b1cde + sessionId: ac08cc3c43470426591ad75b2d685ec04_v2 + properties: + transactionUUIDs: + description: | + An array of transaction UUIDs used to activate specific pending point transactions. + + If provided, do not include the `sessionId` parameter. + example: + - 8f1a8d7c-9c3e-4a5e-9f0d-2c5f7a3b1cde + items: + format: uuid + type: string + maxItems: 50 + minItems: 1 + type: array + uniqueItems: true + sessionId: + description: | + The ID of the session containing the pending point transactions to activate. + + If provided, do not include the `transactionUUIDs` parameter. + example: ac08cc3c43470426591ad75b2d685ec04_v2 + minLength: 1 + type: string + type: object + LoyaltyLedgerEntry: + description: A single row of the ledger, describing one addition or deduction. + example: + eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + properties: + created: + example: 2021-07-20T22:00:00Z + format: date-time + type: string + programID: + example: 5 + format: int64 + type: integer + customerProfileID: + example: URNGV8294NV + type: string + cardID: + example: 241 + format: int64 + type: integer + customerSessionID: + example: t2gy5s-47274 + type: string + eventID: + example: 5 + format: int64 + type: integer + type: + description: | + The type of the ledger transaction. Possible values are: + - `addition` + - `subtraction` + - `expire` + - `expiring` (for expiring points ledgers) + example: addition + type: string + amount: + example: 100.0 + type: number + startDate: + example: 2021-07-20T22:00:00Z + format: date-time + type: string + expiryDate: + example: 2022-07-20T22:00:00Z + format: date-time + type: string + name: + description: A name referencing the condition or effect that added this + entry, or the specific name provided in an API call. + example: Add points on purchase + type: string + subLedgerID: + description: This specifies if we are adding loyalty points to the main + ledger or a subledger. + example: mysubledger + type: string + userID: + description: This is the ID of the user who created this entry, if the addition + or subtraction was done manually. + example: 499 + format: int64 + type: integer + archived: + description: Indicates if the entry belongs to the archived session. + example: false + type: boolean + flags: + $ref: '#/components/schemas/LoyaltyLedgerEntryFlags' + validityDuration: + description: | + The duration for which the points remain active, relative to the activation date. + + **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. + example: 30D + type: string + required: + - amount + - created + - name + - programID + - subLedgerID + - type + type: object + ActivateLoyaltyPointsResponse: + example: + ledgerEntries: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + properties: + ledgerEntries: + description: Updated ledger entries after activation. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + type: object + UpdateLoyaltyProgramTier: + description: Update a tier in a specified loyalty program. + properties: + id: + description: The internal ID of the tier. + example: 6 + format: int64 + type: integer + name: + description: The name of the tier. + example: Gold + type: string + minPoints: + description: The minimum amount of points required to enter the tier. + example: 300.0 + maximum: 999999999999.99 + minimum: 0 + type: number + required: + - id + type: object + UpdateLoyaltyProgramTiers: + description: List of tiers that are updated by the request. + items: + $ref: '#/components/schemas/UpdateLoyaltyProgramTier' + type: array + LoyaltyTiers: + description: A list of the loyalty program's tiers. + items: + $ref: '#/components/schemas/LoyaltyTier' + type: array + LoyaltyDashboardPointsBreakdown: + example: + createdManually: 125.0 + createdViaRuleEngine: 9631.0 + properties: + createdManually: + example: 125.0 + type: number + createdViaRuleEngine: + example: 9631.0 + type: number + required: + - createdManually + - createdViaRuleEngine + type: object + LoyaltyDashboardData: + description: Datapoint for the graphs and cards on a loyalty program dashboard. + example: + date: 2000-01-23T04:56:07.000+00:00 + totalMembers: 2582.0 + totalSpentPoints: 25668.0 + spentPoints: + createdManually: 125.0 + createdViaRuleEngine: 9631.0 + totalActivePoints: 9756.0 + totalPendingPoints: 548.0 + totalExpiredPoints: 1156.0 + totalNegativePoints: 32.0 + newMembers: 3.0 + earnedPoints: + createdManually: 125.0 + createdViaRuleEngine: 9631.0 + properties: + date: + description: Date at which data point was collected. + format: date-time + type: string + totalActivePoints: + description: Total of active points for this loyalty program. + example: 9756.0 + type: number + totalPendingPoints: + description: Total of pending points for this loyalty program. + example: 548.0 + type: number + totalSpentPoints: + description: Total of spent points for this loyalty program. + example: 25668.0 + type: number + totalExpiredPoints: + description: Total of expired points for this loyalty program. + example: 1156.0 + type: number + totalNegativePoints: + description: Total of negative points for this loyalty program. + example: 32.0 + type: number + totalMembers: + description: Number of loyalty program members. + example: 2582.0 + type: number + newMembers: + description: Number of members who joined on this day. + example: 3.0 + type: number + spentPoints: + $ref: '#/components/schemas/LoyaltyDashboardPointsBreakdown' + earnedPoints: + $ref: '#/components/schemas/LoyaltyDashboardPointsBreakdown' + required: + - date + - earnedPoints + - newMembers + - spentPoints + - totalActivePoints + - totalExpiredPoints + - totalMembers + - totalNegativePoints + - totalPendingPoints + - totalSpentPoints + type: object + Import: + example: + accountId: 3886 + amount: 10 + created: 2020-06-10T09:05:27.993483Z + id: 6 + userId: 388 + entity: AttributeAllowedList + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + accountId: + description: The ID of the account that owns this entity. + example: 3886 + format: int64 + type: integer + userId: + description: The ID of the user associated with this entity. + example: 388 + format: int64 + type: integer + entity: + description: | + The name of the entity that was imported. + example: AttributeAllowedList + type: string + amount: + description: The number of values that were imported. + example: 10 + format: int64 + minimum: 0 + type: integer + required: + - accountId + - amount + - created + - entity + - id + - userId + type: object + LoyaltySubLedger: + description: Ledger of Balance in Loyalty Program for a Customer. + example: + total: 0.8008281904610115 + totalSpentPoints: 5.962133916683182 + activePoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + expiringPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + totalActivePoints: 6.027456183070403 + totalPendingPoints: 1.4658129805029452 + totalExpiredPoints: 5.637376656633329 + totalNegativePoints: 2.3021358869347655 + transactions: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + expiredPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + pendingPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + properties: + total: + description: | + **DEPRECATED** Use `totalActivePoints` property instead. Total amount of currently active and available points in the customer's balance. + title: Current Balance (Deprecated) + type: number + x-deprecated: true + totalActivePoints: + description: Total amount of currently active and available points in the + customer's balance. + title: Current Balance + type: number + totalPendingPoints: + description: Total amount of pending points, which are not active yet but + will become active in the future. + title: Total pending points + type: number + totalSpentPoints: + description: Total amount of points already spent by this customer. + title: Total spent points + type: number + totalExpiredPoints: + description: Total amount of points, that expired without ever being spent. + title: Total expired points + type: number + totalNegativePoints: + description: Total amount of negative points. This implies that `totalActivePoints` + is `0`. + title: Total negative points + type: number + transactions: + description: List of all events that have happened such as additions, subtractions + and expiries. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + expiringPoints: + description: List of all points that will expire. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + activePoints: + description: List of all currently active points. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + pendingPoints: + description: List of all points pending activation. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + expiredPoints: + description: List of expired points. + items: + $ref: '#/components/schemas/LoyaltyLedgerEntry' + type: array + currentTier: + $ref: '#/components/schemas/Tier' + required: + - total + - totalActivePoints + - totalExpiredPoints + - totalNegativePoints + - totalPendingPoints + - totalSpentPoints + type: object + LoyaltyLedger: + description: Ledger of Balance in Loyalty Program for a Customer. + example: + ledger: + total: 0.8008281904610115 + totalSpentPoints: 5.962133916683182 + activePoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + expiringPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + totalActivePoints: 6.027456183070403 + totalPendingPoints: 1.4658129805029452 + totalExpiredPoints: 5.637376656633329 + totalNegativePoints: 2.3021358869347655 + transactions: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + expiredPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + pendingPoints: + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + - eventID: 5 + amount: 100.0 + created: 2021-07-20T22:00:00Z + flags: + createsNegativeBalance: true + subLedgerID: mysubledger + customerSessionID: t2gy5s-47274 + type: addition + userID: 499 + expiryDate: 2022-07-20T22:00:00Z + archived: false + customerProfileID: URNGV8294NV + cardID: 241 + name: Add points on purchase + validityDuration: 30D + programID: 5 + startDate: 2021-07-20T22:00:00Z + subLedgers: + mysubledger: + total: 0 + totalActivePoints: 286 + totalPendingPoints: 50 + totalSpentPoints: 150 + totalExpiredPoints: 25 + totalNegativePoints: 0 + properties: + ledger: + $ref: '#/components/schemas/LoyaltySubLedger' + subLedgers: + additionalProperties: + $ref: '#/components/schemas/LoyaltySubLedger' + description: A map containing a list of all loyalty subledger balances. + example: + mysubledger: + total: 0 + totalActivePoints: 286 + totalPendingPoints: 50 + totalSpentPoints: 150 + totalExpiredPoints: 25 + totalNegativePoints: 0 + type: object + required: + - ledger + type: object + DeductLoyaltyPoints: + description: Points to deduct. + example: + subledgerId: sub-123 + name: Penalty + applicationId: 322 points: 300.0 properties: points: @@ -35680,7 +42407,7 @@ components: $ref: '#/components/schemas/LoyaltyLedgerEntryFlags' validityDuration: description: | - The duration for which the points remain active, relative to the activation date. + The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. example: 30D @@ -36583,6 +43310,11 @@ components: assertionConsumerServiceURL: description: The location where the SAML assertion is sent with a HTTP POST. type: string + certificateExpiry: + description: The expiry date of the X.509 certificate. + example: 2021-07-20T21:59:00Z + format: date-time + type: string accountId: description: The ID of the account that owns this entity. example: 3885 @@ -37174,6 +43906,7 @@ components: $ref: '#/components/schemas/LoyaltyMembership' title: Loyalty programed joined type: array + x-deprecated: true audienceMemberships: description: The audiences the customer belongs to. items: @@ -37511,10 +44244,10 @@ components: description: | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: - 1. `open` → `closed` - 2. `open` → `cancelled` - 3. `closed` → `cancelled` or `partially_returned` - 4. `partially_returned` → `cancelled` + 1. `open` -> `closed` + 2. `open` -> `cancelled` + 3. `closed` -> `cancelled` or `partially_returned` + 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). enum: @@ -37584,6 +44317,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -37601,6 +44335,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -37612,6 +44347,7 @@ components: storeIntegrationId: STORE-001 created: 2020-06-10T09:05:27.993483Z profileId: 138 + integrationId: 175KJPS947296 attributes: '{}' id: 6 sessionId: 6 @@ -37619,30 +44355,34 @@ components: storeId: 0 type: type ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details @@ -37680,14 +44420,20 @@ components: maxLength: 1000 minLength: 1 type: string + integrationId: + description: | + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 + type: string sessionId: description: The globally unique Talon.One ID of the session that contains this event. format: int64 type: integer type: - description: A string representing the event. Must not be a reserved event - name. + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. type: string attributes: description: Additional JSON serialized data associated with the event. @@ -37785,6 +44531,7 @@ components: $ref: '#/components/schemas/LoyaltyMembership' title: Loyalty programed joined type: array + x-deprecated: true audienceMemberships: description: The audiences the customer belongs to. items: @@ -37843,6 +44590,7 @@ components: type: object ApplicationReferee: example: + advancedEventIntegrationId: advanced_event_1234 friendIntegrationId: friendIntegrationId code: code created: 2000-01-23T04:56:07.000+00:00 @@ -37859,6 +44607,13 @@ components: description: Integration ID of the session in which the customer redeemed the referral. type: string + advancedEventIntegrationId: + description: The unique ID of the advanced event in which the customer redeemed + the referral. Omitted when the referral was redeemed through a customer + session rather than an advanced event. + example: advanced_event_1234 + maxLength: 1000 + type: string advocateIntegrationId: description: Integration ID of the Advocate's Profile. maxLength: 1000 @@ -38650,8 +45405,8 @@ components: timeframeEndDate: 2020-11-10T23:00:00Z timeframe: "30" skus: - - comma - - period + - SKU1241028 + - SKU7345278 timeframeEndDateType: sale target: targetType: AUDIENCE @@ -38661,8 +45416,8 @@ components: description: List of product SKUs to check when determining the best prior price. example: - - comma - - period + - SKU1241028 + - SKU7345278 items: type: string minItems: 1 @@ -38774,11 +45529,13 @@ components: discountValue: 6.027456183070403 - campaignId: 0 discountValue: 6.027456183070403 - observedAt: 2020-11-10T23:00:00Z + observedAt: 2025-11-10T23:00:00Z price: 99.99 - contextId: Summer Sale 2025 + contextIds: + - SpringSale + - SummerSale2025 id: 1 - sku: NVR-GN-GV-UUP + sku: SKU7345278 target: '{}' properties: id: @@ -38788,18 +45545,22 @@ components: type: integer sku: description: sku - example: NVR-GN-GV-UUP + example: SKU7345278 type: string observedAt: description: The date and time when the price was observed. - example: 2020-11-10T23:00:00Z + example: 2025-11-10T23:00:00Z format: date-time type: string - contextId: + contextIds: description: | - The context ID of the context active at the time of observation. - example: Summer Sale 2025 - type: string + The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. + example: + - SpringSale + - SummerSale2025 + items: + type: string + type: array price: description: Price of the item. example: 99.99 @@ -38809,7 +45570,7 @@ components: target: type: object required: - - contextId + - contextIds - id - metadata - observedAt @@ -38824,13 +45585,13 @@ components: PriceHistoryRequest: example: endDate: 2020-12-10T23:00:00Z - sku: "" + sku: SKU1241028 startDate: 2020-11-10T23:00:00Z properties: sku: description: The SKU of the item for which the historical prices are being retrieved. - example: "" + example: SKU1241028 type: string startDate: description: The start date of the period for which historical prices should @@ -38861,9 +45622,13 @@ components: discountValue: 6.027456183070403 - campaignId: 0 discountValue: 6.027456183070403 - observedAt: 2020-11-10T23:00:00Z + observedAt: 2025-11-10T23:00:00Z price: 99.99 - contextId: Summer Sale 2025 + exclusionReason: Incorrect contextID value + excludedAt: 2025-11-10T23:00:00Z + contextIds: + - SpringSale + - SummerSale2025 id: 1 target: '{}' properties: @@ -38874,14 +45639,18 @@ components: type: integer observedAt: description: The date and time when the price was observed. - example: 2020-11-10T23:00:00Z + example: 2025-11-10T23:00:00Z format: date-time type: string - contextId: + contextIds: description: | - Identifier of the relevant context at the time the price was observed (e.g. summer sale). - example: Summer Sale 2025 - type: string + The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. + example: + - SpringSale + - SummerSale2025 + items: + type: string + type: array price: description: Price of the item. example: 99.99 @@ -38890,8 +45659,17 @@ components: $ref: '#/components/schemas/BestPriorPriceMetadata' target: type: object + excludedAt: + description: The date and time when the historical price ID was excluded. + example: 2025-11-10T23:00:00Z + format: date-time + type: string + exclusionReason: + description: The reason for excluding this historical price ID. + example: Incorrect contextID value + type: string required: - - contextId + - contextIds - id - metadata - observedAt @@ -38911,9 +45689,13 @@ components: discountValue: 6.027456183070403 - campaignId: 0 discountValue: 6.027456183070403 - observedAt: 2020-11-10T23:00:00Z + observedAt: 2025-11-10T23:00:00Z price: 99.99 - contextId: Summer Sale 2025 + exclusionReason: Incorrect contextID value + excludedAt: 2025-11-10T23:00:00Z + contextIds: + - SpringSale + - SummerSale2025 id: 1 target: '{}' - metadata: @@ -38926,16 +45708,20 @@ components: discountValue: 6.027456183070403 - campaignId: 0 discountValue: 6.027456183070403 - observedAt: 2020-11-10T23:00:00Z + observedAt: 2025-11-10T23:00:00Z price: 99.99 - contextId: Summer Sale 2025 + exclusionReason: Incorrect contextID value + excludedAt: 2025-11-10T23:00:00Z + contextIds: + - SpringSale + - SummerSale2025 id: 1 target: '{}' - sku: "" + sku: SKU1241028 properties: sku: description: The SKU of the item for which historical prices should be retrieved. - example: "" + example: SKU1241028 type: string history: items: @@ -38945,6 +45731,37 @@ components: - history - sku type: object + ExcludePriceObservationsRequest: + example: + reason: Incorrect contextID value. + ids: + - 1 + - 1 + - 1 + - 1 + - 1 + properties: + ids: + description: | + A list of historical price IDs to exclude from best prior price calculation. Must contain between 1 and 1000 IDs. All IDs must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, and must not already be excluded from best prior price calculation. + items: + format: int64 + minimum: 1 + type: integer + maxItems: 1000 + minItems: 1 + type: array + uniqueItems: true + reason: + description: | + The reason for excluding these historical price IDs. Applies to all IDs in the batch. + example: Incorrect contextID value. + minLength: 1 + type: string + required: + - ids + - reason + type: object TalangAttribute: properties: entity: @@ -38970,6 +45787,8 @@ components: - Session - Store - Achievements + - AdvancedEvent + - AdvancedEventConnectedSession type: string name: description: | @@ -39240,6 +46059,31 @@ components: required: - sku type: object + CatalogActionAdd: + description: Adds an item to the catalog. + example: + type: ADD + payload: + sku: T123 + attributes: + type: shoes + color: blue + replaceIfExists: true + properties: + type: + description: A catalog sync action discriminator of type `ADD`. + enum: + - ADD + type: string + payload: + $ref: '#/components/schemas/AddItemCatalogAction' + required: + - payload + - type + title: Add + type: object + x-discriminator-value: ADD + x-ms-discriminator-value: ADD PatchItemCatalogAction: description: | The specific properties of the "PATCH" catalog sync action. @@ -39268,6 +46112,23 @@ components: required: - sku type: object + CatalogActionPatch: + description: Updates an item in the catalog. + properties: + type: + description: A catalog sync action discriminator of type `PATCH`. + enum: + - PATCH + type: string + payload: + $ref: '#/components/schemas/PatchItemCatalogAction' + required: + - payload + - type + title: Patch + type: object + x-discriminator-value: PATCH + x-ms-discriminator-value: PATCH CatalogActionFilter: description: The properties for a single filtering condition in a catalog sync action. @@ -39313,6 +46174,23 @@ components: properties: {} type: object type: object + CatalogActionPatchMany: + description: Updates the items of the catalog that match the given filters. + properties: + type: + description: A catalog sync action discriminator of type `PATCH_MANY`. + enum: + - PATCH_MANY + type: string + payload: + $ref: '#/components/schemas/PatchManyItemsCatalogAction' + required: + - payload + - type + title: PatchMany + type: object + x-discriminator-value: PATCH_MANY + x-ms-discriminator-value: PATCH_MANY RemoveItemCatalogAction: description: The specific properties of the "REMOVE" catalog sync action. properties: @@ -39322,6 +46200,23 @@ components: required: - sku type: object + CatalogActionRemove: + description: Removes an item from the catalog. + properties: + type: + description: A catalog sync action discriminator of type `REMOVE`. + enum: + - REMOVE + type: string + payload: + $ref: '#/components/schemas/RemoveItemCatalogAction' + required: + - payload + - type + title: Remove + type: object + x-discriminator-value: REMOVE + x-ms-discriminator-value: REMOVE RemoveManyItemsCatalogAction: description: The specific properties of the "REMOVE_MANY" catalog sync action. properties: @@ -39334,6 +46229,23 @@ components: $ref: '#/components/schemas/CatalogActionFilter' type: array type: object + CatalogActionRemoveMany: + description: Removes the items of the catalog that match the given filters. + properties: + type: + description: A catalog sync action discriminator of type `REMOVE_MANY`. + enum: + - REMOVE_MANY + type: string + payload: + $ref: '#/components/schemas/RemoveManyItemsCatalogAction' + required: + - payload + - type + title: RemoveMany + type: object + x-discriminator-value: REMOVE_MANY + x-ms-discriminator-value: REMOVE_MANY NewPriceAdjustment: properties: priceType: @@ -39397,9 +46309,28 @@ components: - adjustments - sku type: object + CatalogActionAddPriceAdjustment: + description: Adds price adjustments to an item of the catalog. + properties: + type: + description: A catalog sync action discriminator of type `ADD_PRICE_ADJUSTMENT`. + enum: + - ADD_PRICE_ADJUSTMENT + type: string + payload: + $ref: '#/components/schemas/AddPriceAdjustmentCatalogAction' + required: + - payload + - type + title: AddPriceAdjustment + type: object + x-discriminator-value: ADD_PRICE_ADJUSTMENT + x-ms-discriminator-value: ADD_PRICE_ADJUSTMENT CatalogAction: description: Definition of all the properties that are needed for a single catalog - sync action. + sync action. The `type` field selects the concrete action variant. + discriminator: + propertyName: type example: payload: '{}' type: ADD @@ -39418,10 +46349,11 @@ components: payload: properties: {} type: object - required: - - payload - - type type: object + x-go-merge-oneof: + properties: + type: + description: The type of sync action. CatalogSyncRequest: example: actions: @@ -39672,8 +46604,61 @@ components: - type - webhooks type: object - WebhookAuthenticationBase: + WebhookAuthenticationBaseBasic: + description: Authenticates the webhook with Basic HTTP authentication. + properties: + name: + description: The name of the webhook authentication. + example: My basic auth + type: string + type: + description: A webhook authentication discriminator of type `basic`. + enum: + - basic + type: string + data: + $ref: '#/components/schemas/WebhookAuthenticationDataBasic' + required: + - data + - name + - type + title: Basic + type: object + x-discriminator-value: basic + x-ms-discriminator-value: basic + WebhookAuthenticationBaseCustom: + description: Authenticates the webhook with a custom set of HTTP headers. + properties: + name: + description: The name of the webhook authentication. + example: My custom auth + type: string + type: + description: A webhook authentication discriminator of type `custom`. + enum: + - custom + type: string + data: + $ref: '#/components/schemas/WebhookAuthenticationDataCustom' + required: + - data + - name + - type + title: Custom type: object + x-discriminator-value: custom + x-ms-discriminator-value: custom + WebhookAuthenticationBase: + description: Definition of all the properties that are needed to create or update + a webhook authentication. The `type` field selects the concrete authentication + variant. + discriminator: + propertyName: type + type: object + x-go-merge-oneof: + properties: + type: + description: The type of authentication. MessageLogRequest: description: Details of the request. example: @@ -40690,6 +47675,561 @@ components: - name - value type: object + FeatureFlagUpdate: + properties: + name: + description: The name of the feature flag. + example: canCreateCampaignFromTemplate + type: string + value: + description: The value of the feature flag. + example: "true" + type: string + required: + - name + - value + type: object + NewRiskNotification: + description: Data for creating a new risk notification. + properties: + entity: + description: The entity type to analyze within the given time frame. + enum: + - customer_profile + - customer_session + example: customer_profile + type: string + activity: + description: The activity metric to analyze within the given entity. + enum: + - loyalty_points_earned + - discounted_amount + - completed_orders + - coupon_attempts + example: loyalty_points_earned + type: string + timeFrame: + description: The rolling time window for risk evaluation. + enum: + - 1D + - 7D + - 30D + example: 7D + type: string + required: + - activity + - entity + - timeFrame + type: object + RiskNotification: + description: A risk notification configuration rule. + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + entity: + description: The entity type to analyze within the given time frame. + enum: + - customer_profile + - customer_session + example: customer_profile + type: string + activity: + description: The activity metric to analyze within the given entity. + enum: + - loyalty_points_earned + - discounted_amount + - completed_orders + - coupon_attempts + example: loyalty_points_earned + type: string + timeFrame: + description: The rolling time window for risk evaluation. + enum: + - 1D + - 7D + - 30D + example: 7D + type: string + active: + description: Indicates whether this risk notification is active. + example: true + type: boolean + modified: + description: Timestamp of the most recent update. + example: 2026-04-16T09:05:27.993483Z + format: date-time + type: string + required: + - active + - activity + - created + - entity + - id + - modified + - timeFrame + type: object + UpdateRiskNotification: + description: Data for updating a risk notification. + properties: + entity: + description: The entity type to analyze within the given time frame. + enum: + - customer_profile + - customer_session + example: customer_profile + type: string + activity: + description: The activity metric to analyze within the given entity. + enum: + - loyalty_points_earned + - discounted_amount + - completed_orders + - coupon_attempts + example: loyalty_points_earned + type: string + timeFrame: + description: The rolling time window for risk evaluation. + enum: + - 1D + - 7D + - 30D + example: 7D + type: string + active: + description: Indicates whether this risk notification is active. + example: true + type: boolean + required: + - active + - activity + - entity + - timeFrame + type: object + Risk: + description: A risk detected by the anomaly detection service for one Application + group. + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + notificationId: + description: The ID of the risk notification rule that flagged this risk. + example: 3 + format: int64 + type: integer + featureDate: + description: | + The date of the activity data in which this risk was detected. The anomaly + detection pipeline scores complete 24-hour cycles, so this is always the day + before the risk was reported, not the reporting date itself. + example: 2026-06-05 + format: date + type: string + groupKey: + description: | + The Application group this risk was detected in. Contains the Application ID, + or `__GLOBAL__` for metrics that are not grouped by Application. + example: "7" + type: string + applicationId: + description: The ID of the Application this risk belongs to. Absent for + global metrics. + example: 7 + format: int64 + type: integer + status: + description: The triage lifecycle status of this risk. + enum: + - active + - in_review + - confirmed + - discarded + example: active + type: string + criticality: + description: The critical classification bucket of this risk. + enum: + - critical + - not_critical + example: critical + type: string + entity: + description: The entity type the risk was detected in. + enum: + - customer_profile + - customer_session + example: customer_profile + type: string + activity: + description: The activity metric the risk was detected in. + enum: + - loyalty_points_earned + - discounted_amount + - completed_orders + - coupon_attempts + example: discounted_amount + type: string + timeFrame: + description: The rolling time window of the risk evaluation. + enum: + - 1D + - 7D + - 30D + example: 7D + type: string + reportedDate: + description: The time the ML service reported this risk. + example: 2026-06-05T06:26:13.698884Z + format: date-time + type: string + affectedEntityCount: + description: The total number of entities affected by this risk. + example: 4437 + format: int64 + type: integer + description: + description: Human-readable description of the detected anomaly. + example: Unusual discount usage detected for 4437 customer profiles. + type: string + discardReason: + description: The reason this risk was discarded. Only present on discarded + risks. + enum: + - expected_behavior + - other + example: expected_behavior + type: string + statusComment: + description: | + The free-text details of the latest reclassification action: the description + for resolving confirmed risks, or the details for discarding risks. + example: Investigated with the customer and fixed the loyalty rule. + type: string + statusChangedBy: + description: The ID of the user who performed the latest reclassification + action. + example: 42 + format: int64 + type: integer + statusChangedAt: + description: The time of the latest reclassification action. + example: 2026-06-06T09:12:45Z + format: date-time + type: string + modified: + description: Timestamp of the most recent update. + example: 2026-06-05T06:26:13.698884Z + format: date-time + type: string + required: + - activity + - affectedEntityCount + - created + - criticality + - entity + - featureDate + - groupKey + - id + - modified + - notificationId + - reportedDate + - status + - timeFrame + type: object + RiskCriticalityUpdate: + properties: + riskIds: + description: The IDs of the risks to reclassify. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + maxItems: 1000 + minItems: 1 + type: array + criticality: + description: | + The criticality to assign to risks. Only `not_critical` is accepted: critical risks can be + reclassified as non-critical, but not the other way around. + enum: + - not_critical + example: not_critical + type: string + required: + - criticality + - riskIds + type: object + ReviewRisksRequest: + properties: + riskIds: + description: The IDs of the risks to move to `In review` status. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + maxItems: 1000 + minItems: 1 + type: array + required: + - riskIds + type: object + ConfirmRisksRequest: + properties: + riskIds: + description: The IDs of the risks to confirm. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + maxItems: 1000 + minItems: 1 + type: array + comment: + description: Free-text description of how the risk was resolved. + example: Investigated with the customer and fixed the loyalty rule. + minLength: 1 + type: string + required: + - comment + - riskIds + type: object + DiscardRisksRequest: + properties: + riskIds: + description: The IDs of the risks to discard. + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + maxItems: 1000 + minItems: 1 + type: array + reason: + description: The reason the risks are being discarded. + enum: + - expected_behavior + - other + example: expected_behavior + type: string + comment: + description: | + Free-text description of why the risks are being discarded. Required when `reason` is `other`, optional for + `expected_behavior`. + example: Duplicate of a risk already being handled. + type: string + required: + - reason + - riskIds + type: object + RiskAffectedEntityItem: + description: A single entity flagged as anomalous within a risk. + properties: + entityId: + description: The integration ID of the affected entity. + example: "174165415" + type: string + activityValue: + description: The observed value of the monitored activity metric for this + entity. + example: 2898.2 + format: double + type: number + threshold: + description: The anomaly threshold computed for the entity's Application + group. + example: 60.0 + format: double + type: number + severityRatio: + description: The ratio of the observed value to the threshold. + example: 48.3 + format: double + type: number + criticality: + description: The critical classification bucket of this entity. + enum: + - critical + - not_critical + example: critical + type: string + required: + - activityValue + - criticality + - entityId + - severityRatio + - threshold + type: object + RiskDetail: + description: Details of a risk, including its most severely affected entities. + properties: + id: + description: The internal ID of this entity. + example: 6 + format: int64 + type: integer + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + notificationId: + description: The ID of the risk notification rule that flagged this risk. + example: 3 + format: int64 + type: integer + featureDate: + description: | + The date of the activity data in which this risk was detected. The anomaly + detection pipeline scores complete 24-hour cycles, so this is always the day + before the risk was reported, not the reporting date itself. + example: 2026-06-05 + format: date + type: string + groupKey: + description: | + The Application group this risk was detected in. Contains the Application ID, + or `__GLOBAL__` for metrics that are not grouped by Application. + example: "7" + type: string + applicationId: + description: The ID of the Application this risk belongs to. Absent for + global metrics. + example: 7 + format: int64 + type: integer + status: + description: The triage lifecycle status of this risk. + enum: + - active + - in_review + - confirmed + - discarded + example: active + type: string + criticality: + description: The critical classification bucket of this risk. + enum: + - critical + - not_critical + example: critical + type: string + entity: + description: The entity type the risk was detected in. + enum: + - customer_profile + - customer_session + example: customer_profile + type: string + activity: + description: The activity metric the risk was detected in. + enum: + - loyalty_points_earned + - discounted_amount + - completed_orders + - coupon_attempts + example: discounted_amount + type: string + timeFrame: + description: The rolling time window of the risk evaluation. + enum: + - 1D + - 7D + - 30D + example: 7D + type: string + reportedDate: + description: The time the ML service reported this risk. + example: 2026-06-05T06:26:13.698884Z + format: date-time + type: string + affectedEntityCount: + description: The total number of entities affected by this risk. + example: 4437 + format: int64 + type: integer + description: + description: Human-readable description of the detected anomaly. + example: Unusual discount usage detected for 4437 customer profiles. + type: string + discardReason: + description: The reason this risk was discarded. Only present on discarded + risks. + enum: + - expected_behavior + - other + example: expected_behavior + type: string + statusComment: + description: | + The free-text details of the latest reclassification action: the description + for resolving confirmed risks, or the details for discarding risks. + example: Investigated with the customer and fixed the loyalty rule. + type: string + statusChangedBy: + description: The ID of the user who performed the latest reclassification + action. + example: 42 + format: int64 + type: integer + statusChangedAt: + description: The time of the latest reclassification action. + example: 2026-06-06T09:12:45Z + format: date-time + type: string + modified: + description: Timestamp of the most recent update. + example: 2026-06-05T06:26:13.698884Z + format: date-time + type: string + affectedEntities: + description: The affected entities with the highest severity ratios, in + descending order. + items: + $ref: '#/components/schemas/RiskAffectedEntityItem' + type: array + required: + - activity + - affectedEntities + - affectedEntityCount + - created + - criticality + - entity + - featureDate + - groupKey + - id + - modified + - notificationId + - reportedDate + - status + - timeFrame + type: object Change: example: new: @@ -41472,15 +49012,6 @@ components: - logicalOperations - name type: object - RolesV2Thresholds: - properties: - loyaltyPointsLimit: - description: Maximum number of loyalty points a support user can award without - approval. - example: 100 - format: int64 - type: integer - type: object RoleV2ApplicationDetails: properties: application: @@ -41498,8 +49029,6 @@ components: description: Name of the tools-related permission set. example: Tools permission set type: string - thresholds: - $ref: '#/components/schemas/RolesV2Thresholds' type: object RoleV2Application: additionalProperties: @@ -41589,8 +49118,32 @@ components: description: Name of the account-level permission set type: string type: object + RolesV2Thresholds: + example: + loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + properties: + loyaltyProgramId: + description: Identifier of the loyalty program. You can get the ID with + the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) + endpoint. + example: 8 + format: int64 + type: integer + loyaltyPointsLimit: + description: Maximum number of loyalty points a support user can award without + approval. + example: 100 + format: int64 + type: integer + type: object RoleV2Permissions: example: + thresholds: + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 permissionSets: - name: Application permission set logicalOperations: @@ -41657,10 +49210,21 @@ components: type: array roles: $ref: '#/components/schemas/RoleV2RolesGroup' + thresholds: + description: Support user limits for actions that require admin approval + within the given application. + items: + $ref: '#/components/schemas/RolesV2Thresholds' + type: array type: object RoleV2Base: example: permissions: + thresholds: + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 permissionSets: - name: Application permission set logicalOperations: @@ -41743,6 +49307,11 @@ components: isReadonly: false created: 2020-06-10T09:05:27.993483Z permissions: + thresholds: + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 permissionSets: - name: Application permission set logicalOperations: @@ -42444,6 +50013,240 @@ components: - key - name type: object + MCPOAuthTokenRequest: + properties: + grant_type: + description: OAuth2 grant type. + enum: + - authorization_code + - refresh_token + example: authorization_code + type: string + code: + description: Authorization code. Required for `authorization_code` grant. + example: 4a3b2c1d9e6f78901234567890abcdef + type: string + client_id: + description: Client ID. Required for `authorization_code` grant. + example: a3f8c1e2b4d56789 + type: string + redirect_uri: + description: Redirect URI. Required for `authorization_code` grant. + example: http://localhost:3000/callback + type: string + code_verifier: + description: PKCE code verifier. Required for `authorization_code` grant. + example: dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk + type: string + refresh_token: + description: Refresh token. Required for `refresh_token` grant. + example: mcpor:9f8e7d6c + type: string + required: + - grant_type + type: object + MCPOAuthToken: + properties: + access_token: + description: Bearer access token. + example: mcpoa:4a3b2c1d... + type: string + token_type: + description: Token type. Always "Bearer". + enum: + - Bearer + example: Bearer + type: string + expires_in: + description: Seconds until the access token expires. + example: 3600 + format: int64 + type: integer + refresh_token: + description: Refresh token for obtaining a new access token. + example: mcpor:9f8e7d6c... + type: string + refresh_token_expires_in: + description: Seconds until the refresh token expires. + example: 2592000 + format: int64 + type: integer + required: + - access_token + - expires_in + - refresh_token + - refresh_token_expires_in + - token_type + type: object + MCPOAuthTokenError: + properties: + error: + description: RFC 6749 §5.2 error code. + enum: + - invalid_request + - invalid_client + - invalid_grant + - unsupported_grant_type + example: invalid_grant + type: string + error_description: + description: Human-readable description of the error. + example: authorization code is invalid, already used, or expired + type: string + required: + - error + type: object + NewMCPOAuthClient: + properties: + client_name: + description: Human-readable name for the OAuth2 client. + example: My MCP Integration + type: string + redirect_uris: + description: List of allowed redirect URIs for the authorization code flow. + At least one URI is required. + example: + - http://localhost:3000/callback + items: + type: string + minItems: 1 + type: array + required: + - client_name + - redirect_uris + type: object + MCPOAuthClient: + properties: + client_id: + description: Unique identifier for the OAuth2 client. + example: a3f8c1e2b4d56789 + type: string + client_name: + description: Human-readable name for the OAuth2 client. + example: My MCP Integration + type: string + redirect_uris: + description: List of allowed redirect URIs for the authorization code flow. + example: + - https://example.com/callback + - http://localhost:3000/callback + items: + type: string + type: array + created_at: + description: Timestamp of when the client was registered. + example: 2026-06-12T10:00:00Z + format: date-time + type: string + required: + - client_id + - client_name + - created_at + - redirect_uris + type: object + MCPCompleteOAuthSession: + properties: + sessionId: + description: The pending authorization session ID to complete. + example: a3f8c1e2b4d567890123456789abcdef + type: string + required: + - sessionId + type: object + MCPOAuthCompleteResult: + properties: + redirectUrl: + description: The full redirect URL the browser should be sent to, containing + the authorization code and state as query parameters. + example: http://localhost:3000/callback?code=abc123&state=xyz + type: string + required: + - redirectUrl + type: object + MCPOAuthSessionInfo: + properties: + session_id: + description: The identifier of the authorization session. + example: a3f8c1e2b4d567890123456789abcdef + type: string + expires_at: + description: The date and time at which the session expires. Date and time. + Follows RFC3339 format. + example: 2016-03-28T08:34:32Z + format: date-time + type: string + client: + $ref: '#/components/schemas/MCPOAuthClient' + required: + - client + - session_id + type: object + MCPOAuthProtectedResource: + properties: + resource: + description: The URL of the protected resource (the MCP entrypoint). + example: https://mycompany.talon.one/v1/mcp/entrypoint + type: string + authorization_servers: + description: List of authorization server base URLs that can issue tokens + for this resource. + example: + - https://mycompany.talon.one/v1/mcp/auth + items: + type: string + type: array + required: + - authorization_servers + - resource + type: object + MCPOAuthServerMetadata: + properties: + issuer: + description: The authorization server's issuer identifier (its base URL). + example: https://mycompany.talon.one + type: string + authorization_endpoint: + description: URL of the authorization endpoint. + example: https://mycompany.talon.one/v1/mcp/auth/authorize + type: string + token_endpoint: + description: URL of the token endpoint. + example: https://mycompany.talon.one/v1/mcp/auth/token + type: string + registration_endpoint: + description: URL of the client registration endpoint. + example: https://mycompany.talon.one/v1/mcp/auth/register + type: string + response_types_supported: + description: List of supported OAuth2 response types. + example: + - code + items: + type: string + type: array + grant_types_supported: + description: List of supported OAuth2 grant types. + example: + - authorization_code + items: + type: string + type: array + code_challenge_methods_supported: + description: List of supported PKCE code challenge methods. + example: + - S256 + items: + type: string + type: array + required: + - authorization_endpoint + - code_challenge_methods_supported + - grant_types_supported + - issuer + - registration_endpoint + - response_types_supported + - token_endpoint + type: object NewValueMap: type: object ValueMap: @@ -42696,7 +50499,7 @@ components: - - - Item - - catch - false - - - = + - - contains - - "." - Item - Category @@ -42716,7 +50519,7 @@ components: - - - Item - - catch - false - - - = + - - contains - - "." - Item - Category @@ -42759,7 +50562,7 @@ components: - - - Item - - catch - false - - - = + - - contains - - "." - Item - Category @@ -42847,7 +50650,7 @@ components: - - - Item - - catch - false - - - = + - - contains - - "." - Item - Category @@ -43135,6 +50938,37 @@ components: - imported - storeCount type: object + CampaignLoyaltyProgram: + description: A loyalty program referenced in a campaign. + properties: + id: + description: The ID of the loyalty program. + example: 5 + format: int64 + type: integer + name: + description: The name of the loyalty program. + example: My program + type: string + tiers: + description: The names of the tiers in the loyalty program. + example: + - Silver + - Gold + - Platinum + items: + type: string + type: array + cardBased: + description: Whether the loyalty program is card-based. + example: false + type: boolean + required: + - cardBased + - id + - name + - tiers + type: object UpdateAchievement: example: fixedStartDate: 2000-01-23T04:56:07.000+00:00 @@ -43349,13 +51183,6 @@ components: achievements. example: false type: boolean - sandbox: - description: Indicates if this achievement is a live or sandbox achievement. - Achievements of a given type can only be connected to Applications of - the same type. - example: true - title: Sandbox - type: boolean subscribedApplications: description: A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to @@ -43368,11 +51195,6 @@ components: type: integer minItems: 0 type: array - timezone: - description: A string containing an IANA timezone descriptor. - example: Europe/Berlin - minLength: 1 - type: string type: object AchievementAdditionalPropertiesV2: properties: @@ -43388,22 +51210,61 @@ components: **Note**: This is not available if the user has been deleted. example: John Doe type: string + periodEndOverride: + $ref: '#/components/schemas/TimePoint' hasProgress: description: Indicates if a customer has made progress in the achievement. type: boolean status: - description: The status of the achievement. + description: "The status of the achievement. \ + \ \n\ + - `active`: The achievement is available to customers.\n- `scheduled`:\ + \ The achievement has a `fixedStartDate` set in the future.\n- `expired`:\ + \ The achievement's `endDate` is in the past.\n" enum: - - inprogress + - active + - scheduled - expired - - not_started - - completed - example: inprogress + example: active type: string required: - userId type: object AchievementV2: + example: + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + period: 1Y + endDate: 2024-01-15T15:04:05+07:00 + created: 2020-06-10T09:05:27.993483Z + timezone: Europe/Berlin + campaignId: 3 + sandbox: true + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + userId: 1234 + hasProgress: true + target: 50.0 + subscribedApplications: + - 132 + - 97 + fixedStartDate: 2024-01-15T15:04:05+07:00 + createdBy: John Doe + name: Order50Discount + periodEndOverride: + month: 11 + dayOfMonth: 23 + hour: 23 + minute: 59 + second: 59 + id: 6 + recurrencePolicy: no_recurrence + status: active properties: id: description: The internal ID of this entity. @@ -43511,13 +51372,6 @@ components: achievements. example: false type: boolean - sandbox: - description: Indicates if this achievement is a live or sandbox achievement. - Achievements of a given type can only be connected to Applications of - the same type. - example: true - title: Sandbox - type: boolean subscribedApplications: description: A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to @@ -43530,11 +51384,6 @@ components: type: integer minItems: 0 type: array - timezone: - description: A string containing an IANA timezone descriptor. - example: Europe/Berlin - minLength: 1 - type: string userId: description: The ID of the user that created this achievement. example: 1234 @@ -43547,18 +51396,49 @@ components: **Note**: This is not available if the user has been deleted. example: John Doe type: string + periodEndOverride: + $ref: '#/components/schemas/TimePoint' hasProgress: description: Indicates if a customer has made progress in the achievement. type: boolean status: - description: The status of the achievement. + description: "The status of the achievement. \ + \ \n\ + - `active`: The achievement is available to customers.\n- `scheduled`:\ + \ The achievement has a `fixedStartDate` set in the future.\n- `expired`:\ + \ The achievement's `endDate` is in the past.\n" enum: - - inprogress + - active + - scheduled - expired - - not_started - - completed - example: inprogress + example: active + type: string + sandbox: + description: Indicates if this achievement is a live or sandbox achievement. + Achievements of a given type can only be connected to Applications of + the same type. + example: true + title: Sandbox + type: boolean + timezone: + description: A string containing an IANA timezone descriptor. + example: Europe/Berlin + minLength: 1 type: string + campaignId: + description: This property is **deprecated**. Use `referencedByCampaigns` + instead. This field contains the first campaign ID from the related `referencedByCampaigns`, + and is omitted when `referencedByCampaigns` is empty. + example: 3 + format: int64 + type: integer + x-deprecated: true + referencedByCampaigns: + description: The campaigns that reference this achievement. They are sorted + in ascending order by their id. + items: + $ref: '#/components/schemas/CampaignReference' + type: array required: - activationPolicy - created @@ -43566,6 +51446,7 @@ components: - id - name - recurrencePolicy + - referencedByCampaigns - sandbox - subscribedApplications - target @@ -43574,6 +51455,22 @@ components: - userId type: object CreateAchievementV2: + example: + period: 1Y + endDate: 2024-01-15T15:04:05+07:00 + timezone: Europe/Berlin + sandbox: true + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 50.0 + subscribedApplications: + - 132 + - 97 + fixedStartDate: 2024-01-15T15:04:05+07:00 + name: Order50Discount + recurrencePolicy: no_recurrence properties: name: description: | @@ -43671,13 +51568,6 @@ components: achievements. example: false type: boolean - sandbox: - description: Indicates if this achievement is a live or sandbox achievement. - Achievements of a given type can only be connected to Applications of - the same type. - example: true - title: Sandbox - type: boolean subscribedApplications: description: A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to @@ -43690,6 +51580,13 @@ components: type: integer minItems: 0 type: array + sandbox: + description: Indicates if this achievement is a live or sandbox achievement. + Achievements of a given type can only be connected to Applications of + the same type. + example: true + title: Sandbox + type: boolean timezone: description: A string containing an IANA timezone descriptor. example: Europe/Berlin @@ -43704,6 +51601,20 @@ components: - title type: object UpdateAchievementV2: + example: + fixedStartDate: 2024-01-15T15:04:05+07:00 + period: 1Y + endDate: 2024-01-15T15:04:05+07:00 + name: Order50Discount + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 50.0 + recurrencePolicy: no_recurrence + subscribedApplications: + - 132 + - 97 properties: name: description: | @@ -43797,16 +51708,9 @@ components: format: date-time type: string allowRollbackAfterCompletion: - description: When `true`, customer progress can be rolled back in completed - achievements. - example: false - type: boolean - sandbox: - description: Indicates if this achievement is a live or sandbox achievement. - Achievements of a given type can only be connected to Applications of - the same type. - example: true - title: Sandbox + description: When `true`, customer progress can be rolled back in completed + achievements. + example: false type: boolean subscribedApplications: description: A list containing the IDs of all applications that are subscribed @@ -43820,11 +51724,12 @@ components: type: integer minItems: 0 type: array - timezone: - description: A string containing an IANA timezone descriptor. - example: Europe/Berlin - minLength: 1 - type: string + required: + - description + - name + - subscribedApplications + - target + - title type: object AchievementReference: properties: @@ -43851,11 +51756,25 @@ components: example: 4501 format: int64 type: integer + campaignName: + description: The name of the campaign that references this achievement. + example: Summer promotions + type: string + campaignState: + description: The state of the campaign that references this achievement. + enum: + - enabled + - disabled + - archived + example: enabled + type: string required: - achievementId - applicationId - applicationName - campaignId + - campaignName + - campaignState type: object AnalyticsDataPoint: properties: @@ -44029,1188 +51948,2912 @@ components: format: int64 type: integer required: - - value + - value + type: object + AnalyticsProduct: + properties: + id: + description: The ID of the product. + example: 1 + format: int64 + type: integer + name: + description: The name of the product. + example: MyProduct + type: string + catalogId: + description: | + The ID of the catalog. You can find the ID in the Campaign Manager in **Account** > **Tools** > **Cart item catalogs**. + example: 1 + format: int64 + type: integer + unitsSold: + $ref: '#/components/schemas/AnalyticsDataPointWithTrend' + required: + - catalogId + - id + - name + type: object + ProductUnitAnalyticsDataPoint: + properties: + startTime: + description: The start of the aggregation time frame in UTC. + example: 2024-02-01T00:00:00Z + format: date-time + type: string + endTime: + description: The end of the aggregation time frame in UTC. + format: date-time + type: string + unitsSold: + $ref: '#/components/schemas/AnalyticsDataPointWithTrend' + productId: + description: The ID of the product. + example: 1 + format: int64 + type: integer + productName: + description: The name of the product. + example: MyProduct + type: string + required: + - endTime + - productId + - productName + - startTime + - unitsSold + type: object + ProductUnitAnalytics: + properties: + data: + items: + $ref: '#/components/schemas/ProductUnitAnalyticsDataPoint' + type: array + totals: + $ref: '#/components/schemas/ProductUnitAnalytics_totals' + required: + - data + - totals + type: object + AnalyticsSKU: + properties: + id: + description: The ID of the SKU linked to the Application. + example: 1 + format: int64 + type: integer + sku: + description: The SKU linked to the Application. + example: SKU-123 + type: string + lastUpdated: + description: Values in UTC for the date the SKU linked to the product was + last updated. + example: 2024-02-01T00:00:00Z + format: date-time + type: string + catalogId: + description: The ID of the catalog that contains the SKU. + example: 1 + format: int64 + type: integer + productId: + description: The ID of the product that the SKU belongs to. + example: 1 + format: int64 + type: integer + unitsSold: + $ref: '#/components/schemas/AnalyticsDataPointWithTrend' + required: + - id + - sku + type: object + SkuUnitAnalyticsDataPoint: + properties: + startTime: + description: The start of the aggregation time frame in UTC. + example: 2024-02-01T00:00:00Z + format: date-time + type: string + endTime: + description: The end of the aggregation time frame in UTC. + format: date-time + type: string + unitsSold: + $ref: '#/components/schemas/AnalyticsDataPointWithTrend' + sku: + description: The SKU linked to the application. + example: SKU-123 + type: string + required: + - endTime + - sku + - startTime + - unitsSold + type: object + SkuUnitAnalytics: + properties: + data: + items: + $ref: '#/components/schemas/SkuUnitAnalyticsDataPoint' + type: array + totals: + $ref: '#/components/schemas/ProductUnitAnalytics_totals' + required: + - data + - totals + type: object + GenerateCampaignDescription: + properties: + campaignID: + description: ID of a campaign. + format: int64 + type: integer + rulesetID: + description: ID of a ruleset. + format: int64 + type: integer + currency: + description: Currency for the campaign. + type: string + required: + - campaignID + - currency + - rulesetID + type: object + GenerateCampaignTags: + properties: + rulesetID: + description: ID of a ruleset. + format: int64 + type: integer + required: + - rulesetID + type: object + GenerateItemFilterDescription: + properties: + itemFilter: + description: An array of item filter Talang expressions. + example: + - filter + - - "." + - Session + - CartItems + - - - Item + - - catch + - false + - - and + - - '!=' + - - "." + - Item + - Attributes + - c_productType + - egiftcard + items: + properties: {} + type: object + type: array + required: + - itemFilter + type: object + GenerateCampaignSummary: + properties: + campaignID: + description: ID of a campaign. + format: int64 + type: integer + rulesetID: + description: ID of a ruleset. + format: int64 + type: integer + currency: + description: Currency for the campaign. + type: string + required: + - campaignID + - currency + - rulesetID + type: object + GenerateUserSessionSummary: + properties: + sessionID: + description: The ID of the session. + type: string + applicationID: + description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + type: number + required: + - applicationID + - sessionID + type: object + GenerateAuditLogSummary: + properties: + logID: + description: The ID of the audit log. + format: int64 + type: integer + required: + - logID + type: object + GenerateCouponFailureSummary: + properties: + eventID: + description: The ID of the event. + format: int64 + type: integer + language: + description: The language the summary will be generated in. + example: en + type: string + required: + - eventID + type: object + CouponFailureSummary: + description: Summary of the reasons for coupon redemption failure. + example: + summary: Session total was less than the required total. + eventID: 1011 + createdAt: 2021-07-20T21:59:00Z + profileID: a48f10dddb5c9493aad194e49bb9c1dac + language: en + id: 1 + sessionID: "1" + couponCode: ABC123 + status: rejected + updatedAt: 2021-07-20T21:59:00Z + properties: + id: + description: ID of the evaluation record. + example: 1 + format: int64 + type: integer + eventID: + description: ID of the event. + example: 1011 + format: int64 + type: integer + sessionID: + description: ID of the customer session set by your integration layer. + example: "1" + type: string + profileID: + description: ID of the customer profile set by your integration layer. + example: a48f10dddb5c9493aad194e49bb9c1dac + type: string + status: + description: Status defines if the coupon code was applied or rejected. + example: rejected + type: string + couponCode: + description: Coupon code passed for evaluation. + example: ABC123 + type: string + language: + description: Language of the summary. + example: en + type: string + summary: + description: A summary of the reasons for coupon redemption failure. + example: Session total was less than the required total. + type: string + createdAt: + description: Timestamp when the request was made. + example: 2021-07-20T21:59:00Z + format: date-time + type: string + updatedAt: + description: Timestamp when the request was last updated. + example: 2021-07-20T21:59:00Z + format: date-time + type: string + required: + - couponCode + - createdAt + - eventID + - id + - language + - status + - summary + - updatedAt + type: object + GenerateCouponFailureDetailedSummary: + properties: + applicationID: + description: The ID of the Application. It is displayed in your Talon.One + deployment URL. + type: number + sessionID: + description: ID of the customer session where the coupon redemption failed. + example: 05c2da0d-48fa-4aa1-b629-898f58f1584d + maxLength: 255 + type: string + eventID: + description: The ID of the event for which the coupon redemption failed. + format: int64 + type: integer + coupon: + description: The coupon code that could not be redeemed. + example: BKDB946 + type: string + language: + description: The language of the summary. + example: en + type: string + required: + - applicationID + - coupon + - eventID + - sessionID + type: object + CampaignLogSummary: + description: Campaign Log Summary + properties: + name: + description: Name of the user that performed the change. + example: Admin + type: string + email: + description: E-mail of the user that performed the change. + example: admin@talon.one + type: string + created: + description: Date and time the change was performed. + format: date-time + type: string + action: + description: Action performed by the user. + enum: + - create + - delete + - update + example: create + type: string + summary: + description: AI-generated summary of the action performed. + type: string + required: + - action + - created + - email + - name + - summary + type: object + IntegrationHubEventType: + description: The type of integration hub event. + enum: + - LoyaltyPointsChanged + - LoyaltyTierDowngrade + - LoyaltyTierUpgrade + - CouponCreated + - CouponUpdated + - CouponDeleted + example: CouponCreated + type: string + x-generate-enum-go: true + IntegrationHubFlowConfigResponse: + properties: + WorkerCount: + description: Number of IntegrationHub workers to run in parallel for this + flow (maximum 500). + format: int64 + maximum: 5E+2 + minimum: 1 + type: integer + MaxEventsPerMessage: + description: Maximum number of events to send in a single message to IntegrationHub. + format: int64 + minimum: 1 + type: integer + MaxRetries: + description: Maximum number of retries for a IntegrationHub event before + it is ignored. + format: int64 + minimum: 0 + type: integer + type: object + IntegrationHubFlowResponse: + properties: + id: + description: ID of the integration hub flow. + format: int64 + type: integer + integrationName: + description: Name of the integration. + type: string + instanceName: + description: Name of the integration instance. + type: string + createdAt: + description: Timestamp when the flow was created. + format: date-time + type: string + disabledUntil: + description: Timestamp until which the flow is disabled. Null when the flow + is active. + format: date-time + nullable: true + type: string + applicationId: + description: ID of the application the flow is registered for. + example: 54 + format: int64 + type: integer + loyaltyProgramId: + description: ID of the loyalty program the flow is registered for. + example: 12 + format: int64 + type: integer + eventType: + description: The event type we want to register a flow for. + type: string + x-fieldType: IntegrationHubEventType + config: + $ref: '#/components/schemas/IntegrationHubFlowConfigResponse' + required: + - config + - createdAt + - eventType + - id + type: object + IntegrationHubFlowConfig: + properties: + ApiKey: + type: string + WorkerCount: + default: 10 + description: Number of IntegrationHub workers to run in parallel for this + flow (maximum 500). + format: int64 + maximum: 5E+2 + minimum: 1 + type: integer + MaxEventsPerMessage: + default: 1000 + description: Maximum number of events to send in a single message to IntegrationHub. + format: int64 + minimum: 1 + type: integer + MaxRetries: + default: 10 + description: Maximum number of retries for a IntegrationHub event before + it is ignored. + format: int64 + minimum: 0 + type: integer + InstanceName: + description: Name of the Prismatic instance that registered this flow. + type: string + IntegrationName: + description: Name of the Prismatic integration that registered this flow. + type: string + required: + - ApiKey + type: object + IntegrationHubFlowWithConfig: + properties: + ApplicationID: + description: ID of the application the flow is registered for. + example: 54 + format: int64 + type: integer + LoyaltyProgramID: + description: ID of the loyalty program the flow is registered for. + example: 12 + format: int64 + type: integer + EventType: + $ref: '#/components/schemas/IntegrationHubEventType' + IntegrationHubFlowUrl: + description: The URL of the integration hub flow that we want to trigger + for the event. + type: string + Config: + $ref: '#/components/schemas/IntegrationHubFlowConfig' + required: + - Config + - EventType + - IntegrationHubFlowUrl + type: object + IntegrationHubFlow: + properties: + ApplicationID: + description: ID of the application the flow is registered for. + example: 54 + format: int64 + type: integer + LoyaltyProgramID: + description: ID of the loyalty program the flow is registered for. + example: 12 + format: int64 + type: integer + EventType: + $ref: '#/components/schemas/IntegrationHubEventType' + IntegrationHubFlowUrl: + description: The URL of the integration hub flow that we want to trigger + for the event. + type: string + required: + - EventType + - IntegrationHubFlowUrl type: object - AnalyticsProduct: + IntegrationHubEventRecord: properties: id: - description: The ID of the product. - example: 1 + description: ID of the event record. format: int64 type: integer - name: - description: The name of the product. - example: MyProduct + flowId: + description: ID of the integration hub flow. + format: int64 + type: integer + integrationName: + description: Name of the integration. type: string - catalogId: - description: | - The ID of the catalog. You can find the ID in the Campaign Manager in **Account** > **Tools** > **Cart item catalogs**. - example: 1 + instanceName: + description: Name of the integration instance. + type: string + eventType: + $ref: '#/components/schemas/IntegrationHubEventType' + publishedAt: + description: Timestamp when the event was published. + format: date-time + type: string + processedAt: + description: Timestamp when the event was processed. + format: date-time + type: string + deliveredAt: + description: Timestamp when the event was delivered. + format: date-time + type: string + scheduledTo: + description: Timestamp after which the event is scheduled to be processed. + format: date-time + type: string + retry: + description: Number of delivery retries attempted. format: int64 type: integer - unitsSold: - $ref: '#/components/schemas/AnalyticsDataPointWithTrend' + payload: + description: The event payload as a formatted JSON string. + type: string required: - - catalogId + - eventType + - flowId - id - - name + - payload + - publishedAt + - retry + - scheduledTo type: object - ProductUnitAnalyticsDataPoint: + IntegrationHubEventStatusUpdate: properties: - startTime: - description: The start of the aggregation time frame in UTC. - example: 2024-02-01T00:00:00Z - format: date-time - type: string - endTime: - description: The end of the aggregation time frame in UTC. - format: date-time - type: string - unitsSold: - $ref: '#/components/schemas/AnalyticsDataPointWithTrend' - productId: - description: The ID of the product. - example: 1 + EventId: + description: The ID of the integration hub event. + example: 123 format: int64 type: integer - productName: - description: The name of the product. - example: MyProduct + Status: + description: The delivery outcome for the event. + enum: + - delivered + - failed type: string + x-generate-enum-go: true required: - - endTime - - productId - - productName - - startTime - - unitsSold + - EventId + - Status type: object - ProductUnitAnalytics: + IntegrationHubEventStatusUpdates: + items: + $ref: '#/components/schemas/IntegrationHubEventStatusUpdate' + type: array + IntegrationHubConfig: + description: Config used for accessing integrations in IntegrationHub properties: - data: - items: - $ref: '#/components/schemas/ProductUnitAnalyticsDataPoint' - type: array - totals: - $ref: '#/components/schemas/ProductUnitAnalytics_totals' + integrationHubUrl: + description: The url used to integrate the IntegrationHub Marketplace. + example: https://hub.talon.farm/ + type: string + accessToken: + description: Access token used to authenticate a user in Talon.One. + example: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9 + type: string required: - - data - - totals + - accessToken + - integrationHubUrl type: object - AnalyticsSKU: + IntegrationHubInstance: properties: - id: - description: The ID of the SKU linked to the Application. - example: 1 - format: int64 - type: integer - sku: - description: The SKU linked to the Application. - example: SKU-123 + instanceId: + description: The ID of the Prismatic integration instance. + example: aW5zdGFuY2U6MTIz type: string - lastUpdated: - description: Values in UTC for the date the SKU linked to the product was - last updated. - example: 2024-02-01T00:00:00Z - format: date-time + instanceName: + description: The name of the Prismatic integration instance. + example: Create Coupon type: string - catalogId: - description: The ID of the catalog that contains the SKU. - example: 1 + required: + - instanceId + - instanceName + type: object + IntegrationHubInstanceList: + items: + $ref: '#/components/schemas/IntegrationHubInstance' + type: array + NewIntegrationHubCoupons: + properties: + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 format: int64 + maximum: 999999 + minimum: 0 type: integer - productId: - description: The ID of the product that the SKU belongs to. - example: 1 + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 format: int64 + maximum: 999999 + minimum: 0 type: integer - unitsSold: - $ref: '#/components/schemas/AnalyticsDataPointWithTrend' - required: - - id - - sku - type: object - SkuUnitAnalyticsDataPoint: - properties: - startTime: - description: The start of the aggregation time frame in UTC. - example: 2024-02-01T00:00:00Z + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z format: date-time type: string - endTime: - description: The end of the aggregation time frame in UTC. + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z format: date-time type: string - unitsSold: - $ref: '#/components/schemas/AnalyticsDataPointWithTrend' - sku: - description: The SKU linked to the application. - example: SKU-123 - type: string - required: - - endTime - - sku - - startTime - - unitsSold - type: object - SkuUnitAnalytics: - properties: - data: + limits: + description: | + Limits configuration for a coupon. These limits will override the limits + set from the campaign. + + **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. + Only per-profile limits are allowed to be configured. items: - $ref: '#/components/schemas/SkuUnitAnalyticsDataPoint' + $ref: '#/components/schemas/LimitConfig' type: array - totals: - $ref: '#/components/schemas/ProductUnitAnalytics_totals' - required: - - data - - totals - type: object - GenerateCampaignDescription: - properties: - campaignID: - description: ID of a campaign. + applicationId: + description: The ID of the Application the coupons will belong to. + example: 1 format: int64 type: integer - rulesetID: - description: ID of a ruleset. + campaignId: + description: The ID of the Campaign the coupons will belong to. + example: 1 format: int64 type: integer - currency: - description: Currency for the campaign. + batchId: + description: An identifier for the batch of coupons being created. + example: abcdef123 type: string - required: - - campaignID - - currency - - rulesetID - type: object - GenerateCampaignTags: - properties: - rulesetID: - description: ID of a ruleset. + numberOfCoupons: + description: The number of new coupon codes to generate for the campaign. + Must be at least 1. + example: 100 format: int64 type: integer - required: - - rulesetID - type: object - GenerateItemFilterDescription: - properties: - itemFilter: - description: An array of item filter Talang expressions. + attributes: + description: Arbitrary properties associated with this item. example: - - filter - - - "." - - Session - - CartItems - - - - Item - - - catch - - false - - - and - - - '!=' - - - "." - - Item - - Attributes - - c_productType - - egiftcard + campaignSource: cep-integration + properties: {} + type: object + validCharacters: + description: | + List of characters used to generate the random parts of a code. By default, + the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. + example: + - A + - B + - C items: - properties: {} - type: object + type: string type: array + couponPattern: + description: | + The pattern used to generate coupon codes. + The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + example: CEP-####-#### + maxLength: 100 + minLength: 3 + type: string + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + title: Is reservation mandatory + type: boolean + implicitlyReserved: + description: An indication of whether the coupon is implicitly reserved + for all customers. + example: false + title: Is coupon implicitly reserved for all customers + type: boolean + recipientIntegrationId: + description: The integration ID for this coupon's beneficiary's profile. + example: URNGV8294NV + maxLength: 1000 + title: Receiving customer profile integration ID + type: string + supportRequestId: + description: The identifier of the support request to link to the coupon + creation. The request must exist and not yet be processed. + example: 42 + format: int64 + type: integer + supportRequestNote: + description: A note recorded when the linked support request is approved + or rejected. Applied when `supportRequestId` is provided. + example: Approved as compensation for the delayed order. + type: string required: - - itemFilter + - applicationId + - batchId + - campaignId + - numberOfCoupons + - usageLimit type: object - GenerateCampaignSummary: + CouponWithApplication: properties: - campaignID: - description: ID of a campaign. + id: + description: The internal ID of the coupon. + example: 6 format: int64 type: integer - rulesetID: - description: ID of a ruleset. + created: + description: The time the coupon was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time + type: string + campaignId: + description: The ID of the campaign that owns this entity. + example: 211 format: int64 + title: Campaign ID type: integer - currency: - description: Currency for the campaign. + value: + description: The coupon code. + example: XMAS-20-2021 + minLength: 4 + title: Coupon Code type: string - required: - - campaignID - - currency - - rulesetID - type: object - GenerateUserSessionSummary: - properties: - sessionID: - description: The ID of the session. + usageLimit: + description: | + The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + example: 100 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + discountLimit: + description: | + The total discount value that the code can give. Typically used to represent a gift card value. + example: 30.0 + maximum: 1E+15 + minimum: 0 + type: number + reservationLimit: + description: | + The number of reservations that can be made with this coupon code. + example: 45 + format: int64 + maximum: 999999 + minimum: 0 + type: integer + startDate: + description: Timestamp at which point the coupon becomes valid. + example: 2020-01-24T14:15:22Z + format: date-time type: string - applicationID: - description: The ID of the Application. It is displayed in your Talon.One - deployment URL. + expiryDate: + description: Expiration date of the coupon. Coupon never expires if this + is omitted. + example: 2023-08-24T14:15:22Z + format: date-time + type: string + limits: + description: | + Limits configuration for a coupon. These limits will override the limits + set from the campaign. + + **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. + Only per-profile limits are allowed to be configured. + items: + $ref: '#/components/schemas/LimitConfig' + type: array + usageCounter: + description: The number of times the coupon has been successfully redeemed. + example: 10 + format: int64 + title: Total coupon redemptions + type: integer + discountCounter: + description: The amount of discounts given on rules redeeming this coupon. + Only usable if a coupon discount budget was set for this coupon. + example: 10.0 + title: Discounts Given type: number - required: - - applicationID - - sessionID - type: object - GenerateAuditLogSummary: - properties: - logID: - description: The ID of the audit log. + discountRemainder: + description: The remaining discount this coupon can give. + example: 5.0 + title: Coupon Discount Remainder + type: number + reservationCounter: + description: The number of times this coupon has been reserved. + example: 1.0 + title: Number of reservations + type: number + attributes: + description: Custom attributes associated with this coupon. + properties: {} + title: Attributes of coupon + type: object + referralId: + description: The integration ID of the referring customer (if any) for whom + this coupon was created as an effect. + example: 326632952 + format: int64 + title: Advocate ID + type: integer + recipientIntegrationId: + description: The Integration ID of the customer that is allowed to redeem + this coupon. + example: URNGV8294NV + maxLength: 1000 + title: Recipient ID + type: string + importId: + description: The ID of the Import which created this coupon. + example: 4 + format: int64 + title: Import ID + type: integer + reservation: + default: true + description: | + Defines the reservation type: + - `true`: The coupon can be reserved for multiple customers. + - `false`: The coupon can be reserved only for one customer. It is a personal code. + example: false + title: Reservation Type + type: boolean + batchId: + description: The id of the batch the coupon belongs to. + example: 32535-43255 + title: Batch ID + type: string + isReservationMandatory: + default: false + description: An indication of whether the code can be redeemed only if it + has been reserved first. + example: false + title: Is reservation mandatory + type: boolean + implicitlyReserved: + description: An indication of whether the coupon is implicitly reserved + for all customers. + example: false + title: Is coupon implicitly reserved for all customers + type: boolean + applicationId: + description: The ID of the application. + example: 123 format: int64 type: integer + applicationName: + description: Name of the Application that is connected to the coupon. + example: Test Application + type: string required: - - logID + - applicationId + - applicationName + - campaignId + - created + - id + - usageCounter + - usageLimit + - value type: object - GenerateCouponFailureSummary: + SupportRequestInput: properties: - eventID: - description: The ID of the event. + applicationId: + description: Identifier of the Application connected to the loyalty program + or the campaign. It is displayed in your Talon.One deployment URL. + example: 322 format: int64 type: integer - language: - description: The language the summary will be generated in. - example: en + campaignId: + description: Identifier of the campaign where the coupon or gift card is + created. + example: 100 + format: int64 + type: integer + loyaltyProgramId: + description: Identifier of the loyalty program. You can get the ID with + the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) + endpoint. + example: 8 + format: int64 + type: integer + subledgerId: + description: Identifier of the subledger the points are added to or deducted + from. If there is no existing subledger with this ID, the subledger is + created automatically. + example: 123 + format: int64 + type: integer + customerProfileId: + description: Integration ID of the customer profile linked to the support + request. + example: URNGV8294NV + type: string + requestType: + description: Type of reward requested, including gift cards, personal coupons, + and loyalty point additions or deductions. + enum: + - gift_card + - personal_coupon + - loyalty_points_added + - loyalty_points_deducted + example: personal_coupon + type: string + requestValue: + description: Requested monetary balance of the gift card or the number of + loyalty points to be added or deducted. + example: 20.5 + exclusiveMinimum: false + format: float + type: number + requestNote: + description: Notes attached to the support request. + example: Support request for coupon failure. type: string required: - - eventID + - applicationId + - customerProfileId + - requestNote + - requestType type: object - CouponFailureSummary: - description: Summary of the reasons for coupon redemption failure. - example: - summary: Session total was less than the required total. - eventID: 1011 - createdAt: 2021-07-20T21:59:00Z - profileID: a48f10dddb5c9493aad194e49bb9c1dac - language: en - id: 1 - sessionID: "1" - couponCode: ABC123 - status: rejected - updatedAt: 2021-07-20T21:59:00Z + SupportRequest: + description: Summary of a support request created by a customer support agent. properties: id: - description: ID of the evaluation record. + description: Identifier of the support request. example: 1 format: int64 type: integer - eventID: - description: ID of the event. - example: 1011 + applicationId: + description: Identifier of the Application connected to the loyalty program + or the campaign. It is displayed in your Talon.One deployment URL. + example: 322 + format: int64 + type: integer + campaignId: + description: Identifier of the campaign where the coupon or gift card is + created. + example: 100 format: int64 type: integer - sessionID: - description: ID of the customer session set by your integration layer. - example: "1" + loyaltyProgramId: + description: Identifier of the loyalty program where the points are added + or deducted. + example: 8 + format: int64 + type: integer + subledgerId: + description: Identifier of the subledger the points are added to or deducted + from. If there is no existing subledger with this ID, the subledger is + created automatically. + example: 123 + format: int64 + type: integer + createdByUser: + description: Email address of the customer support agent who created the + support request. + example: support.agent.name@company.com type: string - profileID: - description: ID of the customer profile set by your integration layer. - example: a48f10dddb5c9493aad194e49bb9c1dac + createdAt: + description: Timestamp when the request was made. + example: 2025-07-20T22:00:00Z + format: date-time type: string - status: - description: Status defines if the coupon code was applied or rejected. - example: rejected + customerProfileId: + description: Integration ID of the customer profile linked to the support + request. + example: URNGV8294NV type: string - couponCode: - description: Coupon code passed for evaluation. - example: ABC123 + requestType: + description: Type of reward requested, including gift cards, personal coupons, + and loyalty point additions or deductions. + enum: + - gift_card + - personal_coupon + - loyalty_points_added + - loyalty_points_deducted + example: personal_coupon type: string - language: - description: Language of the summary. - example: en + requestValue: + description: Requested monetary balance of the gift card or the number of + loyalty points to be added or deducted. + example: 20.5 + exclusiveMinimum: false + format: float + type: number + requestNote: + description: Notes attached to the support request. + example: Support request for coupon failure. type: string - summary: - description: A summary of the reasons for coupon redemption failure. - example: Session total was less than the required total. + requestStatus: + description: Current status of the support request. + enum: + - pending_approval + - approved + - rejected + - expired + example: approved type: string - createdAt: - description: Timestamp when the request was made. - example: 2021-07-20T21:59:00Z + processedAt: + description: Timestamp when the request was approved or rejected. + example: 2025-07-20T22:10:00Z format: date-time type: string - updatedAt: - description: Timestamp when the request was last updated. - example: 2021-07-20T21:59:00Z - format: date-time + processingNote: + description: Notes attached by the admin when rejecting or approving a request. + example: Rejected as the customer was awarded points already. + type: string + processedByUser: + description: Email address of the admin who approved or rejected the support + request. + example: admin.name@company.com + type: string + couponCode: + description: Coupon code associated with the approved support request. + example: SUMMER-2025-XYZ type: string required: - - couponCode + - applicationId - createdAt - - eventID + - createdByUser + - customerProfileId - id - - language - - status - - summary - - updatedAt + - requestNote + - requestStatus + - requestType type: object - GenerateCouponFailureDetailedSummary: + UpdateSupportRequest: properties: - applicationID: - description: The ID of the Application. It is displayed in your Talon.One - deployment URL. - type: number - sessionID: - description: ID of the customer session where the coupon redemption failed. - example: 05c2da0d-48fa-4aa1-b629-898f58f1584d - maxLength: 255 - type: string - eventID: - description: The ID of the event for which the coupon redemption failed. - format: int64 - type: integer - coupon: - description: The coupon code that could not be redeemed. - example: BKDB946 + requestStatus: + description: Current status of the support request. + enum: + - approved + - rejected + - expired + example: approved type: string - language: - description: The language of the summary. - example: en + processingNote: + description: Notes attached by the admin when rejecting or approving a request. + example: Rejected as the customer was awarded points already. type: string required: - - applicationID - - coupon - - eventID - - sessionID + - requestStatus type: object - CampaignLogSummary: - description: Campaign Log Summary + AddLoyaltyPointsSupport: + description: Points to add via the support portal. properties: + points: + description: Amount of loyalty points. + example: 300.0 + exclusiveMinimum: false + maximum: 999999999999.99 + type: number name: - description: Name of the user that performed the change. - example: Admin + description: Name / reason for the point addition. + example: Compensation type: string - email: - description: E-mail of the user that performed the change. - example: admin@talon.one + validityDuration: + description: | + The time format is either: + - `unlimited` or, + - an **integer** followed by one letter indicating the time unit. + + Examples: `unlimited`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. + + Available units: + + - `s`: seconds + - `m`: minutes + - `h`: hours + - `D`: days + - `W`: weeks + - `M`: months + - `Y`: years + + You can round certain units up or down: + - `_D` for rounding down days only. Signifies the start of the day. + - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. + + If passed, `validUntil` should be omitted. + example: 5D type: string - created: - description: Date and time the change was performed. + validUntil: + description: | + Date and time when points should expire. The value should be provided in RFC 3339 format. + If passed, `validityDuration` should be omitted. + example: 2021-07-20T22:00:00Z format: date-time type: string - action: - description: Action performed by the user. - enum: - - create - - delete - - update - example: create + pendingDuration: + description: | + The amount of time before the points are considered valid. + + The time format is either: + - `immediate` or, + - `on_action` or, + - an **integer** followed by one letter indicating the time unit. + + Examples: `immediate`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`, `on_action`. + + Available units: + + - `s`: seconds + - `m`: minutes + - `h`: hours + - `D`: days + - `W`: weeks + - `M`: months + - `Y`: years + + You can round certain units up or down: + - `_D` for rounding down days only. Signifies the start of the day. + - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. + example: 12h type: string - summary: - description: AI-generated summary of the action performed. + pendingUntil: + description: | + Date and time after the points are considered valid. The value should be provided in RFC 3339 format. + If passed, `pendingDuration` should be omitted. + example: 2021-07-20T22:00:00Z + format: date-time type: string - required: - - action - - created - - email - - name - - summary - type: object - IntegrationHubFlowConfigResponse: - properties: - WorkerCount: - description: Number of IntegrationHub workers to run in parallel for this - flow (maximum 500). - format: int64 - maximum: 5E+2 - minimum: 1 - type: integer - MaxEventsPerMessage: - description: Maximum number of events to send in a single message to IntegrationHub. + subledgerId: + description: ID of the subledger the points are added to. If there is no + existing subledger with this ID, the subledger is created automatically. + example: sub-123 + type: string + applicationId: + description: ID of the Application that is connected to the loyalty program. + It is displayed in your Talon.One deployment URL. + example: 322 format: int64 - minimum: 1 type: integer - MaxRetries: - description: Maximum number of retries for a IntegrationHub event before - it is ignored. + supportRequestId: + description: ID of the support request to approve. When provided by an admin, + the points are added on behalf of the support user who created the request. + example: 42 format: int64 - minimum: 0 type: integer + processingNote: + description: Note from the admin approving the support request. Stored as + the processing note on the support request record. This is only used when + a supportRequestId is passed. + example: Approved after manual review. + type: string + required: + - points type: object - IntegrationHubFlowResponse: + ApplicationMembership: properties: - Id: - description: ID of the integration hub flow. + applicationId: + description: The ID of the Application the customer belongs to. + example: 1 format: int64 type: integer - ApplicationID: - description: ID of application the flow is registered for. - example: 54 + applicationName: + description: The name of the Application the customer belongs to. + example: My Application + type: string + required: + - applicationId + - applicationName + type: object + SupportCustomerProfile: + properties: + id: + description: The internal ID of the customer profile. + example: 6 format: int64 type: integer - EventType: - description: The event type we want to register a flow for. + created: + description: The time the customer profile was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time type: string - x-fieldType: IntegrationHubEventType - IntegrationHubFlowUrl: - description: The URL of the integration hub flow that we want to trigger - for the event. + integrationId: + description: The integration ID set by your integration layer. + example: URNGV8294NV type: string - Config: - $ref: '#/components/schemas/IntegrationHubFlowConfigResponse' + attributes: + description: Arbitrary properties associated with this item. + example: + Language: english + ShippingCountry: DE + properties: {} + type: object + applicationMemberships: + description: The applications the customer belongs to. + items: + $ref: '#/components/schemas/ApplicationMembership' + type: array required: - - Config - - EventType - - Id - - IntegrationHubFlowUrl + - applicationMemberships + - attributes + - created + - id + - integrationId type: object - IntegrationHubFlowConfig: + RedeemableCoupon: properties: - ApiKey: - type: string - WorkerCount: - default: 10 - description: Number of IntegrationHub workers to run in parallel for this - flow (maximum 500). + couponId: + description: The internal ID of the coupon. + example: 34 format: int64 - maximum: 5E+2 - minimum: 1 type: integer - MaxEventsPerMessage: - default: 1000 - description: Maximum number of events to send in a single message to IntegrationHub. + couponCode: + description: The coupon code. + example: SUMMER10 + type: string + usageCounter: + description: The number of times the coupon has been successfully redeemed. + example: 3 format: int64 - minimum: 1 type: integer - MaxRetries: - default: 10 - description: Maximum number of retries for a IntegrationHub event before - it is ignored. + usageLimit: + description: The number of times the coupon code can be redeemed. `0` means + unlimited redemptions but any campaign usage limits still apply. + example: 10 format: int64 - minimum: 0 type: integer + campaignName: + description: The name of the campaign that owns the coupon. + example: Summer Sale 2026 + type: string required: - - ApiKey + - campaignName + - couponCode + - couponId + - usageCounter + - usageLimit type: object - IntegrationHubFlowWithConfig: + CouponEligibilityInfo: properties: - ApplicationID: - description: ID of application the flow is registered for. - example: 54 + campaignId: + description: The ID of the campaign that owns the coupon. + example: 42 format: int64 type: integer - EventType: - description: The event type we want to register a flow for. + campaignName: + description: The name of the campaign that owns the coupon. + example: Summer Sale 2026 type: string - x-fieldType: IntegrationHubEventType - IntegrationHubFlowUrl: - description: The URL of the integration hub flow that we want to trigger - for the event. + failureReason: + description: The reason the coupon is not eligible, if applicable. + example: Coupon has expired type: string - Config: - $ref: '#/components/schemas/IntegrationHubFlowConfig' required: - - Config - - EventType - - IntegrationHubFlowUrl + - campaignId + - campaignName type: object - IntegrationHubFlow: + RewardPointsRequired: + description: The loyalty points required to activate a reward. + example: + amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 properties: - ApplicationID: - description: ID of application the flow is registered for. - example: 54 + id: + description: | + The ID of the `pointsRequired` entry. When updating a reward, + include this property to update an existing entry. Omit it to create a new one. + example: 1 format: int64 type: integer - EventType: - description: The event type we want to register a flow for. - type: string - x-fieldType: IntegrationHubEventType - IntegrationHubFlowUrl: - description: The URL of the integration hub flow that we want to trigger - for the event. - type: string - required: - - EventType - - IntegrationHubFlowUrl - type: object - IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction: - properties: - Amount: - format: float + amount: + description: The number of loyalty points required to activate the reward. + example: 500.0 + minimum: 0 type: number - Reason: - type: string - Operation: - enum: - - addition - - subtraction - type: string - StartDate: - format: date-time - type: string - ExpiryDate: - format: date-time - type: string - TransactionUUID: - description: The identifier of the transaction in the loyalty ledger. - format: uuid + loyaltyProgramId: + description: The ID of the associated loyalty program. + example: 10 + format: int64 + type: integer + subledgerId: + description: | + The ID of the subledger within the loyalty program from which points are deducted when activating the reward. + + To specify the main ledger, provide an empty string (""). + example: mysubledger type: string required: - - Amount - - Operation - - TransactionUUID + - amount + - loyaltyProgramId + - subledgerId type: object - IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification: + NewReward: properties: - ProfileIntegrationID: - type: string - LoyaltyProgramID: - format: int64 - type: integer - SubledgerID: + name: + description: The name of the reward. + example: Free Coffee + minLength: 1 type: string - SourceOfEvent: + apiName: + description: A unique identifier used to reference the reward in API integrations. + example: free-coffee + minLength: 1 type: string - EmployeeName: + description: + description: A description of the reward. + example: This reward gets you one free coffee. type: string - UserID: - format: int64 - type: integer - CurrentPoints: - format: float - type: number - Actions: + applicationIds: + description: "The IDs of the Applications this reward is connected to. \n\ + \n**Note**: Currently, a reward can only be connected to one Application.\n" + example: + - 1 + - 2 + - 3 items: - $ref: '#/components/schemas/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction' + format: int64 + type: integer + type: array + sandbox: + description: Indicates if this is a live or sandbox reward. Rewards of a + given type can only be connected to Applications of the same type. + example: true + title: Sandbox + type: boolean + eligibilityConditions: + $ref: '#/components/schemas/Rule' + rule: + $ref: '#/components/schemas/Rule' + bindings: + description: A list of named variables created before the reward's rules + are evaluated. Each binding pairs a name with a talang expression. The + expression is evaluated once and its result is available by name in any + rule condition or effect. Bindings must be defined outside of individual + rules. + example: [] + items: + $ref: '#/components/schemas/Binding' + type: array + pointsRequired: + description: | + The loyalty points required to activate the reward. Each object defines the specific + loyalty program and subledger from which points are deducted when activating the reward. + + **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is + always created. + items: + $ref: '#/components/schemas/RewardPointsRequired' type: array - PublishedAt: - description: Timestamp when the event was published. - format: date-time - type: string required: - - CurrentPoints - - LoyaltyProgramID - - ProfileIntegrationID - - PublishedAt - - SourceOfEvent - - SubledgerID + - apiName + - applicationIds + - name + - sandbox type: object - x-discriminator-value: LoyaltyPointsChanged - x-ms-discriminator-value: LoyaltyPointsChanged - IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification: + Reward: properties: - ProfileIntegrationID: - type: string - LoyaltyProgramID: + id: + description: The internal ID of this entity. + example: 6 format: int64 type: integer - SubledgerID: - type: string - SourceOfEvent: - type: string - CurrentTier: + created: + description: The time this entity was created. + example: 2020-06-10T09:05:27.993483Z + format: date-time type: string - CurrentPoints: - format: float - type: number - OldTier: + accountId: + description: The ID of the account that owns this entity. + example: 3886 + format: int64 + type: integer + name: + description: The name of the reward. + example: Free Coffee + minLength: 1 type: string - TierExpirationDate: - format: date-time + apiName: + description: A unique identifier used to reference the reward in API integrations. + example: free-coffee + minLength: 1 type: string - TimestampOfTierChange: - format: date-time + description: + description: A description of the reward. + example: This reward gets you one free coffee. type: string - PublishedAt: - description: Timestamp when the event was published. + applicationIds: + description: "The IDs of the Applications this reward is connected to. \n\ + \n**Note**: Currently, a reward can only be connected to one Application.\n" + example: + - 1 + - 2 + - 3 + items: + format: int64 + type: integer + type: array + sandbox: + description: Indicates if this is a live or sandbox reward. Rewards of a + given type can only be connected to Applications of the same type. + example: true + title: Sandbox + type: boolean + eligibilityConditions: + $ref: '#/components/schemas/Rule' + rule: + $ref: '#/components/schemas/Rule' + bindings: + description: A list of named variables created before the reward's rules + are evaluated. Each binding pairs a name with a talang expression. The + expression is evaluated once and its result is available by name in any + rule condition or effect. Bindings must be defined outside of individual + rules. + example: [] + items: + $ref: '#/components/schemas/Binding' + type: array + pointsRequired: + description: | + The loyalty points required to activate the reward. Each object defines the specific + loyalty program and subledger from which points are deducted when activating the reward. + + **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is + always created. + items: + $ref: '#/components/schemas/RewardPointsRequired' + type: array + modified: + description: The timestamp when the reward was last updated in RFC3339 format. format: date-time type: string + status: + description: The status of the reward. + enum: + - active + - inactive + example: active + type: string required: - - CurrentPoints - - LoyaltyProgramID - - ProfileIntegrationID - - PublishedAt - - SourceOfEvent - - SubledgerID + - accountId + - apiName + - applicationIds + - created + - id + - name + - sandbox + - status type: object - x-discriminator-value: LoyaltyTierDowngrade - x-ms-discriminator-value: LoyaltyTierDowngrade - IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification: + RewardEligibilityFailureDetails: + description: The details about why the customer is not eligible for the reward. + example: + failureCode: CONDITION_NOT_MET + conditionIndex: 0 properties: - ProfileIntegrationID: + failureCode: + description: A code identifying why the customer is not eligible for the + reward. + enum: + - CONDITION_NOT_MET + - INSUFFICIENT_BALANCE + - CARD_REQUIRED + - PROFILE_REQUIRED + example: CONDITION_NOT_MET type: string - LoyaltyProgramID: + conditionIndex: + description: The index of the eligibility condition that the customer did + not meet. Only applicable when `failureCode` is `CONDITION_NOT_MET`. + example: 0 format: int64 type: integer - SubledgerID: - type: string - SourceOfEvent: - type: string - CurrentTier: - type: string - CurrentPoints: - format: float - type: number - OldTier: - type: string - PointsRequiredToTheNextTier: - format: float - type: number - NextTier: - type: string - TierExpirationDate: - format: date-time - type: string - TimestampOfTierChange: - format: date-time - type: string - PublishedAt: - description: Timestamp when the event was published. - format: date-time - type: string required: - - CurrentPoints - - LoyaltyProgramID - - ProfileIntegrationID - - PublishedAt - - SourceOfEvent - - SubledgerID + - failureCode type: object - x-discriminator-value: LoyaltyTierUpgrade - x-ms-discriminator-value: LoyaltyTierUpgrade - IntegrationHubEventPayloadLoyaltyProfileBasedNotification: + RewardEligibility: + description: The customer's eligibility for the reward based on the specified + customer profile or loyalty card. + example: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + properties: + passed: + description: Indicates whether the customer is eligible for the reward. + example: true + type: boolean + details: + description: The reasons the customer is not eligible for the reward. Empty + when `passed` is `true`. + items: + $ref: '#/components/schemas/RewardEligibilityFailureDetails' + type: array + required: + - passed + type: object + RewardCatalogItem: + description: A reward returned by the rewards catalog Integration API endpoint. + example: + name: 10% Off Coupon + pointsRequired: + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + eligibility: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + id: 42 properties: - ProfileIntegrationID: - type: string - LoyaltyProgramID: + id: + description: The unique ID of the reward. + example: 42 format: int64 type: integer - SubledgerID: - type: string - SourceOfEvent: + name: + description: The customer-facing name of the reward. + example: 10% Off Coupon type: string - EmployeeName: + description: + description: The customer-facing description of the reward. + example: Applies to next order type: string - UserID: - format: int64 - type: integer - CurrentPoints: - format: float - type: number - Actions: + pointsRequired: + description: The loyalty points required to activate the reward. items: - $ref: '#/components/schemas/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction' + $ref: '#/components/schemas/RewardPointsRequired' type: array - PublishedAt: - description: Timestamp when the event was published. - format: date-time - type: string - CurrentTier: - type: string - OldTier: - type: string - TierExpirationDate: - format: date-time - type: string - TimestampOfTierChange: - format: date-time - type: string - PointsRequiredToTheNextTier: - format: float - type: number - NextTier: - type: string + rule: + $ref: '#/components/schemas/RuleMetadata' + eligibility: + $ref: '#/components/schemas/RewardEligibility' required: - - CurrentPoints - - LoyaltyProgramID - - ProfileIntegrationID - - PublishedAt - - SourceOfEvent - - SubledgerID + - id + - name + - rule type: object - IntegrationHubEventPayloadCouponBasedNotificationsLimits: + UpdateReward: properties: - Action: + name: + description: The name of the reward. + example: Free Coffee + minLength: 1 type: string - Limit: - format: float - type: number - Period: + description: + description: A description of the reward. + example: This reward gets you one free coffee. type: string - Entities: + status: + description: The status of the reward. + enum: + - active + - inactive + example: active + type: string + eligibilityConditions: + $ref: '#/components/schemas/Rule' + rule: + $ref: '#/components/schemas/Rule' + bindings: + description: A list of named variables created before the reward's rules + are evaluated. Each binding pairs a name with a talang expression. The + expression is evaluated once and its result is available by name in any + rule condition or effect. Bindings must be defined outside of individual + rules. + example: [] items: - type: string + $ref: '#/components/schemas/Binding' + type: array + pointsRequired: + description: | + The loyalty points required to activate the reward. Each object defines the specific + loyalty program and subledger from which points are deducted when activating the reward. + + **Note:** + - Objects with an `id` are updated. + - Objects without an `id` are created. + - Existing objects omitted from the payload are deleted. + items: + $ref: '#/components/schemas/RewardPointsRequired' type: array required: - - Action - - Entities - - Limit + - name + - status type: object - IntegrationHubEventPayloadCouponBasedNotifications: + IntegrationUnlockRewardRequest: + description: | + The request body for unlocking a reward for a customer profile, optionally + using the balance of one of the customer's loyalty cards. + example: + profileIntegrationId: customer1 + subledgerId: sub1 + integrationId: reward-unlock-123 + loyaltyProgramId: 2 + responseContent: + - customerProfile + - loyalty + cardIdentifier: summer-loyalty-card-0543 properties: - Id: - format: int64 - type: integer - Created: - format: date-time - type: string - CampaignId: - format: int64 - type: integer - Value: - type: string - UsageLimit: - format: int64 - type: integer - DiscountLimit: - format: float - type: number - ReservationLimit: - format: int64 - type: integer - StartDate: - format: date-time + integrationId: + description: The integration ID to assign to the created customer reward + unlock. + example: reward-unlock-123 type: string - ExpiryDate: - format: date-time + profileIntegrationId: + description: The integration ID of the customer profile unlocking the reward. + example: customer1 type: string - UsageCounter: - format: int64 - type: integer - DiscountCounter: - format: float - type: number - DiscountRemainder: - format: float - type: number - ReferralId: - format: int64 - type: integer - RecipientIntegrationId: + cardIdentifier: + description: | + The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + example: summer-loyalty-card-0543 + maxLength: 108 + minLength: 4 + pattern: ^[A-Za-z0-9._%+@-]+$ type: string - ImportId: + loyaltyProgramId: + description: The ID of the loyalty program from which points will be deducted. + Required when the reward has `pointsRequired` configured. + example: 2 format: int64 type: integer - BatchId: + subledgerId: + description: | + The ID of the subledger from which points will be deducted. + Required when the reward has `pointsRequired` configured. + + To specify the main ledger, provide an empty string (""). + example: sub1 type: string - Attributes: - properties: {} - type: object - Limits: + responseContent: + description: 'Determines which data is included in the response. Add any + of the following optional values to the array to get that data in the + response: `customerProfile`, `ruleFailureReasons`, `loyalty`. `effects` + is always returned regardless of whether it is included here.' + example: + - customerProfile + - loyalty items: - $ref: '#/components/schemas/IntegrationHubEventPayloadCouponBasedNotificationsLimits' + enum: + - customerProfile + - effects + - ruleFailureReasons + - loyalty + type: string type: array - PublishedAt: - description: Timestamp when the event was published. - format: date-time - type: string - SourceOfEvent: - type: string - EmployeeName: - type: string required: - - CampaignId - - Created - - EmployeeName - - Id - - PublishedAt - - SourceOfEvent - - UsageCounter - - UsageLimit - - Value + - integrationId + - profileIntegrationId type: object - x-discriminator-value: CouponDeleted - x-ms-discriminator-value: CouponDeleted - IntegrationHubEventRecord: + RewardUnlockRejection: + description: | + Returned when a reward unlock is rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. properties: - Id: - format: int64 - type: integer - FlowId: - format: int64 - type: integer - EventType: - type: string - x-fieldType: IntegrationHubEventType - EventData: - type: object - PublishedAt: - format: date-time - type: string - ProcessedAt: - format: date-time - type: string - ProcessAfter: - format: date-time + message: + description: A human-readable summary of why the reward unlock was rejected. + example: reward unlock rejected type: string - Retry: - format: int64 - type: integer + ruleFailureReasons: + description: The reasons why the reward could not be unlocked. + items: + $ref: '#/components/schemas/RuleFailureReason' + type: array required: - - EventData - - EventType - - FlowId - - Id - - ProcessAfter - - PublishedAt - - Retry + - message + - ruleFailureReasons type: object - IntegrationHubConfig: - description: Config used for accessing integrations in IntegrationHub + IntegrationProfileEntityV3: properties: - integrationHubUrl: - description: The url used to integrate the IntegrationHub Marketplace. - example: https://hub.talon.farm/ - type: string - accessToken: - description: Access token used to authenticate a user in Talon.One. - example: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9 + profileId: + description: | + ID of the customer profile set by your integration layer. + + **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. + example: URNGV8294NV type: string required: - - accessToken - - integrationHubUrl + - profileId type: object - CouponWithApplication: + NewEventV3Entity: properties: - id: - description: The internal ID of the coupon. - example: 6 - format: int64 - type: integer - created: - description: The time the coupon was created. - example: 2020-06-10T09:05:27.993483Z - format: date-time - type: string - campaignId: - description: The ID of the campaign that owns this entity. - example: 211 - format: int64 - title: Campaign ID - type: integer - value: - description: The coupon code. - example: XMAS-20-2021 - minLength: 4 - title: Coupon Code - type: string - usageLimit: - description: | - The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. - example: 100 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - discountLimit: + integrationId: description: | - The total discount value that the code can give. Typically used to represent a gift card value. - example: 30.0 - maximum: 1E+15 - minimum: 0 - type: number - reservationLimit: + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 + type: string + required: + - integrationId + type: object + EventV3RequestEntity: + properties: + profileId: description: | - The number of reservations that can be made with this coupon code. - example: 45 - format: int64 - maximum: 999999 - minimum: 0 - type: integer - startDate: - description: Timestamp at which point the coupon becomes valid. - example: 2020-01-24T14:15:22Z - format: date-time + ID of the customer profile set by your integration layer. + + **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. + example: URNGV8294NV type: string - expiryDate: - description: Expiration date of the coupon. Coupon never expires if this - is omitted. - example: 2023-08-24T14:15:22Z - format: date-time + storeIntegrationId: + description: The integration ID of the store. You choose this ID when you + create a store. + example: STORE-001 + maxLength: 1000 + minLength: 1 type: string - limits: + evaluableCampaignIds: description: | - Limits configuration for a coupon. These limits will override the limits - set from the campaign. + When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. - **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. - Only per-profile limits are allowed to be configured. + These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. + example: + - 10 + - 12 items: - $ref: '#/components/schemas/LimitConfig' + format: int64 + type: integer + title: Campaigns to evaluate type: array - usageCounter: - description: The number of times the coupon has been successfully redeemed. - example: 10 - format: int64 - title: Total coupon redemptions - type: integer - discountCounter: - description: The amount of discounts given on rules redeeming this coupon. - Only usable if a coupon discount budget was set for this coupon. - example: 10.0 - title: Discounts Given - type: number - discountRemainder: - description: The remaining discount this coupon can give. - example: 5.0 - title: Coupon Discount Remainder - type: number - reservationCounter: - description: The number of times this coupon has been reserved. - example: 1.0 - title: Number of reservations - type: number + type: + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. + example: pageViewed + minLength: 1 + title: Event Type + type: string attributes: - description: Custom attributes associated with this coupon. + description: Arbitrary additional JSON properties associated with the event. + They must be created in the Campaign Manager before setting them with + this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). + example: + myAttribute: myValue properties: {} - title: Attributes of coupon type: object - referralId: - description: The integration ID of the referring customer (if any) for whom - this coupon was created as an effect. - example: 326632952 - format: int64 - title: Advocate ID - type: integer - recipientIntegrationId: - description: The Integration ID of the customer that is allowed to redeem - this coupon. - example: URNGV8294NV - maxLength: 1000 - title: Recipient ID - type: string - importId: - description: The ID of the Import which created this coupon. - example: 4 - format: int64 - title: Import ID - type: integer - reservation: - default: true + integrationId: description: | - Defines the reservation type: - - `true`: The coupon can be reserved for multiple customers. - - `false`: The coupon can be reserved only for one customer. It is a personal code. - example: false - title: Reservation Type - type: boolean - batchId: - description: The id of the batch the coupon belongs to. - example: 32535-43255 - title: Batch ID + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 type: string - isReservationMandatory: - default: false - description: An indication of whether the code can be redeemed only if it - has been reserved first. - example: false - title: Is reservation mandatory - type: boolean - implicitlyReserved: - description: An indication of whether the coupon is implicitly reserved - for all customers. - example: false - title: Is coupon implicitly reserved for all customers - type: boolean - applicationId: - description: The ID of the application. - example: 123 - format: int64 - type: integer - applicationName: - description: Name of the Application that is connected to the coupon. - example: Test Application + connectedSessionId: + description: The ID of the session to reference. The session must be in + `closed` state. Otherwise, the API call will fail. + example: 175KJPS947296 + minLength: 1 + type: string + referralCode: + description: | + The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the "Referral code is valid" condition in the Rule Builder to validate and redeem the code, or "Referral code is valid (without redemption)" to validate without redeeming. + example: NT2K54D9 + maxLength: 100 type: string required: - - applicationId - - applicationName - - campaignId - - created - - id - - usageCounter - - usageLimit - - value + - integrationId + - profileId + - type type: object - NewReward: + IntegrationEventV3Request: + example: + connectedSessionId: 175KJPS947296 + loyaltyCards: + - loyalty-card-1 + storeIntegrationId: STORE-001 + profileId: URNGV8294NV + evaluableCampaignIds: + - 10 + - 12 + referralCode: NT2K54D9 + integrationId: 175KJPS947296 + attributes: + myAttribute: myValue + type: pageViewed + responseContent: + - triggeredCampaigns + - customerProfile properties: - name: - description: The name of the reward. - example: Free Coffee + profileId: + description: | + ID of the customer profile set by your integration layer. + + **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. + example: URNGV8294NV + type: string + storeIntegrationId: + description: The integration ID of the store. You choose this ID when you + create a store. + example: STORE-001 + maxLength: 1000 minLength: 1 type: string - apiName: - description: A unique identifier used to reference the reward in API integrations. - example: free-coffee + evaluableCampaignIds: + description: | + When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. + + These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. + example: + - 10 + - 12 + items: + format: int64 + type: integer + title: Campaigns to evaluate + type: array + type: + description: The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), + not a built-in event. + example: pageViewed minLength: 1 + title: Event Type type: string - description: - description: A description of the reward. - example: This reward gets you one free coffee. + attributes: + description: Arbitrary additional JSON properties associated with the event. + They must be created in the Campaign Manager before setting them with + this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). + example: + myAttribute: myValue + properties: {} + type: object + integrationId: + description: | + The unique ID of the event. Only one event with this ID can be registered. + example: 175KJPS947296 + minLength: 1 type: string - applicationIds: - description: "The IDs of the Applications this reward is connected to. \n\ - \n**Note**: Currently, a reward can only be connected to one Application.\n" + connectedSessionId: + description: The ID of the session to reference. The session must be in + `closed` state. Otherwise, the API call will fail. + example: 175KJPS947296 + minLength: 1 + type: string + referralCode: + description: | + The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the "Referral code is valid" condition in the Rule Builder to validate and redeem the code, or "Referral code is valid (without redemption)" to validate without redeeming. + example: NT2K54D9 + maxLength: 100 + type: string + loyaltyCards: + description: Identifiers of the loyalty cards used during this event. + example: + - loyalty-card-1 + items: + type: string + maxItems: 1 + type: array + responseContent: + description: | + Optional list of requested information to be present on the response related to the tracking custom event. example: + - triggeredCampaigns + - customerProfile + items: + enum: + - advancedEvent + - awardedGiveaways + - customerProfile + - loyalty + - referral + - ruleFailureReasons + - triggeredCampaigns + type: string + type: array + required: + - integrationId + - profileId + - type + type: object + IntegrationEventV3Response: + description: | + This is the response type returned by the trackEventV3 endpoint. + example: + achievements: + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: + - 1 + - 14 + - 27 + recurrencePolicy: no_recurrence + - currentProgress: + endDate: 2000-01-23T04:56:07.000+00:00 + progress: 10.0 + completionDate: 2000-01-23T04:56:07.000+00:00 + startDate: 2000-01-23T04:56:07.000+00:00 + status: completed + referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 + campaignId: 3 + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + target: 10.0 + fixedStartDate: 2000-01-23T04:56:07.000+00:00 + name: FreeCoffee10Orders + id: 3 + campaignIds: + - 1 + - 14 + - 27 + recurrencePolicy: no_recurrence + customerProfile: + accountId: 31 + closedSessions: 3 + created: 2020-02-07T08:15:22Z + sandbox: false + integrationId: URNGV8294NV + attributes: + Language: english + ShippingCountry: DE + totalSales: 299.99 + lastActivity: 2020-02-08T14:15:20Z + id: 6 + loyaltyMemberships: + - joined: 2012-03-20T14:15:22Z + loyaltyProgramId: 323414846 + - joined: 2012-03-20T14:15:22Z + loyaltyProgramId: 323414846 + audienceMemberships: + - name: Travel audience + id: 2 + - name: Travel audience + id: 2 + loyalty: + cards: + - ledger: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + identifier: summer-loyalty-card-0543 + oldCardIdentifier: summer-loyalty-card-0543 + usersPerCardLimit: 111 + created: 2020-06-10T09:05:27.993483Z + profiles: + - integrationId: R195412 + timestamp: 2021-09-12T10:12:42Z + - integrationId: R195412 + timestamp: 2021-09-12T10:12:42Z + subledgers: + key: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + batchId: wdefpov + programTitle: Loyalty program + programName: Loyalty_program + modified: 2021-09-12T10:12:42Z + id: 6 + blockReason: Current card lost. Customer needs a new card. + newCardIdentifier: summer-loyalty-card-0543 + programID: 125 + status: active + - ledger: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + identifier: summer-loyalty-card-0543 + oldCardIdentifier: summer-loyalty-card-0543 + usersPerCardLimit: 111 + created: 2020-06-10T09:05:27.993483Z + profiles: + - integrationId: R195412 + timestamp: 2021-09-12T10:12:42Z + - integrationId: R195412 + timestamp: 2021-09-12T10:12:42Z + subledgers: + key: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + batchId: wdefpov + programTitle: Loyalty program + programName: Loyalty_program + modified: 2021-09-12T10:12:42Z + id: 6 + blockReason: Current card lost. Customer needs a new card. + newCardIdentifier: summer-loyalty-card-0543 + programID: 125 + status: active + programs: + key: + ledger: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + joinDate: 2000-01-23T04:56:07.000+00:00 + subLedgers: + key: + pendingBalance: 10.0 + nextTierName: Silver + negativeBalance: 10.0 + currentBalance: 100.0 + spentBalance: 0.0 + tentativeCurrentBalance: 100.0 + tentativePendingBalance: 20.0 + pointsToNextTier: 20.0 + expiredBalance: 0.0 + currentTier: + expiryDate: 2000-01-23T04:56:07.000+00:00 + downgradePolicy: one_down + name: bronze + id: 11 + startDate: 2000-01-23T04:56:07.000+00:00 + tentativeNegativeBalance: 100.0 + name: program1 + id: 5 + title: My loyalty program + awardedGiveaways: + - profileIntegrationId: R195412 + code: GIVEAWAY1 + importId: 4 + endDate: 2000-01-23T04:56:07.000+00:00 + created: 2020-06-10T09:05:27.993483Z + profileId: 1 + poolId: 1 + attributes: '{}' + id: 6 + used: true + startDate: 2000-01-23T04:56:07.000+00:00 + - profileIntegrationId: R195412 + code: GIVEAWAY1 + importId: 4 + endDate: 2000-01-23T04:56:07.000+00:00 + created: 2020-06-10T09:05:27.993483Z + profileId: 1 + poolId: 1 + attributes: '{}' + id: 6 + used: true + startDate: 2000-01-23T04:56:07.000+00:00 + createdCoupons: + - recipientIntegrationId: URNGV8294NV + implicitlyReserved: false + created: 2020-06-10T09:05:27.993483Z + campaignId: 211 + usageLimit: 100 + referralId: 326632952 + usageCounter: 10 + batchId: 32535-43255 + discountCounter: 10.0 + expiryDate: 2023-08-24T14:15:22Z + importId: 4 + reservationLimit: 45 + reservationCounter: 1.0 + reservation: false + attributes: '{}' + id: 6 + value: XMAS-20-2021 + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + discountRemainder: 5.0 + isReservationMandatory: false + - recipientIntegrationId: URNGV8294NV + implicitlyReserved: false + created: 2020-06-10T09:05:27.993483Z + campaignId: 211 + usageLimit: 100 + referralId: 326632952 + usageCounter: 10 + batchId: 32535-43255 + discountCounter: 10.0 + expiryDate: 2023-08-24T14:15:22Z + importId: 4 + reservationLimit: 45 + reservationCounter: 1.0 + reservation: false + attributes: '{}' + id: 6 + value: XMAS-20-2021 + discountLimit: 30.0 + startDate: 2020-01-24T14:15:22Z + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + discountRemainder: 5.0 + isReservationMandatory: false + createdReferrals: + - code: 27G47Y54VH9L + created: 2020-06-10T09:05:27.993483Z + usageLimit: 1 + campaignId: 78 + usageCounter: 1 + batchId: tqyrgahe + advocateProfileIntegrationId: URNGV8294NV + expiryDate: 2021-11-10T23:00:00Z + importId: 4 + friendProfileIntegrationId: BZGGC2454PA + attributes: + channel: web + id: 6 + startDate: 2020-11-10T23:00:00Z + - code: 27G47Y54VH9L + created: 2020-06-10T09:05:27.993483Z + usageLimit: 1 + campaignId: 78 + usageCounter: 1 + batchId: tqyrgahe + advocateProfileIntegrationId: URNGV8294NV + expiryDate: 2021-11-10T23:00:00Z + importId: 4 + friendProfileIntegrationId: BZGGC2454PA + attributes: + channel: web + id: 6 + startDate: 2020-11-10T23:00:00Z + effects: + - rulesetId: 73 + ruleIndex: 2 + campaignRevisionVersionId: 5 + campaignId: 244 + conditionIndex: 786 + evaluationGroupMode: stackable + effectType: rejectCoupon + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + props: '{}' + rewardId: 7 + selectedPrice: 100.0 + evaluationGroupID: 3 + triggeredForCatalogItem: 786 + selectedPriceType: member + campaignRevisionId: 1 + ruleName: Give 20% discount + experimentId: 12 + triggeredByCoupon: 4928 + - rulesetId: 73 + ruleIndex: 2 + campaignRevisionVersionId: 5 + campaignId: 244 + conditionIndex: 786 + evaluationGroupMode: stackable + effectType: rejectCoupon + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + props: '{}' + rewardId: 7 + selectedPrice: 100.0 + evaluationGroupID: 3 + triggeredForCatalogItem: 786 + selectedPriceType: member + campaignRevisionId: 1 + ruleName: Give 20% discount + experimentId: 12 + triggeredByCoupon: 4928 + referral: + code: 27G47Y54VH9L + created: 2020-06-10T09:05:27.993483Z + usageLimit: 1 + campaignId: 78 + usageCounter: 1 + batchId: tqyrgahe + advocateProfileIntegrationId: URNGV8294NV + expiryDate: 2021-11-10T23:00:00Z + importId: 4 + friendProfileIntegrationId: BZGGC2454PA + attributes: + channel: web + referredCustomers: + - referredCustomers + - referredCustomers + id: 6 + startDate: 2020-11-10T23:00:00Z + triggeredCampaigns: + - type: advanced + templateId: 3 + customEffectCount: 0 + activeRevisionId: 6 + features: + - coupons + - referrals + createdLoyaltyPointsCount: 9.0 + storesImported: true + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + experimentId: 1 + id: 4 + state: enabled + couponAttributes: '{}' + reservecouponEffectCount: 9 + updatedBy: Jane Doe + frontendState: running + created: 2020-06-10T09:05:27.993483Z + referralCreationCount: 8 + stageRevision: false + couponRedemptionCount: 163 + couponCreationCount: 16 + version: 6 + campaignGroups: + - 1 + - 3 + tags: + - summer + discountEffectCount: 343 + budgets: + - limit: 1000.0 + action: createCoupon + counter: 42.0 + - limit: 1000.0 + action: createCoupon + counter: 42.0 + redeemedLoyaltyPointsCount: 8.0 + name: Summer promotions + valueMapsIds: + - 100 + - 215 + applicationId: 322 + updated: 2022-10-27T15:00:00Z + callApiEffectCount: 0 + createdLoyaltyPointsEffectCount: 2 + discountCount: 288.0 + revisionFrontendState: revised + description: Campaign for all summer 2021 promotions + activeRevisionVersionId: 6 + currentRevisionVersionId: 6 + startTime: 2021-07-20T22:00:00Z + currentRevisionId: 6 + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 6 + reevaluateOnReturn: true + userId: 388 + awardedGiveawaysCount: 9 + redeemedLoyaltyPointsEffectCount: 9 + linkedStoreIds: - 1 - 2 - 3 - items: - format: int64 - type: integer - type: array - sandbox: - description: Indicates if this is a live or sandbox reward. Rewards of a - given type can only be connected to Applications of the same type. - example: true - title: Sandbox - type: boolean - required: - - apiName - - applicationIds - - name - - sandbox - type: object - Reward: - properties: - id: - description: The internal ID of this entity. - example: 6 - format: int64 - type: integer - created: - description: The time this entity was created. - example: 2020-06-10T09:05:27.993483Z - format: date-time - type: string - accountId: - description: The ID of the account that owns this entity. - example: 3886 - format: int64 - type: integer - name: - description: The name of the reward. - example: Free Coffee - minLength: 1 - type: string - apiName: - description: A unique identifier used to reference the reward in API integrations. - example: free-coffee - minLength: 1 - type: string - description: - description: A description of the reward. - example: This reward gets you one free coffee. - type: string - applicationIds: - description: "The IDs of the Applications this reward is connected to. \n\ - \n**Note**: Currently, a reward can only be connected to one Application.\n" - example: + createdBy: John Doe + addFreeItemEffectCount: 0 + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + lastActivity: 2022-11-10T23:00:00Z + endTime: 2021-09-22T22:00:00Z + referralRedemptionCount: 3 + - type: advanced + templateId: 3 + customEffectCount: 0 + activeRevisionId: 6 + features: + - coupons + - referrals + createdLoyaltyPointsCount: 9.0 + storesImported: true + couponSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + experimentId: 1 + id: 4 + state: enabled + couponAttributes: '{}' + reservecouponEffectCount: 9 + updatedBy: Jane Doe + frontendState: running + created: 2020-06-10T09:05:27.993483Z + referralCreationCount: 8 + stageRevision: false + couponRedemptionCount: 163 + couponCreationCount: 16 + version: 6 + campaignGroups: + - 1 + - 3 + tags: + - summer + discountEffectCount: 343 + budgets: + - limit: 1000.0 + action: createCoupon + counter: 42.0 + - limit: 1000.0 + action: createCoupon + counter: 42.0 + redeemedLoyaltyPointsCount: 8.0 + name: Summer promotions + valueMapsIds: + - 100 + - 215 + applicationId: 322 + updated: 2022-10-27T15:00:00Z + callApiEffectCount: 0 + createdLoyaltyPointsEffectCount: 2 + discountCount: 288.0 + revisionFrontendState: revised + description: Campaign for all summer 2021 promotions + activeRevisionVersionId: 6 + currentRevisionVersionId: 6 + startTime: 2021-07-20T22:00:00Z + currentRevisionId: 6 + limits: + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + - period: yearly + entities: + - Coupon + limit: 1000.0 + action: createCoupon + activeRulesetId: 6 + reevaluateOnReturn: true + userId: 388 + awardedGiveawaysCount: 9 + redeemedLoyaltyPointsEffectCount: 9 + linkedStoreIds: - 1 - 2 - 3 - items: - format: int64 - type: integer - type: array - sandbox: - description: Indicates if this is a live or sandbox reward. Rewards of a - given type can only be connected to Applications of the same type. - example: true - title: Sandbox - type: boolean - status: - description: The status of the reward. - enum: - - active - - inactive - example: active - type: string - required: - - accountId - - apiName - - applicationIds - - created - - id - - name - - sandbox - - status - type: object - IntegrationEventV3Request: - properties: - profileId: - description: | - ID of the customer profile set by your integration layer. - - **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. - example: URNGV8294NV - type: string - storeIntegrationId: - description: The integration ID of the store. You choose this ID when you - create a store. - example: STORE-001 - maxLength: 1000 - minLength: 1 - type: string - evaluableCampaignIds: - description: | - When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. - - These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. - example: - - 10 - - 12 - items: - format: int64 - type: integer - title: Campaigns to evaluate - type: array - integrationId: - description: | - The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. - example: 175KJPS947296 - minLength: 1 - type: string - type: - description: | - A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. - example: pageViewed - minLength: 1 - title: Event Type - type: string - attributes: - description: Arbitrary additional JSON properties associated with the event. - They must be created in the Campaign Manager before setting them with - this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). - example: + createdBy: John Doe + addFreeItemEffectCount: 0 + referralSettings: + couponPattern: SUMMER-####-#### + validCharacters: + - A + - B + - C + - D + - E + - F + - G + - H + - I + - J + - K + - L + - M + - "N" + - O + - P + - Q + - R + - S + - T + - U + - V + - W + - X + - "Y" + - Z + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + attributes: '{}' + lastActivity: 2022-11-10T23:00:00Z + endTime: 2021-09-22T22:00:00Z + referralRedemptionCount: 3 + campaignEligibility: + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + - description: Campaign for all summer 2021 promotions + eligibility: + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + - details: + failureCode: ALL_RULES_FAILED + passed: true + couponCode: couponCode + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + eligibility: + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + - details: + failureCode: CONDITION_NOT_MET + referralID: 0 + conditionIndex: 6 + effectIndex: 1 + details: details + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + passed: true + couponCode: couponCode + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + features: + - coupons + - referrals + experiment: + id: 5 + variantId: 5 + name: Summer promotions + startTime: 2021-07-20T22:00:00Z + attributes: '{}' + id: 4 + endTime: 2021-09-22T22:00:00Z + state: enabled + applicationId: 322 + advancedEvent: + connectedSessionId: 175KJPS947296 + effects: + - '{}' + - '{}' + storeIntegrationId: STORE-001 + created: 2020-06-10T09:05:27.993483Z + profileId: URNGV8294NV + referralCode: NT2K54D9 + integrationId: 175KJPS947296 + attributes: myAttribute: myValue - properties: {} - type: object - connectedSessionID: - description: The ID of the session that happened in the past. - example: 175KJPS947296 - minLength: 1 - type: string - previousEventID: - description: The unique identifier of the event that happened in the past. - example: 175KJPS947296 - minLength: 1 - type: string - loyaltyCards: - description: Identifiers of the loyalty cards used during this event. - example: - - loyalty-card-1 - items: - type: string - maxItems: 1 - type: array - responseContent: - description: | - Optional list of requested information to be present on the response related to the tracking custom event. - example: - - triggeredCampaigns - - customerProfile - items: - enum: - - customerProfile - - triggeredCampaigns - - loyalty - - advancedEvent - - awardedGiveaways - - ruleFailureReasons - type: string - type: array - required: - - integrationId - - profileId - - type - type: object - IntegrationEventV3Response: - description: | - This is the response type returned by the trackEventV3 endpoint. + id: 6 + applicationId: 322 + type: pageViewed + ruleFailureReasons: + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 + evaluationGroupMode: stackable + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + rewardId: 7 + evaluationGroupID: 3 + ruleName: ruleName + details: details + campaignName: campaignName + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 + evaluationGroupMode: stackable + couponID: 4928 + referralValue: referralValue + couponValue: couponValue + rewardId: 7 + evaluationGroupID: 3 + ruleName: ruleName + details: details + campaignName: campaignName + rewards: + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - name: 10% Off Coupon + integrationId: free-coffee + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + id: 42 + unlocked: + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 + - profileIntegrationId: customer1 + unlockedAt: 2024-01-01T00:00:00Z + integrationId: reward-unlock-123 + usedAt: 2024-01-02T00:00:00Z + applicationId: 3 properties: customerProfile: $ref: '#/components/schemas/CustomerProfile' @@ -45222,6 +54865,15 @@ components: items: $ref: '#/components/schemas/Campaign' type: array + campaignEligibility: + description: "A list of campaigns and their evaluation status for the current\ + \ customer session.\n\n**Note**:\n\n- This response can **only** be included\ + \ if the `dry` parameter in the query is set to `true`. \n- Do not include\ + \ `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to\ + \ avoid duplicate results.\n" + items: + $ref: '#/components/schemas/CampaignEligibility' + type: array effects: description: The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). @@ -45250,8 +54902,20 @@ components: items: $ref: '#/components/schemas/Giveaway' type: array + achievements: + description: The achievements progress of the customer. + items: + $ref: '#/components/schemas/CustomerAchievement' + type: array + rewards: + description: The rewards for the customer profile. + items: + $ref: '#/components/schemas/RewardWithUnlocks' + type: array advancedEvent: $ref: '#/components/schemas/EventV3' + referral: + $ref: '#/components/schemas/InventoryReferral' required: - createdCoupons - createdReferrals @@ -47102,63 +56766,360 @@ components: - UserID - UsersPerCardLimit type: object - SetLoyaltyPointsExpiryDateEffectProps: - description: | - The properties specific to the "setLoyaltyPointsExpiryDate" effect. This gets triggered when a validated rule contains the "set expiry date" effect. The current expiry date gets set to the date given in the effect. + IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction: properties: - programId: - description: ID of the loyalty program that contains these points. + Amount: + format: float + type: number + Reason: + type: string + Operation: + enum: + - addition + - subtraction + type: string + StartDate: + format: date-time + type: string + ExpiryDate: + format: date-time + type: string + TransactionUUID: + description: The identifier of the transaction in the loyalty ledger. + format: uuid + type: string + required: + - Amount + - Operation + - TransactionUUID + type: object + IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification: + properties: + EventId: + description: The ID of the integration hub event. Return this value in the + delivery-status callback to mark the event delivered or failed. + example: 123 format: int64 type: integer - subLedgerId: - description: API name of the loyalty program subledger that contains these - points. + ProfileIntegrationID: type: string - newExpiryDate: - description: The specified expiry date and time for all active and pending - point transactions in the loyalty program subledger. - example: 2024-07-24T14:15:22Z + LoyaltyProgramID: + format: int64 + type: integer + LoyaltyProgramName: + description: The name of the loyalty program. + type: string + SubledgerID: + type: string + SourceOfEvent: + type: string + CurrentTier: + description: The name of the customer's current tier. + type: string + SessionIntegrationID: + description: 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. + type: string + EmployeeName: + type: string + UserID: + format: int64 + type: integer + CurrentPoints: + format: float + type: number + Actions: + items: + $ref: '#/components/schemas/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationAction' + type: array + PublishedAt: + description: Timestamp when the event was published. format: date-time type: string - affectedTransactions: - description: List of transactions affected by the expiry date update. + required: + - CurrentPoints + - CurrentTier + - EventId + - LoyaltyProgramID + - LoyaltyProgramName + - ProfileIntegrationID + - PublishedAt + - SourceOfEvent + - SubledgerID + type: object + x-discriminator-value: LoyaltyPointsChanged + x-ms-discriminator-value: LoyaltyPointsChanged + IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification: + properties: + EventId: + description: The ID of the integration hub event. Return this value in the + delivery-status callback to mark the event delivered or failed. + example: 123 + format: int64 + type: integer + ProfileIntegrationID: + type: string + LoyaltyProgramID: + format: int64 + type: integer + LoyaltyProgramName: + description: The name of the loyalty program. + type: string + SubledgerID: + type: string + SourceOfEvent: + type: string + CurrentTier: + description: The name of the customer's current tier, or null if the customer + was downgraded below all tiers. + type: string + CurrentPoints: + format: float + type: number + OldTier: + type: string + TierExpirationDate: + format: date-time + type: string + TimestampOfTierChange: + format: date-time + type: string + PublishedAt: + description: Timestamp when the event was published. + format: date-time + type: string + required: + - CurrentPoints + - EventId + - LoyaltyProgramID + - LoyaltyProgramName + - ProfileIntegrationID + - PublishedAt + - SourceOfEvent + - SubledgerID + type: object + x-discriminator-value: LoyaltyTierDowngrade + x-ms-discriminator-value: LoyaltyTierDowngrade + IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification: + properties: + EventId: + description: The ID of the integration hub event. Return this value in the + delivery-status callback to mark the event delivered or failed. + example: 123 + format: int64 + type: integer + ProfileIntegrationID: + type: string + LoyaltyProgramID: + format: int64 + type: integer + LoyaltyProgramName: + description: The name of the loyalty program. + type: string + SubledgerID: + type: string + SourceOfEvent: + type: string + CurrentTier: + description: The name of the customer's current tier. + type: string + CurrentPoints: + format: float + type: number + OldTier: + type: string + PointsRequiredToTheNextTier: + format: float + type: number + NextTier: + type: string + TierExpirationDate: + format: date-time + type: string + TimestampOfTierChange: + format: date-time + type: string + PublishedAt: + description: Timestamp when the event was published. + format: date-time + type: string + required: + - CurrentPoints + - CurrentTier + - EventId + - LoyaltyProgramID + - LoyaltyProgramName + - ProfileIntegrationID + - PublishedAt + - SourceOfEvent + - SubledgerID + type: object + x-discriminator-value: LoyaltyTierUpgrade + x-ms-discriminator-value: LoyaltyTierUpgrade + IntegrationHubEventPayloadCouponBasedNotificationsLimits: + properties: + Action: + type: string + Limit: + format: float + type: number + Period: + type: string + Entities: items: - $ref: '#/components/schemas/LoyaltyLedgerEntryExpiryDateChange' + type: string type: array required: - - newExpiryDate - - programId - - subLedgerId + - Action + - Entities + - Limit + type: object + IntegrationHubEventPayloadCouponBasedNotifications: + properties: + EventId: + description: The ID of the integration hub event. Return this value in the + delivery-status callback to mark the event delivered or failed. + example: 123 + format: int64 + type: integer + Id: + format: int64 + type: integer + Created: + format: date-time + type: string + CampaignId: + format: int64 + type: integer + Value: + type: string + UsageLimit: + format: int64 + type: integer + DiscountLimit: + format: float + type: number + ReservationLimit: + format: int64 + type: integer + StartDate: + format: date-time + type: string + ExpiryDate: + format: date-time + type: string + UsageCounter: + format: int64 + type: integer + DiscountCounter: + format: float + type: number + DiscountRemainder: + format: float + type: number + ReferralId: + format: int64 + type: integer + RecipientIntegrationId: + type: string + ImportId: + format: int64 + type: integer + BatchId: + type: string + Attributes: + properties: {} + type: object + Limits: + items: + $ref: '#/components/schemas/IntegrationHubEventPayloadCouponBasedNotificationsLimits' + type: array + PublishedAt: + description: Timestamp when the event was published. + format: date-time + type: string + SourceOfEvent: + type: string + EmployeeName: + type: string + required: + - CampaignId + - Created + - EmployeeName + - EventId + - Id + - PublishedAt + - SourceOfEvent + - UsageCounter + - UsageLimit + - Value type: object + x-discriminator-value: CouponDeleted + x-ms-discriminator-value: CouponDeleted inline_response_200: example: data: - - features: + - description: Campaign for all summer 2021 promotions + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + tags: + - summer + linkedAudienceIds: + - 3 + - 4 + features: - coupons - referrals + linkedStoreIds: + - 1 + - 2 name: Summer promotions - description: Campaign for all summer 2021 promotions startTime: 2021-07-20T22:00:00Z attributes: '{}' id: 4 endTime: 2021-09-22T22:00:00Z state: enabled applicationId: 322 + - description: Campaign for all summer 2021 promotions + rules: + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + - displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon tags: - summer - - features: + linkedAudienceIds: + - 3 + - 4 + features: - coupons - referrals + linkedStoreIds: + - 1 + - 2 name: Summer promotions - description: Campaign for all summer 2021 promotions startTime: 2021-07-20T22:00:00Z attributes: '{}' id: 4 endTime: 2021-09-22T22:00:00Z state: enabled applicationId: 322 - tags: - - summer hasMore: true properties: hasMore: @@ -47299,6 +57260,10 @@ components: minute: 59 second: 59 id: 6 + campaignIds: + - 1 + - 14 + - 27 recurrencePolicy: no_recurrence status: active - currentProgress: @@ -47325,6 +57290,10 @@ components: minute: 59 second: 59 id: 6 + campaignIds: + - 1 + - 14 + - 27 recurrencePolicy: no_recurrence status: active totalResultSize: 1 @@ -47423,6 +57392,7 @@ components: type: addition expiryDate: 2022-08-02T15:04:05Z07:00 transactionUUID: ce59f12a-f53b-4014-a745-636d93f2bd3f + storeIntegrationId: STORE-001 subledgerId: sub-123 name: Reward 10% points of a purchase's current total validityDuration: 30D @@ -47439,6 +57409,7 @@ components: type: addition expiryDate: 2022-08-02T15:04:05Z07:00 transactionUUID: ce59f12a-f53b-4014-a745-636d93f2bd3f + storeIntegrationId: STORE-001 subledgerId: sub-123 name: Reward 10% points of a purchase's current total validityDuration: 30D @@ -47537,7 +57508,9 @@ components: inline_response_200_8: example: data: - - enableFlattenedCartItems: true + - bestPriorPriceSettings: + enableBestPriorPrice: true + enableFlattenedCartItems: true created: 2020-06-10T09:05:27.993483Z timezone: Europe/Berlin defaultCartItemFilterId: 3 @@ -47738,7 +57711,9 @@ components: limit: 1000.0 action: createCoupon enablePartialDiscounts: false - - enableFlattenedCartItems: true + - bestPriorPriceSettings: + enableBestPriorPrice: true + enableFlattenedCartItems: true created: 2020-06-10T09:05:27.993483Z timezone: Europe/Berlin defaultCartItemFilterId: 3 @@ -48035,7 +58010,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -48190,7 +58165,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -48307,22 +58282,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48347,22 +58322,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48389,22 +58364,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48429,22 +58404,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48478,22 +58453,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48518,22 +58493,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48560,22 +58535,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -48600,22 +58575,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49186,7 +59161,10 @@ components: inline_response_200_16: example: data: - - deletedat: 2000-01-23T04:56:07.000+00:00 + - goalType: other + goalDescription: Offering free shipping will increase average order revenue + more than a 10% discount + deletedat: 2000-01-23T04:56:07.000+00:00 created: 2020-06-10T09:05:27.993483Z campaign: type: advanced @@ -49269,7 +59247,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -49377,22 +59355,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49417,22 +59395,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49459,22 +59437,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49499,22 +59477,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49555,22 +59533,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49595,22 +59573,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49637,22 +59615,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49677,22 +59655,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49706,7 +59684,10 @@ components: applicationId: 322 isVariantAssignmentExternal: true activated: 2000-01-23T04:56:07.000+00:00 - - deletedat: 2000-01-23T04:56:07.000+00:00 + - goalType: other + goalDescription: Offering free shipping will increase average order revenue + more than a 10% discount + deletedat: 2000-01-23T04:56:07.000+00:00 created: 2020-06-10T09:05:27.993483Z campaign: type: advanced @@ -49789,7 +59770,7 @@ components: - 100 - 215 applicationId: 322 - updated: 2000-01-23T04:56:07.000+00:00 + updated: 2022-10-27T15:00:00Z callApiEffectCount: 0 createdLoyaltyPointsEffectCount: 2 discountCount: 288.0 @@ -49897,22 +59878,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49937,22 +59918,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -49979,22 +59960,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -50019,22 +60000,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -50075,22 +60056,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -50115,22 +60096,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -50157,22 +60138,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -50197,22 +60178,22 @@ components: - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter - attributeId: 100 minValue: 0.0 expression: - - string1 - - string2 + - identity + - 10 maxValue: 19.9 - valueType: string - name: my property - description: This is a template parameter of type `number`. + valueType: number + name: Discount percentage + description: The percentage discount applied to the cart total. type: templateParameter description: Creates a discount when a coupon is valid id: 7fa800a8-ac8d-4792-85dc-c4650dcc8f23 @@ -51310,6 +61291,187 @@ components: required: - data inline_response_200_32: + example: + data: + - coupon: BKDB946 + created: 2020-02-07T08:15:22Z + totalDiscounts: 100.0 + integrationId: URNGV8294NV + profileintegrationid: 382370BKDB946 + total: 200.0 + referral: BKDB946 + discounts: + key: 0.8008281904610115 + storeIntegrationId: STORE-001 + profileId: 138 + attributes: '{}' + id: 6 + state: closed + applicationId: 322 + cartItems: + - remainingQuantity: 1 + product: + name: sample_product + quantity: 1 + returnedQuantity: 1 + length: 1.4658129805029452 + weight: 1130.0 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + adjustmentEffectiveFrom: 2021-09-12T10:12:42Z + catalogItemID: 5 + additionalCosts: + shipping: + price: 9 + price: 99.99 + selectedPriceType: member + name: Air Glide + width: 6.027456183070403 + attributes: + image: 11.jpeg + material: leather + adjustmentEffectiveUntil: 2021-09-12T10:12:42Z + position: 5.962133916683182 + sku: SKU1241028 + category: shoes + prices: + member: + price: 90 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + effectiveFrom: 2025-05-25T00:00:00Z + effectiveUntil: 2025-05-30T00:00:00Z + base: + price: 100 + height: 0.8008281904610115 + - remainingQuantity: 1 + product: + name: sample_product + quantity: 1 + returnedQuantity: 1 + length: 1.4658129805029452 + weight: 1130.0 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + adjustmentEffectiveFrom: 2021-09-12T10:12:42Z + catalogItemID: 5 + additionalCosts: + shipping: + price: 9 + price: 99.99 + selectedPriceType: member + name: Air Glide + width: 6.027456183070403 + attributes: + image: 11.jpeg + material: leather + adjustmentEffectiveUntil: 2021-09-12T10:12:42Z + position: 5.962133916683182 + sku: SKU1241028 + category: shoes + prices: + member: + price: 90 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + effectiveFrom: 2025-05-25T00:00:00Z + effectiveUntil: 2025-05-30T00:00:00Z + base: + price: 100 + height: 0.8008281904610115 + - coupon: BKDB946 + created: 2020-02-07T08:15:22Z + totalDiscounts: 100.0 + integrationId: URNGV8294NV + profileintegrationid: 382370BKDB946 + total: 200.0 + referral: BKDB946 + discounts: + key: 0.8008281904610115 + storeIntegrationId: STORE-001 + profileId: 138 + attributes: '{}' + id: 6 + state: closed + applicationId: 322 + cartItems: + - remainingQuantity: 1 + product: + name: sample_product + quantity: 1 + returnedQuantity: 1 + length: 1.4658129805029452 + weight: 1130.0 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + adjustmentEffectiveFrom: 2021-09-12T10:12:42Z + catalogItemID: 5 + additionalCosts: + shipping: + price: 9 + price: 99.99 + selectedPriceType: member + name: Air Glide + width: 6.027456183070403 + attributes: + image: 11.jpeg + material: leather + adjustmentEffectiveUntil: 2021-09-12T10:12:42Z + position: 5.962133916683182 + sku: SKU1241028 + category: shoes + prices: + member: + price: 90 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + effectiveFrom: 2025-05-25T00:00:00Z + effectiveUntil: 2025-05-30T00:00:00Z + base: + price: 100 + height: 0.8008281904610115 + - remainingQuantity: 1 + product: + name: sample_product + quantity: 1 + returnedQuantity: 1 + length: 1.4658129805029452 + weight: 1130.0 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + adjustmentEffectiveFrom: 2021-09-12T10:12:42Z + catalogItemID: 5 + additionalCosts: + shipping: + price: 9 + price: 99.99 + selectedPriceType: member + name: Air Glide + width: 6.027456183070403 + attributes: + image: 11.jpeg + material: leather + adjustmentEffectiveUntil: 2021-09-12T10:12:42Z + position: 5.962133916683182 + sku: SKU1241028 + category: shoes + prices: + member: + price: 90 + adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b + effectiveFrom: 2025-05-25T00:00:00Z + effectiveUntil: 2025-05-30T00:00:00Z + base: + price: 100 + height: 0.8008281904610115 + hasMore: true + totalResultSize: 0 + properties: + hasMore: + type: boolean + totalResultSize: + format: int64 + type: integer + data: + items: + $ref: '#/components/schemas/ApplicationSession' + type: array + required: + - data + inline_response_200_33: example: data: - effects: @@ -51322,6 +61484,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -51339,6 +61502,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -51350,6 +61514,7 @@ components: storeIntegrationId: STORE-001 created: 2020-06-10T09:05:27.993483Z profileId: 138 + integrationId: 175KJPS947296 attributes: '{}' id: 6 sessionId: 6 @@ -51357,30 +61522,34 @@ components: storeId: 0 type: type ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details @@ -51395,6 +61564,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -51412,6 +61582,7 @@ components: effectType: rejectCoupon adjustmentReferenceId: 68851723-e6fa-488f-ace9-112581e6c19b props: '{}' + rewardId: 7 selectedPrice: 100.0 evaluationGroupID: 3 triggeredForCatalogItem: 786 @@ -51423,6 +61594,7 @@ components: storeIntegrationId: STORE-001 created: 2020-06-10T09:05:27.993483Z profileId: 138 + integrationId: 175KJPS947296 attributes: '{}' id: 6 sessionId: 6 @@ -51430,30 +61602,34 @@ components: storeId: 0 type: type ruleFailureReasons: - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details campaignName: campaignName - - rulesetID: 6 - ruleIndex: 5 - campaignID: 0 - referralID: 1 - conditionIndex: 5 - effectIndex: 2 + - rulesetID: 7 + ruleIndex: 3 + campaignID: 2 + referralID: 9 + rewardIntegrationId: 5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90 + conditionIndex: 2 + effectIndex: 4 evaluationGroupMode: stackable couponID: 4928 referralValue: referralValue couponValue: couponValue + rewardId: 7 evaluationGroupID: 3 ruleName: ruleName details: details @@ -51469,7 +61645,7 @@ components: required: - data - hasMore - inline_response_200_33: + inline_response_200_34: example: data: - data @@ -51487,7 +61663,7 @@ components: required: - data - totalResultSize - inline_response_200_34: + inline_response_200_35: example: data: - accountId: 3886 @@ -51495,6 +61671,9 @@ components: lastUpdate: 2022-04-26T11:02:38Z name: Travel audience sandbox: true + subscribedApplicationsIds: + - 3 + - 13 integration: mparticle description: Travel audience 18-27 integrationId: 382370BKDB946 @@ -51505,6 +61684,9 @@ components: lastUpdate: 2022-04-26T11:02:38Z name: Travel audience sandbox: true + subscribedApplicationsIds: + - 3 + - 13 integration: mparticle description: Travel audience 18-27 integrationId: 382370BKDB946 @@ -51525,7 +61707,7 @@ components: type: array required: - data - inline_response_200_35: + inline_response_200_36: example: data: - membersCount: 1234 @@ -51542,7 +61724,7 @@ components: type: array required: - data - inline_response_200_36: + inline_response_200_37: example: data: - accountId: 31 @@ -51597,16 +61779,18 @@ components: type: array required: - data - inline_response_200_37: + inline_response_200_38: example: data: - - friendIntegrationId: friendIntegrationId + - advancedEventIntegrationId: advanced_event_1234 + friendIntegrationId: friendIntegrationId code: code created: 2000-01-23T04:56:07.000+00:00 sessionId: sessionId advocateIntegrationId: advocateIntegrationId applicationId: 322 - - friendIntegrationId: friendIntegrationId + - advancedEventIntegrationId: advanced_event_1234 + friendIntegrationId: friendIntegrationId code: code created: 2000-01-23T04:56:07.000+00:00 sessionId: sessionId @@ -51627,7 +61811,7 @@ components: type: array required: - data - inline_response_200_38: + inline_response_200_39: example: data: - created: 2020-06-10T09:05:27.993483Z @@ -51701,7 +61885,7 @@ components: required: - data - totalResultSize - inline_response_200_39: + inline_response_200_40: example: data: - product: @@ -51749,7 +61933,7 @@ components: type: array required: - data - inline_response_200_40: + inline_response_200_41: example: data: - accountId: 3886 @@ -51785,7 +61969,7 @@ components: required: - data - totalResultSize - inline_response_200_41: + inline_response_200_42: example: data: - headers: @@ -51843,7 +62027,7 @@ components: required: - data - totalResultSize - inline_response_200_42: + inline_response_200_43: example: data: - created: 2020-06-10T09:05:27.993483Z @@ -51869,7 +62053,7 @@ components: required: - data - totalResultSize - inline_response_200_43: + inline_response_200_44: example: data: - created: 2020-06-10T09:05:27.993483Z @@ -51923,7 +62107,7 @@ components: required: - data - totalResultSize - inline_response_200_44: + inline_response_200_45: example: data: - new: @@ -51975,7 +62159,7 @@ components: type: array required: - data - inline_response_200_45: + inline_response_200_46: example: data: - filter: '{}' @@ -52003,13 +62187,18 @@ components: required: - data - totalResultSize - inline_response_200_46: + inline_response_200_47: example: data: - accountId: 3886 isReadonly: false created: 2020-06-10T09:05:27.993483Z permissions: + thresholds: + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 permissionSets: - name: Application permission set logicalOperations: @@ -52058,6 +62247,11 @@ components: isReadonly: false created: 2020-06-10T09:05:27.993483Z permissions: + thresholds: + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 + - loyaltyPointsLimit: 100 + loyaltyProgramId: 8 permissionSets: - name: Application permission set logicalOperations: @@ -52115,7 +62309,7 @@ components: required: - data - totalResultSize - inline_response_200_47: + inline_response_200_48: example: data: - linkedCampaignIds: @@ -52161,7 +62355,7 @@ components: type: array required: - data - inline_response_200_48: + inline_response_200_49: example: data: - createdBy: 216 @@ -52192,7 +62386,7 @@ components: type: array required: - data - inline_response_200_49: + inline_response_200_50: example: data: - period: period @@ -52214,7 +62408,7 @@ components: items: $ref: '#/components/schemas/ListCampaignStoreBudgets' type: array - inline_response_200_50: + inline_response_200_51: example: data: - period: overall @@ -52230,7 +62424,7 @@ components: items: $ref: '#/components/schemas/SummaryCampaignStoreBudget' type: array - inline_response_200_51: + inline_response_200_52: example: data: - period: 1Y @@ -52289,10 +62483,94 @@ components: type: array required: - data - inline_response_200_52: + inline_response_200_53: example: data: - - endDate: 2000-01-23T04:56:07.000+00:00 + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + period: 1Y + endDate: 2024-01-15T15:04:05+07:00 + created: 2020-06-10T09:05:27.993483Z + timezone: Europe/Berlin + campaignId: 3 + sandbox: true + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + userId: 1234 + hasProgress: true + target: 50.0 + subscribedApplications: + - 132 + - 97 + fixedStartDate: 2024-01-15T15:04:05+07:00 + createdBy: John Doe + name: Order50Discount + periodEndOverride: + month: 11 + dayOfMonth: 23 + hour: 23 + minute: 59 + second: 59 + id: 6 + recurrencePolicy: no_recurrence + status: active + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + period: 1Y + endDate: 2024-01-15T15:04:05+07:00 + created: 2020-06-10T09:05:27.993483Z + timezone: Europe/Berlin + campaignId: 3 + sandbox: true + description: 50% off for every 50th purchase in a year. + activationPolicy: fixed_schedule + title: 50% off on 50th purchase. + allowRollbackAfterCompletion: false + userId: 1234 + hasProgress: true + target: 50.0 + subscribedApplications: + - 132 + - 97 + fixedStartDate: 2024-01-15T15:04:05+07:00 + createdBy: John Doe + name: Order50Discount + periodEndOverride: + month: 11 + dayOfMonth: 23 + hour: 23 + minute: 59 + second: 59 + id: 6 + recurrencePolicy: no_recurrence + status: active + hasMore: true + properties: + hasMore: + type: boolean + data: + items: + $ref: '#/components/schemas/AchievementV2' + type: array + required: + - data + inline_response_200_54: + example: + data: + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 achievementAllowRollbackAfterCompletion: false campaignId: 3 achievementId: 3 @@ -52306,9 +62584,18 @@ components: achievementEndDate: 2000-01-23T04:56:07.000+00:00 progress: 10.0 completionDate: 2000-01-23T04:56:07.000+00:00 + campaignIds: + - 1 + - 14 + - 27 startDate: 2000-01-23T04:56:07.000+00:00 status: completed - - endDate: 2000-01-23T04:56:07.000+00:00 + - referencedByCampaigns: + - id: 1 + applicationId: 2 + - id: 1 + applicationId: 2 + endDate: 2000-01-23T04:56:07.000+00:00 achievementAllowRollbackAfterCompletion: false campaignId: 3 achievementId: 3 @@ -52322,6 +62609,10 @@ components: achievementEndDate: 2000-01-23T04:56:07.000+00:00 progress: 10.0 completionDate: 2000-01-23T04:56:07.000+00:00 + campaignIds: + - 1 + - 14 + - 27 startDate: 2000-01-23T04:56:07.000+00:00 status: completed hasMore: true @@ -52336,7 +62627,7 @@ components: required: - data - hasMore - inline_response_200_53: + inline_response_200_55: example: data: - summary: Session total was less than the required total. @@ -52366,6 +62657,155 @@ components: type: array required: - data + inline_response_200_56_catalog: + description: The paginated rewards catalog. + example: + data: + - name: 10% Off Coupon + pointsRequired: + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + eligibility: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + id: 42 + - name: 10% Off Coupon + pointsRequired: + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + eligibility: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + id: 42 + hasMore: true + properties: + hasMore: + description: Whether more pages exist after the current one. + type: boolean + data: + items: + $ref: '#/components/schemas/RewardCatalogItem' + type: array + required: + - data + - hasMore + inline_response_200_56: + example: + catalog: + data: + - name: 10% Off Coupon + pointsRequired: + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + eligibility: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + id: 42 + - name: 10% Off Coupon + pointsRequired: + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + - amount: 500.0 + subledgerId: mysubledger + loyaltyProgramId: 10 + id: 1 + description: Applies to next order + rule: + displayDescription: Get a 20% discount on all shoes during Thanksgiving! + Offer valid till Dec 5 only. + displayName: 20% off all shoes! + relatedData: https://example.com/discounts/20-off-shoes.png + title: Give discount via coupon + eligibility: + details: + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + - failureCode: CONDITION_NOT_MET + conditionIndex: 0 + passed: true + id: 42 + hasMore: true + loyalty: + key: + balance: + negativePoints: 286.0 + activePoints: 286.0 + spentPoints: 150.0 + expiredPoints: 286.0 + pendingPoints: 50.0 + subledgerBalances: + mysubledger: + activePoints: 286 + pendingPoints: 50 + spentPoints: 150 + expiredPoints: 25 + negativePoints: 0 + properties: + catalog: + $ref: '#/components/schemas/inline_response_200_56_catalog' + loyalty: + additionalProperties: + $ref: '#/components/schemas/LoyaltyBalances' + description: | + The customer's loyalty balances for the specified loyalty program. + Returned only when `loyaltyProgramId` is provided together with + `profileIntegrationId` or `loyaltyCardId`. + type: object + required: + - catalog GenerateRuleTitle_rule: properties: effects: @@ -52397,6 +62837,297 @@ components: type: object minItems: 1 type: array + TriggerWebhookBlock_webhook: + description: The webhook to trigger. + properties: + id: + description: The unique identifier of the webhook. + example: 1 + format: int64 + type: integer + title: + description: The display name of the webhook. + example: Thank you for your order. + type: string + required: + - id + - title + CheckAudienceBlock_audience: + description: The audience to check the profile against. + properties: + id: + description: The ID of the audience. + example: 42 + format: int64 + type: integer + name: + description: The display name of the audience. + example: Travel audience + type: string + integration: + description: | + The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. + + For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. + + **Note:** If you do not integrate with any of these platforms, do not use this property. + example: mparticle + type: string + integrationId: + description: | + The ID of this audience in the third-party integration. + + **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. + example: 382370BKDB946 + type: string + required: + - id + - name + CheckLoyaltyBalanceBlock_program: + description: The loyalty program whose ledger balance is checked. + properties: + id: + description: The ID of the loyalty program. + example: 10 + format: int64 + type: integer + name: + description: The internal name of the loyalty program. + example: MainProgram + type: string + title: + description: The display name of the loyalty program. + example: Main Loyalty Program + type: string + required: + - id + - name + - title + UpdateAudienceMembershipBlock_audience: + description: The audience to add the customer to or remove them from. + properties: + id: + description: The ID of the audience. + example: 42 + format: int64 + type: integer + name: + description: The display name of the audience. + example: Travel audience + type: string + integration: + description: | + The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. + + For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. + + **Note:** If you do not integrate with any of these platforms, do not use this property. + example: mparticle + type: string + integrationId: + description: | + The ID of this audience in the third-party integration. + + **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. + example: 382370BKDB946 + type: string + required: + - id + - name + UpdateAchievementProgressBlock_achievement: + description: The achievement to update. + properties: + id: + description: The ID of the achievement. + example: 42 + format: int64 + type: integer + name: + description: The internal name of the achievement used in API requests. + example: Order50Discount + type: string + title: + description: The display name of the achievement in the Campaign Manager. + example: 50% off on 50th purchase. + type: string + target: + description: The required number of actions or the transactional milestone + to complete the achievement. + example: 50.0 + type: number + required: + - id + - name + - target + - title + UpdateAttributeValueBlock_attribute: + description: The attribute being updated. + properties: + id: + description: The internal ID of the attribute. Reverts to `0` when the attribute + is deleted or does not exist. + example: 100 + format: int64 + type: integer + entity: + description: The entity type that owns the attribute. Reverts to an empty + string when the attribute is deleted or does not exist. + example: profile + type: string + name: + description: The attribute name as used in API requests. + example: City + type: string + title: + description: The human-readable name of the attribute. + example: City + type: string + type: + description: The data type of the attribute. + example: string + type: string + required: + - entity + - id + - name + - title + - type + UpdateAttributeValueBlock_target: + description: The entity or item scope that this effect operates on. + properties: + type: + description: Identifies the target scope of the attribute update. + enum: + - session + - profile + - advocateProfile + - coupon + - referral + - event + - loyaltyCard + - allItems + - selector + - globalFilter + example: profile + type: string + name: + description: Identifies the name of the target when its type is set to `selector` + or `globalFilter`. + example: Filter items by product + type: string + required: + - type + TriggerCustomEffectBlock_customEffect: + description: The custom effect to trigger. + properties: + id: + description: The unique identifier of the custom effect. + example: 1 + format: int64 + type: integer + name: + description: The name of the custom effect, as used in API requests. + example: sendEmail + type: string + title: + description: The display name of the custom effect. + example: Send email + type: string + required: + - id + - name + - title + TriggerCustomEffectBlock_target: + description: The target scope of this effect. + properties: + type: + description: 'The scope the custom effect applies to: - `cart` applies once + to the whole cart. - `allItems` applies once per cart item. - `selector` + applies once per item matched by the named selector. - `globalFilter` + applies once per item matched by the named global item filter. - `bundle` + applies once per item in the named bundle.' + enum: + - cart + - allItems + - selector + - globalFilter + - bundle + example: cart + type: string + name: + description: The name of the targeted selector or bundle. Only set when + `type` is `selector`, `globalFilter`, or `bundle`. + example: giftBundle + type: string + required: + - type + CheckAchievementBlock_achievement: + description: The achievement to check for. + properties: + id: + description: The ID of the achievement. + example: 42 + format: int64 + type: integer + title: + description: The display name for the achievement in the Campaign Manager. + example: 50% off on 50th purchase. + type: string + name: + description: The internal name of the achievement used in API requests. + example: Order50Discount + type: string + target: + description: The required number of actions or the transactional milestone + to complete the achievement. + example: 50.0 + type: number + required: + - id + - name + - target + - title + CheckTierBlock_tier: + properties: + id: + description: The ID of the tier. + example: 42 + format: int64 + type: integer + name: + description: The display name of the tier. + example: Bronze + type: string + minPoints: + description: The minimum amount of points required to enter the tier. + example: 150.0 + type: number + upperLimit: + type: number + required: + - id + - minPoints + - name + RedeemLoyaltyPointsBlock_program: + description: The loyalty program whose balance points are deducted from. + properties: + id: + description: The ID of the loyalty program. + example: 10 + format: int64 + type: integer + name: + description: The internal name of the loyalty program. + example: MainProgram + type: string + title: + description: The display name of the loyalty program. + example: Main Loyalty Program + type: string + required: + - id + - name + - title ExperimentCopy_experiment: properties: isVariantAssignmentExternal: @@ -52405,11 +63136,24 @@ components: type: boolean campaign: $ref: '#/components/schemas/ExperimentCampaignCopy' + goalType: + description: | + The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the value from the source experiment is used. + enum: + - other + - maximize_revenue + - maximize_items_sold + - optimize_discount_efficiency + type: string + goalDescription: + description: | + A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the value from the source experiment is used. + type: string required: - campaign - isVariantAssignmentExternal ScimBaseUser_name: - description: The components of the user’s real name. + description: The components of the user's real name. example: formatted: Mr. John J Doe properties: @@ -52546,7 +63290,7 @@ components: **Management API Keys**. 1. Click **Create Key** and give it a name. 1. Set an expiration date. - > [!tip] Avoid choosing expiration dates that fall at the end of the year or during other high-traffic periods. + **Tip**: Avoid choosing expiration dates that fall at the end of the year or during other high-traffic periods. 1. Choose the endpoints the key should give access to. 1. Click **Create Key**. 1. Share it with your developer. diff --git a/build.gradle b/build.gradle index a9e02026..a3d5461c 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'eclipse' apply plugin: 'java' group = 'one.talon' -version = '15.0.0' +version = '16.0.0' buildscript { repositories { diff --git a/build.sbt b/build.sbt index cdbff8ee..6deb10b5 100644 --- a/build.sbt +++ b/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "one.talon", name := "talon-one-client", - version := "15.0.0", + version := "16.0.0", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), javacOptions in compile ++= Seq("-Xlint:deprecation"), diff --git a/docs/AcceptCouponEffectProps.md b/docs/AcceptCouponEffectProps.md index ca3a5467..6e2659e7 100644 --- a/docs/AcceptCouponEffectProps.md +++ b/docs/AcceptCouponEffectProps.md @@ -2,7 +2,7 @@ # AcceptCouponEffectProps -The properties specific to the \"acceptCoupon\" effect. This gets triggered whenever the coupon is valid and all other conditions in the rules of its campaign are met. +This effect indicates that the coupon code supplied was valid. You should handle this effect by clearing any messages from previous `rejectCoupon` effects and informing the user that the coupon is valid. The code is automatically redeemed when you close the session. Other effects, such as [setDiscount](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscount), provide more information about the actual rewards received. ## Properties Name | Type | Description | Notes diff --git a/docs/AcceptReferralEffectProps.md b/docs/AcceptReferralEffectProps.md index d08f2556..bd3510e8 100644 --- a/docs/AcceptReferralEffectProps.md +++ b/docs/AcceptReferralEffectProps.md @@ -2,12 +2,12 @@ # AcceptReferralEffectProps -The properties specific to the \"acceptReferral\" effect. TThis gets triggered whenever the referral code is valid and all other conditions in the rules of its campaign are met. +This effect indicates that the referral code supplied is valid. You should handle this effect by informing the user that the referral code is valid. The code is automatically redeemed when you close the session. Other effects will provide more information about the actual reward. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**value** | **String** | The referral code that was accepted. | +**value** | **String** | The referral code provided in the session. | diff --git a/docs/AchievementAdditionalPropertiesV2.md b/docs/AchievementAdditionalPropertiesV2.md index 75423b6e..78cd0322 100644 --- a/docs/AchievementAdditionalPropertiesV2.md +++ b/docs/AchievementAdditionalPropertiesV2.md @@ -8,8 +8,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **userId** | **Long** | The ID of the user that created this achievement. | **createdBy** | **String** | Name of the user that created the achievement. **Note**: This is not available if the user has been deleted. | [optional] +**periodEndOverride** | [**TimePoint**](TimePoint.md) | | [optional] **hasProgress** | **Boolean** | Indicates if a customer has made progress in the achievement. | [optional] -**status** | [**StatusEnum**](#StatusEnum) | The status of the achievement. | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. | [optional] @@ -17,10 +18,9 @@ Name | Type | Description | Notes Name | Value ---- | ----- -INPROGRESS | "inprogress" +ACTIVE | "active" +SCHEDULED | "scheduled" EXPIRED | "expired" -NOT_STARTED | "not_started" -COMPLETED | "completed" diff --git a/docs/AchievementBaseV2.md b/docs/AchievementBaseV2.md index ea809321..f8042bdf 100644 --- a/docs/AchievementBaseV2.md +++ b/docs/AchievementBaseV2.md @@ -16,9 +16,7 @@ Name | Type | Description | Notes **fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is set to `fixed_schedule`. **Note:** It must be an RFC3339 timestamp string. | [optional] **endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It must be an RFC3339 timestamp string. | [optional] **allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | [optional] -**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | [optional] **subscribedApplications** | **List<Long>** | A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. | [optional] -**timezone** | **String** | A string containing an IANA timezone descriptor. | [optional] diff --git a/docs/AchievementProgressWithDefinition.md b/docs/AchievementProgressWithDefinition.md index 303337cd..8793de39 100644 --- a/docs/AchievementProgressWithDefinition.md +++ b/docs/AchievementProgressWithDefinition.md @@ -16,7 +16,9 @@ Name | Type | Description | Notes **name** | **String** | The internal name of the achievement used in API requests. | **title** | **String** | The display name of the achievement in the Campaign Manager. | **description** | **String** | The description of the achievement in the Campaign Manager. | -**campaignId** | **Long** | The ID of the campaign the achievement belongs to. | +**campaignId** | **Long** | This property is **deprecated**. Use `campaignIds` (Integration API) or `referencedByCampaigns` (Management API) instead. This field contains the first campaign ID from the related `campaignIds`, and is omitted when `campaignIds` is empty. | [optional] +**campaignIds** | **List<Long>** | The IDs of the campaigns that reference this achievement, in ascending order. | +**referencedByCampaigns** | [**List<CampaignReference>**](CampaignReference.md) | The campaigns that reference this achievement, in ascending order of their `id`. | **target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | [optional] **achievementRecurrencePolicy** | [**AchievementRecurrencePolicyEnum**](#AchievementRecurrencePolicyEnum) | 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. | **achievementActivationPolicy** | [**AchievementActivationPolicyEnum**](#AchievementActivationPolicyEnum) | 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. | diff --git a/docs/AchievementReference.md b/docs/AchievementReference.md index 22d45e05..676d095e 100644 --- a/docs/AchievementReference.md +++ b/docs/AchievementReference.md @@ -10,6 +10,18 @@ Name | Type | Description | Notes **applicationId** | **Long** | The ID of the Application associated with the campaign that references this achievement. | **applicationName** | **String** | The name of the Application associated with the campaign that references this achievement. | **campaignId** | **Long** | The ID of the campaign that references this achievement. | +**campaignName** | **String** | The name of the campaign that references this achievement. | +**campaignState** | [**CampaignStateEnum**](#CampaignStateEnum) | The state of the campaign that references this achievement. | + + + +## Enum: CampaignStateEnum + +Name | Value +---- | ----- +ENABLED | "enabled" +DISABLED | "disabled" +ARCHIVED | "archived" diff --git a/docs/AchievementStatusEntry.md b/docs/AchievementStatusEntry.md index fc91bb03..14fb9946 100644 --- a/docs/AchievementStatusEntry.md +++ b/docs/AchievementStatusEntry.md @@ -19,7 +19,8 @@ Name | Type | Description | Notes **fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is set to `fixed_schedule`. **Note:** It must be an RFC3339 timestamp string. | [optional] **endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It must be an RFC3339 timestamp string. | [optional] **allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | [optional] -**campaignId** | **Long** | The ID of the campaign the achievement belongs to. | [optional] +**campaignId** | **Long** | This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. | [optional] +**campaignIds** | **List<Long>** | The IDs of the campaigns that reference this achievement, in ascending order. | [optional] **status** | [**StatusEnum**](#StatusEnum) | The status of the achievement. | [optional] **currentProgress** | [**AchievementProgress**](AchievementProgress.md) | | [optional] diff --git a/docs/AchievementV2.md b/docs/AchievementV2.md index 2503a54f..50d4fe4e 100644 --- a/docs/AchievementV2.md +++ b/docs/AchievementV2.md @@ -18,13 +18,16 @@ Name | Type | Description | Notes **fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is set to `fixed_schedule`. **Note:** It must be an RFC3339 timestamp string. | [optional] **endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It must be an RFC3339 timestamp string. | [optional] **allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | [optional] -**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | **subscribedApplications** | **List<Long>** | A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. | -**timezone** | **String** | A string containing an IANA timezone descriptor. | **userId** | **Long** | The ID of the user that created this achievement. | **createdBy** | **String** | Name of the user that created the achievement. **Note**: This is not available if the user has been deleted. | [optional] +**periodEndOverride** | [**TimePoint**](TimePoint.md) | | [optional] **hasProgress** | **Boolean** | Indicates if a customer has made progress in the achievement. | [optional] -**status** | [**StatusEnum**](#StatusEnum) | The status of the achievement. | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. | [optional] +**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | +**timezone** | **String** | A string containing an IANA timezone descriptor. | +**campaignId** | **Long** | This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. | [optional] +**referencedByCampaigns** | [**List<CampaignReference>**](CampaignReference.md) | The campaigns that reference this achievement. They are sorted in ascending order by their id. | @@ -51,10 +54,9 @@ FIXED_SCHEDULE | "fixed_schedule" Name | Value ---- | ----- -INPROGRESS | "inprogress" +ACTIVE | "active" +SCHEDULED | "scheduled" EXPIRED | "expired" -NOT_STARTED | "not_started" -COMPLETED | "completed" diff --git a/docs/AddFreeItemEffectProps.md b/docs/AddFreeItemEffectProps.md index 602629d9..f6d6f59e 100644 --- a/docs/AddFreeItemEffectProps.md +++ b/docs/AddFreeItemEffectProps.md @@ -2,13 +2,13 @@ # AddFreeItemEffectProps -The properties specific to the \"addFreeItem\" effect. This gets triggered whenever a validated rule contained an \"add free item\" effect. +This effect indicates that a free item should be added to the shopping cart in the current session. In this example, add the SKU to the shopping cart and set its price to `0`. The effect of a successful referral can mean a free item for someone else, such as the referrer. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **sku** | **String** | SKU of the item that needs to be added. | -**name** | **String** | The name / description of the effect | +**name** | **String** | Description of the effect. | **desiredQuantity** | **Long** | The original quantity in case a partial reward was applied. | [optional] diff --git a/docs/AddLoyaltyPointsEffectProps.md b/docs/AddLoyaltyPointsEffectProps.md index 3c729023..51d8ed23 100644 --- a/docs/AddLoyaltyPointsEffectProps.md +++ b/docs/AddLoyaltyPointsEffectProps.md @@ -2,27 +2,27 @@ # AddLoyaltyPointsEffectProps -The properties specific to the \"addLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained an \"add loyalty\" effect. These points are automatically stored and managed inside Talon.One. +This effect indicates that a defined amount of loyalty points was successfully added to the customer's profile or to a loyalty card. If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which item to add the loyalty points for. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. See the example below for more information. If your list of cart items is a [bundle definition](https://docs.talon.one/docs/product/rules/create-and-manage-bundles), use the `bundleIndex` and `bundleName` properties to identify the bundle containing the items for which loyalty points are added. If you have set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card on which these points are added. The points only persist when the session is closed. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name / description of this loyalty point addition. | +**name** | **String** | The reason of this loyalty point addition. | **programId** | **Long** | The ID of the loyalty program where these points were added. | **subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were added. | **value** | [**BigDecimal**](BigDecimal.md) | The amount of points that were added. | -**desiredValue** | [**BigDecimal**](BigDecimal.md) | The original amount of loyalty points to be awarded. | [optional] +**desiredValue** | [**BigDecimal**](BigDecimal.md) | (Partial rewards enabled only) The amount of loyalty points to be awarded without considering budget limitations. | [optional] **recipientIntegrationId** | **String** | The user for whom these points were added. | -**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | Date after which points will be valid. | [optional] -**expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | Date after which points will expire. | [optional] -**transactionUUID** | **String** | The identifier of this addition in the loyalty ledger. | -**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item in the cart items list on which the loyal points addition should be applied. | [optional] -**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | For cart items with `quantity` > 1, the sub position indicates to which item the loyalty points addition is applied. | [optional] +**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date after which the added points will be valid. | [optional] +**expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date after which the added points will expire. | [optional] +**transactionUUID** | **String** | The identifier of this loyalty point transaction. | +**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | (_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were added. | [optional] +**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | (_Add points per cart item_ ) The index of the item unit in its line item. | [optional] **cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] -**bundleIndex** | **Long** | The position of the bundle in a list of item bundles created from the same bundle definition. | [optional] -**bundleName** | **String** | The name of the bundle definition. | [optional] -**awaitsActivation** | **Boolean** | If `true`, the loyalty points remain pending until a specific action is complete. The `startDate` parameter automatically sets to `on_action`. | [optional] -**validityDuration** | **String** | The duration for which the points remain active, calculated relative to the activation date. **Note**: This value is returned only if `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] +**bundleIndex** | **Long** | _(With bundles only)_ The position of the specific bundle in the list of bundles created from the same bundle definition. | [optional] +**bundleName** | **String** | _(With bundles only)_ The name of the bundle definition. | [optional] +**awaitsActivation** | **Boolean** | Indicates whether the points have an action-based start date. This property is returned only for point transactions with an action-based start date. | [optional] +**validityDuration** | **String** | The duration for which the points remain active, calculated relative to their start date. | [optional] diff --git a/docs/AddLoyaltyPointsSupport.md b/docs/AddLoyaltyPointsSupport.md new file mode 100644 index 00000000..4d7aed9e --- /dev/null +++ b/docs/AddLoyaltyPointsSupport.md @@ -0,0 +1,22 @@ + + +# AddLoyaltyPointsSupport + +Points to add via the support portal. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**points** | [**BigDecimal**](BigDecimal.md) | Amount of loyalty points. | +**name** | **String** | Name / reason for the point addition. | [optional] +**validityDuration** | **String** | The time format is either: - `unlimited` or, - an **integer** followed by one letter indicating the time unit. Examples: `unlimited`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `validUntil` should be omitted. | [optional] +**validUntil** | [**OffsetDateTime**](OffsetDateTime.md) | Date and time when points should expire. The value should be provided in RFC 3339 format. If passed, `validityDuration` should be omitted. | [optional] +**pendingDuration** | **String** | The amount of time before the points are considered valid. The time format is either: - `immediate` or, - `on_action` or, - an **integer** followed by one letter indicating the time unit. Examples: `immediate`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`, `on_action`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. | [optional] +**pendingUntil** | [**OffsetDateTime**](OffsetDateTime.md) | Date and time after the points are considered valid. The value should be provided in RFC 3339 format. If passed, `pendingDuration` should be omitted. | [optional] +**subledgerId** | **String** | ID of the subledger the points are added to. If there is no existing subledger with this ID, the subledger is created automatically. | [optional] +**applicationId** | **Long** | ID of the Application that is connected to the loyalty program. It is displayed in your Talon.One deployment URL. | [optional] +**supportRequestId** | **Long** | ID of the support request to approve. When provided by an admin, the points are added on behalf of the support user who created the request. | [optional] +**processingNote** | **String** | Note from the admin approving the support request. Stored as the processing note on the support request record. This is only used when a supportRequestId is passed. | [optional] + + + diff --git a/docs/AddToAudienceEffectProps.md b/docs/AddToAudienceEffectProps.md index e75e7fbc..89678a46 100644 --- a/docs/AddToAudienceEffectProps.md +++ b/docs/AddToAudienceEffectProps.md @@ -2,7 +2,7 @@ # AddToAudienceEffectProps -The properties specific to the \"addToAudience\" effect. This gets triggered whenever a validated rule contains an \"addToAudience\" effect. +This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Add customer to an audience** selected is validated. It indicates that a customer was added to an audience and is returned when a customer session is opened, updated, or closed. ## Properties Name | Type | Description | Notes diff --git a/docs/AdditionalCostReference.md b/docs/AdditionalCostReference.md new file mode 100644 index 00000000..7baace76 --- /dev/null +++ b/docs/AdditionalCostReference.md @@ -0,0 +1,15 @@ + + +# AdditionalCostReference + +Identifies an additional cost referenced from a rule. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal identifier of the additional cost. | +**name** | **String** | The additional cost name as used in API requests. | +**title** | **String** | The human-readable title of the additional cost. | [optional] + + + diff --git a/docs/Application.md b/docs/Application.md index 9ff7f51e..73b2d5e6 100644 --- a/docs/Application.md +++ b/docs/Application.md @@ -27,6 +27,7 @@ Name | Type | Description | Notes **defaultEvaluationGroupId** | **Long** | The ID of the default campaign evaluation group to which new campaigns will be added unless a different group is selected when creating the campaign. | [optional] **defaultCartItemFilterId** | **Long** | The ID of the default Cart-Item-Filter for this application. | [optional] **enableCampaignStateManagement** | **Boolean** | Indicates whether the campaign staging and revisions feature is enabled for the Application. **Important:** After this feature is enabled, it cannot be disabled. | [optional] +**bestPriorPriceSettings** | [**BestPriorPriceSettings**](BestPriorPriceSettings.md) | | [optional] **loyaltyPrograms** | [**List<LoyaltyProgram>**](LoyaltyProgram.md) | An array containing all the loyalty programs to which this application is subscribed. | diff --git a/docs/ApplicationEvent.md b/docs/ApplicationEvent.md index 3af451df..fb044497 100644 --- a/docs/ApplicationEvent.md +++ b/docs/ApplicationEvent.md @@ -12,8 +12,9 @@ Name | Type | Description | Notes **profileId** | **Long** | The globally unique Talon.One ID of the customer that created this entity. | [optional] **storeId** | **Long** | The ID of the store. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | [optional] **sessionId** | **Long** | The globally unique Talon.One ID of the session that contains this event. | [optional] -**type** | **String** | A string representing the event. Must not be a reserved event name. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Additional JSON serialized data associated with the event. | **effects** | [**List<Effect>**](Effect.md) | An array containing the effects that were applied as a result of this event. | **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | An array containing the rule failure reasons which happened during this event. | [optional] diff --git a/docs/ApplicationMembership.md b/docs/ApplicationMembership.md new file mode 100644 index 00000000..9744e2f1 --- /dev/null +++ b/docs/ApplicationMembership.md @@ -0,0 +1,13 @@ + + +# ApplicationMembership + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applicationId** | **Long** | The ID of the Application the customer belongs to. | +**applicationName** | **String** | The name of the Application the customer belongs to. | + + + diff --git a/docs/ApplicationReferee.md b/docs/ApplicationReferee.md index ff135584..7d4252a3 100644 --- a/docs/ApplicationReferee.md +++ b/docs/ApplicationReferee.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **applicationId** | **Long** | The ID of the Application that owns this entity. | **sessionId** | **String** | Integration ID of the session in which the customer redeemed the referral. | +**advancedEventIntegrationId** | **String** | The unique ID of the advanced event in which the customer redeemed the referral. Omitted when the referral was redeemed through a customer session rather than an advanced event. | [optional] **advocateIntegrationId** | **String** | Integration ID of the Advocate's Profile. | **friendIntegrationId** | **String** | Integration ID of the Friend's Profile. | **code** | **String** | Advocate's referral code. | diff --git a/docs/ApplicationSession.md b/docs/ApplicationSession.md index fabb2957..34c53e74 100644 --- a/docs/ApplicationSession.md +++ b/docs/ApplicationSession.md @@ -15,7 +15,7 @@ Name | Type | Description | Notes **profileintegrationid** | **String** | Integration ID of the customer for the session. | [optional] **coupon** | **String** | Any coupon code entered. | **referral** | **String** | Any referral code entered. | -**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | +**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | **cartItems** | [**List<CartItem>**](CartItem.md) | Serialized JSON representation. | **discounts** | [**Map<String, BigDecimal>**](BigDecimal.md) | **API V1 only.** A map of labeled discount values, in the same currency as the session. If you are using the V2 endpoints, refer to the `totalDiscounts` property instead. | **totalDiscounts** | [**BigDecimal**](BigDecimal.md) | The total sum of the discounts applied to this session. **Note:** If more than one session is returned, this value is displayed as `0`. | diff --git a/docs/Audience.md b/docs/Audience.md index ab7c334e..406ae245 100644 --- a/docs/Audience.md +++ b/docs/Audience.md @@ -12,6 +12,7 @@ Name | Type | Description | Notes **name** | **String** | The human-friendly display name for this audience. | **sandbox** | **Boolean** | Indicates if this is a live or sandbox Application. | [optional] **description** | **String** | A description of the audience. | [optional] +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] **integration** | **String** | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. | [optional] **integrationId** | **String** | The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. | [optional] **createdIn3rdParty** | **Boolean** | Determines if this audience is a 3rd party audience or not. | [optional] diff --git a/docs/AwardDiscountAdditionalCostTarget.md b/docs/AwardDiscountAdditionalCostTarget.md new file mode 100644 index 00000000..1f342a5d --- /dev/null +++ b/docs/AwardDiscountAdditionalCostTarget.md @@ -0,0 +1,23 @@ + + +# AwardDiscountAdditionalCostTarget + +Applies the discount to an additional cost. The `target` field determines which subset of cart items the additional cost contribution is applied to. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `additionalCost`. | +**additionalCost** | [**AdditionalCostReference**](AdditionalCostReference.md) | | +**target** | [**Object**](.md) | A subset of cart items whose additional cost the discount applies to. Cannot be another `additionalCost` target. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +ADDITIONALCOST | "additionalCost" + + + diff --git a/docs/AwardDiscountAllItemsTarget.md b/docs/AwardDiscountAllItemsTarget.md new file mode 100644 index 00000000..b655ce0a --- /dev/null +++ b/docs/AwardDiscountAllItemsTarget.md @@ -0,0 +1,22 @@ + + +# AwardDiscountAllItemsTarget + +Applies the discount across all cart items. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `allItems`. | +**prorated** | **Boolean** | Whether to distribute the discount proportionally across the targeted items. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +ALLITEMS | "allItems" + + + diff --git a/docs/AwardDiscountBlock.md b/docs/AwardDiscountBlock.md new file mode 100644 index 00000000..ef137243 --- /dev/null +++ b/docs/AwardDiscountBlock.md @@ -0,0 +1,19 @@ + + +# AwardDiscountBlock + +A block that grants a discount when its rule conditions evaluate to `true`. The `target` field determines what the discount applies to (the whole cart, a subset of items, a bundle, an additional cost, etc.); the `value` field is the discount amount. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**name** | **String** | The human-readable label attached to the discount. | +**value** | [**Object**](.md) | Discount amount. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | +**partial** | **Boolean** | Whether to apply a partial discount when the requested value exceeds the configured budget. | +**target** | [**Object**](.md) | Identifies the scope a discount applies to. The `type` field selects the concrete target variant. | + + + diff --git a/docs/AwardDiscountBundleItemByAttribute.md b/docs/AwardDiscountBundleItemByAttribute.md new file mode 100644 index 00000000..9c19ea61 --- /dev/null +++ b/docs/AwardDiscountBundleItemByAttribute.md @@ -0,0 +1,32 @@ + + +# AwardDiscountBundleItemByAttribute + +Identifies a bundle slot by ranking items by a per-item attribute expression and picking the highest- or lowest-ranked one. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A bundle-item selector of type `byAttribute`. | +**attribute** | **String** | A per-item attribute expression used to rank bundle items. | +**direction** | [**DirectionEnum**](#DirectionEnum) | Ranking direction. `highest` picks the item with the largest attribute value, `lowest` the smallest. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +BYATTRIBUTE | "byAttribute" + + + +## Enum: DirectionEnum + +Name | Value +---- | ----- +HIGHEST | "highest" +LOWEST | "lowest" + + + diff --git a/docs/AwardDiscountBundleItemByIndex.md b/docs/AwardDiscountBundleItemByIndex.md new file mode 100644 index 00000000..6ff55f68 --- /dev/null +++ b/docs/AwardDiscountBundleItemByIndex.md @@ -0,0 +1,22 @@ + + +# AwardDiscountBundleItemByIndex + +Identifies a bundle slot by its zero-based index within the bundle. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A bundle-item selector of type `byIndex`. | +**value** | **Long** | The zero-based index of the slot within the bundle. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +BYINDEX | "byIndex" + + + diff --git a/docs/AwardDiscountBundleTarget.md b/docs/AwardDiscountBundleTarget.md new file mode 100644 index 00000000..6da65787 --- /dev/null +++ b/docs/AwardDiscountBundleTarget.md @@ -0,0 +1,24 @@ + + +# AwardDiscountBundleTarget + +Applies the discount to items belonging to a named bundle. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `bundle`. | +**name** | **String** | Name of the bundle binding the discount targets. | +**item** | [**Object**](.md) | Selects which slot inside a bundle a discount applies to. The `type` field picks the selection mode. | [optional] +**prorated** | **Boolean** | Whether to distribute the discount proportionally across the bundle's items. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +BUNDLE | "bundle" + + + diff --git a/docs/AwardDiscountCartTarget.md b/docs/AwardDiscountCartTarget.md new file mode 100644 index 00000000..f8602bd5 --- /dev/null +++ b/docs/AwardDiscountCartTarget.md @@ -0,0 +1,21 @@ + + +# AwardDiscountCartTarget + +Applies the discount to the entire cart as a single unit. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `cart`. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +CART | "cart" + + + diff --git a/docs/AwardDiscountGlobalFilterTarget.md b/docs/AwardDiscountGlobalFilterTarget.md new file mode 100644 index 00000000..4f025ffc --- /dev/null +++ b/docs/AwardDiscountGlobalFilterTarget.md @@ -0,0 +1,23 @@ + + +# AwardDiscountGlobalFilterTarget + +Applies the discount to items matched by a named Application-level cart-item filter. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `globalFilter`. | +**name** | **String** | The name of the Application-level cart-item filter the discount targets. | +**prorated** | **Boolean** | Whether to distribute the discount proportionally across the matched items. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +GLOBALFILTER | "globalFilter" + + + diff --git a/docs/AwardDiscountSelectorTarget.md b/docs/AwardDiscountSelectorTarget.md new file mode 100644 index 00000000..9315a044 --- /dev/null +++ b/docs/AwardDiscountSelectorTarget.md @@ -0,0 +1,23 @@ + + +# AwardDiscountSelectorTarget + +Applies the discount to items matched by a named selector binding. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A target discriminator of type `selector`. | +**name** | **String** | The name of the selector binding the discount targets. | +**prorated** | **Boolean** | Whether to distribute the discount proportionally across the selected items. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +SELECTOR | "selector" + + + diff --git a/docs/AwardGiveawayBlock.md b/docs/AwardGiveawayBlock.md new file mode 100644 index 00000000..e8b183f9 --- /dev/null +++ b/docs/AwardGiveawayBlock.md @@ -0,0 +1,28 @@ + + +# AwardGiveawayBlock + +A block that awards a giveaway item from a configured giveaway pool to the specified customer profile. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**giveawayPool** | [**GiveawayPoolReference**](GiveawayPoolReference.md) | | +**profile** | [**ProfileEnum**](#ProfileEnum) | The customer profile to award the giveaway to. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. | +**onFailure** | **List<Object>** | Blocks evaluated when this block fails or returns false. | [optional] +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + +## Enum: ProfileEnum + +Name | Value +---- | ----- +CURRENT | "Current" +ADVOCATE | "Advocate" + + + diff --git a/docs/AwardGiveawayEffectProps.md b/docs/AwardGiveawayEffectProps.md index 9b68d10c..645f766a 100644 --- a/docs/AwardGiveawayEffectProps.md +++ b/docs/AwardGiveawayEffectProps.md @@ -2,16 +2,16 @@ # AwardGiveawayEffectProps -The properties specific to the \"awardGiveaway\" effect. This effect contains information on the giveaway item, and which profile it was awarded to. +This effect indicates the awarded giveaway item and to which profile the item was awarded. Learn more about [giveaways](https://docs.talon.one/docs/product/giveaways/overview). ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**poolId** | **Long** | The ID of the giveaways pool the code was taken from. | -**poolName** | **String** | The name of the giveaways pool the code was taken from. | -**recipientIntegrationId** | **String** | The integration ID of the profile that was awarded the giveaway. | -**giveawayId** | **Long** | The internal ID for the giveaway that was awarded. | -**code** | **String** | The giveaway code that was awarded. | +**poolId** | **Long** | The internal ID of the giveaway pool. | +**poolName** | **String** | The name of the giveaway pool. | +**recipientIntegrationId** | **String** | The integration ID of the customer that receives the giveaway. | +**giveawayId** | **Long** | The internal ID of the giveaway. | +**code** | **String** | The giveaway code to be rewarded. | diff --git a/docs/AwardItemBlock.md b/docs/AwardItemBlock.md new file mode 100644 index 00000000..2c9898b5 --- /dev/null +++ b/docs/AwardItemBlock.md @@ -0,0 +1,21 @@ + + +# AwardItemBlock + +A block that awards a free cart item to the customer. The item is identified by SKU and name and has a configurable quantity. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**sku** | **String** | The stock keeping unit of the item to award. | +**name** | **String** | The display name of the item to award. | +**quantity** | **String** | The number of items to award. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities. | +**partial** | **Boolean** | When set to `true`, applies a partial item reward if the remaining budget is insufficient to award the full reward. | [optional] +**onFailure** | **List<Object>** | Blocks evaluated when this block fails or returns false. | [optional] +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + diff --git a/docs/BaseBlock.md b/docs/BaseBlock.md new file mode 100644 index 00000000..8ff0c559 --- /dev/null +++ b/docs/BaseBlock.md @@ -0,0 +1,15 @@ + + +# BaseBlock + +Common properties shared by all block types. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] + + + diff --git a/docs/BaseCampaign.md b/docs/BaseCampaign.md index 44a043c2..552f70ac 100644 --- a/docs/BaseCampaign.md +++ b/docs/BaseCampaign.md @@ -46,6 +46,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/BestPriorPrice.md b/docs/BestPriorPrice.md index 7033ccc3..c4fdd6fb 100644 --- a/docs/BestPriorPrice.md +++ b/docs/BestPriorPrice.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **id** | **Long** | The ID of the historical price. | **sku** | **String** | sku | **observedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the price was observed. | -**contextId** | **String** | The context ID of the context active at the time of observation. | +**contextIds** | **List<String>** | The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. | **price** | [**BigDecimal**](BigDecimal.md) | Price of the item. | **metadata** | [**BestPriorPriceMetadata**](BestPriorPriceMetadata.md) | | **target** | [**Object**](.md) | | diff --git a/docs/BestPriorPriceSettings.md b/docs/BestPriorPriceSettings.md new file mode 100644 index 00000000..5cf310d6 --- /dev/null +++ b/docs/BestPriorPriceSettings.md @@ -0,0 +1,13 @@ + + +# BestPriorPriceSettings + +The best prior price settings for this Application. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**enableBestPriorPrice** | **Boolean** | When set to `true`, the best prior price feature is enabled in this Application and its [price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory) is recorded. | [optional] + + + diff --git a/docs/BetweenCheckAttributeBlock.md b/docs/BetweenCheckAttributeBlock.md new file mode 100644 index 00000000..52765874 --- /dev/null +++ b/docs/BetweenCheckAttributeBlock.md @@ -0,0 +1,23 @@ + + +# BetweenCheckAttributeBlock + +Variant of `CheckAttributeBlock` for the `between` operator, which requires both a minimum and maximum value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The range comparison operator. Must be `between`. | [optional] +**min** | [**Object**](.md) | The minimum value allowed for the `between` operator. | +**max** | [**Object**](.md) | The maximum value allowed for the `between` operator. | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +BETWEEN | "between" + + + diff --git a/docs/Binding.md b/docs/Binding.md index 9bad76cd..3ebc05e3 100644 --- a/docs/Binding.md +++ b/docs/Binding.md @@ -8,12 +8,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **name** | **String** | A descriptive name for the value to be bound. | **type** | **String** | The kind of binding. Possible values are: - `bundle` - `cartItemFilter` - `subledgerBalance` - `templateParameter` | [optional] -**expression** | **List<Object>** | A Talang expression that will be evaluated and its result attached to the name of the binding. | -**valueType** | **String** | Can be one of the following: - `string` - `number` - `boolean` | [optional] +**expression** | **List<Object>** | A Talang expression that is evaluated, and its result is bound to the name of the binding. The first element must be one of the functions or operators supported by Talang, followed by its arguments. The arguments can be strings, numbers, or nested expressions. For example: - `[\"list\", \"10014\", \"10015\"]` calls the `list` function to build a list of strings. - `[\"+\", 2, 0]` uses the `+` operator to add two numbers. | +**valueType** | **String** | The data type of the value. One of the following: - `string` - `number` - `boolean` | [optional] **minValue** | [**BigDecimal**](BigDecimal.md) | The minimum value allowed for this placeholder. | [optional] **maxValue** | [**BigDecimal**](BigDecimal.md) | The maximum value allowed for this placeholder. | [optional] -**attributeId** | **Long** | Id of the attribute attached to the placeholder. | [optional] -**description** | **String** | Describes the placeholder field and value in the template. This description can be used when creating campaigns from this template. | [optional] +**attributeId** | **Long** | Identifier of the attribute attached to the placeholder. | [optional] +**description** | **String** | Description of the placeholder field and its value in the template. This text can be shown when creating campaigns from this template. | [optional] diff --git a/docs/Bundle.md b/docs/Bundle.md new file mode 100644 index 00000000..0608ceb7 --- /dev/null +++ b/docs/Bundle.md @@ -0,0 +1,26 @@ + + +# Bundle + +A named bundle definition consisting of selector sources with matching constraints. Replaces `bundle` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | An identifier derived from the bundle content. | +**name** | **String** | The name of the bundle. | +**type** | [**TypeEnum**](#TypeEnum) | A binding of type `bundle`. | +**sources** | **List<String>** | The selector sources of bundle items. Each source is expressed as a `{{$selectorName}}` reference. | +**counts** | **List<Long>** | The number of items to retrieve from each corresponding source in `sources`. | +**matchers** | **List<String>** | Attribute names that the bundled items must share. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +BUNDLE | "bundle" + + + diff --git a/docs/Campaign.md b/docs/Campaign.md index 1763c79d..e897315f 100644 --- a/docs/Campaign.md +++ b/docs/Campaign.md @@ -82,6 +82,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/CampaignEligibility.md b/docs/CampaignEligibility.md new file mode 100644 index 00000000..61a945a1 --- /dev/null +++ b/docs/CampaignEligibility.md @@ -0,0 +1,47 @@ + + +# CampaignEligibility + +A list of campaigns and their evaluation status for the current customer session. For experiment campaigns, the experiment and variant assigned to the customer profile are returned through the `experiment` field. Customer profiles with no variant assignment are not included. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applicationId** | **Long** | The ID of the Application that owns this entity. | +**id** | **Long** | Unique ID of Campaign. | +**name** | **String** | The name of the campaign. | +**description** | **String** | A detailed description of the campaign. | [optional] +**startTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become active. | [optional] +**endTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become inactive. | [optional] +**attributes** | [**Object**](.md) | Arbitrary properties associated with this campaign. | [optional] +**state** | [**StateEnum**](#StateEnum) | The state of the campaign. | +**tags** | **List<String>** | A list of tags for the campaign. | +**features** | [**List<FeaturesEnum>**](#List<FeaturesEnum>) | The features enabled in this campaign. | +**eligibility** | [**List<CampaignEligibilityDetails>**](CampaignEligibilityDetails.md) | The customer's eligibility for each campaign in the current customer session. | +**rules** | [**List<RuleMetadataEligibility>**](RuleMetadataEligibility.md) | A list of rules containing customer-facing details of the rewards defined in the campaign. | +**experiment** | [**CampaignEligibilityExperiment**](CampaignEligibilityExperiment.md) | | [optional] + + + +## Enum: StateEnum + +Name | Value +---- | ----- +ENABLED | "enabled" + + + +## Enum: List<FeaturesEnum> + +Name | Value +---- | ----- +COUPONS | "coupons" +REFERRALS | "referrals" +LOYALTY | "loyalty" +GIVEAWAYS | "giveaways" +STRIKETHROUGH | "strikethrough" +ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" + + + diff --git a/docs/CampaignEligibilityDetails.md b/docs/CampaignEligibilityDetails.md new file mode 100644 index 00000000..3fc6ac34 --- /dev/null +++ b/docs/CampaignEligibilityDetails.md @@ -0,0 +1,14 @@ + + +# CampaignEligibilityDetails + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**passed** | **Boolean** | Indicates whether the customer was eligible for the campaign in the current session. | +**couponCode** | **String** | The coupon code used to check a customer's eligibility for the campaign in the current session, if applicable. | [optional] +**details** | [**CampaignEligibilityFailureDetails**](CampaignEligibilityFailureDetails.md) | | [optional] + + + diff --git a/docs/CampaignEligibilityExperiment.md b/docs/CampaignEligibilityExperiment.md new file mode 100644 index 00000000..fa8619e0 --- /dev/null +++ b/docs/CampaignEligibilityExperiment.md @@ -0,0 +1,14 @@ + + +# CampaignEligibilityExperiment + +The identifiers for the [experiment](https://docs.talon.one/management-api#tag/Experiments) and the variant assigned to the customer profile. Only returned when the customer profile has been assigned to a variant in an experiment campaign. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the experiment. | +**variantId** | **Long** | The ID of the variant assigned to the customer profile. | + + + diff --git a/docs/CampaignEligibilityFailureDetails.md b/docs/CampaignEligibilityFailureDetails.md new file mode 100644 index 00000000..b776d359 --- /dev/null +++ b/docs/CampaignEligibilityFailureDetails.md @@ -0,0 +1,23 @@ + + +# CampaignEligibilityFailureDetails + +The details about why the customer was not eligible for the campaign in the current session. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**failureCode** | [**FailureCodeEnum**](#FailureCodeEnum) | A code identifying why the customer was not eligible for the campaign. | + + + +## Enum: FailureCodeEnum + +Name | Value +---- | ----- +ALL_RULES_FAILED | "ALL_RULES_FAILED" +SKIPPED | "SKIPPED" +AUDIENCE_NOT_MATCHED | "AUDIENCE_NOT_MATCHED" + + + diff --git a/docs/CampaignLoyaltyProgram.md b/docs/CampaignLoyaltyProgram.md new file mode 100644 index 00000000..f69aab4a --- /dev/null +++ b/docs/CampaignLoyaltyProgram.md @@ -0,0 +1,16 @@ + + +# CampaignLoyaltyProgram + +A loyalty program referenced in a campaign. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the loyalty program. | +**name** | **String** | The name of the loyalty program. | +**tiers** | **List<String>** | The names of the tiers in the loyalty program. | +**cardBased** | **Boolean** | Whether the loyalty program is card-based. | + + + diff --git a/docs/CampaignReference.md b/docs/CampaignReference.md new file mode 100644 index 00000000..aea564bb --- /dev/null +++ b/docs/CampaignReference.md @@ -0,0 +1,13 @@ + + +# CampaignReference + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the campaign that references this achievement. | +**applicationId** | **Long** | The ID of the Application the campaign belongs to. | + + + diff --git a/docs/CampaignTemplate.md b/docs/CampaignTemplate.md index 981b042a..3737925a 100644 --- a/docs/CampaignTemplate.md +++ b/docs/CampaignTemplate.md @@ -57,6 +57,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/CardLedgerTransactionLogEntryIntegrationAPI.md b/docs/CardLedgerTransactionLogEntryIntegrationAPI.md index f1961ae2..000a86ee 100644 --- a/docs/CardLedgerTransactionLogEntryIntegrationAPI.md +++ b/docs/CardLedgerTransactionLogEntryIntegrationAPI.md @@ -21,7 +21,7 @@ Name | Type | Description | Notes **id** | **Long** | ID of the loyalty ledger transaction. | **rulesetId** | **Long** | The ID of the ruleset containing the rule that triggered this effect. | [optional] **ruleName** | **String** | The name of the rule that triggered this effect. | [optional] -**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] +**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] diff --git a/docs/CatalogAction.md b/docs/CatalogAction.md index d6c78874..9ba421f5 100644 --- a/docs/CatalogAction.md +++ b/docs/CatalogAction.md @@ -2,13 +2,13 @@ # CatalogAction -Definition of all the properties that are needed for a single catalog sync action. +Definition of all the properties that are needed for a single catalog sync action. The `type` field selects the concrete action variant. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**type** | [**TypeEnum**](#TypeEnum) | The type of sync action. | -**payload** | [**Object**](.md) | | +**type** | [**TypeEnum**](#TypeEnum) | The type of sync action. | [optional] +**payload** | [**Object**](.md) | | [optional] diff --git a/docs/CatalogActionAdd.md b/docs/CatalogActionAdd.md new file mode 100644 index 00000000..3ad1bc2f --- /dev/null +++ b/docs/CatalogActionAdd.md @@ -0,0 +1,22 @@ + + +# CatalogActionAdd + +Adds an item to the catalog. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `ADD`. | +**payload** | [**AddItemCatalogAction**](AddItemCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +ADD | "ADD" + + + diff --git a/docs/CatalogActionAddPriceAdjustment.md b/docs/CatalogActionAddPriceAdjustment.md new file mode 100644 index 00000000..88bd45f2 --- /dev/null +++ b/docs/CatalogActionAddPriceAdjustment.md @@ -0,0 +1,22 @@ + + +# CatalogActionAddPriceAdjustment + +Adds price adjustments to an item of the catalog. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `ADD_PRICE_ADJUSTMENT`. | +**payload** | [**AddPriceAdjustmentCatalogAction**](AddPriceAdjustmentCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +ADD_PRICE_ADJUSTMENT | "ADD_PRICE_ADJUSTMENT" + + + diff --git a/docs/CatalogActionPatch.md b/docs/CatalogActionPatch.md new file mode 100644 index 00000000..2d680d87 --- /dev/null +++ b/docs/CatalogActionPatch.md @@ -0,0 +1,22 @@ + + +# CatalogActionPatch + +Updates an item in the catalog. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `PATCH`. | +**payload** | [**PatchItemCatalogAction**](PatchItemCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +PATCH | "PATCH" + + + diff --git a/docs/CatalogActionPatchMany.md b/docs/CatalogActionPatchMany.md new file mode 100644 index 00000000..90a1dde2 --- /dev/null +++ b/docs/CatalogActionPatchMany.md @@ -0,0 +1,22 @@ + + +# CatalogActionPatchMany + +Updates the items of the catalog that match the given filters. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `PATCH_MANY`. | +**payload** | [**PatchManyItemsCatalogAction**](PatchManyItemsCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +PATCH_MANY | "PATCH_MANY" + + + diff --git a/docs/CatalogActionRemove.md b/docs/CatalogActionRemove.md new file mode 100644 index 00000000..355c853c --- /dev/null +++ b/docs/CatalogActionRemove.md @@ -0,0 +1,22 @@ + + +# CatalogActionRemove + +Removes an item from the catalog. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `REMOVE`. | +**payload** | [**RemoveItemCatalogAction**](RemoveItemCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +REMOVE | "REMOVE" + + + diff --git a/docs/CatalogActionRemoveMany.md b/docs/CatalogActionRemoveMany.md new file mode 100644 index 00000000..30667539 --- /dev/null +++ b/docs/CatalogActionRemoveMany.md @@ -0,0 +1,22 @@ + + +# CatalogActionRemoveMany + +Removes the items of the catalog that match the given filters. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A catalog sync action discriminator of type `REMOVE_MANY`. | +**payload** | [**RemoveManyItemsCatalogAction**](RemoveManyItemsCatalogAction.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +REMOVE_MANY | "REMOVE_MANY" + + + diff --git a/docs/ChangeLoyaltyTierLevelEffectProps.md b/docs/ChangeLoyaltyTierLevelEffectProps.md index f9356324..d953f5d3 100644 --- a/docs/ChangeLoyaltyTierLevelEffectProps.md +++ b/docs/ChangeLoyaltyTierLevelEffectProps.md @@ -2,14 +2,14 @@ # ChangeLoyaltyTierLevelEffectProps -The properties specific to the \"changeLoyaltyTierLevel\" effect. This is triggered whenever the user's loyalty tier is upgraded due to a validated rule that contained an \"addLoyaltyPoints\" effect. +This effect indicates that a customer's loyalty tier has been upgraded. This effect is generated only when the [Add loyalty points](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points) and the [Add loyalty points per cart item](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points-per-cart-item) effects are triggered for a particular customer, and, as a result, the customer's loyalty tier is upgraded. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ruleTitle** | **String** | The title of the rule that triggered the tier upgrade. | -**programId** | **Long** | The ID of the loyalty program where these points were added. | -**subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were added. | +**programId** | **Long** | The ID of the loyalty program where the points were added. | +**subLedgerId** | **String** | The ID of the subledger within the loyalty program where the points were added. | **previousTierName** | **String** | The name of the tier from which the user was upgraded. | [optional] **newTierName** | **String** | The name of the tier to which the user has been upgraded. | **expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | The expiration date of the new tier. | [optional] diff --git a/docs/CheckAchievementBlock.md b/docs/CheckAchievementBlock.md new file mode 100644 index 00000000..257c39a7 --- /dev/null +++ b/docs/CheckAchievementBlock.md @@ -0,0 +1,32 @@ + + +# CheckAchievementBlock + +A block that checks the current customer's completion or progress status in an achievement. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The comparison operator applied to the achievement. | +**achievement** | [**CheckAchievementBlockAchievement**](CheckAchievementBlockAchievement.md) | | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +JUSTCOMPLETED | "justCompleted" +STARTED | "started" +NOT_STARTED_ | "not(started)" +INPROGRESS | "inProgress" +NOT_INPROGRESS_ | "not(inProgress)" +COMPLETED | "completed" +NOT_COMPLETED_ | "not(completed)" + + + diff --git a/docs/CheckAchievementBlockAchievement.md b/docs/CheckAchievementBlockAchievement.md new file mode 100644 index 00000000..7d333055 --- /dev/null +++ b/docs/CheckAchievementBlockAchievement.md @@ -0,0 +1,16 @@ + + +# CheckAchievementBlockAchievement + +The achievement to check for. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the achievement. | +**title** | **String** | The display name for the achievement in the Campaign Manager. | +**name** | **String** | The internal name of the achievement used in API requests. | +**target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | + + + diff --git a/docs/CheckAttributeBlock.md b/docs/CheckAttributeBlock.md new file mode 100644 index 00000000..ef6b6447 --- /dev/null +++ b/docs/CheckAttributeBlock.md @@ -0,0 +1,76 @@ + + +# CheckAttributeBlock + +Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | [**TypeEnum**](#TypeEnum) | A block discriminator of type `checkAttribute`. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The comparison operator applied to the attribute. | +**attribute** | [**Object**](.md) | The attribute path identifier (e.g. \"$Session.Total\"). | +**value** | [**Object**](.md) | The comparison value for scalar operators. | [optional] +**min** | [**Object**](.md) | The minimum value allowed for the `between` operator. | [optional] +**max** | [**Object**](.md) | The maximum value allowed for the `between` operator. | [optional] +**start** | [**Object**](.md) | The start value for the `within` operator. | [optional] +**end** | [**Object**](.md) | The end value for the `within` operator. | [optional] +**startInclusive** | **Boolean** | When `true`, the `start` value is included in the range for the `within` operator. | [optional] +**endInclusive** | **Boolean** | When `true`, the `end` value is included in the range for the `within` operator. | [optional] +**timezoneInsensitive** | **Boolean** | Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. | [optional] +**values** | [**Object**](.md) | The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute. | [optional] +**count** | [**Object**](.md) | The count threshold for `containsAtLeast` and `containsExactly` operators. | [optional] +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +CHECKATTRIBUTE | "checkAttribute" + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +EQUALS | "equals" +NOT_EQUALS_ | "not(equals)" +LESSTHAN | "lessThan" +LESSTHANOREQUAL | "lessThanOrEqual" +GREATERTHAN | "greaterThan" +GREATERTHANOREQUAL | "greaterThanOrEqual" +BETWEEN | "between" +CONTAINS | "contains" +NOT_CONTAINS_ | "not(contains)" +MATCHESREGEXP | "matchesRegexp" +STARTSWITH | "startsWith" +ENDSWITH | "endsWith" +ONEOF | "oneOf" +NOT_ONEOF_ | "not(oneOf)" +INCOLLECTION | "inCollection" +NOT_INCOLLECTION_ | "not(inCollection)" +EMPTY | "empty" +NOT_EMPTY_ | "not(empty)" +EXISTS | "exists" +NOT_EXISTS_ | "not(exists)" +ISTRUE | "isTrue" +ISFALSE | "isFalse" +CONTAINSATLEAST | "containsAtLeast" +CONTAINSEXACTLY | "containsExactly" +CONTAINSONEOF | "containsOneOf" +CONTAINSNONEOF | "containsNoneOf" +CONTAINSALLOF | "containsAllOf" +AFTER | "after" +BEFORE | "before" +WITHIN | "within" +NOT_WITHIN_ | "not(within)" +IN | "in" +NOT_IN_ | "not(in)" + + + diff --git a/docs/CheckAttributeBlockBase.md b/docs/CheckAttributeBlockBase.md new file mode 100644 index 00000000..0aafe742 --- /dev/null +++ b/docs/CheckAttributeBlockBase.md @@ -0,0 +1,68 @@ + + +# CheckAttributeBlockBase + +Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The comparison operator applied to the attribute. | +**attribute** | [**Object**](.md) | The attribute path identifier (e.g. \"$Session.Total\"). | +**value** | [**Object**](.md) | The comparison value for scalar operators. | [optional] +**min** | [**Object**](.md) | The minimum value allowed for the `between` operator. | [optional] +**max** | [**Object**](.md) | The maximum value allowed for the `between` operator. | [optional] +**start** | [**Object**](.md) | The start value for the `within` operator. | [optional] +**end** | [**Object**](.md) | The end value for the `within` operator. | [optional] +**startInclusive** | **Boolean** | When `true`, the `start` value is included in the range for the `within` operator. | [optional] +**endInclusive** | **Boolean** | When `true`, the `end` value is included in the range for the `within` operator. | [optional] +**timezoneInsensitive** | **Boolean** | Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. | [optional] +**values** | [**Object**](.md) | The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute. | [optional] +**count** | [**Object**](.md) | The count threshold for `containsAtLeast` and `containsExactly` operators. | [optional] +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +EQUALS | "equals" +NOT_EQUALS_ | "not(equals)" +LESSTHAN | "lessThan" +LESSTHANOREQUAL | "lessThanOrEqual" +GREATERTHAN | "greaterThan" +GREATERTHANOREQUAL | "greaterThanOrEqual" +BETWEEN | "between" +CONTAINS | "contains" +NOT_CONTAINS_ | "not(contains)" +MATCHESREGEXP | "matchesRegexp" +STARTSWITH | "startsWith" +ENDSWITH | "endsWith" +ONEOF | "oneOf" +NOT_ONEOF_ | "not(oneOf)" +INCOLLECTION | "inCollection" +NOT_INCOLLECTION_ | "not(inCollection)" +EMPTY | "empty" +NOT_EMPTY_ | "not(empty)" +EXISTS | "exists" +NOT_EXISTS_ | "not(exists)" +ISTRUE | "isTrue" +ISFALSE | "isFalse" +CONTAINSATLEAST | "containsAtLeast" +CONTAINSEXACTLY | "containsExactly" +CONTAINSONEOF | "containsOneOf" +CONTAINSNONEOF | "containsNoneOf" +CONTAINSALLOF | "containsAllOf" +AFTER | "after" +BEFORE | "before" +WITHIN | "within" +NOT_WITHIN_ | "not(within)" +IN | "in" +NOT_IN_ | "not(in)" + + + diff --git a/docs/CheckAudienceBlock.md b/docs/CheckAudienceBlock.md new file mode 100644 index 00000000..e8348a79 --- /dev/null +++ b/docs/CheckAudienceBlock.md @@ -0,0 +1,39 @@ + + +# CheckAudienceBlock + +A block that checks whether a given customer profile is a member of an audience. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | An indicator of how the block compares its elements. | +**profile** | [**ProfileEnum**](#ProfileEnum) | The customer profile to check against the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. | +**audience** | [**CheckAudienceBlockAudience**](CheckAudienceBlockAudience.md) | | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +MEMBER | "member" +NOT_MEMBER_ | "not(member)" +JUSTJOINED | "justJoined" +JUSTLEFT | "justLeft" + + + +## Enum: ProfileEnum + +Name | Value +---- | ----- +CURRENT | "Current" +ADVOCATE | "Advocate" + + + diff --git a/docs/CheckAudienceBlockAudience.md b/docs/CheckAudienceBlockAudience.md new file mode 100644 index 00000000..dd768454 --- /dev/null +++ b/docs/CheckAudienceBlockAudience.md @@ -0,0 +1,16 @@ + + +# CheckAudienceBlockAudience + +The audience to check the profile against. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the audience. | +**name** | **String** | The display name of the audience. | +**integration** | **String** | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. | [optional] +**integrationId** | **String** | The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. | [optional] + + + diff --git a/docs/CheckBudgetBlock.md b/docs/CheckBudgetBlock.md new file mode 100644 index 00000000..e0447bc2 --- /dev/null +++ b/docs/CheckBudgetBlock.md @@ -0,0 +1,49 @@ + + +# CheckBudgetBlock + +A block that verifies if a specific budget has sufficient limit available, and whether this limit meets or exceeds a specific value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The comparison operator applied to the limit. `available` checks if there is budget available for a given limitable action; `enoughFor` checks if the available budget meets or exceeds a specific value limit. | +**action** | [**ActionEnum**](#ActionEnum) | The limitable action to check. | +**value** | [**BigDecimal**](BigDecimal.md) | The value to check against when using the `enoughFor` operator. | [optional] +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +AVAILABLE | "available" +ENOUGHFOR | "enoughFor" + + + +## Enum: ActionEnum + +Name | Value +---- | ----- +REDEEMCOUPON | "redeemCoupon" +REDEEMREFERRAL | "redeemReferral" +SETDISCOUNT | "setDiscount" +CREATECOUPON | "createCoupon" +CREATEREFERRAL | "createReferral" +SETDISCOUNTEFFECT | "setDiscountEffect" +CREATELOYALTYPOINTS | "createLoyaltyPoints" +CREATELOYALTYPOINTSEFFECT | "createLoyaltyPointsEffect" +REDEEMLOYALTYPOINTS | "redeemLoyaltyPoints" +REDEEMLOYALTYPOINTSEFFECT | "redeemLoyaltyPointsEffect" +AWARDGIVEAWAY | "awardGiveaway" +ADDFREEITEMEFFECT | "addFreeItemEffect" +CUSTOMEFFECT | "customEffect" +CALLAPI | "callApi" + + + diff --git a/docs/CheckCouponBlock.md b/docs/CheckCouponBlock.md new file mode 100644 index 00000000..929c9d54 --- /dev/null +++ b/docs/CheckCouponBlock.md @@ -0,0 +1,17 @@ + + +# CheckCouponBlock + +A block that validates the coupon code value and date. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**redeem** | **Boolean** | When `true`, the coupon code is redeemed. | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + diff --git a/docs/CheckEventBlock.md b/docs/CheckEventBlock.md new file mode 100644 index 00000000..a09fc093 --- /dev/null +++ b/docs/CheckEventBlock.md @@ -0,0 +1,18 @@ + + +# CheckEventBlock + +A block that validates the event type. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**eventType** | **String** | The event type to check against. | +**matchers** | **List<Object>** | | [optional] +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + diff --git a/docs/CheckLoyaltyBalanceBlock.md b/docs/CheckLoyaltyBalanceBlock.md new file mode 100644 index 00000000..806fc1b6 --- /dev/null +++ b/docs/CheckLoyaltyBalanceBlock.md @@ -0,0 +1,45 @@ + + +# CheckLoyaltyBalanceBlock + +A block that checks a specific loyalty program's ledger or subledger balance against a numeric value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | An indicator of how the block compares the balance to the value. | +**program** | [**CheckLoyaltyBalanceBlockProgram**](CheckLoyaltyBalanceBlockProgram.md) | | +**subledger** | **String** | The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger. | +**balance** | [**BalanceEnum**](#BalanceEnum) | The type of balance to check: - `current` is the sum of currently active points - `pending` is the sum of pending points. - `negative` is the sum of negative points. - `tentativeCurrent` is the tentative points balance within the current open customer session. | +**value** | [**BigDecimal**](BigDecimal.md) | The numeric value to compare the balance against. | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +EQUALS | "equals" +NOT_EQUALS_ | "not(equals)" +LESSTHAN | "lessThan" +LESSTHANOREQUAL | "lessThanOrEqual" +GREATERTHAN | "greaterThan" +GREATERTHANOREQUAL | "greaterThanOrEqual" + + + +## Enum: BalanceEnum + +Name | Value +---- | ----- +CURRENT | "current" +PENDING | "pending" +NEGATIVE | "negative" +TENTATIVECURRENT | "tentativeCurrent" + + + diff --git a/docs/CheckLoyaltyBalanceBlockProgram.md b/docs/CheckLoyaltyBalanceBlockProgram.md new file mode 100644 index 00000000..2069c381 --- /dev/null +++ b/docs/CheckLoyaltyBalanceBlockProgram.md @@ -0,0 +1,15 @@ + + +# CheckLoyaltyBalanceBlockProgram + +The loyalty program whose ledger balance is checked. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the loyalty program. | +**name** | **String** | The internal name of the loyalty program. | +**title** | **String** | The display name of the loyalty program. | + + + diff --git a/docs/CheckLoyaltyCardBlock.md b/docs/CheckLoyaltyCardBlock.md new file mode 100644 index 00000000..c132feab --- /dev/null +++ b/docs/CheckLoyaltyCardBlock.md @@ -0,0 +1,26 @@ + + +# CheckLoyaltyCardBlock + +A block that verifies whether a loyalty card is linked to the user's profile. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | An indicator of how the block compares its elements. | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +LINKED | "linked" +NOT_LINKED_ | "not(linked)" + + + diff --git a/docs/CheckReferralBlock.md b/docs/CheckReferralBlock.md new file mode 100644 index 00000000..7fff9e91 --- /dev/null +++ b/docs/CheckReferralBlock.md @@ -0,0 +1,17 @@ + + +# CheckReferralBlock + +A block that validates the referral code value and date. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**redeem** | **Boolean** | When `true`, the referral code is redeemed. | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + diff --git a/docs/CheckTierBlock.md b/docs/CheckTierBlock.md new file mode 100644 index 00000000..2237af68 --- /dev/null +++ b/docs/CheckTierBlock.md @@ -0,0 +1,28 @@ + + +# CheckTierBlock + +A block that checks whether a user profile is a member of a specific tier within a loyalty program. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | An indicator of how the block compares its elements. | +**subledger** | **String** | The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger. | +**tier** | [**CheckTierBlockTier**](CheckTierBlockTier.md) | | +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +MEMBER | "member" +NOT_MEMBER_ | "not(member)" + + + diff --git a/docs/CheckTierBlockTier.md b/docs/CheckTierBlockTier.md new file mode 100644 index 00000000..af0cd813 --- /dev/null +++ b/docs/CheckTierBlockTier.md @@ -0,0 +1,15 @@ + + +# CheckTierBlockTier + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the tier. | +**name** | **String** | The display name of the tier. | +**minPoints** | [**BigDecimal**](BigDecimal.md) | The minimum amount of points required to enter the tier. | +**upperLimit** | [**BigDecimal**](BigDecimal.md) | | [optional] + + + diff --git a/docs/ConfirmRisksRequest.md b/docs/ConfirmRisksRequest.md new file mode 100644 index 00000000..6d63d643 --- /dev/null +++ b/docs/ConfirmRisksRequest.md @@ -0,0 +1,13 @@ + + +# ConfirmRisksRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**riskIds** | **List<Long>** | The IDs of the risks to confirm. | +**comment** | **String** | Free-text description of how the risk was resolved. | + + + diff --git a/docs/CouponCreatedEffectProps.md b/docs/CouponCreatedEffectProps.md index 9ce3e9bb..ddde4430 100644 --- a/docs/CouponCreatedEffectProps.md +++ b/docs/CouponCreatedEffectProps.md @@ -2,7 +2,7 @@ # CouponCreatedEffectProps -The properties specific to the \"couponCreated\" effect. This gets triggered whenever a validated rule contained a \"create coupon\" effect, and a coupon was created for a customer. See \"createdCoupons\" on the response for all details of this coupon. +This effect indicates that a coupon was created. For referrals and retention marketing, a common use case is to generate a coupon that can only be redeemed by one specific customer. Handle this effect by notifying the recipient about their new coupon code. ## Properties Name | Type | Description | Notes diff --git a/docs/CouponEligibilityInfo.md b/docs/CouponEligibilityInfo.md new file mode 100644 index 00000000..3cd50925 --- /dev/null +++ b/docs/CouponEligibilityInfo.md @@ -0,0 +1,14 @@ + + +# CouponEligibilityInfo + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**campaignId** | **Long** | The ID of the campaign that owns the coupon. | +**campaignName** | **String** | The name of the campaign that owns the coupon. | +**failureReason** | **String** | The reason the coupon is not eligible, if applicable. | [optional] + + + diff --git a/docs/CreateAchievementV2.md b/docs/CreateAchievementV2.md index 659ed192..e33af71a 100644 --- a/docs/CreateAchievementV2.md +++ b/docs/CreateAchievementV2.md @@ -16,8 +16,8 @@ Name | Type | Description | Notes **fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is set to `fixed_schedule`. **Note:** It must be an RFC3339 timestamp string. | [optional] **endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It must be an RFC3339 timestamp string. | [optional] **allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | [optional] -**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | **subscribedApplications** | **List<Long>** | A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. | [optional] +**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | **timezone** | **String** | A string containing an IANA timezone descriptor. | diff --git a/docs/CreateCouponBlock.md b/docs/CreateCouponBlock.md new file mode 100644 index 00000000..5eb6df2f --- /dev/null +++ b/docs/CreateCouponBlock.md @@ -0,0 +1,25 @@ + + +# CreateCouponBlock + +A block that creates a coupon code. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**campaignId** | [**Object**](.md) | The ID of the campaign in which the coupon code is created. | +**recipientId** | **String** | The integration ID of the customer that is allowed to redeem this coupon. | +**storeInSession** | **Boolean** | When `true`, the coupon is stored in the session. | +**usageLimit** | [**Object**](.md) | The number of times the coupon code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | [optional] +**discountLimit** | [**Object**](.md) | The total discount value that the code can give. Typically used to represent a gift card value. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | [optional] +**startDate** | [**Object**](.md) | Timestamp at which point the coupon becomes valid. | [optional] +**expiryDate** | [**Object**](.md) | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional] +**attributes** | [**Object**](.md) | Custom attributes associated with this coupon code. | [optional] +**validCharacters** | **String** | Characters used to generate the random parts of a code. | [optional] +**pattern** | **String** | The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. | [optional] + + + diff --git a/docs/CreateReferralBlock.md b/docs/CreateReferralBlock.md new file mode 100644 index 00000000..f31b066a --- /dev/null +++ b/docs/CreateReferralBlock.md @@ -0,0 +1,24 @@ + + +# CreateReferralBlock + +A block that creates a referral code. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**campaignId** | [**Object**](.md) | The ID of the campaign in which the referral code is created. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | +**friendId** | **String** | An optional integration ID of the friend's profile. | +**storeInSession** | **Boolean** | When `true`, the referral code is stored in the session. | +**usageLimit** | [**Object**](.md) | The number of times the referral code code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | [optional] +**startDate** | [**Object**](.md) | Timestamp at which point the referral code becomes valid. | [optional] +**expiryDate** | [**Object**](.md) | Expiration date of the referral code. Referral code never expires if this is omitted. | [optional] +**attributes** | [**Object**](.md) | Custom attributes associated with this referral code. | [optional] +**validCharacters** | **String** | Characters used to generate the random parts of a code. | [optional] +**pattern** | **String** | The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. | [optional] + + + diff --git a/docs/CustomEffectProps.md b/docs/CustomEffectProps.md index 2209dfc1..4afa6daf 100644 --- a/docs/CustomEffectProps.md +++ b/docs/CustomEffectProps.md @@ -2,7 +2,7 @@ # CustomEffectProps -Effect containing custom payload. +If you want to return data as an effect but no effect matches your use case, you can [create a custom effect](https://docs.talon.one/docs/dev/tutorials/create-custom-effects). Custom effects can be used as both rule effects and failure effects. The structure of a custom effect depends on your specifications but is always named `customEffect`. ## Properties Name | Type | Description | Notes diff --git a/docs/CustomerAchievement.md b/docs/CustomerAchievement.md new file mode 100644 index 00000000..c9e4ea6a --- /dev/null +++ b/docs/CustomerAchievement.md @@ -0,0 +1,45 @@ + + +# CustomerAchievement + +A customer's progress in an achievement, together with the achievement definition. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of the achievement. | +**name** | **String** | The internal name of the achievement used in API requests. | +**title** | **String** | The display name of the achievement in the Campaign Manager. | +**description** | **String** | The description of the achievement in the Campaign Manager. | +**target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | +**recurrencePolicy** | [**RecurrencePolicyEnum**](#RecurrencePolicyEnum) | 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. | +**activationPolicy** | [**ActivationPolicyEnum**](#ActivationPolicyEnum) | 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. | +**fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is equal to `fixed_schedule`. **Note:** It is an RFC3339 timestamp string. | [optional] +**endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It is an RFC3339 timestamp string. | [optional] +**allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | +**campaignId** | **Long** | This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. | [optional] +**campaignIds** | **List<Long>** | The IDs of the campaigns that reference this achievement, in ascending order. | +**referencedByCampaigns** | [**List<CampaignReference>**](CampaignReference.md) | The campaigns that reference this achievement. They are sorted in ascending order by their `id`. | +**currentProgress** | [**AchievementProgress**](AchievementProgress.md) | | [optional] + + + +## Enum: RecurrencePolicyEnum + +Name | Value +---- | ----- +NO_RECURRENCE | "no_recurrence" +ON_EXPIRATION | "on_expiration" +ON_COMPLETION | "on_completion" + + + +## Enum: ActivationPolicyEnum + +Name | Value +---- | ----- +USER_ACTION | "user_action" +FIXED_SCHEDULE | "fixed_schedule" + + + diff --git a/docs/CustomerInventory.md b/docs/CustomerInventory.md index a33eb4e5..5644740d 100644 --- a/docs/CustomerInventory.md +++ b/docs/CustomerInventory.md @@ -12,6 +12,7 @@ Name | Type | Description | Notes **coupons** | [**List<InventoryCoupon>**](InventoryCoupon.md) | The coupons reserved by this profile. This array includes hard and soft reservations. | [optional] **giveaways** | [**List<Giveaway>**](Giveaway.md) | | [optional] **achievements** | [**List<AchievementProgressWithDefinition>**](AchievementProgressWithDefinition.md) | | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The customer rewards that are `unlocked` and not yet `used`. | [optional] diff --git a/docs/CustomerProfileIntegrationRequestV2.md b/docs/CustomerProfileIntegrationRequestV2.md index 25b2ccb1..30053d3d 100644 --- a/docs/CustomerProfileIntegrationRequestV2.md +++ b/docs/CustomerProfileIntegrationRequestV2.md @@ -24,6 +24,9 @@ LOYALTY | "loyalty" EVENT | "event" AWARDEDGIVEAWAYS | "awardedGiveaways" RULEFAILUREREASONS | "ruleFailureReasons" +CAMPAIGNELIGIBILITY | "campaignEligibility" +ACHIEVEMENTS | "achievements" +UNLOCKEDREWARDS | "unlockedRewards" diff --git a/docs/CustomerProfileIntegrationResponseV2.md b/docs/CustomerProfileIntegrationResponseV2.md index af5c7347..e7bffe4b 100644 --- a/docs/CustomerProfileIntegrationResponseV2.md +++ b/docs/CustomerProfileIntegrationResponseV2.md @@ -12,7 +12,9 @@ Name | Type | Description | Notes **loyalty** | [**Loyalty**](Loyalty.md) | | [optional] **triggeredCampaigns** | [**List<Campaign>**](Campaign.md) | | [optional] **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | | [optional] +**campaignEligibility** | [**List<CampaignEligibility>**](CampaignEligibility.md) | | [optional] **awardedGiveaways** | [**List<Giveaway>**](Giveaway.md) | | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The rewards for the customer profile. | [optional] **effects** | [**List<Effect>**](Effect.md) | The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **createdCoupons** | [**List<Coupon>**](Coupon.md) | | **createdReferrals** | [**List<Referral>**](Referral.md) | | diff --git a/docs/CustomerProfileReward.md b/docs/CustomerProfileReward.md new file mode 100644 index 00000000..964736b2 --- /dev/null +++ b/docs/CustomerProfileReward.md @@ -0,0 +1,35 @@ + + +# CustomerProfileReward + +A reward instance held by a customer profile. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the customer reward instance. A customer profile can have multiple instances of the same reward. | +**integrationId** | **String** | The integration ID of the customer reward instance. | +**rewardId** | **Long** | The ID of the reward this instance belongs to. | +**rewardIntegrationId** | **String** | The integration ID of the reward this instance belongs to. | +**rewardName** | **String** | The name of the reward. | +**description** | **String** | The customer-facing description of the reward. | [optional] +**rule** | [**RuleMetadata**](RuleMetadata.md) | | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The status of the customer reward: - `unlocked`: The reward is available for use. - `used`: The reward has been used. | +**unlockedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the reward was unlocked. | +**unlockedByProfileIntegrationId** | **String** | The integration ID of the customer profile that unlocked the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. | [optional] +**usedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the reward was used. | [optional] +**usedByProfileIntegrationId** | **String** | The integration ID of the customer profile that used the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. Only returned when the reward has been used. | [optional] +**loyaltyProgramId** | **Long** | The ID of the loyalty program that the loyalty card belongs to. Only returned for rewards unlocked with a loyalty card. | [optional] +**loyaltyCardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +UNLOCKED | "unlocked" +USED | "used" + + + diff --git a/docs/CustomerReward.md b/docs/CustomerReward.md new file mode 100644 index 00000000..78658461 --- /dev/null +++ b/docs/CustomerReward.md @@ -0,0 +1,17 @@ + + +# CustomerReward + +A reward unlocked by a customer profile. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applicationId** | **Long** | The ID of the Application in which the reward was unlocked. | +**profileIntegrationId** | **String** | The integration ID of the customer profile that unlocked this reward. | +**integrationId** | **String** | The integration ID assigned to this reward unlock. | +**unlockedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the reward was unlocked. | +**usedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the reward was used. | [optional] + + + diff --git a/docs/CustomerSession.md b/docs/CustomerSession.md index 6160b45d..5085e812 100644 --- a/docs/CustomerSession.md +++ b/docs/CustomerSession.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | **coupon** | **String** | Any coupon code entered. | **referral** | **String** | Any referral code entered. | -**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | +**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | **cartItems** | [**List<CartItem>**](CartItem.md) | Serialized JSON representation. | **identifiers** | **List<String>** | Session custom identifiers that you can set limits on or use inside your rules. For example, you can use IP addresses as identifiers to potentially identify devices and limit discounts abuse in case of customers creating multiple accounts. See the [tutorial](https://docs.talon.one/docs/dev/tutorials/using-identifiers). | [optional] **total** | [**BigDecimal**](BigDecimal.md) | The total sum of the cart in one session. | diff --git a/docs/CustomerSessionV2.md b/docs/CustomerSessionV2.md index 1e10406c..c2051cc0 100644 --- a/docs/CustomerSessionV2.md +++ b/docs/CustomerSessionV2.md @@ -17,7 +17,8 @@ Name | Type | Description | Notes **couponCodes** | **List<String>** | Any coupon codes entered. **Important - for requests only**: - If you [create a coupon budget](https://docs.talon.one/docs/product/campaigns/settings/managing-campaign-budgets/#budget-types) for your campaign, ensure the session contains a coupon code by the time you close it. - In requests where `dry=false`, providing an empty array discards any previous coupons. To avoid this, omit the parameter entirely. | [optional] **referralCode** | **String** | Any referral code entered. **Important - for requests only**: - If you [create a referral budget](https://docs.talon.one/docs/product/campaigns/settings/managing-campaign-budgets/#budget-types) for your campaign, ensure the session contains a referral code by the time you close it. - In requests where `dry=false`, providing an empty value discards the previous referral code. To avoid this, omit the parameter entirely. | [optional] **loyaltyCards** | **List<String>** | Identifier of a loyalty card. | [optional] -**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | +**rewardIntegrationIds** | **List<String>** | The integration IDs of the unlocked rewards that can be used in this session. | [optional] +**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | **cartItems** | [**List<CartItem>**](CartItem.md) | The items to add to this session. **Do not exceed 1000 items** and ensure the sum of all cart item's `quantity` **does not exceed 10.000** per request. | **experimentVariantAllocations** | [**List<ExperimentVariantAllocation>**](ExperimentVariantAllocation.md) | The experiment variant allocations to add to this session. | [optional] **additionalCosts** | [**Map<String, AdditionalCost>**](AdditionalCost.md) | Use this property to set a value for the additional costs of this session, such as a shipping cost. They must be created in the Campaign Manager before you set them with this property. See [Managing additional costs](https://docs.talon.one/docs/product/account/dev-tools/managing-additional-costs). | [optional] @@ -28,6 +29,7 @@ Name | Type | Description | Notes **total** | [**BigDecimal**](BigDecimal.md) | The total value of cart items and additional costs in the session, before any discounts are applied. | **cartItemTotal** | [**BigDecimal**](BigDecimal.md) | The total value of cart items, before any discounts are applied. | **additionalCostTotal** | [**BigDecimal**](BigDecimal.md) | The total value of additional costs, before any discounts are applied. | +**cartItemAdditionalCostTotal** | [**BigDecimal**](BigDecimal.md) | The total value of additional costs applied to individual items, before any discounts are applied. | [readonly] **updated** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp of the most recent event received on this session. | diff --git a/docs/DeductLoyaltyPointsEffectProps.md b/docs/DeductLoyaltyPointsEffectProps.md index 76a9d1b3..756d1d49 100644 --- a/docs/DeductLoyaltyPointsEffectProps.md +++ b/docs/DeductLoyaltyPointsEffectProps.md @@ -2,17 +2,17 @@ # DeductLoyaltyPointsEffectProps -The properties specific to the \"deductLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained a condition to only trigger when the given number of loyalty points could be deduced. These points are automatically stored and managed inside Talon.One. +This effect is triggered when a customer redeems loyalty points. The points are deducted from their active point balance. If the loyalty program is card-based, use the `cardIdentifier` property to identify the loyalty card from which these points are deducted. The Rule Engine deducts points in this order: - Points with the earliest expiry date are deducted first, regardless of when they were added. - Points with an unlimited expiry date are deducted last. - For points with an unlimited expiry date, the points awarded first are deducted first. The points only persist when the session is closed. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ruleTitle** | **String** | The title of the rule that contained triggered this points deduction. | -**programId** | **Long** | The ID of the loyalty program where these points were added. | -**subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were added. | +**programId** | **Long** | The ID of the loyalty program from which these points were deducted. | +**subLedgerId** | **String** | The ID of the subledger within the loyalty program from which these points were deducted. | **value** | [**BigDecimal**](BigDecimal.md) | The amount of points that were deducted. | -**transactionUUID** | **String** | The identifier of this deduction in the loyalty ledger. | -**name** | **String** | The name property gets one of the following two values. It can be the loyalty program name or it can represent a reason for the respective deduction of loyalty points. The latter is an optional value defined in a deduction rule. | +**transactionUUID** | **String** | The identifier of this loyalty point transaction. | +**name** | **String** | The reason of this loyalty points deduction. | **cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] diff --git a/docs/DigitalPass.md b/docs/DigitalPass.md new file mode 100644 index 00000000..3e0f1843 --- /dev/null +++ b/docs/DigitalPass.md @@ -0,0 +1,23 @@ + + +# DigitalPass + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**passId** | **String** | The ID of the generated digital pass. | +**passTemplateId** | **String** | The ID of the digital pass template used to generate the pass. | +**status** | [**StatusEnum**](#StatusEnum) | The status of the digital pass. | +**passUrl** | [**URI**](URI.md) | The URL you can use to let the customer add the digital pass to their wallet. | + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +CREATED | "created" + + + diff --git a/docs/DiscardRisksRequest.md b/docs/DiscardRisksRequest.md new file mode 100644 index 00000000..96336597 --- /dev/null +++ b/docs/DiscardRisksRequest.md @@ -0,0 +1,23 @@ + + +# DiscardRisksRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**riskIds** | **List<Long>** | The IDs of the risks to discard. | +**reason** | [**ReasonEnum**](#ReasonEnum) | The reason the risks are being discarded. | +**comment** | **String** | Free-text description of why the risks are being discarded. Required when `reason` is `other`, optional for `expected_behavior`. | [optional] + + + +## Enum: ReasonEnum + +Name | Value +---- | ----- +EXPECTED_BEHAVIOR | "expected_behavior" +OTHER | "other" + + + diff --git a/docs/Effect.md b/docs/Effect.md index 9922c6cd..0190d437 100644 --- a/docs/Effect.md +++ b/docs/Effect.md @@ -23,6 +23,7 @@ Name | Type | Description | Notes **selectedPriceType** | **String** | The selected price type for the SKU targeted by this effect. | [optional] **selectedPrice** | [**BigDecimal**](BigDecimal.md) | The value of the selected price type to apply to the SKU targeted by this effect, before any discounts are applied. | [optional] **adjustmentReferenceId** | [**UUID**](UUID.md) | The reference identifier of the selected price adjustment for this SKU. This is only returned if the `selectedPrice` resulted from a price adjustment. | [optional] +**rewardId** | **Long** | The ID of the reward that was being evaluated when this effect was triggered. | [optional] **props** | [**Object**](.md) | | diff --git a/docs/EffectEntity.md b/docs/EffectEntity.md index 6a3f73d7..a11ba6b3 100644 --- a/docs/EffectEntity.md +++ b/docs/EffectEntity.md @@ -23,6 +23,7 @@ Name | Type | Description | Notes **selectedPriceType** | **String** | The selected price type for the SKU targeted by this effect. | [optional] **selectedPrice** | [**BigDecimal**](BigDecimal.md) | The value of the selected price type to apply to the SKU targeted by this effect, before any discounts are applied. | [optional] **adjustmentReferenceId** | [**UUID**](UUID.md) | The reference identifier of the selected price adjustment for this SKU. This is only returned if the `selectedPrice` resulted from a price adjustment. | [optional] +**rewardId** | **Long** | The ID of the reward that was being evaluated when this effect was triggered. | [optional] diff --git a/docs/ErrorEffectProps.md b/docs/ErrorEffectProps.md index e46da507..7332c5a8 100644 --- a/docs/ErrorEffectProps.md +++ b/docs/ErrorEffectProps.md @@ -2,7 +2,7 @@ # ErrorEffectProps -Whenever an error occurred during evaluation, we return an error effect. This should never happen for rules created in the rule builder. +This effect is triggered whenever an error occurs during rule evaluation. This effect only provides information about what the error is. ## Properties Name | Type | Description | Notes diff --git a/docs/Event.md b/docs/Event.md index a9035102..86949ca4 100644 --- a/docs/Event.md +++ b/docs/Event.md @@ -11,8 +11,9 @@ Name | Type | Description | Notes **applicationId** | **Long** | The ID of the Application that owns this entity. | **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] -**type** | **String** | A string representing the event. Must not be a reserved event name. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON data associated with the event. | +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | [optional] **sessionId** | **String** | The ID of the session that this event occurred in. | [optional] **effects** | **List<Object>** | An array of effects generated by the rules of the enabled campaigns of the Application. You decide how to apply them in your system. See the list of [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **ledgerEntries** | [**List<LedgerEntry>**](LedgerEntry.md) | Ledger entries for the event. | [optional] diff --git a/docs/EventAttributesEntity.md b/docs/EventAttributesEntity.md index 8bfd2d7e..e98ebeaa 100644 --- a/docs/EventAttributesEntity.md +++ b/docs/EventAttributesEntity.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**type** | **String** | A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] diff --git a/docs/EventV2.md b/docs/EventV2.md index 190c1e92..b4ee9ec8 100644 --- a/docs/EventV2.md +++ b/docs/EventV2.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] **evaluableCampaignIds** | **List<Long>** | When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. | [optional] -**type** | **String** | A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] diff --git a/docs/EventV3.md b/docs/EventV3.md index 9f4fc30f..921512b8 100644 --- a/docs/EventV3.md +++ b/docs/EventV3.md @@ -6,14 +6,17 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | +**connectedSessionId** | **String** | The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. | [optional] +**id** | **Long** | The internal ID of this entity. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | +**applicationId** | **Long** | The ID of the Application that owns this entity. | +**profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] -**evaluableCampaignIds** | **List<Long>** | When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. | [optional] -**integrationId** | **String** | The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. | -**type** | **String** | A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. | -**attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] -**connectedSessionID** | **String** | The ID of the session that happened in the past. | [optional] -**previousEventID** | **String** | The unique identifier of the event that happened in the past. | [optional] +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | +**attributes** | [**Object**](.md) | Arbitrary additional JSON data associated with the event. | +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | [optional] +**referralCode** | **String** | The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. | [optional] +**effects** | **List<Object>** | An array of effects generated by the rules of the enabled campaigns of the Application. You decide how to apply them in your system. See the list of [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | diff --git a/docs/EventV3Connections.md b/docs/EventV3Connections.md new file mode 100644 index 00000000..92847dbd --- /dev/null +++ b/docs/EventV3Connections.md @@ -0,0 +1,12 @@ + + +# EventV3Connections + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connectedSessionId** | **String** | The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. | [optional] + + + diff --git a/docs/EventV3Entity.md b/docs/EventV3Entity.md new file mode 100644 index 00000000..50dc3451 --- /dev/null +++ b/docs/EventV3Entity.md @@ -0,0 +1,12 @@ + + +# EventV3Entity + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | [optional] + + + diff --git a/docs/EventV3ReferralEntity.md b/docs/EventV3ReferralEntity.md new file mode 100644 index 00000000..1e2edc47 --- /dev/null +++ b/docs/EventV3ReferralEntity.md @@ -0,0 +1,12 @@ + + +# EventV3ReferralEntity + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**referralCode** | **String** | The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. | [optional] + + + diff --git a/docs/EventV3RequestEntity.md b/docs/EventV3RequestEntity.md new file mode 100644 index 00000000..65d976fe --- /dev/null +++ b/docs/EventV3RequestEntity.md @@ -0,0 +1,19 @@ + + +# EventV3RequestEntity + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | +**storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] +**evaluableCampaignIds** | **List<Long>** | When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. | [optional] +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | +**attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | +**connectedSessionId** | **String** | The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. | [optional] +**referralCode** | **String** | The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. | [optional] + + + diff --git a/docs/ExcludePriceObservationsRequest.md b/docs/ExcludePriceObservationsRequest.md new file mode 100644 index 00000000..1a551295 --- /dev/null +++ b/docs/ExcludePriceObservationsRequest.md @@ -0,0 +1,13 @@ + + +# ExcludePriceObservationsRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ids** | **List<Long>** | A list of historical price IDs to exclude from best prior price calculation. Must contain between 1 and 1000 IDs. All IDs must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, and must not already be excluded from best prior price calculation. | +**reason** | **String** | The reason for excluding these historical price IDs. Applies to all IDs in the batch. | + + + diff --git a/docs/Experiment.md b/docs/Experiment.md index 802868ab..8e75ff2e 100644 --- a/docs/Experiment.md +++ b/docs/Experiment.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **activated** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time the experiment was activated. | [optional] **state** | [**StateEnum**](#StateEnum) | A disabled experiment is not evaluated for rules or coupons. | **variants** | [**List<ExperimentVariant>**](ExperimentVariant.md) | | [optional] +**goalType** | [**GoalTypeEnum**](#GoalTypeEnum) | The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. | +**goalDescription** | **String** | A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. | [optional] **deletedat** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time the experiment was deleted. | [optional] @@ -28,3 +30,14 @@ ARCHIVED | "archived" +## Enum: GoalTypeEnum + +Name | Value +---- | ----- +OTHER | "other" +MAXIMIZE_REVENUE | "maximize_revenue" +OPTIMIZE_DISCOUNT_EFFICIENCY | "optimize_discount_efficiency" +MAXIMIZE_ITEMS_SOLD | "maximize_items_sold" + + + diff --git a/docs/ExperimentConfidenceTimeline.md b/docs/ExperimentConfidenceTimeline.md new file mode 100644 index 00000000..0f40f08c --- /dev/null +++ b/docs/ExperimentConfidenceTimeline.md @@ -0,0 +1,12 @@ + + +# ExperimentConfidenceTimeline + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**List<ExperimentConfidenceTimelineDataPoint>**](ExperimentConfidenceTimelineDataPoint.md) | Daily cumulative confidence values ordered chronologically from experiment start to end, or to today if the experiment is still running. Empty if the experiment has no data yet. | + + + diff --git a/docs/ExperimentConfidenceTimelineDataPoint.md b/docs/ExperimentConfidenceTimelineDataPoint.md new file mode 100644 index 00000000..a0b06b1a --- /dev/null +++ b/docs/ExperimentConfidenceTimelineDataPoint.md @@ -0,0 +1,13 @@ + + +# ExperimentConfidenceTimelineDataPoint + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**date** | [**OffsetDateTime**](OffsetDateTime.md) | The date-time this data point represents. | +**confidence** | [**ExperimentVariantResultConfidence**](ExperimentVariantResultConfidence.md) | | + + + diff --git a/docs/ExperimentCopyExperiment.md b/docs/ExperimentCopyExperiment.md index 84bc7ecb..abd77090 100644 --- a/docs/ExperimentCopyExperiment.md +++ b/docs/ExperimentCopyExperiment.md @@ -8,6 +8,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **isVariantAssignmentExternal** | **Boolean** | The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. | **campaign** | [**ExperimentCampaignCopy**](ExperimentCampaignCopy.md) | | +**goalType** | [**GoalTypeEnum**](#GoalTypeEnum) | The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the value from the source experiment is used. | [optional] +**goalDescription** | **String** | A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the value from the source experiment is used. | [optional] + + + +## Enum: GoalTypeEnum + +Name | Value +---- | ----- +OTHER | "other" +MAXIMIZE_REVENUE | "maximize_revenue" +MAXIMIZE_ITEMS_SOLD | "maximize_items_sold" +OPTIMIZE_DISCOUNT_EFFICIENCY | "optimize_discount_efficiency" diff --git a/docs/ExtendLoyaltyPointsExpiryDateEffectProps.md b/docs/ExtendLoyaltyPointsExpiryDateEffectProps.md index e00392dd..a16fa38f 100644 --- a/docs/ExtendLoyaltyPointsExpiryDateEffectProps.md +++ b/docs/ExtendLoyaltyPointsExpiryDateEffectProps.md @@ -2,13 +2,13 @@ # ExtendLoyaltyPointsExpiryDateEffectProps -The properties specific to the \"extendLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"extend expiry date\" effect. The current expiry date gets extended by the time frame given in the effect. +If loyalty points have an expiry date, this effect extends the expiry of all active and pending point transactions by a selected duration. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **programId** | **Long** | ID of the loyalty program that contains these points. | -**subLedgerId** | **String** | API name of the loyalty program subledger that contains these points. added. | +**subLedgerId** | **String** | API name of the loyalty program subledger that contains these points. | **extensionDuration** | **String** | Time frame by which the expiry date extends. The time format is either: - immediate, or - an **integer** followed by a letter indicating the time unit. Examples: `immediate`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. | **affectedTransactions** | [**List<LoyaltyLedgerEntryExpiryDateChange>**](LoyaltyLedgerEntryExpiryDateChange.md) | List of transactions affected by the expiry date update. | [optional] diff --git a/docs/FeatureFlagUpdate.md b/docs/FeatureFlagUpdate.md new file mode 100644 index 00000000..4871a1b0 --- /dev/null +++ b/docs/FeatureFlagUpdate.md @@ -0,0 +1,13 @@ + + +# FeatureFlagUpdate + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the feature flag. | +**value** | **String** | The value of the feature flag. | + + + diff --git a/docs/FilterAndMapValuesSelectorStep.md b/docs/FilterAndMapValuesSelectorStep.md new file mode 100644 index 00000000..6bfc2695 --- /dev/null +++ b/docs/FilterAndMapValuesSelectorStep.md @@ -0,0 +1,22 @@ + + +# FilterAndMapValuesSelectorStep + +Keeps items that exist in the value map, and attaches each kept item's mapped value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `filterAndMapValues`. | +**valueMap** | [**SelectorValueMapRef**](SelectorValueMapRef.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +FILTERANDMAPVALUES | "filterAndMapValues" + + + diff --git a/docs/FilterSelectorStep.md b/docs/FilterSelectorStep.md new file mode 100644 index 00000000..80648e09 --- /dev/null +++ b/docs/FilterSelectorStep.md @@ -0,0 +1,22 @@ + + +# FilterSelectorStep + +Filters only items that match a predicate block. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `filter`. | +**predicate** | [**Object**](.md) | Describes a part of the logic of the rule. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +FILTER | "filter" + + + diff --git a/docs/GeoJSONGeometryCollection.md b/docs/GeoJSONGeometryCollection.md new file mode 100644 index 00000000..aaee7fea --- /dev/null +++ b/docs/GeoJSONGeometryCollection.md @@ -0,0 +1,22 @@ + + +# GeoJSONGeometryCollection + +A group of different shapes combined into a single location, following the GeoJSON format. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | The geometry type discriminator. | +**geometries** | **List<Object>** | The shapes contained in this group. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +GEOMETRYCOLLECTION | "GeometryCollection" + + + diff --git a/docs/GeoJSONMultiPolygon.md b/docs/GeoJSONMultiPolygon.md new file mode 100644 index 00000000..bd953d00 --- /dev/null +++ b/docs/GeoJSONMultiPolygon.md @@ -0,0 +1,22 @@ + + +# GeoJSONMultiPolygon + +One or more separate shapes grouped together as a single location, following the GeoJSON format. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | The geometry type discriminator. | +**coordinates** | [**List<List<List<List<BigDecimal>>>>**](List.md) | The shapes in this group. Each one follows the same boundary structure as a polygon. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +MULTIPOLYGON | "MultiPolygon" + + + diff --git a/docs/GeoJSONPoint.md b/docs/GeoJSONPoint.md new file mode 100644 index 00000000..eaa77c7d --- /dev/null +++ b/docs/GeoJSONPoint.md @@ -0,0 +1,22 @@ + + +# GeoJSONPoint + +A single point on a map, defined by its longitude and latitude coordinates, following the GeoJSON format. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | The geometry type discriminator. | +**coordinates** | [**List<BigDecimal>**](BigDecimal.md) | The longitude and latitude coordinates of the point, optionally followed by altitude. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +POINT | "Point" + + + diff --git a/docs/GeoJSONPolygon.md b/docs/GeoJSONPolygon.md new file mode 100644 index 00000000..c84fe3ac --- /dev/null +++ b/docs/GeoJSONPolygon.md @@ -0,0 +1,22 @@ + + +# GeoJSONPolygon + +A shape formed by one or more boundaries, following the GeoJSON format. The first boundary defines the outer edge of the shape; any additional boundaries define holes within the shape. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | The geometry type discriminator. | +**coordinates** | [**List<List<List<BigDecimal>>>**](List.md) | The boundaries that make up the shape. Each boundary is a closed loop of longitude and latitude points, where the first and last point are the same. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +POLYGON | "Polygon" + + + diff --git a/docs/GiveawayPoolReference.md b/docs/GiveawayPoolReference.md new file mode 100644 index 00000000..d6adcf6d --- /dev/null +++ b/docs/GiveawayPoolReference.md @@ -0,0 +1,14 @@ + + +# GiveawayPoolReference + +The giveaway pool from which a giveaway is awarded. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The unique identifier of the giveaway pool. | +**name** | **String** | The display name of the giveaway pool. | [readonly] + + + diff --git a/docs/GroupBlock.md b/docs/GroupBlock.md new file mode 100644 index 00000000..ba56c349 --- /dev/null +++ b/docs/GroupBlock.md @@ -0,0 +1,29 @@ + + +# GroupBlock + +A structural combinator block that groups child blocks using a logical operator. Evaluates to true when its operator condition is satisfied across all child blocks. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | Logical operator applied across child blocks. `all` requires every child to pass, `atLeastOne` requires at least one, `none` requires all to fail. | +**blocks** | **List<Object>** | Child blocks evaluated according to the operator. | +**onFailure** | **List<Object>** | Blocks evaluated when this block fails or returns false. | [optional] +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +ALL | "all" +ATLEASTONE | "atLeastOne" +NONE | "none" + + + diff --git a/docs/History.md b/docs/History.md index 94101ccd..9dd009fe 100644 --- a/docs/History.md +++ b/docs/History.md @@ -8,10 +8,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **id** | **Long** | The ID of the historical price. | **observedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the price was observed. | -**contextId** | **String** | Identifier of the relevant context at the time the price was observed (e.g. summer sale). | +**contextIds** | **List<String>** | The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. | **price** | [**BigDecimal**](BigDecimal.md) | Price of the item. | **metadata** | [**BestPriorPriceMetadata**](BestPriorPriceMetadata.md) | | **target** | [**Object**](.md) | | +**excludedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the historical price ID was excluded. | [optional] +**exclusionReason** | **String** | The reason for excluding this historical price ID. | [optional] diff --git a/docs/IncreaseAchievementProgressEffectProps.md b/docs/IncreaseAchievementProgressEffectProps.md index 93c88f38..814da10b 100644 --- a/docs/IncreaseAchievementProgressEffectProps.md +++ b/docs/IncreaseAchievementProgressEffectProps.md @@ -2,15 +2,15 @@ # IncreaseAchievementProgressEffectProps -The properties specific to the \"increaseAchievementProgress\" effect. This gets triggered whenever a validated rule contained an \"increase customer progress\" effect. +This effect indicates that the customer's progress in an achievement was updated during the current session. It is triggered when a rule using the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect is successfully validated. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), any customer progress exceeding the target automatically starts a new iteration. This generates a new `progressTrackerId` for each iteration, and there can be multiple progress updates for the same achievement from a single validation of this effect. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **achievementId** | **Long** | The internal ID of the achievement. | **achievementName** | **String** | The name of the achievement. | -**progressTrackerId** | **Long** | The internal ID of the achievement progress tracker. | [optional] -**delta** | [**BigDecimal**](BigDecimal.md) | The value by which the customer's current progress in the achievement is increased. | +**progressTrackerId** | **Long** | The internal ID of the customer progress tracker. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. | [optional] +**delta** | [**BigDecimal**](BigDecimal.md) | The value by which the customer's current progress in the achievement has increased. | **value** | [**BigDecimal**](BigDecimal.md) | The current progress of the customer in the achievement. | **target** | [**BigDecimal**](BigDecimal.md) | The target value to complete the achievement. | **isJustCompleted** | **Boolean** | Indicates if the customer has completed the achievement in the current session. | diff --git a/docs/InlineResponse20032.md b/docs/InlineResponse20032.md index c27b86d7..822d38f3 100644 --- a/docs/InlineResponse20032.md +++ b/docs/InlineResponse20032.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | -**data** | [**List<ApplicationEvent>**](ApplicationEvent.md) | | +**hasMore** | **Boolean** | | [optional] +**totalResultSize** | **Long** | | [optional] +**data** | [**List<ApplicationSession>**](ApplicationSession.md) | | diff --git a/docs/InlineResponse20033.md b/docs/InlineResponse20033.md index 07a2a78f..3be9466b 100644 --- a/docs/InlineResponse20033.md +++ b/docs/InlineResponse20033.md @@ -6,8 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**totalResultSize** | **Long** | | -**data** | **List<String>** | | +**hasMore** | **Boolean** | | +**data** | [**List<ApplicationEvent>**](ApplicationEvent.md) | | diff --git a/docs/InlineResponse20034.md b/docs/InlineResponse20034.md index 020200ae..3697ba64 100644 --- a/docs/InlineResponse20034.md +++ b/docs/InlineResponse20034.md @@ -6,9 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | [optional] -**totalResultSize** | **Long** | | [optional] -**data** | [**List<Audience>**](Audience.md) | | +**totalResultSize** | **Long** | | +**data** | **List<String>** | | diff --git a/docs/InlineResponse20035.md b/docs/InlineResponse20035.md index 553f5b62..80363565 100644 --- a/docs/InlineResponse20035.md +++ b/docs/InlineResponse20035.md @@ -7,7 +7,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **hasMore** | **Boolean** | | [optional] -**data** | [**List<AudienceAnalytics>**](AudienceAnalytics.md) | | +**totalResultSize** | **Long** | | [optional] +**data** | [**List<Audience>**](Audience.md) | | diff --git a/docs/InlineResponse20036.md b/docs/InlineResponse20036.md index 78da0954..270f13b4 100644 --- a/docs/InlineResponse20036.md +++ b/docs/InlineResponse20036.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **hasMore** | **Boolean** | | [optional] -**data** | [**List<CustomerProfile>**](CustomerProfile.md) | | +**data** | [**List<AudienceAnalytics>**](AudienceAnalytics.md) | | diff --git a/docs/InlineResponse20037.md b/docs/InlineResponse20037.md index 24e0274a..e16eebbe 100644 --- a/docs/InlineResponse20037.md +++ b/docs/InlineResponse20037.md @@ -7,8 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **hasMore** | **Boolean** | | [optional] -**totalResultSize** | **Long** | | [optional] -**data** | [**List<ApplicationReferee>**](ApplicationReferee.md) | | +**data** | [**List<CustomerProfile>**](CustomerProfile.md) | | diff --git a/docs/InlineResponse20038.md b/docs/InlineResponse20038.md index f902d82b..a8eb52bc 100644 --- a/docs/InlineResponse20038.md +++ b/docs/InlineResponse20038.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**totalResultSize** | **Long** | | -**data** | [**List<Attribute>**](Attribute.md) | | +**hasMore** | **Boolean** | | [optional] +**totalResultSize** | **Long** | | [optional] +**data** | [**List<ApplicationReferee>**](ApplicationReferee.md) | | diff --git a/docs/InlineResponse20039.md b/docs/InlineResponse20039.md index 650f4b84..92fc6439 100644 --- a/docs/InlineResponse20039.md +++ b/docs/InlineResponse20039.md @@ -6,9 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | [optional] -**totalResultSize** | **Long** | | [optional] -**data** | [**List<CatalogItem>**](CatalogItem.md) | | +**totalResultSize** | **Long** | | +**data** | [**List<Attribute>**](Attribute.md) | | diff --git a/docs/InlineResponse20040.md b/docs/InlineResponse20040.md index 8750ef6d..4f955fcb 100644 --- a/docs/InlineResponse20040.md +++ b/docs/InlineResponse20040.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**totalResultSize** | **Long** | | -**data** | [**List<AccountAdditionalCost>**](AccountAdditionalCost.md) | | +**hasMore** | **Boolean** | | [optional] +**totalResultSize** | **Long** | | [optional] +**data** | [**List<CatalogItem>**](CatalogItem.md) | | diff --git a/docs/InlineResponse20041.md b/docs/InlineResponse20041.md index 0dc5db38..74793735 100644 --- a/docs/InlineResponse20041.md +++ b/docs/InlineResponse20041.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **totalResultSize** | **Long** | | -**data** | [**List<WebhookWithOutgoingIntegrationDetails>**](WebhookWithOutgoingIntegrationDetails.md) | | +**data** | [**List<AccountAdditionalCost>**](AccountAdditionalCost.md) | | diff --git a/docs/InlineResponse20042.md b/docs/InlineResponse20042.md index 56ff961a..226f1c4a 100644 --- a/docs/InlineResponse20042.md +++ b/docs/InlineResponse20042.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **totalResultSize** | **Long** | | -**data** | [**List<EventType>**](EventType.md) | | +**data** | [**List<WebhookWithOutgoingIntegrationDetails>**](WebhookWithOutgoingIntegrationDetails.md) | | diff --git a/docs/InlineResponse20043.md b/docs/InlineResponse20043.md index 4d69f414..a30adc5c 100644 --- a/docs/InlineResponse20043.md +++ b/docs/InlineResponse20043.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **totalResultSize** | **Long** | | -**data** | [**List<User>**](User.md) | | +**data** | [**List<EventType>**](EventType.md) | | diff --git a/docs/InlineResponse20044.md b/docs/InlineResponse20044.md index 5af1b6d0..f8ce5b3c 100644 --- a/docs/InlineResponse20044.md +++ b/docs/InlineResponse20044.md @@ -6,9 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**totalResultSize** | **Long** | | [optional] -**hasMore** | **Boolean** | | [optional] -**data** | [**List<Change>**](Change.md) | | +**totalResultSize** | **Long** | | +**data** | [**List<User>**](User.md) | | diff --git a/docs/InlineResponse20045.md b/docs/InlineResponse20045.md index 3712756c..bc911072 100644 --- a/docs/InlineResponse20045.md +++ b/docs/InlineResponse20045.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**totalResultSize** | **Long** | | -**data** | [**List<Export>**](Export.md) | | +**totalResultSize** | **Long** | | [optional] +**hasMore** | **Boolean** | | [optional] +**data** | [**List<Change>**](Change.md) | | diff --git a/docs/InlineResponse20046.md b/docs/InlineResponse20046.md index 20110f99..cf49f6e6 100644 --- a/docs/InlineResponse20046.md +++ b/docs/InlineResponse20046.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **totalResultSize** | **Long** | | -**data** | [**List<RoleV2>**](RoleV2.md) | | +**data** | [**List<Export>**](Export.md) | | diff --git a/docs/InlineResponse20047.md b/docs/InlineResponse20047.md index c994c7d7..1d175867 100644 --- a/docs/InlineResponse20047.md +++ b/docs/InlineResponse20047.md @@ -6,9 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | [optional] -**totalResultSize** | **Long** | | [optional] -**data** | [**List<Store>**](Store.md) | | +**totalResultSize** | **Long** | | +**data** | [**List<RoleV2>**](RoleV2.md) | | diff --git a/docs/InlineResponse20048.md b/docs/InlineResponse20048.md index 3dbf56d2..b350abb7 100644 --- a/docs/InlineResponse20048.md +++ b/docs/InlineResponse20048.md @@ -7,7 +7,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **hasMore** | **Boolean** | | [optional] -**data** | [**List<ApplicationCIF>**](ApplicationCIF.md) | | +**totalResultSize** | **Long** | | [optional] +**data** | [**List<Store>**](Store.md) | | diff --git a/docs/InlineResponse20049.md b/docs/InlineResponse20049.md index 8b156d17..fed6f269 100644 --- a/docs/InlineResponse20049.md +++ b/docs/InlineResponse20049.md @@ -6,7 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<ListCampaignStoreBudgets>**](ListCampaignStoreBudgets.md) | | [optional] +**hasMore** | **Boolean** | | [optional] +**data** | [**List<ApplicationCIF>**](ApplicationCIF.md) | | diff --git a/docs/InlineResponse20050.md b/docs/InlineResponse20050.md index 395c4f9e..2399730f 100644 --- a/docs/InlineResponse20050.md +++ b/docs/InlineResponse20050.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<SummaryCampaignStoreBudget>**](SummaryCampaignStoreBudget.md) | | [optional] +**data** | [**List<ListCampaignStoreBudgets>**](ListCampaignStoreBudgets.md) | | [optional] diff --git a/docs/InlineResponse20051.md b/docs/InlineResponse20051.md index e5ed265b..db710e8f 100644 --- a/docs/InlineResponse20051.md +++ b/docs/InlineResponse20051.md @@ -6,8 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | [optional] -**data** | [**List<Achievement>**](Achievement.md) | | +**data** | [**List<SummaryCampaignStoreBudget>**](SummaryCampaignStoreBudget.md) | | [optional] diff --git a/docs/InlineResponse20052.md b/docs/InlineResponse20052.md index d8275356..ccf8f778 100644 --- a/docs/InlineResponse20052.md +++ b/docs/InlineResponse20052.md @@ -6,8 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**hasMore** | **Boolean** | | -**data** | [**List<AchievementProgressWithDefinition>**](AchievementProgressWithDefinition.md) | | +**hasMore** | **Boolean** | | [optional] +**data** | [**List<Achievement>**](Achievement.md) | | diff --git a/docs/InlineResponse20053.md b/docs/InlineResponse20053.md index 6974901d..35f349e5 100644 --- a/docs/InlineResponse20053.md +++ b/docs/InlineResponse20053.md @@ -6,7 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<CouponFailureSummary>**](CouponFailureSummary.md) | | +**hasMore** | **Boolean** | | [optional] +**data** | [**List<AchievementV2>**](AchievementV2.md) | | diff --git a/docs/InlineResponse20054.md b/docs/InlineResponse20054.md new file mode 100644 index 00000000..fc0bd47b --- /dev/null +++ b/docs/InlineResponse20054.md @@ -0,0 +1,13 @@ + + +# InlineResponse20054 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hasMore** | **Boolean** | | +**data** | [**List<AchievementProgressWithDefinition>**](AchievementProgressWithDefinition.md) | | + + + diff --git a/docs/InlineResponse20055.md b/docs/InlineResponse20055.md new file mode 100644 index 00000000..6f016f92 --- /dev/null +++ b/docs/InlineResponse20055.md @@ -0,0 +1,12 @@ + + +# InlineResponse20055 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**List<CouponFailureSummary>**](CouponFailureSummary.md) | | + + + diff --git a/docs/InlineResponse20056.md b/docs/InlineResponse20056.md new file mode 100644 index 00000000..9550c4a0 --- /dev/null +++ b/docs/InlineResponse20056.md @@ -0,0 +1,13 @@ + + +# InlineResponse20056 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**catalog** | [**InlineResponse20056Catalog**](InlineResponse20056Catalog.md) | | +**loyalty** | [**Map<String, LoyaltyBalances>**](LoyaltyBalances.md) | The customer's loyalty balances for the specified loyalty program. Returned only when `loyaltyProgramId` is provided together with `profileIntegrationId` or `loyaltyCardId`. | [optional] + + + diff --git a/docs/InlineResponse20056Catalog.md b/docs/InlineResponse20056Catalog.md new file mode 100644 index 00000000..91d5bf2d --- /dev/null +++ b/docs/InlineResponse20056Catalog.md @@ -0,0 +1,14 @@ + + +# InlineResponse20056Catalog + +The paginated rewards catalog. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hasMore** | **Boolean** | Whether more pages exist after the current one. | +**data** | [**List<RewardCatalogItem>**](RewardCatalogItem.md) | | + + + diff --git a/docs/IntegrationApi.md b/docs/IntegrationApi.md index 11b434c0..61279d15 100644 --- a/docs/IntegrationApi.md +++ b/docs/IntegrationApi.md @@ -20,6 +20,7 @@ Method | HTTP request | Description [**getCustomerAchievements**](IntegrationApi.md#getCustomerAchievements) | **GET** /v1/customer_profiles/{integrationId}/achievements | List customer's available achievements [**getCustomerInventory**](IntegrationApi.md#getCustomerInventory) | **GET** /v1/customer_profiles/{integrationId}/inventory | List customer data [**getCustomerSession**](IntegrationApi.md#getCustomerSession) | **GET** /v2/customer_sessions/{customerSessionId} | Get customer session +[**getEventV3**](IntegrationApi.md#getEventV3) | **GET** /v3/events/{integrationId} | Get advanced event [**getLoyaltyBalances**](IntegrationApi.md#getLoyaltyBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/balances | Get customer's loyalty balances [**getLoyaltyCardBalances**](IntegrationApi.md#getLoyaltyCardBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/balances | Get card's point balances [**getLoyaltyCardPoints**](IntegrationApi.md#getLoyaltyCardPoints) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/points | List card's unused loyalty points @@ -28,12 +29,16 @@ Method | HTTP request | Description [**getLoyaltyProgramProfileTransactions**](IntegrationApi.md#getLoyaltyProgramProfileTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/transactions | List customer's loyalty transactions [**getReservedCustomers**](IntegrationApi.md#getReservedCustomers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | List customers that have this coupon reserved [**integrationGetAllCampaigns**](IntegrationApi.md#integrationGetAllCampaigns) | **GET** /v1/integration/campaigns | List all running campaigns +[**integrationRewardsCatalog**](IntegrationApi.md#integrationRewardsCatalog) | **GET** /v1/rewards/catalog | List rewards in the catalog +[**joinLoyaltyProgram**](IntegrationApi.md#joinLoyaltyProgram) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join | Join customer profile to loyalty program [**linkLoyaltyCardToProfile**](IntegrationApi.md#linkLoyaltyCardToProfile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile | Link customer profile to card [**reopenCustomerSession**](IntegrationApi.md#reopenCustomerSession) | **PUT** /v2/customer_sessions/{customerSessionId}/reopen | Reopen customer session [**returnCartItems**](IntegrationApi.md#returnCartItems) | **POST** /v2/customer_sessions/{customerSessionId}/returns | Return cart items [**syncCatalog**](IntegrationApi.md#syncCatalog) | **PUT** /v1/catalogs/{catalogId}/sync | Sync cart item catalog [**trackEventV2**](IntegrationApi.md#trackEventV2) | **POST** /v2/events | Track event +[**trackEventV3**](IntegrationApi.md#trackEventV3) | **POST** /v3/events | Track advanced event [**unlinkLoyaltyCardFromProfile**](IntegrationApi.md#unlinkLoyaltyCardFromProfile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/unlink_profile | Unlink customer profile from a loyalty card +[**unlockReward**](IntegrationApi.md#unlockReward) | **POST** /v1/rewards/{rewardId}/unlock | Unlock a reward [**updateAudienceCustomersAttributes**](IntegrationApi.md#updateAudienceCustomersAttributes) | **PUT** /v2/audience_customers/{audienceId}/attributes | Update profile attributes for all customers in audience [**updateAudienceV2**](IntegrationApi.md#updateAudienceV2) | **PUT** /v2/audiences/{audienceId} | Update audience name [**updateCustomerProfileAudiences**](IntegrationApi.md#updateCustomerProfileAudiences) | **POST** /v2/customer_audiences | Update multiple customer profiles' audiences @@ -586,7 +591,7 @@ null (empty response body) Delete audience -Delete an audience created by a third-party integration. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). +Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). The audience isn't deleted if any experiment variant uses it. The response identifies each blocking experiment by its Campaign Manager path. ### Example @@ -652,6 +657,7 @@ null (empty response body) | **400** | Bad request | - | | **401** | Unauthorized | - | | **404** | Not found | - | +| **409** | Conflict. The audience is used by one or more experiments. Each `errors[].source.resource` value contains the Campaign Manager path of a blocking experiment. | - | ## deleteCouponReservation @@ -1133,7 +1139,7 @@ Name | Type | Description | Notes ## getCustomerInventory -> CustomerInventory getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements) +> CustomerInventory getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards) List customer data @@ -1169,8 +1175,9 @@ public class Example { Boolean loyalty = true; // Boolean | Set to `true` to include loyalty information in the response. Boolean giveaways = true; // Boolean | Set to `true` to include giveaways information in the response. Boolean achievements = true; // Boolean | Set to `true` to include achievement information in the response. + Boolean unlockedRewards = true; // Boolean | Set to `true` to include `unlocked` rewards that have not been `used` in the response. try { - CustomerInventory result = apiInstance.getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements); + CustomerInventory result = apiInstance.getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling IntegrationApi#getCustomerInventory"); @@ -1195,6 +1202,7 @@ Name | Type | Description | Notes **loyalty** | **Boolean**| Set to `true` to include loyalty information in the response. | [optional] **giveaways** | **Boolean**| Set to `true` to include giveaways information in the response. | [optional] **achievements** | **Boolean**| Set to `true` to include achievement information in the response. | [optional] + **unlockedRewards** | **Boolean**| Set to `true` to include `unlocked` rewards that have not been `used` in the response. | [optional] ### Return type cool @@ -1248,7 +1256,7 @@ public class Example { //api_key_v1.setApiKeyPrefix("Token"); IntegrationApi apiInstance = new IntegrationApi(defaultClient); - String customerSessionId = "customerSessionId_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. + String customerSessionId = "customerSessionId_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). try { IntegrationCustomerSessionResponse result = apiInstance.getCustomerSession(customerSessionId); System.out.println(result); @@ -1268,7 +1276,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **customerSessionId** | **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. | + **customerSessionId** | **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). | ### Return type cool @@ -1291,6 +1299,79 @@ Name | Type | Description | Notes | **401** | Unauthorized - Invalid API key | - | +## getEventV3 + +> EventV3 getEventV3(integrationId) + +Get advanced event + +Retrieve an advanced event by its identifier. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.IntegrationApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + IntegrationApi apiInstance = new IntegrationApi(defaultClient); + String integrationId = "integrationId_example"; // String | The unique ID of the advanced event. + try { + EventV3 result = apiInstance.getEventV3(integrationId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#getEventV3"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **integrationId** | **String**| The unique ID of the advanced event. | + +### Return type cool + +[**EventV3**](EventV3.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **404** | Not found | - | + + ## getLoyaltyBalances > LoyaltyBalancesWithTiers getLoyaltyBalances(loyaltyProgramId, integrationId, endDate, subledgerId, includeTiers, includeProjectedTier) @@ -1677,12 +1758,12 @@ public class Example { Long loyaltyProgramId = 56L; // Long | 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. String integrationId = "integrationId_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. String status = "active"; // String | Filter points based on their status. - String subledgerId = "subledgerId_example"; // String | The ID of the subledger by which we filter the data. - List customerSessionIDs = Arrays.asList(); // List | Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. - List transactionUUIDs = Arrays.asList(); // List | Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. + List subledgerId = Arrays.asList(); // List | Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. + List customerSessionIDs = Arrays.asList(); // List | Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. + List transactionUUIDs = Arrays.asList(); // List | Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. Long pageSize = 50lL; // Long | The number of items in the response. Long skip = 56L; // Long | The number of items to skip when paging through large result sets. - String sort = "sort_example"; // String | The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. + String sort = "sort_example"; // String | The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. try { InlineResponse2007 result = apiInstance.getLoyaltyProgramProfilePoints(loyaltyProgramId, integrationId, status, subledgerId, customerSessionIDs, transactionUUIDs, pageSize, skip, sort); System.out.println(result); @@ -1705,12 +1786,12 @@ Name | Type | Description | Notes **loyaltyProgramId** | **Long**| 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. | **integrationId** | **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. | **status** | **String**| Filter points based on their status. | [optional] [default to active] [enum: active, pending, expired] - **subledgerId** | **String**| The ID of the subledger by which we filter the data. | [optional] - **customerSessionIDs** | [**List<String>**](String.md)| Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. | [optional] - **transactionUUIDs** | [**List<String>**](String.md)| Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. | [optional] + **subledgerId** | [**List<String>**](String.md)| Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. | [optional] + **customerSessionIDs** | [**List<String>**](String.md)| Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. | [optional] + **transactionUUIDs** | [**List<String>**](String.md)| Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. | [optional] **pageSize** | **Long**| The number of items in the response. | [optional] [default to 50l] **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] - **sort** | **String**| The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. | [optional] [enum: startDate, expiryDate] + **sort** | **String**| The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. | [optional] [enum: startDate, expiryDate] ### Return type cool @@ -1769,7 +1850,7 @@ public class Example { String integrationId = "integrationId_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. List customerSessionIDs = Arrays.asList(); // List | Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. List transactionUUIDs = Arrays.asList(); // List | Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. - String subledgerId = "subledgerId_example"; // String | The ID of the subledger by which we filter the data. + List subledgerId = Arrays.asList(); // List | Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. String loyaltyTransactionType = "loyaltyTransactionType_example"; // String | Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. OffsetDateTime startDate = new OffsetDateTime(); // OffsetDateTime | Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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. OffsetDateTime endDate = new OffsetDateTime(); // OffsetDateTime | Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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. @@ -1799,7 +1880,7 @@ Name | Type | Description | Notes **integrationId** | **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. | **customerSessionIDs** | [**List<String>**](String.md)| Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. | [optional] **transactionUUIDs** | [**List<String>**](String.md)| Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. | [optional] - **subledgerId** | **String**| The ID of the subledger by which we filter the data. | [optional] + **subledgerId** | [**List<String>**](String.md)| Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. | [optional] **loyaltyTransactionType** | **String**| Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. | [optional] [enum: manual, session, import] **startDate** | **OffsetDateTime**| Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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] **endDate** | **OffsetDateTime**| Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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] @@ -1860,7 +1941,7 @@ public class Example { //api_key_v1.setApiKeyPrefix("Token"); IntegrationApi apiInstance = new IntegrationApi(defaultClient); - String couponValue = "couponValue_example"; // String | The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. + String couponValue = "couponValue_example"; // String | The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. try { InlineResponse2001 result = apiInstance.getReservedCustomers(couponValue); System.out.println(result); @@ -1880,7 +1961,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **couponValue** | **String**| The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. | + **couponValue** | **String**| The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. | ### Return type cool @@ -1906,7 +1987,7 @@ Name | Type | Description | Notes ## integrationGetAllCampaigns -> InlineResponse200 integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore) +> InlineResponse200 integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId) List all running campaigns @@ -1942,8 +2023,10 @@ public class Example { OffsetDateTime startBefore = new OffsetDateTime(); // OffsetDateTime | 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. OffsetDateTime endAfter = new OffsetDateTime(); // OffsetDateTime | 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. OffsetDateTime endBefore = new OffsetDateTime(); // OffsetDateTime | 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. + Long storeId = 56L; // Long | Filter results to campaigns linked to the specified store ID. + Long audienceId = 56L; // Long | Filter results to campaigns linked to the specified audience ID. try { - InlineResponse200 result = apiInstance.integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore); + InlineResponse200 result = apiInstance.integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling IntegrationApi#integrationGetAllCampaigns"); @@ -1968,6 +2051,8 @@ Name | Type | Description | Notes **startBefore** | **OffsetDateTime**| 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] **endAfter** | **OffsetDateTime**| 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] **endBefore** | **OffsetDateTime**| 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] + **storeId** | **Long**| Filter results to campaigns linked to the specified store ID. | [optional] + **audienceId** | **Long**| Filter results to campaigns linked to the specified audience ID. | [optional] ### Return type cool @@ -1991,6 +2076,173 @@ Name | Type | Description | Notes | **404** | Not found | - | +## integrationRewardsCatalog + +> InlineResponse20056 integrationRewardsCatalog(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId) + +List rewards in the catalog + +Retrieve the rewards catalog for the Application. Returns a paginated list of rewards. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.IntegrationApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + IntegrationApi apiInstance = new IntegrationApi(defaultClient); + Long pageSize = 1000lL; // Long | The number of items in the response. + Long skip = 56L; // Long | The number of items to skip when paging through large result sets. + BigDecimal pointsFrom = new BigDecimal(); // BigDecimal | Return only rewards whose points required is greater than or equal to this value. + BigDecimal pointsTo = new BigDecimal(); // BigDecimal | Return only rewards whose points required is less than or equal to this value. + Boolean includeFree = true; // Boolean | Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. + Long loyaltyProgramId = 56L; // Long | Return only rewards available in this loyalty program. + String subledgerId = "subledgerId_example"; // String | Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). + String profileIntegrationId = "profileIntegrationId_example"; // String | The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. + String loyaltyCardId = "loyaltyCardId_example"; // String | The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. + try { + InlineResponse20056 result = apiInstance.integrationRewardsCatalog(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#integrationRewardsCatalog"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pageSize** | **Long**| The number of items in the response. | [optional] [default to 1000l] + **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] + **pointsFrom** | **BigDecimal**| Return only rewards whose points required is greater than or equal to this value. | [optional] + **pointsTo** | **BigDecimal**| Return only rewards whose points required is less than or equal to this value. | [optional] + **includeFree** | **Boolean**| Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. | [optional] [default to true] + **loyaltyProgramId** | **Long**| Return only rewards available in this loyalty program. | [optional] + **subledgerId** | **String**| Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). | [optional] + **profileIntegrationId** | **String**| The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. | [optional] + **loyaltyCardId** | **String**| The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. | [optional] + +### Return type cool + +[**InlineResponse20056**](InlineResponse20056.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | + + +## joinLoyaltyProgram + +> joinLoyaltyProgram(loyaltyProgramId, integrationId) + +Join customer profile to loyalty program + +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. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.IntegrationApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + IntegrationApi apiInstance = new IntegrationApi(defaultClient); + Long loyaltyProgramId = 56L; // Long | 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. + String integrationId = "integrationId_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. + try { + apiInstance.joinLoyaltyProgram(loyaltyProgramId, integrationId); + } catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#joinLoyaltyProgram"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **loyaltyProgramId** | **Long**| 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. | + **integrationId** | **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. | + +### Return type cool + +null (empty response body) + +### Authorization + +[api_key_v1](../README.md#api_key_v1) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | + + ## linkLoyaltyCardToProfile > LoyaltyCard linkLoyaltyCardToProfile(loyaltyProgramId, loyaltyCardId, body) @@ -2150,7 +2402,7 @@ Name | Type | Description | Notes Return cart items -Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. +Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). ### Example @@ -2230,7 +2482,7 @@ Name | Type | Description | Notes Sync cart item catalog -Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. ### Payload examples Synchronization actions are sent as `PUT` requests. See the structure for each action: <details> <summary><strong>Adding an item to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Adding multiple items to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241027\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" }, { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of an item in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"age\": 11, \"origin\": \"germany\" }, \"createIfNotExists\": false, \"sku\": \"SKU1241028\", \"product\": { \"name\": \"sneakers\" } }, \"type\": \"PATCH\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of multiple items in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"red\" }, \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"PATCH_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing an item from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"sku\": \"SKU1241028\" }, \"type\": \"REMOVE\" } ] } ``` </div> </details> <details> <summary><strong>Removing multiple items from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing shoes of sizes above 45 from the catalog</strong></summary> <div> <p> Let's imagine that we have a shoe store and we have decided to stop selling shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 with a single action:</p> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"size\", \"op\": \"GT\", \"value\": \"45\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> +Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. For request examples of each action, see the **Request Body** examples. ### Example @@ -2307,7 +2559,7 @@ Name | Type | Description | Notes Track event -Triggers a custom event. To use this endpoint: 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) in the Campaign Manager. 1. Update or create a rule to check for this event. 1. Trigger the event with this endpoint. After you have successfully sent an event to Talon.One, you can list the received events in the **Events** view in the Campaign Manager. Talon.One also offers a set of [built-in events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure you do not create a custom event when you can use a built-in event. For example, use this endpoint to trigger an event when a customer shares a link to a product. See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. +Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to trigger an event when a customer shares a link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. ### Example @@ -2377,9 +2629,91 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | +| **204** | No content | - | | **400** | Bad request | - | | **401** | Unauthorized - Invalid API key | - | -| **409** | Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). | - | +| **409** | Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). | - | + + +## trackEventV3 + +> IntegrationEventV3Response trackEventV3(body, silent, dry, forceCompleteEvaluation) + +Track advanced event + +Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). Advanced events are idempotent, uniquely identifiable events. They can also reference a previously closed session to add more context for rule evaluation. To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to award loyalty points after an order is delivered. See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). > [!note] **Note** > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.IntegrationApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + IntegrationApi apiInstance = new IntegrationApi(defaultClient); + IntegrationEventV3Request body = new IntegrationEventV3Request(); // IntegrationEventV3Request | body + String silent = "\"yes\""; // String | Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. + Boolean dry = true; // Boolean | Indicates whether to persist the changes. Changes are ignored when `dry=true`. + Boolean forceCompleteEvaluation = false; // Boolean | Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. + try { + IntegrationEventV3Response result = apiInstance.trackEventV3(body, silent, dry, forceCompleteEvaluation); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#trackEventV3"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **body** | [**IntegrationEventV3Request**](IntegrationEventV3Request.md)| body | + **silent** | **String**| Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. | [optional] [default to "yes"] + **dry** | **Boolean**| Indicates whether to persist the changes. Changes are ignored when `dry=true`. | [optional] + **forceCompleteEvaluation** | **Boolean**| Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. | [optional] [default to false] + +### Return type cool + +[**IntegrationEventV3Response**](IntegrationEventV3Response.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized - Invalid API key | - | +| **409** | An advanced event already exists, too many requests, or limit reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). | - | ## unlinkLoyaltyCardFromProfile @@ -2461,6 +2795,88 @@ Name | Type | Description | Notes | **404** | Not found | - | +## unlockReward + +> IntegrationStateV2 unlockReward(rewardId, body, dry) + +Unlock a reward + +Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.IntegrationApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + IntegrationApi apiInstance = new IntegrationApi(defaultClient); + Long rewardId = 56L; // Long | The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. + IntegrationUnlockRewardRequest body = new IntegrationUnlockRewardRequest(); // IntegrationUnlockRewardRequest | + Boolean dry = true; // Boolean | When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. + try { + IntegrationStateV2 result = apiInstance.unlockReward(rewardId, body, dry); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#unlockReward"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **rewardId** | **Long**| The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. | + **body** | [**IntegrationUnlockRewardRequest**](IntegrationUnlockRewardRequest.md)| | + **dry** | **Boolean**| When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. | [optional] + +### Return type cool + +[**IntegrationStateV2**](IntegrationStateV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | +| **403** | Forbidden | - | +| **404** | Not found | - | +| **409** | Conflict. A reward unlock with this integration ID already exists. | - | +| **422** | Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. | - | + + ## updateAudienceCustomersAttributes > updateAudienceCustomersAttributes(audienceId, body) @@ -2692,7 +3108,7 @@ null (empty response body) Update customer profile -Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. +Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. ### Example @@ -2717,7 +3133,7 @@ public class Example { //api_key_v1.setApiKeyPrefix("Token"); IntegrationApi apiInstance = new IntegrationApi(defaultClient); - String integrationId = "integrationId_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. + String integrationId = "integrationId_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). CustomerProfileIntegrationRequestV2 body = new CustomerProfileIntegrationRequestV2(); // CustomerProfileIntegrationRequestV2 | body Boolean runRuleEngine = false; // 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. Boolean dry = true; // 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. @@ -2740,7 +3156,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **integrationId** | **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. | + **integrationId** | **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). | **body** | [**CustomerProfileIntegrationRequestV2**](CustomerProfileIntegrationRequestV2.md)| body | **runRuleEngine** | **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] **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] @@ -2839,6 +3255,7 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | +| **204** | No content | - | | **400** | Bad request | - | | **401** | Unauthorized - Invalid API key | - | @@ -2874,7 +3291,7 @@ public class Example { //api_key_v1.setApiKeyPrefix("Token"); IntegrationApi apiInstance = new IntegrationApi(defaultClient); - String customerSessionId = "customerSessionId_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. + String customerSessionId = "customerSessionId_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). IntegrationRequest body = new IntegrationRequest(); // IntegrationRequest | body Boolean 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). OffsetDateTime now = new OffsetDateTime(); // OffsetDateTime | 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`. @@ -2897,7 +3314,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **customerSessionId** | **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. | + **customerSessionId** | **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). | **body** | [**IntegrationRequest**](IntegrationRequest.md)| body | **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] **now** | **OffsetDateTime**| 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] diff --git a/docs/IntegrationCampaign.md b/docs/IntegrationCampaign.md index e376a6c3..4fde5490 100644 --- a/docs/IntegrationCampaign.md +++ b/docs/IntegrationCampaign.md @@ -6,9 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**id** | **Long** | Unique ID of Campaign. | **applicationId** | **Long** | The ID of the Application that owns this entity. | -**name** | **String** | A user-facing name for this campaign. | +**id** | **Long** | Unique ID of Campaign. | +**name** | **String** | The name of the campaign. | **description** | **String** | A detailed description of the campaign. | [optional] **startTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become active. | [optional] **endTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become inactive. | [optional] @@ -16,6 +16,9 @@ Name | Type | Description | Notes **state** | [**StateEnum**](#StateEnum) | The state of the campaign. | **tags** | **List<String>** | A list of tags for the campaign. | **features** | [**List<FeaturesEnum>**](#List<FeaturesEnum>) | The features enabled in this campaign. | +**rules** | [**List<RuleMetadata>**](RuleMetadata.md) | A list of rules containing customer-facing details of the rewards defined in the campaign. | +**linkedStoreIds** | **List<Long>** | A list of store IDs linked to this campaign. | [optional] +**linkedAudienceIds** | **List<Long>** | A list of audience IDs linked to this campaign. | [optional] @@ -37,6 +40,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/IntegrationCampaignBase.md b/docs/IntegrationCampaignBase.md new file mode 100644 index 00000000..caa24671 --- /dev/null +++ b/docs/IntegrationCampaignBase.md @@ -0,0 +1,43 @@ + + +# IntegrationCampaignBase + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applicationId** | **Long** | The ID of the Application that owns this entity. | +**id** | **Long** | Unique ID of Campaign. | +**name** | **String** | The name of the campaign. | +**description** | **String** | A detailed description of the campaign. | [optional] +**startTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become active. | [optional] +**endTime** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the campaign will become inactive. | [optional] +**attributes** | [**Object**](.md) | Arbitrary properties associated with this campaign. | [optional] +**state** | [**StateEnum**](#StateEnum) | The state of the campaign. | +**tags** | **List<String>** | A list of tags for the campaign. | +**features** | [**List<FeaturesEnum>**](#List<FeaturesEnum>) | The features enabled in this campaign. | + + + +## Enum: StateEnum + +Name | Value +---- | ----- +ENABLED | "enabled" + + + +## Enum: List<FeaturesEnum> + +Name | Value +---- | ----- +COUPONS | "coupons" +REFERRALS | "referrals" +LOYALTY | "loyalty" +GIVEAWAYS | "giveaways" +STRIKETHROUGH | "strikethrough" +ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" + + + diff --git a/docs/IntegrationEvent.md b/docs/IntegrationEvent.md index 518f0bbe..a0f6ed5b 100644 --- a/docs/IntegrationEvent.md +++ b/docs/IntegrationEvent.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] -**type** | **String** | A string representing the event. Must not be a reserved event name. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON data associated with the event. | diff --git a/docs/IntegrationEventV2Request.md b/docs/IntegrationEventV2Request.md index 59c204ba..b3d7c399 100644 --- a/docs/IntegrationEventV2Request.md +++ b/docs/IntegrationEventV2Request.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] **evaluableCampaignIds** | **List<Long>** | When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. | [optional] -**type** | **String** | A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] **responseContent** | [**List<ResponseContentEnum>**](#List<ResponseContentEnum>) | Extends the response with the chosen data entities. Use this property to get as much data back as needed from one request instead of sending extra requests to other endpoints. | [optional] **loyaltyCards** | **List<String>** | Identifiers of the loyalty cards used during this event. | [optional] @@ -26,6 +26,9 @@ LOYALTY | "loyalty" EVENT | "event" AWARDEDGIVEAWAYS | "awardedGiveaways" RULEFAILUREREASONS | "ruleFailureReasons" +CAMPAIGNELIGIBILITY | "campaignEligibility" +ACHIEVEMENTS | "achievements" +UNLOCKEDREWARDS | "unlockedRewards" diff --git a/docs/IntegrationEventV2Response.md b/docs/IntegrationEventV2Response.md index f2b86f5e..2e60fd34 100644 --- a/docs/IntegrationEventV2Response.md +++ b/docs/IntegrationEventV2Response.md @@ -10,11 +10,14 @@ Name | Type | Description | Notes **customerProfile** | [**CustomerProfile**](CustomerProfile.md) | | [optional] **loyalty** | [**Loyalty**](Loyalty.md) | | [optional] **triggeredCampaigns** | [**List<Campaign>**](Campaign.md) | The campaigns that were triggered as a result of processing the event. | [optional] +**campaignEligibility** | [**List<CampaignEligibility>**](CampaignEligibility.md) | A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. | [optional] **effects** | [**List<Effect>**](Effect.md) | The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | The reasons why certain rules were not triggered during the event processing. | [optional] **createdCoupons** | [**List<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | **createdReferrals** | [**List<Referral>**](Referral.md) | The referrals that were created during the event processing. | **awardedGiveaways** | [**List<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] +**achievements** | [**List<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The rewards for the customer profile. | [optional] **event** | [**Event**](Event.md) | | [optional] diff --git a/docs/IntegrationEventV3Request.md b/docs/IntegrationEventV3Request.md index 0934c639..58704ffe 100644 --- a/docs/IntegrationEventV3Request.md +++ b/docs/IntegrationEventV3Request.md @@ -9,11 +9,11 @@ Name | Type | Description | Notes **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] **evaluableCampaignIds** | **List<Long>** | When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. | [optional] -**integrationId** | **String** | The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. | -**type** | **String** | A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). | [optional] -**connectedSessionID** | **String** | The ID of the session that happened in the past. | [optional] -**previousEventID** | **String** | The unique identifier of the event that happened in the past. | [optional] +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | +**connectedSessionId** | **String** | The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. | [optional] +**referralCode** | **String** | The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. | [optional] **loyaltyCards** | **List<String>** | Identifiers of the loyalty cards used during this event. | [optional] **responseContent** | [**List<ResponseContentEnum>**](#List<ResponseContentEnum>) | Optional list of requested information to be present on the response related to the tracking custom event. | [optional] @@ -23,12 +23,13 @@ Name | Type | Description | Notes Name | Value ---- | ----- -CUSTOMERPROFILE | "customerProfile" -TRIGGEREDCAMPAIGNS | "triggeredCampaigns" -LOYALTY | "loyalty" ADVANCEDEVENT | "advancedEvent" AWARDEDGIVEAWAYS | "awardedGiveaways" +CUSTOMERPROFILE | "customerProfile" +LOYALTY | "loyalty" +REFERRAL | "referral" RULEFAILUREREASONS | "ruleFailureReasons" +TRIGGEREDCAMPAIGNS | "triggeredCampaigns" diff --git a/docs/IntegrationEventV3Response.md b/docs/IntegrationEventV3Response.md index 7ccb7dd9..9e568550 100644 --- a/docs/IntegrationEventV3Response.md +++ b/docs/IntegrationEventV3Response.md @@ -10,12 +10,16 @@ Name | Type | Description | Notes **customerProfile** | [**CustomerProfile**](CustomerProfile.md) | | [optional] **loyalty** | [**Loyalty**](Loyalty.md) | | [optional] **triggeredCampaigns** | [**List<Campaign>**](Campaign.md) | The campaigns that were triggered as a result of processing the event. | [optional] +**campaignEligibility** | [**List<CampaignEligibility>**](CampaignEligibility.md) | A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. | [optional] **effects** | [**List<Effect>**](Effect.md) | The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | The reasons why certain rules were not triggered during the event processing. | [optional] **createdCoupons** | [**List<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | **createdReferrals** | [**List<Referral>**](Referral.md) | The referrals that were created during the event processing. | **awardedGiveaways** | [**List<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] +**achievements** | [**List<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The rewards for the customer profile. | [optional] **advancedEvent** | [**EventV3**](EventV3.md) | | [optional] +**referral** | [**InventoryReferral**](InventoryReferral.md) | | [optional] diff --git a/docs/IntegrationHubEventPayloadCouponBasedNotifications.md b/docs/IntegrationHubEventPayloadCouponBasedNotifications.md index de62cedf..1ea90098 100644 --- a/docs/IntegrationHubEventPayloadCouponBasedNotifications.md +++ b/docs/IntegrationHubEventPayloadCouponBasedNotifications.md @@ -6,6 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**eventId** | **Long** | The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. | **id** | **Long** | | **created** | [**OffsetDateTime**](OffsetDateTime.md) | | **campaignId** | **Long** | | diff --git a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md index 45b9322d..d9e21898 100644 --- a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md +++ b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md @@ -6,10 +6,14 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**eventId** | **Long** | The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. | **profileIntegrationID** | **String** | | **loyaltyProgramID** | **Long** | | +**loyaltyProgramName** | **String** | The name of the loyalty program. | **subledgerID** | **String** | | **sourceOfEvent** | **String** | | +**currentTier** | **String** | The name of the customer's current tier. | +**sessionIntegrationID** | **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] **employeeName** | **String** | | [optional] **userID** | **Long** | | [optional] **currentPoints** | **Float** | | diff --git a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.md b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.md index 46772660..7a7ebd4b 100644 --- a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.md +++ b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.md @@ -6,11 +6,13 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**eventId** | **Long** | The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. | **profileIntegrationID** | **String** | | **loyaltyProgramID** | **Long** | | +**loyaltyProgramName** | **String** | The name of the loyalty program. | **subledgerID** | **String** | | **sourceOfEvent** | **String** | | -**currentTier** | **String** | | [optional] +**currentTier** | **String** | The name of the customer's current tier, or null if the customer was downgraded below all tiers. | [optional] **currentPoints** | **Float** | | **oldTier** | **String** | | [optional] **tierExpirationDate** | [**OffsetDateTime**](OffsetDateTime.md) | | [optional] diff --git a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.md b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.md index dbda7e6f..4c8d6182 100644 --- a/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.md +++ b/docs/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.md @@ -6,11 +6,13 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**eventId** | **Long** | The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. | **profileIntegrationID** | **String** | | **loyaltyProgramID** | **Long** | | +**loyaltyProgramName** | **String** | The name of the loyalty program. | **subledgerID** | **String** | | **sourceOfEvent** | **String** | | -**currentTier** | **String** | | [optional] +**currentTier** | **String** | The name of the customer's current tier. | **currentPoints** | **Float** | | **oldTier** | **String** | | [optional] **pointsRequiredToTheNextTier** | **Float** | | [optional] diff --git a/docs/IntegrationHubEventRecord.md b/docs/IntegrationHubEventRecord.md index f9ccd850..a205929f 100644 --- a/docs/IntegrationHubEventRecord.md +++ b/docs/IntegrationHubEventRecord.md @@ -6,14 +6,17 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**id** | **Long** | | -**flowId** | **Long** | | -**eventType** | **String** | | -**eventData** | [**Object**](.md) | | -**publishedAt** | [**OffsetDateTime**](OffsetDateTime.md) | | -**processedAt** | [**OffsetDateTime**](OffsetDateTime.md) | | [optional] -**processAfter** | [**OffsetDateTime**](OffsetDateTime.md) | | -**retry** | **Long** | | +**id** | **Long** | ID of the event record. | +**flowId** | **Long** | ID of the integration hub flow. | +**integrationName** | **String** | Name of the integration. | [optional] +**instanceName** | **String** | Name of the integration instance. | [optional] +**eventType** | [**IntegrationHubEventType**](IntegrationHubEventType.md) | | +**publishedAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the event was published. | +**processedAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the event was processed. | [optional] +**deliveredAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the event was delivered. | [optional] +**scheduledTo** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp after which the event is scheduled to be processed. | +**retry** | **Long** | Number of delivery retries attempted. | +**payload** | **String** | The event payload as a formatted JSON string. | diff --git a/docs/IntegrationHubEventStatusUpdate.md b/docs/IntegrationHubEventStatusUpdate.md new file mode 100644 index 00000000..50748f14 --- /dev/null +++ b/docs/IntegrationHubEventStatusUpdate.md @@ -0,0 +1,22 @@ + + +# IntegrationHubEventStatusUpdate + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**eventId** | **Long** | The ID of the integration hub event. | +**status** | [**StatusEnum**](#StatusEnum) | The delivery outcome for the event. | + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +DELIVERED | "delivered" +FAILED | "failed" + + + diff --git a/docs/IntegrationHubEventType.md b/docs/IntegrationHubEventType.md new file mode 100644 index 00000000..ad6b61ff --- /dev/null +++ b/docs/IntegrationHubEventType.md @@ -0,0 +1,21 @@ + + +# IntegrationHubEventType + +## Enum + + +* `LOYALTYPOINTSCHANGED` (value: `"LoyaltyPointsChanged"`) + +* `LOYALTYTIERDOWNGRADE` (value: `"LoyaltyTierDowngrade"`) + +* `LOYALTYTIERUPGRADE` (value: `"LoyaltyTierUpgrade"`) + +* `COUPONCREATED` (value: `"CouponCreated"`) + +* `COUPONUPDATED` (value: `"CouponUpdated"`) + +* `COUPONDELETED` (value: `"CouponDeleted"`) + + + diff --git a/docs/IntegrationHubFlow.md b/docs/IntegrationHubFlow.md index 57035e01..63a2b237 100644 --- a/docs/IntegrationHubFlow.md +++ b/docs/IntegrationHubFlow.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**applicationID** | **Long** | ID of application the flow is registered for. | [optional] -**eventType** | **String** | The event type we want to register a flow for. | +**applicationID** | **Long** | ID of the application the flow is registered for. | [optional] +**loyaltyProgramID** | **Long** | ID of the loyalty program the flow is registered for. | [optional] +**eventType** | [**IntegrationHubEventType**](IntegrationHubEventType.md) | | **integrationHubFlowUrl** | **String** | The URL of the integration hub flow that we want to trigger for the event. | diff --git a/docs/IntegrationHubFlowConfig.md b/docs/IntegrationHubFlowConfig.md index 74f5a01b..72893e03 100644 --- a/docs/IntegrationHubFlowConfig.md +++ b/docs/IntegrationHubFlowConfig.md @@ -10,6 +10,8 @@ Name | Type | Description | Notes **workerCount** | **Long** | Number of IntegrationHub workers to run in parallel for this flow (maximum 500). | [optional] **maxEventsPerMessage** | **Long** | Maximum number of events to send in a single message to IntegrationHub. | [optional] **maxRetries** | **Long** | Maximum number of retries for a IntegrationHub event before it is ignored. | [optional] +**instanceName** | **String** | Name of the Prismatic instance that registered this flow. | [optional] +**integrationName** | **String** | Name of the Prismatic integration that registered this flow. | [optional] diff --git a/docs/IntegrationHubFlowResponse.md b/docs/IntegrationHubFlowResponse.md index 22a1f955..6e4ac192 100644 --- a/docs/IntegrationHubFlowResponse.md +++ b/docs/IntegrationHubFlowResponse.md @@ -7,9 +7,13 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **id** | **Long** | ID of the integration hub flow. | -**applicationID** | **Long** | ID of application the flow is registered for. | [optional] +**integrationName** | **String** | Name of the integration. | [optional] +**instanceName** | **String** | Name of the integration instance. | [optional] +**createdAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the flow was created. | +**disabledUntil** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp until which the flow is disabled. Null when the flow is active. | [optional] +**applicationId** | **Long** | ID of the application the flow is registered for. | [optional] +**loyaltyProgramId** | **Long** | ID of the loyalty program the flow is registered for. | [optional] **eventType** | **String** | The event type we want to register a flow for. | -**integrationHubFlowUrl** | **String** | The URL of the integration hub flow that we want to trigger for the event. | **config** | [**IntegrationHubFlowConfigResponse**](IntegrationHubFlowConfigResponse.md) | | diff --git a/docs/IntegrationHubFlowWithConfig.md b/docs/IntegrationHubFlowWithConfig.md index ad09ebf2..f6d18b7a 100644 --- a/docs/IntegrationHubFlowWithConfig.md +++ b/docs/IntegrationHubFlowWithConfig.md @@ -6,8 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**applicationID** | **Long** | ID of application the flow is registered for. | [optional] -**eventType** | **String** | The event type we want to register a flow for. | +**applicationID** | **Long** | ID of the application the flow is registered for. | [optional] +**loyaltyProgramID** | **Long** | ID of the loyalty program the flow is registered for. | [optional] +**eventType** | [**IntegrationHubEventType**](IntegrationHubEventType.md) | | **integrationHubFlowUrl** | **String** | The URL of the integration hub flow that we want to trigger for the event. | **config** | [**IntegrationHubFlowConfig**](IntegrationHubFlowConfig.md) | | diff --git a/docs/IntegrationHubInstance.md b/docs/IntegrationHubInstance.md new file mode 100644 index 00000000..fb5cb8ad --- /dev/null +++ b/docs/IntegrationHubInstance.md @@ -0,0 +1,13 @@ + + +# IntegrationHubInstance + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**instanceId** | **String** | The ID of the Prismatic integration instance. | +**instanceName** | **String** | The name of the Prismatic integration instance. | + + + diff --git a/docs/IntegrationHubPaginatedEventPayload.md b/docs/IntegrationHubPaginatedEventPayload.md index b5c2e3b4..8701bbaa 100644 --- a/docs/IntegrationHubPaginatedEventPayload.md +++ b/docs/IntegrationHubPaginatedEventPayload.md @@ -8,21 +8,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **totalResultSize** | **Long** | | **batchedAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the batch was created. | [optional] -**eventType** | [**EventTypeEnum**](#EventTypeEnum) | | +**eventType** | [**IntegrationHubEventType**](IntegrationHubEventType.md) | | **data** | **List<Object>** | | -## Enum: EventTypeEnum - -Name | Value ----- | ----- -LOYALTYPOINTSCHANGED | "LoyaltyPointsChanged" -LOYALTYTIERDOWNGRADE | "LoyaltyTierDowngrade" -LOYALTYTIERUPGRADE | "LoyaltyTierUpgrade" -COUPONCREATED | "CouponCreated" -COUPONUPDATED | "CouponUpdated" -COUPONDELETED | "CouponDeleted" - - - diff --git a/docs/IntegrationRequest.md b/docs/IntegrationRequest.md index 0515d4e8..84b9059b 100644 --- a/docs/IntegrationRequest.md +++ b/docs/IntegrationRequest.md @@ -26,6 +26,9 @@ EVENT | "event" AWARDEDGIVEAWAYS | "awardedGiveaways" RULEFAILUREREASONS | "ruleFailureReasons" PREVIOUSRETURNS | "previousReturns" +CAMPAIGNELIGIBILITY | "campaignEligibility" +ACHIEVEMENTS | "achievements" +UNLOCKEDREWARDS | "unlockedRewards" diff --git a/docs/IntegrationResponse.md b/docs/IntegrationResponse.md index 802f9948..d97d6ecf 100644 --- a/docs/IntegrationResponse.md +++ b/docs/IntegrationResponse.md @@ -10,11 +10,14 @@ Name | Type | Description | Notes **customerProfile** | [**CustomerProfile**](CustomerProfile.md) | | [optional] **loyalty** | [**Loyalty**](Loyalty.md) | | [optional] **triggeredCampaigns** | [**List<Campaign>**](Campaign.md) | The campaigns that were triggered as a result of processing the event. | [optional] +**campaignEligibility** | [**List<CampaignEligibility>**](CampaignEligibility.md) | A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. | [optional] **effects** | [**List<Effect>**](Effect.md) | The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | The reasons why certain rules were not triggered during the event processing. | [optional] **createdCoupons** | [**List<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | **createdReferrals** | [**List<Referral>**](Referral.md) | The referrals that were created during the event processing. | **awardedGiveaways** | [**List<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] +**achievements** | [**List<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The rewards for the customer profile. | [optional] diff --git a/docs/IntegrationStateV2.md b/docs/IntegrationStateV2.md index d8c09895..1e16517c 100644 --- a/docs/IntegrationStateV2.md +++ b/docs/IntegrationStateV2.md @@ -10,11 +10,14 @@ Name | Type | Description | Notes **customerProfile** | [**CustomerProfile**](CustomerProfile.md) | | [optional] **loyalty** | [**Loyalty**](Loyalty.md) | | [optional] **triggeredCampaigns** | [**List<Campaign>**](Campaign.md) | The campaigns that were triggered as a result of processing the event. | [optional] +**campaignEligibility** | [**List<CampaignEligibility>**](CampaignEligibility.md) | A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. | [optional] **effects** | [**List<Effect>**](Effect.md) | The effects generated by the rules in your running campaigns. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). | **ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | The reasons why certain rules were not triggered during the event processing. | [optional] **createdCoupons** | [**List<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | **createdReferrals** | [**List<Referral>**](Referral.md) | The referrals that were created during the event processing. | **awardedGiveaways** | [**List<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] +**achievements** | [**List<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] +**rewards** | [**List<RewardWithUnlocks>**](RewardWithUnlocks.md) | The rewards for the customer profile. | [optional] **referral** | [**InventoryReferral**](InventoryReferral.md) | | [optional] **coupons** | [**List<IntegrationCoupon>**](IntegrationCoupon.md) | The coupons that were processed. | [optional] **event** | [**Event**](Event.md) | | [optional] diff --git a/docs/IntegrationUnlockRewardRequest.md b/docs/IntegrationUnlockRewardRequest.md new file mode 100644 index 00000000..04e2ee08 --- /dev/null +++ b/docs/IntegrationUnlockRewardRequest.md @@ -0,0 +1,29 @@ + + +# IntegrationUnlockRewardRequest + +The request body for unlocking a reward for a customer profile, optionally using the balance of one of the customer's loyalty cards. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The integration ID to assign to the created customer reward unlock. | +**profileIntegrationId** | **String** | The integration ID of the customer profile unlocking the reward. | +**cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] +**loyaltyProgramId** | **Long** | The ID of the loyalty program from which points will be deducted. Required when the reward has `pointsRequired` configured. | [optional] +**subledgerId** | **String** | The ID of the subledger from which points will be deducted. Required when the reward has `pointsRequired` configured. To specify the main ledger, provide an empty string (\"\"). | [optional] +**responseContent** | [**List<ResponseContentEnum>**](#List<ResponseContentEnum>) | Determines which data is included in the response. Add any of the following optional values to the array to get that data in the response: `customerProfile`, `ruleFailureReasons`, `loyalty`. `effects` is always returned regardless of whether it is included here. | [optional] + + + +## Enum: List<ResponseContentEnum> + +Name | Value +---- | ----- +CUSTOMERPROFILE | "customerProfile" +EFFECTS | "effects" +RULEFAILUREREASONS | "ruleFailureReasons" +LOYALTY | "loyalty" + + + diff --git a/docs/JoinLoyaltyProgramEffectProps.md b/docs/JoinLoyaltyProgramEffectProps.md new file mode 100644 index 00000000..ebb1da29 --- /dev/null +++ b/docs/JoinLoyaltyProgramEffectProps.md @@ -0,0 +1,14 @@ + + +# JoinLoyaltyProgramEffectProps + +This effect indicates that a customer profile was joined to a profile-based loyalty program with the specified join date. > [!note] **Note** > - This effect requires a customer profile. It does not work for anonymous sessions. > - The effect fails if the customer profile has already joined the loyalty program. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**programId** | **Long** | The ID of the loyalty program the customer profile is joined to. | +**joinDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time when the customer profile joined the loyalty program. | + + + diff --git a/docs/LedgerTransactionLogEntryIntegrationAPI.md b/docs/LedgerTransactionLogEntryIntegrationAPI.md index 89553818..f3f83705 100644 --- a/docs/LedgerTransactionLogEntryIntegrationAPI.md +++ b/docs/LedgerTransactionLogEntryIntegrationAPI.md @@ -11,6 +11,7 @@ Name | Type | Description | Notes **created** | [**OffsetDateTime**](OffsetDateTime.md) | Date and time the loyalty transaction occurred. | **programId** | **Long** | ID of the loyalty program. | **customerSessionId** | **String** | ID of the customer session where the transaction occurred. | [optional] +**storeIntegrationId** | **String** | The integration ID of the store where the transaction occurred. Only set for transactions created by a customer session or event that referenced a store. | [optional] **type** | [**TypeEnum**](#TypeEnum) | Type of transaction. Possible values: - `addition`: Signifies added points. - `subtraction`: Signifies deducted points. | **name** | **String** | Name or reason of the loyalty ledger transaction. | **startDate** | **String** | When points become active. Possible values: - `immediate`: Points are immediately active. - `on_action`: Points become active based on the customer's action. - a timestamp value: Points become active at a given date and time. | @@ -21,7 +22,7 @@ Name | Type | Description | Notes **rulesetId** | **Long** | The ID of the ruleset containing the rule that triggered this effect. | [optional] **ruleName** | **String** | The name of the rule that triggered this effect. | [optional] **flags** | [**LoyaltyLedgerEntryFlags**](LoyaltyLedgerEntryFlags.md) | | [optional] -**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] +**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] diff --git a/docs/ListCheckAttributeBlock.md b/docs/ListCheckAttributeBlock.md new file mode 100644 index 00000000..83bea3ea --- /dev/null +++ b/docs/ListCheckAttributeBlock.md @@ -0,0 +1,24 @@ + + +# ListCheckAttributeBlock + +Variant of `CheckAttributeBlock` for operators that test list membership against a set of values. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The list membership operator applied to the attribute. | [optional] +**values** | [**Object**](.md) | The set of values to match against. | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +CONTAINSONEOF | "containsOneOf" +CONTAINSNONEOF | "containsNoneOf" +CONTAINSALLOF | "containsAllOf" + + + diff --git a/docs/ListWithCountCheckAttributeBlock.md b/docs/ListWithCountCheckAttributeBlock.md new file mode 100644 index 00000000..a181c9fd --- /dev/null +++ b/docs/ListWithCountCheckAttributeBlock.md @@ -0,0 +1,24 @@ + + +# ListWithCountCheckAttributeBlock + +Variant of `CheckAttributeBlock` for operators that test list membership with a minimum or exact count threshold. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The list membership operator with a count threshold applied to the attribute. | [optional] +**values** | [**Object**](.md) | The set of values to match against. | +**count** | [**Object**](.md) | The count threshold for this operator. | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +CONTAINSATLEAST | "containsAtLeast" +CONTAINSEXACTLY | "containsExactly" + + + diff --git a/docs/LocationCheckAttributeBlock.md b/docs/LocationCheckAttributeBlock.md new file mode 100644 index 00000000..bc118c96 --- /dev/null +++ b/docs/LocationCheckAttributeBlock.md @@ -0,0 +1,23 @@ + + +# LocationCheckAttributeBlock + +A block variant of `CheckAttributeBlock` for operators that check whether a geographical location is inside a set of geometric areas. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The location membership operator applied to the attribute. | [optional] +**values** | [**Object**](.md) | The geometric areas to check the location against. | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +IN | "in" +NOT_IN_ | "not(in)" + + + diff --git a/docs/LoyaltyProgramLedgers.md b/docs/LoyaltyProgramLedgers.md index b05bd41d..7ef703e5 100644 --- a/docs/LoyaltyProgramLedgers.md +++ b/docs/LoyaltyProgramLedgers.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **name** | **String** | Internal name of loyalty program. | **joinDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date on which the customer joined the loyalty program in RFC3339. **Note**: This is in the loyalty program's time zone. | [optional] **ledger** | [**LedgerInfo**](LedgerInfo.md) | | -**subLedgers** | [**Map<String, LedgerInfo>**](LedgerInfo.md) | A map containing information about each loyalty subledger. | [optional] +**subLedgers** | [**Map<String, LedgerInfo>**](LedgerInfo.md) | A map containing information about each loyalty subledger. Subledgers for which all balances are zero are excluded from the response. | [optional] diff --git a/docs/LoyaltyProgramTransaction.md b/docs/LoyaltyProgramTransaction.md index cfd0bb30..28bd85ab 100644 --- a/docs/LoyaltyProgramTransaction.md +++ b/docs/LoyaltyProgramTransaction.md @@ -26,7 +26,7 @@ Name | Type | Description | Notes **rulesetId** | **Long** | ID of the ruleset containing the rule that triggered the effect. Applies only for transactions that resulted from a customer session. | [optional] **ruleName** | **String** | Name of the rule that triggered the effect. Applies only for transactions that resulted from a customer session. | [optional] **flags** | [**LoyaltyLedgerEntryFlags**](LoyaltyLedgerEntryFlags.md) | | [optional] -**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] +**validityDuration** | **String** | The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. | [optional] diff --git a/docs/MCPCompleteOAuthSession.md b/docs/MCPCompleteOAuthSession.md new file mode 100644 index 00000000..60a3f3cd --- /dev/null +++ b/docs/MCPCompleteOAuthSession.md @@ -0,0 +1,12 @@ + + +# MCPCompleteOAuthSession + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**sessionId** | **String** | The pending authorization session ID to complete. | + + + diff --git a/docs/MCPOAuthClient.md b/docs/MCPOAuthClient.md new file mode 100644 index 00000000..41487b68 --- /dev/null +++ b/docs/MCPOAuthClient.md @@ -0,0 +1,15 @@ + + +# MCPOAuthClient + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**clientId** | **String** | Unique identifier for the OAuth2 client. | +**clientName** | **String** | Human-readable name for the OAuth2 client. | +**redirectUris** | **List<String>** | List of allowed redirect URIs for the authorization code flow. | +**createdAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp of when the client was registered. | + + + diff --git a/docs/MCPOAuthCompleteResult.md b/docs/MCPOAuthCompleteResult.md new file mode 100644 index 00000000..9fbe6d10 --- /dev/null +++ b/docs/MCPOAuthCompleteResult.md @@ -0,0 +1,12 @@ + + +# MCPOAuthCompleteResult + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**redirectUrl** | **String** | The full redirect URL the browser should be sent to, containing the authorization code and state as query parameters. | + + + diff --git a/docs/MCPOAuthProtectedResource.md b/docs/MCPOAuthProtectedResource.md new file mode 100644 index 00000000..0fd0681e --- /dev/null +++ b/docs/MCPOAuthProtectedResource.md @@ -0,0 +1,13 @@ + + +# MCPOAuthProtectedResource + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**resource** | **String** | The URL of the protected resource (the MCP entrypoint). | +**authorizationServers** | **List<String>** | List of authorization server base URLs that can issue tokens for this resource. | + + + diff --git a/docs/MCPOAuthServerMetadata.md b/docs/MCPOAuthServerMetadata.md new file mode 100644 index 00000000..0091f6c0 --- /dev/null +++ b/docs/MCPOAuthServerMetadata.md @@ -0,0 +1,18 @@ + + +# MCPOAuthServerMetadata + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**issuer** | **String** | The authorization server's issuer identifier (its base URL). | +**authorizationEndpoint** | **String** | URL of the authorization endpoint. | +**tokenEndpoint** | **String** | URL of the token endpoint. | +**registrationEndpoint** | **String** | URL of the client registration endpoint. | +**responseTypesSupported** | **List<String>** | List of supported OAuth2 response types. | +**grantTypesSupported** | **List<String>** | List of supported OAuth2 grant types. | +**codeChallengeMethodsSupported** | **List<String>** | List of supported PKCE code challenge methods. | + + + diff --git a/docs/MCPOAuthSessionInfo.md b/docs/MCPOAuthSessionInfo.md new file mode 100644 index 00000000..4263c03c --- /dev/null +++ b/docs/MCPOAuthSessionInfo.md @@ -0,0 +1,14 @@ + + +# MCPOAuthSessionInfo + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**sessionId** | **String** | The identifier of the authorization session. | +**expiresAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date and time at which the session expires. Date and time. Follows RFC3339 format. | [optional] +**client** | [**MCPOAuthClient**](MCPOAuthClient.md) | | + + + diff --git a/docs/MCPOAuthToken.md b/docs/MCPOAuthToken.md new file mode 100644 index 00000000..e06c9e21 --- /dev/null +++ b/docs/MCPOAuthToken.md @@ -0,0 +1,24 @@ + + +# MCPOAuthToken + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**accessToken** | **String** | Bearer access token. | +**tokenType** | [**TokenTypeEnum**](#TokenTypeEnum) | Token type. Always \"Bearer\". | +**expiresIn** | **Long** | Seconds until the access token expires. | +**refreshToken** | **String** | Refresh token for obtaining a new access token. | +**refreshTokenExpiresIn** | **Long** | Seconds until the refresh token expires. | + + + +## Enum: TokenTypeEnum + +Name | Value +---- | ----- +BEARER | "Bearer" + + + diff --git a/docs/MCPOAuthTokenError.md b/docs/MCPOAuthTokenError.md new file mode 100644 index 00000000..aa81efe8 --- /dev/null +++ b/docs/MCPOAuthTokenError.md @@ -0,0 +1,24 @@ + + +# MCPOAuthTokenError + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**error** | [**ErrorEnum**](#ErrorEnum) | RFC 6749 §5.2 error code. | +**errorDescription** | **String** | Human-readable description of the error. | [optional] + + + +## Enum: ErrorEnum + +Name | Value +---- | ----- +INVALID_REQUEST | "invalid_request" +INVALID_CLIENT | "invalid_client" +INVALID_GRANT | "invalid_grant" +UNSUPPORTED_GRANT_TYPE | "unsupported_grant_type" + + + diff --git a/docs/MCPOAuthTokenRequest.md b/docs/MCPOAuthTokenRequest.md new file mode 100644 index 00000000..383ad0e4 --- /dev/null +++ b/docs/MCPOAuthTokenRequest.md @@ -0,0 +1,26 @@ + + +# MCPOAuthTokenRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**grantType** | [**GrantTypeEnum**](#GrantTypeEnum) | OAuth2 grant type. | +**code** | **String** | Authorization code. Required for `authorization_code` grant. | [optional] +**clientId** | **String** | Client ID. Required for `authorization_code` grant. | [optional] +**redirectUri** | **String** | Redirect URI. Required for `authorization_code` grant. | [optional] +**codeVerifier** | **String** | PKCE code verifier. Required for `authorization_code` grant. | [optional] +**refreshToken** | **String** | Refresh token. Required for `refresh_token` grant. | [optional] + + + +## Enum: GrantTypeEnum + +Name | Value +---- | ----- +AUTHORIZATION_CODE | "authorization_code" +REFRESH_TOKEN | "refresh_token" + + + diff --git a/docs/ManagementApi.md b/docs/ManagementApi.md index 6e6680ec..76220c83 100644 --- a/docs/ManagementApi.md +++ b/docs/ManagementApi.md @@ -10,6 +10,7 @@ Method | HTTP request | Description [**copyCampaignToApplications**](ManagementApi.md#copyCampaignToApplications) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/copy | Copy the campaign into the specified Application [**createAccountCollection**](ManagementApi.md#createAccountCollection) | **POST** /v1/collections | Create account-level collection [**createAchievement**](ManagementApi.md#createAchievement) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements | Create achievement +[**createAchievementV2**](ManagementApi.md#createAchievementV2) | **POST** /v2/achievements | Create achievement [**createAdditionalCost**](ManagementApi.md#createAdditionalCost) | **POST** /v1/additional_costs | Create additional cost [**createAttribute**](ManagementApi.md#createAttribute) | **POST** /v1/attributes | Create custom attribute [**createBatchLoyaltyCards**](ManagementApi.md#createBatchLoyaltyCards) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/cards/batch | Create loyalty cards @@ -23,12 +24,14 @@ Method | HTTP request | Description [**createInviteEmail**](ManagementApi.md#createInviteEmail) | **POST** /v1/invite_emails | Resend invitation email [**createInviteV2**](ManagementApi.md#createInviteV2) | **POST** /v2/invites | Invite user [**createPasswordRecoveryEmail**](ManagementApi.md#createPasswordRecoveryEmail) | **POST** /v1/password_recovery_emails | Request a password reset +[**createRulesetV2**](ManagementApi.md#createRulesetV2) | **POST** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets | Create ruleset (V2) [**createSession**](ManagementApi.md#createSession) | **POST** /v1/sessions | Create session [**createStore**](ManagementApi.md#createStore) | **POST** /v1/applications/{applicationId}/stores | Create store [**deactivateUserByEmail**](ManagementApi.md#deactivateUserByEmail) | **POST** /v1/users/deactivate | Disable user by email address [**deductLoyaltyCardPoints**](ManagementApi.md#deductLoyaltyCardPoints) | **PUT** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/deduct_points | Deduct points from card [**deleteAccountCollection**](ManagementApi.md#deleteAccountCollection) | **DELETE** /v1/collections/{collectionId} | Delete account-level collection [**deleteAchievement**](ManagementApi.md#deleteAchievement) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Delete achievement +[**deleteAchievementV2**](ManagementApi.md#deleteAchievementV2) | **DELETE** /v2/achievements/{achievementId} | Delete achievement [**deleteCampaign**](ManagementApi.md#deleteCampaign) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId} | Delete campaign [**deleteCampaignStoreBudgets**](ManagementApi.md#deleteCampaignStoreBudgets) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/stores/budgets | Delete campaign store budgets [**deleteCollection**](ManagementApi.md#deleteCollection) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/collections/{collectionId} | Delete campaign-level collection @@ -41,7 +44,9 @@ Method | HTTP request | Description [**deleteUserByEmail**](ManagementApi.md#deleteUserByEmail) | **POST** /v1/users/delete | Delete user by email address [**destroySession**](ManagementApi.md#destroySession) | **DELETE** /v1/sessions | Destroy session [**disconnectCampaignStores**](ManagementApi.md#disconnectCampaignStores) | **DELETE** /v1/applications/{applicationId}/campaigns/{campaignId}/stores | Disconnect stores +[**excludePriceHistory**](ManagementApi.md#excludePriceHistory) | **POST** /v1/applications/{applicationId}/price_history/exclusions | Exclude price records from price history [**exportAccountCollectionItems**](ManagementApi.md#exportAccountCollectionItems) | **GET** /v1/collections/{collectionId}/export | Export account-level collection's items +[**exportAchievementV2**](ManagementApi.md#exportAchievementV2) | **GET** /v2/achievements/{achievementId}/export | Export achievement customer data [**exportAchievements**](ManagementApi.md#exportAchievements) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}/export | Export achievement customer data [**exportApplicationCampaignAnalytics**](ManagementApi.md#exportApplicationCampaignAnalytics) | **GET** /v1/applications/{applicationId}/campaign_analytics/export | Export Application analytics aggregated by campaign [**exportAudiencesMemberships**](ManagementApi.md#exportAudiencesMemberships) | **GET** /v1/audiences/{audienceId}/memberships/export | Export audience members @@ -68,6 +73,7 @@ Method | HTTP request | Description [**getAccountAnalytics**](ManagementApi.md#getAccountAnalytics) | **GET** /v1/accounts/{accountId}/analytics | Get account analytics [**getAccountCollection**](ManagementApi.md#getAccountCollection) | **GET** /v1/collections/{collectionId} | Get account-level collection [**getAchievement**](ManagementApi.md#getAchievement) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Get achievement +[**getAchievementV2**](ManagementApi.md#getAchievementV2) | **GET** /v2/achievements/{achievementId} | Get achievement [**getAdditionalCost**](ManagementApi.md#getAdditionalCost) | **GET** /v1/additional_costs/{additionalCostId} | Get additional cost [**getAdditionalCosts**](ManagementApi.md#getAdditionalCosts) | **GET** /v1/additional_costs | List additional costs [**getApplication**](ManagementApi.md#getApplication) | **GET** /v1/applications/{applicationId} | Get Application @@ -81,6 +87,7 @@ Method | HTTP request | Description [**getApplicationEventsWithoutTotalCount**](ManagementApi.md#getApplicationEventsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/events/no_total | List Applications events [**getApplicationSession**](ManagementApi.md#getApplicationSession) | **GET** /v1/applications/{applicationId}/sessions/{sessionId} | Get Application session [**getApplicationSessions**](ManagementApi.md#getApplicationSessions) | **GET** /v1/applications/{applicationId}/sessions | List Application sessions +[**getApplicationSessionsByCustomerAttributes**](ManagementApi.md#getApplicationSessionsByCustomerAttributes) | **POST** /v1/applications/{applicationId}/sessions_search | List Application sessions matching the given customer attributes [**getApplications**](ManagementApi.md#getApplications) | **GET** /v1/applications | List Applications [**getAttribute**](ManagementApi.md#getAttribute) | **GET** /v1/attributes/{attributeId} | Get custom attribute [**getAttributes**](ManagementApi.md#getAttributes) | **GET** /v1/attributes | List custom attributes @@ -110,12 +117,12 @@ Method | HTTP request | Description [**getExperiment**](ManagementApi.md#getExperiment) | **GET** /v1/applications/{applicationId}/experiments/{experimentId} | Get experiment in Application [**getExports**](ManagementApi.md#getExports) | **GET** /v1/exports | Get exports [**getLoyaltyCard**](ManagementApi.md#getLoyaltyCard) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId} | Get loyalty card -[**getLoyaltyCardTransactionLogs**](ManagementApi.md#getLoyaltyCardTransactionLogs) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/logs | List card's transactions +[**getLoyaltyCardTransactionLogs**](ManagementApi.md#getLoyaltyCardTransactionLogs) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/logs | List card's transactions (Management API) [**getLoyaltyCards**](ManagementApi.md#getLoyaltyCards) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/cards | List loyalty cards -[**getLoyaltyLedgerBalances**](ManagementApi.md#getLoyaltyLedgerBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_balances | Get customer's loyalty balances +[**getLoyaltyLedgerBalances**](ManagementApi.md#getLoyaltyLedgerBalances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_balances | Get customer's loyalty balances (Management API) [**getLoyaltyPoints**](ManagementApi.md#getLoyaltyPoints) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId} | Get customer's full loyalty ledger [**getLoyaltyProgram**](ManagementApi.md#getLoyaltyProgram) | **GET** /v1/loyalty_programs/{loyaltyProgramId} | Get loyalty program -[**getLoyaltyProgramProfileLedgerTransactions**](ManagementApi.md#getLoyaltyProgramProfileLedgerTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_transactions | List customer's loyalty transactions +[**getLoyaltyProgramProfileLedgerTransactions**](ManagementApi.md#getLoyaltyProgramProfileLedgerTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/ledger_transactions | List customer's loyalty transactions (Management API) [**getLoyaltyProgramTransactions**](ManagementApi.md#getLoyaltyProgramTransactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/transactions | List loyalty program transactions [**getLoyaltyPrograms**](ManagementApi.md#getLoyaltyPrograms) | **GET** /v1/loyalty_programs | List loyalty programs [**getLoyaltyStatistics**](ManagementApi.md#getLoyaltyStatistics) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/statistics | Get loyalty program statistics @@ -123,6 +130,7 @@ Method | HTTP request | Description [**getReferralsWithoutTotalCount**](ManagementApi.md#getReferralsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/referrals/no_total | List referrals [**getRoleV2**](ManagementApi.md#getRoleV2) | **GET** /v2/roles/{roleId} | Get role [**getRuleset**](ManagementApi.md#getRuleset) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset +[**getRulesetV2**](ManagementApi.md#getRulesetV2) | **GET** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset (V2) [**getRulesets**](ManagementApi.md#getRulesets) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets | List campaign rulesets [**getStore**](ManagementApi.md#getStore) | **GET** /v1/applications/{applicationId}/stores/{storeId} | Get store [**getUser**](ManagementApi.md#getUser) | **GET** /v1/users/{userId} | Get user @@ -138,12 +146,14 @@ Method | HTTP request | Description [**importCoupons**](ManagementApi.md#importCoupons) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/import_coupons | Import coupons [**importLoyaltyCards**](ManagementApi.md#importLoyaltyCards) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_cards | Import loyalty cards [**importLoyaltyCustomersTiers**](ManagementApi.md#importLoyaltyCustomersTiers) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_customers_tiers | Import customers into loyalty tiers +[**importLoyaltyJoinDates**](ManagementApi.md#importLoyaltyJoinDates) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_join_dates | Import join dates for a loyalty program [**importLoyaltyPoints**](ManagementApi.md#importLoyaltyPoints) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/import_points | Import loyalty points [**importPoolGiveaways**](ManagementApi.md#importPoolGiveaways) | **POST** /v1/giveaways/pools/{poolId}/import | Import giveaway codes into a giveaway pool [**importReferrals**](ManagementApi.md#importReferrals) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/import_referrals | Import referrals [**inviteUserExternal**](ManagementApi.md#inviteUserExternal) | **POST** /v1/users/invite | Invite user from identity provider [**listAccountCollections**](ManagementApi.md#listAccountCollections) | **GET** /v1/collections | List collections in account [**listAchievements**](ManagementApi.md#listAchievements) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements | List achievements +[**listAchievementsV2**](ManagementApi.md#listAchievementsV2) | **GET** /v2/achievements | List achievements [**listAllRolesV2**](ManagementApi.md#listAllRolesV2) | **GET** /v2/roles | List roles [**listApplicationCartItemFilters**](ManagementApi.md#listApplicationCartItemFilters) | **GET** /v1/applications/{applicationId}/cart_item_filters | List Application cart item filters [**listCampaignStoreBudgetLimits**](ManagementApi.md#listCampaignStoreBudgetLimits) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/stores/budgets | List campaign store budget limits @@ -177,6 +187,7 @@ Method | HTTP request | Description [**transferLoyaltyCard**](ManagementApi.md#transferLoyaltyCard) | **PUT** /v1/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/transfer | Transfer card data [**updateAccountCollection**](ManagementApi.md#updateAccountCollection) | **PUT** /v1/collections/{collectionId} | Update account-level collection [**updateAchievement**](ManagementApi.md#updateAchievement) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId} | Update achievement +[**updateAchievementV2**](ManagementApi.md#updateAchievementV2) | **PUT** /v2/achievements/{achievementId} | Update achievement [**updateAdditionalCost**](ManagementApi.md#updateAdditionalCost) | **PUT** /v1/additional_costs/{additionalCostId} | Update additional cost [**updateAttribute**](ManagementApi.md#updateAttribute) | **PUT** /v1/attributes/{attributeId} | Update custom attribute [**updateCampaign**](ManagementApi.md#updateCampaign) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId} | Update campaign @@ -720,6 +731,93 @@ Name | Type | Description | Notes | **409** | Conflict. An achievement with this name or title already exists. | - | +## createAchievementV2 + +> AchievementV2 createAchievementV2(body) + +Create achievement + +Create a new account-level achievement. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + CreateAchievementV2 body = new CreateAchievementV2(); // CreateAchievementV2 | body + try { + AchievementV2 result = apiInstance.createAchievementV2(body); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#createAchievementV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **body** | [**CreateAchievementV2**](CreateAchievementV2.md)| body | + +### Return type cool + +[**AchievementV2**](AchievementV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **201** | Created | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | +| **409** | Conflict. An achievement with this name already exists. | - | + + ## createAdditionalCost > AccountAdditionalCost createAdditionalCost(body) @@ -1850,6 +1948,95 @@ Name | Type | Description | Notes | **204** | Created | - | +## createRulesetV2 + +> RulesetV2 createRulesetV2(applicationId, campaignId, body) + +Create ruleset (V2) + +Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. + RulesetV2 body = new RulesetV2(); // RulesetV2 | body + try { + RulesetV2 result = apiInstance.createRulesetV2(applicationId, campaignId, body); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#createRulesetV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | + **body** | [**RulesetV2**](RulesetV2.md)| body | + +### Return type cool + +[**RulesetV2**](RulesetV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **201** | Created | - | +| **400** | Bad request | - | + + ## createSession > Session createSession(body) @@ -2368,6 +2555,91 @@ null (empty response body) | **404** | Not found | - | +## deleteAchievementV2 + +> deleteAchievementV2(achievementId) + +Delete achievement + +Delete a specific achievement. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long achievementId = 56L; // Long | The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. + try { + apiInstance.deleteAchievementV2(achievementId); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#deleteAchievementV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **achievementId** | **Long**| The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. | + +### Return type cool + +null (empty response body) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **204** | No Content | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | + + ## deleteCampaign > deleteCampaign(applicationId, campaignId) @@ -3172,13 +3444,175 @@ null (empty response body) | **204** | No Content | - | -## deleteUserByEmail +## deleteUserByEmail + +> deleteUserByEmail(body) + +Delete user by email address + +[Delete a specific user](https://docs.talon.one/docs/product/account/account-settings/managing-users#deleting-a-user) by their email address. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + DeleteUserRequest body = new DeleteUserRequest(); // DeleteUserRequest | body + try { + apiInstance.deleteUserByEmail(body); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#deleteUserByEmail"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **body** | [**DeleteUserRequest**](DeleteUserRequest.md)| body | + +### Return type cool + +null (empty response body) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **204** | No Content | - | + + +## destroySession + +> destroySession() + +Destroy session + +Destroys the session. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + try { + apiInstance.destroySession(); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#destroySession"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + +This endpoint does not need any parameter. + +### Return type cool + +null (empty response body) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **204** | No Content | - | + + +## disconnectCampaignStores -> deleteUserByEmail(body) +> disconnectCampaignStores(applicationId, campaignId) -Delete user by email address +Disconnect stores -[Delete a specific user](https://docs.talon.one/docs/product/account/account-settings/managing-users#deleting-a-user) by their email address. +Disconnect the stores linked to a specific campaign. ### Example @@ -3215,11 +3649,12 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - DeleteUserRequest body = new DeleteUserRequest(); // DeleteUserRequest | body + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. try { - apiInstance.deleteUserByEmail(body); + apiInstance.disconnectCampaignStores(applicationId, campaignId); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#deleteUserByEmail"); + System.err.println("Exception when calling ManagementApi#disconnectCampaignStores"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -3234,7 +3669,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**DeleteUserRequest**](DeleteUserRequest.md)| body | + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | ### Return type cool @@ -3246,22 +3682,25 @@ null (empty response body) ### HTTP request headers -- **Content-Type**: application/json -- **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: application/json ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| | **204** | No Content | - | +| **400** | Bad request | - | +| **401** | Unauthorized - Invalid API key | - | +| **404** | Not found | - | -## destroySession +## excludePriceHistory -> destroySession() +> excludePriceHistory(applicationId, body) -Destroy session +Exclude price records from price history -Destroys the session. +Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. ### Example @@ -3298,10 +3737,12 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + ExcludePriceObservationsRequest body = new ExcludePriceObservationsRequest(); // ExcludePriceObservationsRequest | body try { - apiInstance.destroySession(); + apiInstance.excludePriceHistory(applicationId, body); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#destroySession"); + System.err.println("Exception when calling ManagementApi#excludePriceHistory"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -3313,7 +3754,11 @@ public class Example { ### Parameters -This endpoint does not need any parameter. + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **body** | [**ExcludePriceObservationsRequest**](ExcludePriceObservationsRequest.md)| body | ### Return type cool @@ -3325,22 +3770,22 @@ null (empty response body) ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **204** | No Content | - | +| **200** | Ok | - | -## disconnectCampaignStores +## exportAccountCollectionItems -> disconnectCampaignStores(applicationId, campaignId) +> String exportAccountCollectionItems(collectionId) -Disconnect stores +Export account-level collection's items -Disconnect the stores linked to a specific campaign. +Download a CSV file containing items from a given account-level collection. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). ### Example @@ -3377,12 +3822,12 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. - Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. + Long collectionId = 56L; // Long | The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. try { - apiInstance.disconnectCampaignStores(applicationId, campaignId); + String result = apiInstance.exportAccountCollectionItems(collectionId); + System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#disconnectCampaignStores"); + System.err.println("Exception when calling ManagementApi#exportAccountCollectionItems"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -3397,12 +3842,11 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | - **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | + **collectionId** | **Long**| The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. | ### Return type cool -null (empty response body) +**String** ### Authorization @@ -3411,24 +3855,23 @@ null (empty response body) ### HTTP request headers - **Content-Type**: Not defined -- **Accept**: application/json +- **Accept**: application/csv ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **204** | No Content | - | -| **400** | Bad request | - | +| **200** | OK | - | | **401** | Unauthorized - Invalid API key | - | | **404** | Not found | - | -## exportAccountCollectionItems +## exportAchievementV2 -> String exportAccountCollectionItems(collectionId) +> String exportAchievementV2(achievementId) -Export account-level collection's items +Export achievement customer data -Download a CSV file containing items from a given account-level collection. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). +Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. ### Example @@ -3465,12 +3908,12 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - Long collectionId = 56L; // Long | The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. + Long achievementId = 56L; // Long | The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. try { - String result = apiInstance.exportAccountCollectionItems(collectionId); + String result = apiInstance.exportAchievementV2(achievementId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#exportAccountCollectionItems"); + System.err.println("Exception when calling ManagementApi#exportAchievementV2"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -3485,7 +3928,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **collectionId** | **Long**| The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. | + **achievementId** | **Long**| The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. | ### Return type cool @@ -3504,7 +3947,8 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | -| **401** | Unauthorized - Invalid API key | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | | **404** | Not found | - | @@ -4141,7 +4585,7 @@ Name | Type | Description | Notes ## exportCoupons -> String exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly) +> String exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter) Export coupons @@ -4197,8 +4641,10 @@ public class Example { String dateFormat = "dateFormat_example"; // String | Determines the format of dates in the export document. String campaignState = "campaignState_example"; // 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. Boolean valuesOnly = false; // Boolean | Filter results to only return the coupon codes (`value` column) without the associated coupon data. + OffsetDateTime deletedBefore = new OffsetDateTime(); // OffsetDateTime | 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. + OffsetDateTime deletedAfter = new OffsetDateTime(); // OffsetDateTime | 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. try { - String result = apiInstance.exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly); + String result = apiInstance.exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#exportCoupons"); @@ -4231,6 +4677,8 @@ Name | Type | Description | Notes **dateFormat** | **String**| Determines the format of dates in the export document. | [optional] [enum: excel, ISO8601] **campaignState** | **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] [enum: enabled, disabled, archived, scheduled, running, expired, staged] **valuesOnly** | **Boolean**| Filter results to only return the coupon codes (`value` column) without the associated coupon data. | [optional] [default to false] + **deletedBefore** | **OffsetDateTime**| 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] + **deletedAfter** | **OffsetDateTime**| 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] ### Return type cool @@ -4253,7 +4701,7 @@ Name | Type | Description | Notes ## exportCustomerSessions -> String exportCustomerSessions(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState) +> String exportCustomerSessions(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState) Export customer sessions @@ -4297,11 +4745,13 @@ public class Example { Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. + OffsetDateTime updatedBefore = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. + OffsetDateTime updatedAfter = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. String profileIntegrationId = "profileIntegrationId_example"; // String | Only return sessions for the customer that matches this customer integration ID. String dateFormat = "dateFormat_example"; // String | Determines the format of dates in the export document. String customerSessionState = "customerSessionState_example"; // String | Filter results by state. try { - String result = apiInstance.exportCustomerSessions(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState); + String result = apiInstance.exportCustomerSessions(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#exportCustomerSessions"); @@ -4322,6 +4772,8 @@ Name | Type | Description | Notes **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | **createdBefore** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. | [optional] **createdAfter** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. | [optional] + **updatedBefore** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. | [optional] + **updatedAfter** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. | [optional] **profileIntegrationId** | **String**| Only return sessions for the customer that matches this customer integration ID. | [optional] **dateFormat** | **String**| Determines the format of dates in the export document. | [optional] [enum: excel, ISO8601] **customerSessionState** | **String**| Filter results by state. | [optional] [enum: open, closed, partially_returned, cancelled] @@ -4527,7 +4979,7 @@ Name | Type | Description | Notes ## exportLoyaltyBalance -> String exportLoyaltyBalance(loyaltyProgramId, endDate) +> String exportLoyaltyBalance(loyaltyProgramId, endDate, balances) Export customer loyalty balance to CSV @@ -4570,8 +5022,9 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); String loyaltyProgramId = "loyaltyProgramId_example"; // String | The identifier for the loyalty program. OffsetDateTime endDate = new OffsetDateTime(); // OffsetDateTime | Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. + String balances = "balances_example"; // String | Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. try { - String result = apiInstance.exportLoyaltyBalance(loyaltyProgramId, endDate); + String result = apiInstance.exportLoyaltyBalance(loyaltyProgramId, endDate, balances); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#exportLoyaltyBalance"); @@ -4591,6 +5044,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **loyaltyProgramId** | **String**| The identifier for the loyalty program. | **endDate** | **OffsetDateTime**| Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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] + **balances** | **String**| Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. | [optional] ### Return type cool @@ -4615,7 +5069,7 @@ Name | Type | Description | Notes ## exportLoyaltyBalances -> String exportLoyaltyBalances(loyaltyProgramId, endDate) +> String exportLoyaltyBalances(loyaltyProgramId, endDate, balances) Export customer loyalty balances @@ -4658,8 +5112,9 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); String loyaltyProgramId = "loyaltyProgramId_example"; // String | The identifier for the loyalty program. OffsetDateTime endDate = new OffsetDateTime(); // OffsetDateTime | Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. + String balances = "balances_example"; // String | Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. try { - String result = apiInstance.exportLoyaltyBalances(loyaltyProgramId, endDate); + String result = apiInstance.exportLoyaltyBalances(loyaltyProgramId, endDate, balances); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#exportLoyaltyBalances"); @@ -4679,6 +5134,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **loyaltyProgramId** | **String**| The identifier for the loyalty program. | **endDate** | **OffsetDateTime**| Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. | [optional] + **balances** | **String**| Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. | [optional] ### Return type cool @@ -4703,7 +5159,7 @@ Name | Type | Description | Notes ## exportLoyaltyCardBalances -> String exportLoyaltyCardBalances(loyaltyProgramId, endDate) +> String exportLoyaltyCardBalances(loyaltyProgramId, endDate, balances) Export all card transaction logs @@ -4746,8 +5202,9 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long loyaltyProgramId = 56L; // Long | Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. OffsetDateTime endDate = new OffsetDateTime(); // OffsetDateTime | Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. + String balances = "balances_example"; // String | Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. try { - String result = apiInstance.exportLoyaltyCardBalances(loyaltyProgramId, endDate); + String result = apiInstance.exportLoyaltyCardBalances(loyaltyProgramId, endDate, balances); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#exportLoyaltyCardBalances"); @@ -4767,6 +5224,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **loyaltyProgramId** | **Long**| Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | **endDate** | **OffsetDateTime**| Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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] + **balances** | **String**| Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. | [optional] ### Return type cool @@ -4889,7 +5347,7 @@ Name | Type | Description | Notes Export loyalty cards -Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. +Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. ### Example @@ -5344,7 +5802,7 @@ Name | Type | Description | Notes ## generateCouponRejections -> InlineResponse20053 generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode) +> InlineResponse20055 generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode) Summarize coupon redemption failures in session @@ -5390,7 +5848,7 @@ public class Example { String language = "language_example"; // String | The [ISO-639](https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes) code of the language in which the summary will be generated. String couponCode = "couponCode_example"; // String | The coupon code for which to get the rejection reason. try { - InlineResponse20053 result = apiInstance.generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode); + InlineResponse20055 result = apiInstance.generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#generateCouponRejections"); @@ -5415,7 +5873,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20053**](InlineResponse20053.md) +[**InlineResponse20055**](InlineResponse20055.md) ### Authorization @@ -5875,6 +6333,92 @@ Name | Type | Description | Notes | **404** | Not found | - | +## getAchievementV2 + +> AchievementV2 getAchievementV2(achievementId) + +Get achievement + +Retrieve the details of a specific achievement. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long achievementId = 56L; // Long | The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. + try { + AchievementV2 result = apiInstance.getAchievementV2(achievementId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#getAchievementV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **achievementId** | **Long**| The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. | + +### Return type cool + +[**AchievementV2**](AchievementV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | + + ## getAdditionalCost > AccountAdditionalCost getAdditionalCost(additionalCostId) @@ -5961,7 +6505,7 @@ Name | Type | Description | Notes ## getAdditionalCosts -> InlineResponse20040 getAdditionalCosts(pageSize, skip, sort) +> InlineResponse20041 getAdditionalCosts(pageSize, skip, sort) List additional costs @@ -6006,7 +6550,7 @@ public class Example { Long skip = 56L; // Long | The number of items to skip when paging through large result sets. String 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. try { - InlineResponse20040 result = apiInstance.getAdditionalCosts(pageSize, skip, sort); + InlineResponse20041 result = apiInstance.getAdditionalCosts(pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAdditionalCosts"); @@ -6030,7 +6574,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20040**](InlineResponse20040.md) +[**InlineResponse20041**](InlineResponse20041.md) ### Authorization @@ -6391,7 +6935,7 @@ Name | Type | Description | Notes ## getApplicationCustomerFriends -> InlineResponse20037 getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize) +> InlineResponse20038 getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize) List friends referred by customer profile @@ -6439,7 +6983,7 @@ public class Example { String 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. Boolean withTotalResultSize = true; // Boolean | When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. try { - InlineResponse20037 result = apiInstance.getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); + InlineResponse20038 result = apiInstance.getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getApplicationCustomerFriends"); @@ -6466,7 +7010,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20037**](InlineResponse20037.md) +[**InlineResponse20038**](InlineResponse20038.md) ### Authorization @@ -6669,7 +7213,7 @@ Name | Type | Description | Notes ## getApplicationEventTypes -> InlineResponse20033 getApplicationEventTypes(applicationId, pageSize, skip, sort) +> InlineResponse20034 getApplicationEventTypes(applicationId, pageSize, skip, sort) List Applications event types @@ -6715,7 +7259,7 @@ public class Example { Long skip = 56L; // Long | The number of items to skip when paging through large result sets. String 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. try { - InlineResponse20033 result = apiInstance.getApplicationEventTypes(applicationId, pageSize, skip, sort); + InlineResponse20034 result = apiInstance.getApplicationEventTypes(applicationId, pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getApplicationEventTypes"); @@ -6740,7 +7284,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20033**](InlineResponse20033.md) +[**InlineResponse20034**](InlineResponse20034.md) ### Authorization @@ -6759,7 +7303,7 @@ Name | Type | Description | Notes ## getApplicationEventsWithoutTotalCount -> InlineResponse20032 getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType) +> InlineResponse20033 getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType) List Applications events @@ -6817,7 +7361,7 @@ public class Example { String campaignQuery = "campaignQuery_example"; // String | Campaign name filter for events String effectType = "effectType_example"; // String | The type of effect that was triggered. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). try { - InlineResponse20032 result = apiInstance.getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); + InlineResponse20033 result = apiInstance.getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getApplicationEventsWithoutTotalCount"); @@ -6854,7 +7398,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20032**](InlineResponse20032.md) +[**InlineResponse20033**](InlineResponse20033.md) ### Authorization @@ -6875,9 +7419,95 @@ Name | Type | Description | Notes > ApplicationSession getApplicationSession(applicationId, sessionId) -Get Application session +Get Application session + +Get the details of the given session. You can list the sessions with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + Long sessionId = 56L; // Long | The **internal** ID of the session. You can get the ID with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. + try { + ApplicationSession result = apiInstance.getApplicationSession(applicationId, sessionId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#getApplicationSession"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **sessionId** | **Long**| The **internal** ID of the session. You can get the ID with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. | + +### Return type cool + +[**ApplicationSession**](ApplicationSession.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | + + +## getApplicationSessions + +> InlineResponse20031 getApplicationSessions(applicationId, pageSize, skip, sort, partialMatch, profile, state, createdBefore, createdAfter, coupon, referral, integrationId, storeIntegrationId) + +List Application sessions -Get the details of the given session. You can list the sessions with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. +List all the sessions of the specified Application. ### Example @@ -6915,12 +7545,23 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. - Long sessionId = 56L; // Long | The **internal** ID of the session. You can get the ID with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. + Long pageSize = 1000lL; // Long | The number of items in the response. + Long skip = 56L; // Long | The number of items to skip when paging through large result sets. + String 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. + Boolean partialMatch = false; // Boolean | Enables partial matching for a single text search field. When enabled, the search term matches anywhere within the field value (case-insensitive). Minimum 3 characters required for partial matches; shorter inputs automatically fall back to exact match. **Note:** Use with one of: `integrationId`, `profile`, `coupon`, `referral`, or `storeIntegrationId`. + String profile = "profile_example"; // String | Filter by sessions with this profile integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). + String state = "state_example"; // String | Filter by sessions with this state. Must be exact match. + OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Only return events created before this date. You can use any time zone setting. Talon.One will convert to UTC internally. + OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Only return events created after this date. You can use any time zone setting. Talon.One will convert to UTC internally. + String coupon = "coupon_example"; // String | Filter by sessions with this coupon. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). + String referral = "referral_example"; // String | Filter by sessions with this referral. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). + String integrationId = "integrationId_example"; // String | Filter by sessions with this integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). + String storeIntegrationId = "storeIntegrationId_example"; // String | The integration ID of the store. You choose this ID when you create a store. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). try { - ApplicationSession result = apiInstance.getApplicationSession(applicationId, sessionId); + InlineResponse20031 result = apiInstance.getApplicationSessions(applicationId, pageSize, skip, sort, partialMatch, profile, state, createdBefore, createdAfter, coupon, referral, integrationId, storeIntegrationId); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#getApplicationSession"); + System.err.println("Exception when calling ManagementApi#getApplicationSessions"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -6936,11 +7577,22 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | - **sessionId** | **Long**| The **internal** ID of the session. You can get the ID with the [List Application sessions](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. | + **pageSize** | **Long**| The number of items in the response. | [optional] [default to 1000l] + **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] + **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] + **partialMatch** | **Boolean**| Enables partial matching for a single text search field. When enabled, the search term matches anywhere within the field value (case-insensitive). Minimum 3 characters required for partial matches; shorter inputs automatically fall back to exact match. **Note:** Use with one of: `integrationId`, `profile`, `coupon`, `referral`, or `storeIntegrationId`. | [optional] [default to false] + **profile** | **String**| Filter by sessions with this profile integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] + **state** | **String**| Filter by sessions with this state. Must be exact match. | [optional] [enum: open, closed, partially_returned, cancelled] + **createdBefore** | **OffsetDateTime**| Only return events created before this date. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] + **createdAfter** | **OffsetDateTime**| Only return events created after this date. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] + **coupon** | **String**| Filter by sessions with this coupon. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] + **referral** | **String**| Filter by sessions with this referral. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] + **integrationId** | **String**| Filter by sessions with this integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] + **storeIntegrationId** | **String**| The integration ID of the store. You choose this ID when you create a store. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] ### Return type cool -[**ApplicationSession**](ApplicationSession.md) +[**InlineResponse20031**](InlineResponse20031.md) ### Authorization @@ -6957,13 +7609,13 @@ Name | Type | Description | Notes | **200** | OK | - | -## getApplicationSessions +## getApplicationSessionsByCustomerAttributes -> InlineResponse20031 getApplicationSessions(applicationId, pageSize, skip, sort, partialMatch, profile, state, createdBefore, createdAfter, coupon, referral, integrationId, storeIntegrationId) +> InlineResponse20032 getApplicationSessionsByCustomerAttributes(applicationId, body, pageSize, skip, withTotalResultSize) -List Application sessions +List Application sessions matching the given customer attributes -List all the sessions of the specified Application. +Get a list of the Application sessions matching the provided customer profile attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. ### Example @@ -7001,23 +7653,15 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + CustomerProfileSearchQuery body = new CustomerProfileSearchQuery(); // CustomerProfileSearchQuery | body Long pageSize = 1000lL; // Long | The number of items in the response. Long skip = 56L; // Long | The number of items to skip when paging through large result sets. - String 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. - Boolean partialMatch = false; // Boolean | Enables partial matching for a single text search field. When enabled, the search term matches anywhere within the field value (case-insensitive). Minimum 3 characters required for partial matches; shorter inputs automatically fall back to exact match. **Note:** Use with one of: `integrationId`, `profile`, `coupon`, `referral`, or `storeIntegrationId`. - String profile = "profile_example"; // String | Filter by sessions with this profile integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). - String state = "state_example"; // String | Filter by sessions with this state. Must be exact match. - OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Only return events created before this date. You can use any time zone setting. Talon.One will convert to UTC internally. - OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Only return events created after this date. You can use any time zone setting. Talon.One will convert to UTC internally. - String coupon = "coupon_example"; // String | Filter by sessions with this coupon. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). - String referral = "referral_example"; // String | Filter by sessions with this referral. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). - String integrationId = "integrationId_example"; // String | Filter by sessions with this integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). - String storeIntegrationId = "storeIntegrationId_example"; // String | The integration ID of the store. You choose this ID when you create a store. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). + Boolean withTotalResultSize = true; // Boolean | When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. try { - InlineResponse20031 result = apiInstance.getApplicationSessions(applicationId, pageSize, skip, sort, partialMatch, profile, state, createdBefore, createdAfter, coupon, referral, integrationId, storeIntegrationId); + InlineResponse20032 result = apiInstance.getApplicationSessionsByCustomerAttributes(applicationId, body, pageSize, skip, withTotalResultSize); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#getApplicationSessions"); + System.err.println("Exception when calling ManagementApi#getApplicationSessionsByCustomerAttributes"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -7033,22 +7677,14 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **body** | [**CustomerProfileSearchQuery**](CustomerProfileSearchQuery.md)| body | **pageSize** | **Long**| The number of items in the response. | [optional] [default to 1000l] **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] - **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] - **partialMatch** | **Boolean**| Enables partial matching for a single text search field. When enabled, the search term matches anywhere within the field value (case-insensitive). Minimum 3 characters required for partial matches; shorter inputs automatically fall back to exact match. **Note:** Use with one of: `integrationId`, `profile`, `coupon`, `referral`, or `storeIntegrationId`. | [optional] [default to false] - **profile** | **String**| Filter by sessions with this profile integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] - **state** | **String**| Filter by sessions with this state. Must be exact match. | [optional] [enum: open, closed, partially_returned, cancelled] - **createdBefore** | **OffsetDateTime**| Only return events created before this date. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] - **createdAfter** | **OffsetDateTime**| Only return events created after this date. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] - **coupon** | **String**| Filter by sessions with this coupon. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] - **referral** | **String**| Filter by sessions with this referral. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] - **integrationId** | **String**| Filter by sessions with this integration ID. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] - **storeIntegrationId** | **String**| The integration ID of the store. You choose this ID when you create a store. By default, requires exact match. Use `partialMatch=true` to search for partial matches (minimum 3 characters). | [optional] + **withTotalResultSize** | **Boolean**| When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. | [optional] ### Return type cool -[**InlineResponse20031**](InlineResponse20031.md) +[**InlineResponse20032**](InlineResponse20032.md) ### Authorization @@ -7056,7 +7692,7 @@ Name | Type | Description | Notes ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: application/json ### HTTP response details @@ -7239,7 +7875,7 @@ Name | Type | Description | Notes ## getAttributes -> InlineResponse20038 getAttributes(pageSize, skip, sort, entity, applicationIds, type, kind, search) +> InlineResponse20039 getAttributes(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search) List custom attributes @@ -7285,11 +7921,12 @@ public class Example { String 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. String entity = "entity_example"; // String | Returned attributes will be filtered by supplied entity. String applicationIds = "applicationIds_example"; // String | Returned attributes will be filtered by supplied application ids + String loyaltyProgramIds = "loyaltyProgramIds_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`. String type = "type_example"; // String | Returned attributes will be filtered by supplied type String kind = "kind_example"; // String | Returned attributes will be filtered by supplied kind (builtin or custom) String search = "search_example"; // String | Returned attributes will be filtered by searching case insensitive through Attribute name, description and type try { - InlineResponse20038 result = apiInstance.getAttributes(pageSize, skip, sort, entity, applicationIds, type, kind, search); + InlineResponse20039 result = apiInstance.getAttributes(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAttributes"); @@ -7312,13 +7949,14 @@ Name | Type | Description | Notes **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] **entity** | **String**| Returned attributes will be filtered by supplied entity. | [optional] **applicationIds** | **String**| Returned attributes will be filtered by supplied application ids | [optional] + **loyaltyProgramIds** | **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] **type** | **String**| Returned attributes will be filtered by supplied type | [optional] **kind** | **String**| Returned attributes will be filtered by supplied kind (builtin or custom) | [optional] [enum: builtin, custom] **search** | **String**| Returned attributes will be filtered by searching case insensitive through Attribute name, description and type | [optional] ### Return type cool -[**InlineResponse20038**](InlineResponse20038.md) +[**InlineResponse20039**](InlineResponse20039.md) ### Authorization @@ -7337,7 +7975,7 @@ Name | Type | Description | Notes ## getAudienceMemberships -> InlineResponse20036 getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery) +> InlineResponse20037 getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery) List audience members @@ -7384,7 +8022,7 @@ public class Example { String 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. String profileQuery = "profileQuery_example"; // String | The filter to select a profile. try { - InlineResponse20036 result = apiInstance.getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery); + InlineResponse20037 result = apiInstance.getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAudienceMemberships"); @@ -7410,7 +8048,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20036**](InlineResponse20036.md) +[**InlineResponse20037**](InlineResponse20037.md) ### Authorization @@ -7430,7 +8068,7 @@ Name | Type | Description | Notes ## getAudiences -> InlineResponse20034 getAudiences(pageSize, skip, sort, withTotalResultSize) +> InlineResponse20035 getAudiences(pageSize, skip, sort, withTotalResultSize) List audiences @@ -7476,7 +8114,7 @@ public class Example { String 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. Boolean withTotalResultSize = true; // Boolean | When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. try { - InlineResponse20034 result = apiInstance.getAudiences(pageSize, skip, sort, withTotalResultSize); + InlineResponse20035 result = apiInstance.getAudiences(pageSize, skip, sort, withTotalResultSize); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAudiences"); @@ -7501,7 +8139,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20034**](InlineResponse20034.md) +[**InlineResponse20035**](InlineResponse20035.md) ### Authorization @@ -7520,7 +8158,7 @@ Name | Type | Description | Notes ## getAudiencesAnalytics -> InlineResponse20035 getAudiencesAnalytics(audienceIds, sort) +> InlineResponse20036 getAudiencesAnalytics(audienceIds, sort) List audience analytics @@ -7561,10 +8199,10 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - String audienceIds = "audienceIds_example"; // String | The IDs of one or more audiences, separated by commas, by which to filter results. + String audienceIds = "audienceIds_example"; // String | The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. String 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. try { - InlineResponse20035 result = apiInstance.getAudiencesAnalytics(audienceIds, sort); + InlineResponse20036 result = apiInstance.getAudiencesAnalytics(audienceIds, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAudiencesAnalytics"); @@ -7582,12 +8220,12 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **audienceIds** | **String**| The IDs of one or more audiences, separated by commas, by which to filter results. | + **audienceIds** | **String**| The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. | **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] ### Return type cool -[**InlineResponse20035**](InlineResponse20035.md) +[**InlineResponse20036**](InlineResponse20036.md) ### Authorization @@ -8193,7 +8831,7 @@ public class Example { String 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. String campaignState = "campaignState_example"; // 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. String name = "name_example"; // String | Filter results performing case-insensitive matching against the name of the campaign. - String tags = "tags_example"; // String | Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values + List tags = Arrays.asList(); // List | Filter results performing case-insensitive matching against the tags of the campaign. OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. OffsetDateTime startBefore = new OffsetDateTime(); // OffsetDateTime | Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. @@ -8228,7 +8866,7 @@ Name | Type | Description | Notes **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] **campaignState** | **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] [enum: enabled, disabled, archived, scheduled, running, expired, staged] **name** | **String**| Filter results performing case-insensitive matching against the name of the campaign. | [optional] - **tags** | **String**| Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values | [optional] + **tags** | [**List<String>**](String.md)| Filter results performing case-insensitive matching against the tags of the campaign. | [optional] **createdBefore** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] **createdAfter** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] **startBefore** | **OffsetDateTime**| Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. | [optional] @@ -8261,7 +8899,7 @@ Name | Type | Description | Notes ## getChanges -> InlineResponse20044 getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld) +> InlineResponse20045 getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld) Get audit logs for an account @@ -8314,7 +8952,7 @@ public class Example { Long managementKeyId = 56L; // Long | Filter results that match the given management key ID. Boolean includeOld = true; // Boolean | When this flag is set to false, the state without the change will not be returned. The default value is true. try { - InlineResponse20044 result = apiInstance.getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); + InlineResponse20045 result = apiInstance.getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getChanges"); @@ -8346,7 +8984,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20044**](InlineResponse20044.md) +[**InlineResponse20045**](InlineResponse20045.md) ### Authorization @@ -9037,7 +9675,7 @@ Name | Type | Description | Notes ## getCustomerProfileAchievementProgress -> InlineResponse20052 getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title) +> InlineResponse20054 getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title) List customer achievements @@ -9085,7 +9723,7 @@ public class Example { Long achievementId = 56L; // Long | The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. String title = "title_example"; // String | Filter results by the `title` of an achievement. try { - InlineResponse20052 result = apiInstance.getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title); + InlineResponse20054 result = apiInstance.getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getCustomerProfileAchievementProgress"); @@ -9112,7 +9750,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20052**](InlineResponse20052.md) +[**InlineResponse20054**](InlineResponse20054.md) ### Authorization @@ -9401,7 +10039,7 @@ Name | Type | Description | Notes ## getEventTypes -> InlineResponse20042 getEventTypes(name, includeOldVersions, pageSize, skip, sort) +> InlineResponse20043 getEventTypes(name, includeOldVersions, pageSize, skip, sort) List event types @@ -9448,7 +10086,7 @@ public class Example { Long skip = 56L; // Long | The number of items to skip when paging through large result sets. String 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. try { - InlineResponse20042 result = apiInstance.getEventTypes(name, includeOldVersions, pageSize, skip, sort); + InlineResponse20043 result = apiInstance.getEventTypes(name, includeOldVersions, pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getEventTypes"); @@ -9474,7 +10112,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20042**](InlineResponse20042.md) +[**InlineResponse20043**](InlineResponse20043.md) ### Authorization @@ -9579,7 +10217,7 @@ Name | Type | Description | Notes ## getExports -> InlineResponse20045 getExports(pageSize, skip, applicationId, campaignId, entity) +> InlineResponse20046 getExports(pageSize, skip, applicationId, campaignId, entity) Get exports @@ -9626,7 +10264,7 @@ public class Example { Long campaignId = 56L; // Long | Filter by the campaign ID on which the limit counters are used. String entity = "entity_example"; // String | The name of the entity type that was exported. try { - InlineResponse20045 result = apiInstance.getExports(pageSize, skip, applicationId, campaignId, entity); + InlineResponse20046 result = apiInstance.getExports(pageSize, skip, applicationId, campaignId, entity); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getExports"); @@ -9652,7 +10290,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20045**](InlineResponse20045.md) +[**InlineResponse20046**](InlineResponse20046.md) ### Authorization @@ -9762,9 +10400,9 @@ Name | Type | Description | Notes > InlineResponse20021 getLoyaltyCardTransactionLogs(loyaltyProgramId, loyaltyCardId, startDate, endDate, pageSize, skip, subledgerId, customerSessionIDs, transactionUUIDs) -List card's transactions +List card's transactions (Management API) -Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. +Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. ### Example @@ -9962,9 +10600,9 @@ Name | Type | Description | Notes > LoyaltyBalancesWithTiers getLoyaltyLedgerBalances(loyaltyProgramId, integrationId, endDate, subledgerId, includeTiers, includeProjectedTier) -Get customer's loyalty balances +Get customer's loyalty balances (Management API) -Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] If no filtering options are applied, you retrieve all loyalty > balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) +Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) ### Example @@ -10229,9 +10867,9 @@ Name | Type | Description | Notes > InlineResponse2005 getLoyaltyProgramProfileLedgerTransactions(loyaltyProgramId, integrationId, customerSessionIDs, transactionUUIDs, subledgerId, loyaltyTransactionType, startDate, endDate, pageSize, skip, awaitsActivation) -List customer's loyalty transactions +List customer's loyalty transactions (Management API) -Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] To retrieve all loyalty program transaction logs in a given > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) > endpoint. +Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). > - To retrieve all loyalty program transaction logs in a given loyalty program, use the > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. ### Example @@ -10523,7 +11161,7 @@ This endpoint does not need any parameter. Get loyalty program statistics -> [warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. +> [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. ### Example @@ -10603,7 +11241,7 @@ Name | Type | Description | Notes ## getMessageLogs -> MessageLogEntries getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs) +> MessageLogEntries getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs) List message log entries @@ -10651,6 +11289,7 @@ public class Example { OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. byte[] cursor = null; // byte[] | A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. + Long pageSize = 50lL; // Long | The maximum number of message log entries to return. String period = "period_example"; // String | Filter results by time period. Choose between the available relative time frames. Boolean isSuccessful = true; // Boolean | Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. BigDecimal applicationId = new BigDecimal(); // BigDecimal | Filter results by Application ID. @@ -10659,7 +11298,7 @@ public class Example { Long responseCode = 56L; // Long | Filter results by response status code. String webhookIDs = "webhookIDs_example"; // String | Filter results by webhook ID (include up to 30 values, separated by a comma). try { - MessageLogEntries result = apiInstance.getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); + MessageLogEntries result = apiInstance.getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getMessageLogs"); @@ -10684,6 +11323,7 @@ Name | Type | Description | Notes **createdBefore** | **OffsetDateTime**| Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. | [optional] **createdAfter** | **OffsetDateTime**| Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. | [optional] **cursor** | **byte[]**| A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. | [optional] + **pageSize** | **Long**| The maximum number of message log entries to return. | [optional] [default to 50l] **period** | **String**| Filter results by time period. Choose between the available relative time frames. | [optional] [enum: 15m, 30m, 1h, 4h, 1d, 2d] **isSuccessful** | **Boolean**| Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. | [optional] **applicationId** | **BigDecimal**| Filter results by Application ID. | [optional] @@ -10987,6 +11627,94 @@ Name | Type | Description | Notes | **200** | OK | - | +## getRulesetV2 + +> RulesetV2 getRulesetV2(applicationId, campaignId, rulesetId) + +Get ruleset (V2) + +Retrieve the specified ruleset as a JSON object. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. + Long rulesetId = 56L; // Long | The ID of the ruleset. + try { + RulesetV2 result = apiInstance.getRulesetV2(applicationId, campaignId, rulesetId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#getRulesetV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | + **rulesetId** | **Long**| The ID of the ruleset. | + +### Return type cool + +[**RulesetV2**](RulesetV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | + + ## getRulesets > InlineResponse20010 getRulesets(applicationId, campaignId, pageSize, skip, sort) @@ -11252,7 +11980,7 @@ Name | Type | Description | Notes ## getUsers -> InlineResponse20043 getUsers(pageSize, skip, sort) +> InlineResponse20044 getUsers(pageSize, skip, sort) List users in account @@ -11297,7 +12025,7 @@ public class Example { Long skip = 56L; // Long | The number of items to skip when paging through large result sets. String 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. try { - InlineResponse20043 result = apiInstance.getUsers(pageSize, skip, sort); + InlineResponse20044 result = apiInstance.getUsers(pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getUsers"); @@ -11321,7 +12049,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20043**](InlineResponse20043.md) +[**InlineResponse20044**](InlineResponse20044.md) ### Authorization @@ -11424,7 +12152,7 @@ Name | Type | Description | Notes ## getWebhooks -> InlineResponse20041 getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title) +> InlineResponse20042 getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title) List webhooks @@ -11474,7 +12202,7 @@ public class Example { Long outgoingIntegrationsTypeId = 56L; // Long | Filter results by outgoing integration type ID. String title = "title_example"; // String | Filter results performing case-insensitive matching against the webhook title. try { - InlineResponse20041 result = apiInstance.getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); + InlineResponse20042 result = apiInstance.getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getWebhooks"); @@ -11503,7 +12231,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20041**](InlineResponse20041.md) +[**InlineResponse20042**](InlineResponse20042.md) ### Authorization @@ -11564,7 +12292,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long collectionId = 56L; // Long | The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importAccountCollection(collectionId, upFile); System.out.println(result); @@ -11585,7 +12313,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **collectionId** | **Long**| The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -11652,7 +12380,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long attributeId = 56L; // Long | The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importAllowedList(attributeId, upFile); System.out.println(result); @@ -11673,7 +12401,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **attributeId** | **Long**| The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -11741,7 +12469,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long audienceId = 56L; // Long | The ID of the audience. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importAudiencesMemberships(audienceId, upFile); System.out.println(result); @@ -11762,7 +12490,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **audienceId** | **Long**| The ID of the audience. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -11833,7 +12561,7 @@ public class Example { Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. String action = "action_example"; // String | The action that this budget is limiting. String period = "period_example"; // String | The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importCampaignStoreBudget(applicationId, campaignId, action, period, upFile); System.out.println(result); @@ -11857,7 +12585,7 @@ Name | Type | Description | Notes **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | **action** | **String**| The action that this budget is limiting. | [optional] [enum: setDiscount] **period** | **String**| The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. | [optional] [enum: overall, daily, weekly, monthly, yearly] - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -11883,9 +12611,100 @@ Name | Type | Description | Notes > ModelImport importCampaignStores(applicationId, campaignId, upFile) -Import stores +Import stores + +Upload a CSV file containing the stores you want to link to a specific campaign. Send the file as multipart data. The CSV file **must** only contain the following column: - `store_integration_id`: The identifier of the store. The import **replaces** the previous list of stores linked to the campaign. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. + Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. + try { + ModelImport result = apiInstance.importCampaignStores(applicationId, campaignId, upFile); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#importCampaignStores"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | + **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] + +### Return type cool + +[**ModelImport**](ModelImport.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: multipart/form-data +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized - Invalid API key | - | +| **404** | Not found | - | + + +## importCollection + +> ModelImport importCollection(applicationId, campaignId, collectionId, upFile) + +Import data into existing campaign-level collection -Upload a CSV file containing the stores you want to link to a specific campaign. Send the file as multipart data. The CSV file **must** only contain the following column: - `store_integration_id`: The identifier of the store. The import **replaces** the previous list of stores linked to the campaign. +Upload a CSV file containing the collection of string values that should be attached as payload for collection. The file should be sent as multipart data. The import **replaces** the initial content of the collection. The CSV file **must** only contain the following column: - `item`: the values in your collection. A collection is limited to 500,000 items. ## Example ``` item Adidas Nike Asics ``` > [!note] Before sending a request to this endpoint, ensure the data in the > CSV to import is different from the data currently stored in the collection. ### Example @@ -11924,12 +12743,13 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + Long collectionId = 56L; // Long | The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { - ModelImport result = apiInstance.importCampaignStores(applicationId, campaignId, upFile); + ModelImport result = apiInstance.importCollection(applicationId, campaignId, collectionId, upFile); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#importCampaignStores"); + System.err.println("Exception when calling ManagementApi#importCollection"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -11946,7 +12766,8 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **collectionId** | **Long**| The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. | + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -11965,18 +12786,16 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | -| **400** | Bad request | - | -| **401** | Unauthorized - Invalid API key | - | -| **404** | Not found | - | +| **401** | Unauthorized | - | -## importCollection +## importCoupons -> ModelImport importCollection(applicationId, campaignId, collectionId, upFile) +> ModelImport importCoupons(applicationId, campaignId, skipDuplicates, upFile) -Import data into existing campaign-level collection +Import coupons -Upload a CSV file containing the collection of string values that should be attached as payload for collection. The file should be sent as multipart data. The import **replaces** the initial content of the collection. The CSV file **must** only contain the following column: - `item`: the values in your collection. A collection is limited to 500,000 items. ## Example ``` item Adidas Nike Asics ``` > [!note] Before sending a request to this endpoint, ensure the data in the > CSV to import is different from the data currently stored in the collection. +Upload a CSV file containing the coupons that should be created. The file should be sent as multipart data. The CSV file contains the following columns: - `value` (required): The coupon code. Must be at least 3 characters long. We recommend using alphanumeric characters. There is no maximum length but limiting the code to 30 characters ensures it is fully readable in the Campaign Manager. The code should be unique unless you set `skipDuplicates` to `true`. - `expirydate`: The end date in RFC3339 of the code redemption period. - `startdate`: The start date in RFC3339 of the code redemption period. - `recipientintegrationid`: The integration ID of the recipient of the coupon. Only the customer with this integration ID can redeem this code. Available only for personal codes. - `limitval`: The maximum number of redemptions of this code. For unlimited redemptions, use `0`. Defaults to `1` when not provided. - `discountlimit`: The total discount value that the code can give. This is typically used to represent a gift card value. - `attributes`: A JSON object describing _custom_ coupon attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `category` associated with the coupon entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"category\": \"10_off\"}\"`. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text \"value\",\"expirydate\",\"startdate\",\"recipientintegrationid\",\"limitval\",\"attributes\",\"discountlimit\" COUP1,2018-07-01T04:00:00Z,2018-05-01T04:00:00Z,cust123,1,\"{\"\"Category\"\": \"\"10_off\"\"}\",2.4 ``` Once imported, you can find the `batchId` in the Campaign Manager or by using [List coupons](#tag/Coupons/operation/getCouponsWithoutTotalCount). ### Example @@ -12015,13 +12834,13 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. - Long collectionId = 56L; // Long | The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + Boolean skipDuplicates = true; // Boolean | An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { - ModelImport result = apiInstance.importCollection(applicationId, campaignId, collectionId, upFile); + ModelImport result = apiInstance.importCoupons(applicationId, campaignId, skipDuplicates, upFile); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#importCollection"); + System.err.println("Exception when calling ManagementApi#importCoupons"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -12038,8 +12857,8 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | - **collectionId** | **Long**| The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **skipDuplicates** | **Boolean**| An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12058,16 +12877,15 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | -| **401** | Unauthorized | - | -## importCoupons +## importLoyaltyCards -> ModelImport importCoupons(applicationId, campaignId, skipDuplicates, upFile) +> ModelImport importLoyaltyCards(loyaltyProgramId, upFile) -Import coupons +Import loyalty cards -Upload a CSV file containing the coupons that should be created. The file should be sent as multipart data. The CSV file contains the following columns: - `value` (required): The coupon code. Must be at least 3 characters long. We recommend using alphanumeric characters. There is no maximum length but limiting the code to 30 characters ensures it is fully readable in the Campaign Manager. The code should be unique unless you set `skipDuplicates` to `true`. - `expirydate`: The end date in RFC3339 of the code redemption period. - `startdate`: The start date in RFC3339 of the code redemption period. - `recipientintegrationid`: The integration ID of the recipient of the coupon. Only the customer with this integration ID can redeem this code. Available only for personal codes. - `limitval`: The maximum number of redemptions of this code. For unlimited redemptions, use `0`. Defaults to `1` when not provided. - `discountlimit`: The total discount value that the code can give. This is typically used to represent a gift card value. - `attributes`: A JSON object describing _custom_ coupon attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `category` associated with the coupon entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"category\": \"10_off\"}\"`. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text \"value\",\"expirydate\",\"startdate\",\"recipientintegrationid\",\"limitval\",\"attributes\",\"discountlimit\" COUP1,2018-07-01T04:00:00Z,2018-05-01T04:00:00Z,cust123,1,\"{\"\"Category\"\": \"\"10_off\"\"}\",2.4 ``` Once imported, you can find the `batchId` in the Campaign Manager or by using [List coupons](#tag/Coupons/operation/getCouponsWithoutTotalCount). +Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). - `attributes` (optional): A JSON object that contains the loyalty card's custom attributes and their values. These attributes must be created and connected to this loyalty program before they can be assigned to the cards through this endpoint. > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv identifier,state,customerprofileids,attributes 123-456-789AT,active,Alexa001;UserA,'{\"\"my_attributes\"\": \"\"10_off\"\"}\" ``` ### Example @@ -12104,15 +12922,13 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. - Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. - Boolean skipDuplicates = true; // Boolean | An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + Long loyaltyProgramId = 56L; // Long | Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { - ModelImport result = apiInstance.importCoupons(applicationId, campaignId, skipDuplicates, upFile); + ModelImport result = apiInstance.importLoyaltyCards(loyaltyProgramId, upFile); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#importCoupons"); + System.err.println("Exception when calling ManagementApi#importLoyaltyCards"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -12127,10 +12943,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | - **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | - **skipDuplicates** | **Boolean**| An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. | [optional] - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **loyaltyProgramId** | **Long**| Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12149,15 +12963,17 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | -## importLoyaltyCards +## importLoyaltyCustomersTiers -> ModelImport importLoyaltyCards(loyaltyProgramId, upFile) +> ModelImport importLoyaltyCustomersTiers(loyaltyProgramId, upFile) -Import loyalty cards +Import customers into loyalty tiers -Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). > [!note] We recommend limiting your file size to 500MB. ## Example ```csv identifier,state,customerprofileids 123-456-789AT,active,Alexa001;UserA ``` +Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiry date is updated. > [!note] We recommend importing customers into the tier that matches their > current balance. If a customer is imported into a lower tier, any session > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` ### Example @@ -12194,13 +13010,13 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - Long loyaltyProgramId = 56L; // Long | Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + Long loyaltyProgramId = 56L; // Long | Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { - ModelImport result = apiInstance.importLoyaltyCards(loyaltyProgramId, upFile); + ModelImport result = apiInstance.importLoyaltyCustomersTiers(loyaltyProgramId, upFile); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#importLoyaltyCards"); + System.err.println("Exception when calling ManagementApi#importLoyaltyCustomersTiers"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -12215,8 +13031,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **loyaltyProgramId** | **Long**| Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **loyaltyProgramId** | **Long**| Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12235,17 +13051,18 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | +| **400** | Bad request | - | | **401** | Unauthorized | - | | **404** | Not found | - | -## importLoyaltyCustomersTiers +## importLoyaltyJoinDates -> ModelImport importLoyaltyCustomersTiers(loyaltyProgramId, upFile) +> ModelImport importLoyaltyJoinDates(loyaltyProgramId, upFile) -Import customers into loyalty tiers +Import join dates for a loyalty program -Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiration date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiration date is updated. > [!note] We recommend not using this endpoint to update the tier of a customer. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` +Upload a CSV file containing customer profile IDs and their join dates for the specified loyalty program. Send the file as multipart data. > [!important] This endpoint only works with profile-based loyalty programs. The CSV file **must** contain the following columns: - `customerprofileid`: The integration ID of the customer profile whose join date you want to update. - `newjoindate`: The new join date for the customer in RFC3339 format. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. **Note**: - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. - If a join date already exists for a profile, the uploaded date replaces it. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv customerprofileid,newjoindate customer1,2024-03-21T07:32:14Z customer2,2025-04-16T21:12:37Z customer3,2026-05-03T11:47:01Z ``` ### Example @@ -12282,13 +13099,13 @@ public class Example { //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(defaultClient); - Long loyaltyProgramId = 56L; // Long | Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + Long loyaltyProgramId = 56L; // Long | 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. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { - ModelImport result = apiInstance.importLoyaltyCustomersTiers(loyaltyProgramId, upFile); + ModelImport result = apiInstance.importLoyaltyJoinDates(loyaltyProgramId, upFile); System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#importLoyaltyCustomersTiers"); + System.err.println("Exception when calling ManagementApi#importLoyaltyJoinDates"); System.err.println("Status code: " + e.getCode()); System.err.println("Reason: " + e.getResponseBody()); System.err.println("Response headers: " + e.getResponseHeaders()); @@ -12303,8 +13120,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **loyaltyProgramId** | **Long**| Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **loyaltyProgramId** | **Long**| 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. | + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12373,7 +13190,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long loyaltyProgramId = 56L; // Long | Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. Boolean notificationsEnabled = true; // Boolean | Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importLoyaltyPoints(loyaltyProgramId, notificationsEnabled, upFile); System.out.println(result); @@ -12395,7 +13212,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **loyaltyProgramId** | **Long**| Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | **notificationsEnabled** | **Boolean**| Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. | [optional] - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12460,7 +13277,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long poolId = 56L; // Long | The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importPoolGiveaways(poolId, upFile); System.out.println(result); @@ -12481,7 +13298,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **poolId** | **Long**| The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12547,7 +13364,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. - String upFile = "upFile_example"; // String | The file containing the data that is being imported. + String upFile = "upFile_example"; // String | The CSV file containing the data that is being imported. try { ModelImport result = apiInstance.importReferrals(applicationId, campaignId, upFile); System.out.println(result); @@ -12569,7 +13386,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | **campaignId** | **Long**| The ID of the campaign. It is displayed in your Talon.One deployment URL. | - **upFile** | **String**| The file containing the data that is being imported. | [optional] + **upFile** | **String**| The CSV file containing the data that is being imported. | [optional] ### Return type cool @@ -12770,7 +13587,7 @@ Name | Type | Description | Notes ## listAchievements -> InlineResponse20051 listAchievements(applicationId, campaignId, pageSize, skip, title) +> InlineResponse20052 listAchievements(applicationId, campaignId, pageSize, skip, title) List achievements @@ -12817,7 +13634,7 @@ public class Example { Long skip = 56L; // Long | The number of items to skip when paging through large result sets. String title = "title_example"; // String | Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. try { - InlineResponse20051 result = apiInstance.listAchievements(applicationId, campaignId, pageSize, skip, title); + InlineResponse20052 result = apiInstance.listAchievements(applicationId, campaignId, pageSize, skip, title); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listAchievements"); @@ -12843,7 +13660,99 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20051**](InlineResponse20051.md) +[**InlineResponse20052**](InlineResponse20052.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | + + +## listAchievementsV2 + +> InlineResponse20053 listAchievementsV2(pageSize, skip, sort, title, applicationId) + +List achievements + +List all achievements. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long pageSize = 50lL; // Long | The number of items in the response. + Long skip = 56L; // Long | The number of items to skip when paging through large result sets. + String 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. + String title = "title_example"; // String | Filter by the display name of the achievement. + Long applicationId = 56L; // Long | Filter by the ID of an Application connected to the achievement. + try { + InlineResponse20053 result = apiInstance.listAchievementsV2(pageSize, skip, sort, title, applicationId); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#listAchievementsV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pageSize** | **Long**| The number of items in the response. | [optional] [default to 50l] + **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] + **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] + **title** | **String**| Filter by the display name of the achievement. | [optional] + **applicationId** | **Long**| Filter by the ID of an Application connected to the achievement. | [optional] + +### Return type cool + +[**InlineResponse20053**](InlineResponse20053.md) ### Authorization @@ -12858,11 +13767,13 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | ## listAllRolesV2 -> InlineResponse20046 listAllRolesV2() +> InlineResponse20047 listAllRolesV2() List roles @@ -12904,7 +13815,7 @@ public class Example { ManagementApi apiInstance = new ManagementApi(defaultClient); try { - InlineResponse20046 result = apiInstance.listAllRolesV2(); + InlineResponse20047 result = apiInstance.listAllRolesV2(); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listAllRolesV2"); @@ -12923,7 +13834,7 @@ This endpoint does not need any parameter. ### Return type cool -[**InlineResponse20046**](InlineResponse20046.md) +[**InlineResponse20047**](InlineResponse20047.md) ### Authorization @@ -12942,7 +13853,7 @@ This endpoint does not need any parameter. ## listApplicationCartItemFilters -> InlineResponse20048 listApplicationCartItemFilters(applicationId, pageSize, skip, title) +> InlineResponse20049 listApplicationCartItemFilters(applicationId, pageSize, skip, name) List Application cart item filters @@ -12986,9 +13897,9 @@ public class Example { Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. Long pageSize = 50lL; // Long | The number of items in the response. Long skip = 56L; // Long | The number of items to skip when paging through large result sets. - String title = "title_example"; // String | Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. + String name = "name_example"; // String | Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. try { - InlineResponse20048 result = apiInstance.listApplicationCartItemFilters(applicationId, pageSize, skip, title); + InlineResponse20049 result = apiInstance.listApplicationCartItemFilters(applicationId, pageSize, skip, name); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listApplicationCartItemFilters"); @@ -13009,11 +13920,11 @@ Name | Type | Description | Notes **applicationId** | **Long**| The ID of the Application. It is displayed in your Talon.One deployment URL. | **pageSize** | **Long**| The number of items in the response. | [optional] [default to 50l] **skip** | **Long**| The number of items to skip when paging through large result sets. | [optional] - **title** | **String**| Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. | [optional] + **name** | **String**| Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. | [optional] ### Return type cool -[**InlineResponse20048**](InlineResponse20048.md) +[**InlineResponse20049**](InlineResponse20049.md) ### Authorization @@ -13032,7 +13943,7 @@ Name | Type | Description | Notes ## listCampaignStoreBudgetLimits -> InlineResponse20049 listCampaignStoreBudgetLimits(applicationId, campaignId, action, period) +> InlineResponse20050 listCampaignStoreBudgetLimits(applicationId, campaignId, action, period) List campaign store budget limits @@ -13078,7 +13989,7 @@ public class Example { String action = "action_example"; // String | The action that this budget is limiting. String period = "period_example"; // String | The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. try { - InlineResponse20049 result = apiInstance.listCampaignStoreBudgetLimits(applicationId, campaignId, action, period); + InlineResponse20050 result = apiInstance.listCampaignStoreBudgetLimits(applicationId, campaignId, action, period); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listCampaignStoreBudgetLimits"); @@ -13103,7 +14014,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20049**](InlineResponse20049.md) +[**InlineResponse20050**](InlineResponse20050.md) ### Authorization @@ -13125,7 +14036,7 @@ Name | Type | Description | Notes ## listCatalogItems -> InlineResponse20039 listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames) +> InlineResponse20040 listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames) List items in a catalog @@ -13173,7 +14084,7 @@ public class Example { List sku = Arrays.asList(); // List | Filter results by one or more SKUs. Must be exact match. List productNames = Arrays.asList(); // List | Filter results by one or more product names. Must be exact match. try { - InlineResponse20039 result = apiInstance.listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); + InlineResponse20040 result = apiInstance.listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listCatalogItems"); @@ -13200,7 +14111,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20039**](InlineResponse20039.md) +[**InlineResponse20040**](InlineResponse20040.md) ### Authorization @@ -13501,7 +14412,7 @@ Name | Type | Description | Notes ## listStores -> InlineResponse20047 listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query) +> InlineResponse20048 listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query) List stores @@ -13552,7 +14463,7 @@ public class Example { String integrationId = "integrationId_example"; // String | The integration ID of the store. String query = "query_example"; // String | Filter results by `name` or `integrationId`. try { - InlineResponse20047 result = apiInstance.listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); + InlineResponse20048 result = apiInstance.listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#listStores"); @@ -13582,7 +14493,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20047**](InlineResponse20047.md) +[**InlineResponse20048**](InlineResponse20048.md) ### Authorization @@ -15410,7 +16321,7 @@ Name | Type | Description | Notes ## summarizeCampaignStoreBudget -> InlineResponse20050 summarizeCampaignStoreBudget(applicationId, campaignId) +> InlineResponse20051 summarizeCampaignStoreBudget(applicationId, campaignId) Get summary of campaign store budgets @@ -15454,7 +16365,7 @@ public class Example { Long applicationId = 56L; // Long | The ID of the Application. It is displayed in your Talon.One deployment URL. Long campaignId = 56L; // Long | The ID of the campaign. It is displayed in your Talon.One deployment URL. try { - InlineResponse20050 result = apiInstance.summarizeCampaignStoreBudget(applicationId, campaignId); + InlineResponse20051 result = apiInstance.summarizeCampaignStoreBudget(applicationId, campaignId); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#summarizeCampaignStoreBudget"); @@ -15477,7 +16388,7 @@ Name | Type | Description | Notes ### Return type cool -[**InlineResponse20050**](InlineResponse20050.md) +[**InlineResponse20051**](InlineResponse20051.md) ### Authorization @@ -15769,6 +16680,95 @@ Name | Type | Description | Notes | **404** | Not found | - | +## updateAchievementV2 + +> AchievementV2 updateAchievementV2(achievementId, body) + +Update achievement + +Update the details of a specific achievement. + +### Example + +```java +// Import classes: +import one.talon.ApiClient; +import one.talon.ApiException; +import one.talon.Configuration; +import one.talon.auth.*; +import one.talon.models.*; +import one.talon.api.ManagementApi; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = Configuration.getDefaultApiClient(); + defaultClient.setBasePath("https://yourbaseurl.talon.one"); + + // Configure API key authorization: api_key_v1 + ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); + api_key_v1.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //api_key_v1.setApiKeyPrefix("Token"); + + // Configure API key authorization: management_key + ApiKeyAuth management_key = (ApiKeyAuth) defaultClient.getAuthentication("management_key"); + management_key.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //management_key.setApiKeyPrefix("Token"); + + // Configure API key authorization: manager_auth + ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); + manager_auth.setApiKey("YOUR API KEY"); + // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) + //manager_auth.setApiKeyPrefix("Token"); + + ManagementApi apiInstance = new ManagementApi(defaultClient); + Long achievementId = 56L; // Long | The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. + UpdateAchievementV2 body = new UpdateAchievementV2(); // UpdateAchievementV2 | body + try { + AchievementV2 result = apiInstance.updateAchievementV2(achievementId, body); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#updateAchievementV2"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **achievementId** | **Long**| The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. | + **body** | [**UpdateAchievementV2**](UpdateAchievementV2.md)| body | + +### Return type cool + +[**AchievementV2**](AchievementV2.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [management_key](../README.md#management_key), [manager_auth](../README.md#manager_auth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | OK | - | +| **400** | Bad request | - | +| **401** | Unauthorized | - | +| **404** | Not found | - | + + ## updateAdditionalCost > AccountAdditionalCost updateAdditionalCost(additionalCostId, body) diff --git a/docs/MapSelectorStep.md b/docs/MapSelectorStep.md new file mode 100644 index 00000000..6ed58a83 --- /dev/null +++ b/docs/MapSelectorStep.md @@ -0,0 +1,22 @@ + + +# MapSelectorStep + +Transforms each item using an expression. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `map`. | +**expression** | **String** | The attribute path each item is mapped to. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +MAP | "map" + + + diff --git a/docs/MultipleAudiencesItem.md b/docs/MultipleAudiencesItem.md index ec8347de..718cb76c 100644 --- a/docs/MultipleAudiencesItem.md +++ b/docs/MultipleAudiencesItem.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **id** | **Long** | The internal ID of this entity. | **created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | **name** | **String** | The human-friendly display name for this audience. | +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] **integrationId** | **String** | The ID of this audience in the third-party integration. | **status** | [**StatusEnum**](#StatusEnum) | Indicates whether the audience is new, updated or unmodified by the request. | diff --git a/docs/NewApplication.md b/docs/NewApplication.md index c04e5d4f..91c2d42c 100644 --- a/docs/NewApplication.md +++ b/docs/NewApplication.md @@ -22,6 +22,7 @@ Name | Type | Description | Notes **defaultDiscountAdditionalCostPerItemScope** | [**DefaultDiscountAdditionalCostPerItemScopeEnum**](#DefaultDiscountAdditionalCostPerItemScopeEnum) | The default scope to apply `setDiscountPerItem` effects on if no scope was provided with the effect. | [optional] **key** | **String** | Hex key for HMAC-signing API calls as coming from this application (16 hex digits). | [optional] **enableCampaignStateManagement** | **Boolean** | Indicates whether the campaign staging and revisions feature is enabled for the Application. **Important:** After this feature is enabled, it cannot be disabled. | [optional] +**bestPriorPriceSettings** | [**BestPriorPriceSettings**](BestPriorPriceSettings.md) | | [optional] diff --git a/docs/NewAudience.md b/docs/NewAudience.md index 3ef81ff9..bd2f4b47 100644 --- a/docs/NewAudience.md +++ b/docs/NewAudience.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **name** | **String** | The human-friendly display name for this audience. | **sandbox** | **Boolean** | Indicates if this is a live or sandbox Application. | [optional] **description** | **String** | A description of the audience. | [optional] +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] **integration** | **String** | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. | [optional] **integrationId** | **String** | The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. | [optional] **createdIn3rdParty** | **Boolean** | Determines if this audience is a 3rd party audience or not. | [optional] diff --git a/docs/NewCampaign.md b/docs/NewCampaign.md index d5335705..6e67fedd 100644 --- a/docs/NewCampaign.md +++ b/docs/NewCampaign.md @@ -47,6 +47,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/NewCampaignTemplate.md b/docs/NewCampaignTemplate.md index 5b5d1f19..6668ea04 100644 --- a/docs/NewCampaignTemplate.md +++ b/docs/NewCampaignTemplate.md @@ -46,6 +46,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/NewCoupons.md b/docs/NewCoupons.md index cbaceaef..c05aeb48 100644 --- a/docs/NewCoupons.md +++ b/docs/NewCoupons.md @@ -13,6 +13,7 @@ Name | Type | Description | Notes **expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional] **limits** | [**List<LimitConfig>**](LimitConfig.md) | Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured. | [optional] **numberOfCoupons** | **Long** | The number of new coupon codes to generate for the campaign. Must be at least 1. | +**batchId** | **String** | The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically. | [optional] **uniquePrefix** | **String** | **DEPRECATED** To create more than 20,000 coupons in one request, use [Create coupons asynchronously](https://docs.talon.one/management-api#tag/Coupons/operation/createCouponsAsync) endpoint. | [optional] **attributes** | [**Object**](.md) | Arbitrary properties associated with this item. | [optional] **recipientIntegrationId** | **String** | The integration ID for this coupon's beneficiary's profile. | [optional] @@ -20,6 +21,8 @@ Name | Type | Description | Notes **couponPattern** | **String** | The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. | [optional] **isReservationMandatory** | **Boolean** | An indication of whether the code can be redeemed only if it has been reserved first. | [optional] **implicitlyReserved** | **Boolean** | An indication of whether the coupon is implicitly reserved for all customers. | [optional] +**supportRequestId** | **Long** | The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed. | [optional] +**supportRequestNote** | **String** | A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided. | [optional] diff --git a/docs/NewCouponsForMultipleRecipients.md b/docs/NewCouponsForMultipleRecipients.md index f3bbb939..afd36c5b 100644 --- a/docs/NewCouponsForMultipleRecipients.md +++ b/docs/NewCouponsForMultipleRecipients.md @@ -11,6 +11,7 @@ Name | Type | Description | Notes **reservationLimit** | **Long** | The number of reservations that can be made with this coupon code. | [optional] **startDate** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp at which point the coupon becomes valid. | [optional] **expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional] +**batchId** | **String** | The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically. | [optional] **attributes** | [**Object**](.md) | Arbitrary properties associated with this item. | [optional] **recipientsIntegrationIds** | **List<String>** | The integration IDs for recipients. | **validCharacters** | **List<String>** | List of characters used to generate the random parts of a code. By default, the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. | [optional] diff --git a/docs/NewCustomerSession.md b/docs/NewCustomerSession.md index 0e000914..b9fedaac 100644 --- a/docs/NewCustomerSession.md +++ b/docs/NewCustomerSession.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **coupon** | **String** | Any coupon code entered. | [optional] **referral** | **String** | Any referral code entered. | [optional] -**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | [optional] +**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | [optional] **cartItems** | [**List<CartItem>**](CartItem.md) | Serialized JSON representation. | [optional] **identifiers** | **List<String>** | Session custom identifiers that you can set limits on or use inside your rules. For example, you can use IP addresses as identifiers to potentially identify devices and limit discounts abuse in case of customers creating multiple accounts. See the [tutorial](https://docs.talon.one/docs/dev/tutorials/using-identifiers). | [optional] **total** | [**BigDecimal**](BigDecimal.md) | The total sum of the cart in one session. | [optional] diff --git a/docs/NewCustomerSessionV2.md b/docs/NewCustomerSessionV2.md index fea87e4d..3423b8c5 100644 --- a/docs/NewCustomerSessionV2.md +++ b/docs/NewCustomerSessionV2.md @@ -13,7 +13,8 @@ Name | Type | Description | Notes **couponCodes** | **List<String>** | Any coupon codes entered. **Important - for requests only**: - If you [create a coupon budget](https://docs.talon.one/docs/product/campaigns/settings/managing-campaign-budgets/#budget-types) for your campaign, ensure the session contains a coupon code by the time you close it. - In requests where `dry=false`, providing an empty array discards any previous coupons. To avoid this, omit the parameter entirely. | [optional] **referralCode** | **String** | Any referral code entered. **Important - for requests only**: - If you [create a referral budget](https://docs.talon.one/docs/product/campaigns/settings/managing-campaign-budgets/#budget-types) for your campaign, ensure the session contains a referral code by the time you close it. - In requests where `dry=false`, providing an empty value discards the previous referral code. To avoid this, omit the parameter entirely. | [optional] **loyaltyCards** | **List<String>** | Identifier of a loyalty card. | [optional] -**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | [optional] +**rewardIntegrationIds** | **List<String>** | The integration IDs of the unlocked rewards that can be used in this session. | [optional] +**state** | [**StateEnum**](#StateEnum) | Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). | [optional] **cartItems** | [**List<CartItem>**](CartItem.md) | The items to add to this session. **Do not exceed 1000 items** and ensure the sum of all cart item's `quantity` **does not exceed 10.000** per request. | [optional] **experimentVariantAllocations** | [**List<ExperimentVariantAllocation>**](ExperimentVariantAllocation.md) | The experiment variant allocations to add to this session. | [optional] **additionalCosts** | [**Map<String, AdditionalCost>**](AdditionalCost.md) | Use this property to set a value for the additional costs of this session, such as a shipping cost. They must be created in the Campaign Manager before you set them with this property. See [Managing additional costs](https://docs.talon.one/docs/product/account/dev-tools/managing-additional-costs). | [optional] diff --git a/docs/NewDigitalPass.md b/docs/NewDigitalPass.md new file mode 100644 index 00000000..164d409b --- /dev/null +++ b/docs/NewDigitalPass.md @@ -0,0 +1,26 @@ + + +# NewDigitalPass + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**loyaltyProgramId** | **Long** | The ID of the associated loyalty program. | +**passTemplateId** | **String** | The ID of the digital pass template used to generate the pass. | +**profileId** | **String** | The integration ID of the customer profile the pass is issued for. | +**loyaltyCardId** | **String** | The identifier of the loyalty card the pass is issued for. **Note**: Only applicable for card-based loyalty programs. | [optional] +**platform** | [**PlatformEnum**](#PlatformEnum) | The wallet platform the pass is generated for. | +**attributes** | **Map<String, String>** | A map of placeholder values that you provide to fill in the pass template. These values are not validated against the template. | [optional] + + + +## Enum: PlatformEnum + +Name | Value +---- | ----- +APPLE | "apple" +GOOGLE | "google" + + + diff --git a/docs/NewEvent.md b/docs/NewEvent.md index daa4173c..59a9512c 100644 --- a/docs/NewEvent.md +++ b/docs/NewEvent.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **profileId** | **String** | ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. | [optional] **storeIntegrationId** | **String** | The integration ID of the store. You choose this ID when you create a store. | [optional] -**type** | **String** | A string representing the event. Must not be a reserved event name. | +**type** | **String** | The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. | **attributes** | [**Object**](.md) | Arbitrary additional JSON data associated with the event. | **sessionId** | **String** | The ID of the session that this event occurred in. | diff --git a/docs/NewEventV3Entity.md b/docs/NewEventV3Entity.md new file mode 100644 index 00000000..438f44ff --- /dev/null +++ b/docs/NewEventV3Entity.md @@ -0,0 +1,12 @@ + + +# NewEventV3Entity + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The unique ID of the event. Only one event with this ID can be registered. | + + + diff --git a/docs/NewExperiment.md b/docs/NewExperiment.md index d1a681a9..b9061303 100644 --- a/docs/NewExperiment.md +++ b/docs/NewExperiment.md @@ -8,6 +8,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **isVariantAssignmentExternal** | **Boolean** | The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. | **campaign** | [**NewCampaign**](NewCampaign.md) | | +**goalType** | [**GoalTypeEnum**](#GoalTypeEnum) | The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. | +**goalDescription** | **String** | A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. | [optional] + + + +## Enum: GoalTypeEnum + +Name | Value +---- | ----- +OTHER | "other" +MAXIMIZE_REVENUE | "maximize_revenue" +MAXIMIZE_ITEMS_SOLD | "maximize_items_sold" +OPTIMIZE_DISCOUNT_EFFICIENCY | "optimize_discount_efficiency" diff --git a/docs/NewIntegrationHubCoupons.md b/docs/NewIntegrationHubCoupons.md new file mode 100644 index 00000000..4b05dac7 --- /dev/null +++ b/docs/NewIntegrationHubCoupons.md @@ -0,0 +1,29 @@ + + +# NewIntegrationHubCoupons + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**usageLimit** | **Long** | The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. | +**discountLimit** | [**BigDecimal**](BigDecimal.md) | The total discount value that the code can give. Typically used to represent a gift card value. | [optional] +**reservationLimit** | **Long** | The number of reservations that can be made with this coupon code. | [optional] +**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp at which point the coupon becomes valid. | [optional] +**expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional] +**limits** | [**List<LimitConfig>**](LimitConfig.md) | Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured. | [optional] +**applicationId** | **Long** | The ID of the Application the coupons will belong to. | +**campaignId** | **Long** | The ID of the Campaign the coupons will belong to. | +**batchId** | **String** | An identifier for the batch of coupons being created. | +**numberOfCoupons** | **Long** | The number of new coupon codes to generate for the campaign. Must be at least 1. | +**attributes** | [**Object**](.md) | Arbitrary properties associated with this item. | [optional] +**validCharacters** | **List<String>** | List of characters used to generate the random parts of a code. By default, the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. | [optional] +**couponPattern** | **String** | The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. | [optional] +**isReservationMandatory** | **Boolean** | An indication of whether the code can be redeemed only if it has been reserved first. | [optional] +**implicitlyReserved** | **Boolean** | An indication of whether the coupon is implicitly reserved for all customers. | [optional] +**recipientIntegrationId** | **String** | The integration ID for this coupon's beneficiary's profile. | [optional] +**supportRequestId** | **Long** | The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed. | [optional] +**supportRequestNote** | **String** | A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided. | [optional] + + + diff --git a/docs/NewInternalAudience.md b/docs/NewInternalAudience.md index cc32a364..3154a2d9 100644 --- a/docs/NewInternalAudience.md +++ b/docs/NewInternalAudience.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **name** | **String** | The human-friendly display name for this audience. | **sandbox** | **Boolean** | Indicates if this is a live or sandbox Application. | [optional] **description** | **String** | A description of the audience. | [optional] +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] diff --git a/docs/NewMCPOAuthClient.md b/docs/NewMCPOAuthClient.md new file mode 100644 index 00000000..6165282f --- /dev/null +++ b/docs/NewMCPOAuthClient.md @@ -0,0 +1,13 @@ + + +# NewMCPOAuthClient + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**clientName** | **String** | Human-readable name for the OAuth2 client. | +**redirectUris** | **List<String>** | List of allowed redirect URIs for the authorization code flow. At least one URI is required. | + + + diff --git a/docs/NewMultipleAudiencesItem.md b/docs/NewMultipleAudiencesItem.md index 2906b597..fe8cddd7 100644 --- a/docs/NewMultipleAudiencesItem.md +++ b/docs/NewMultipleAudiencesItem.md @@ -7,6 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **name** | **String** | The human-friendly display name for this audience. | +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] **integrationId** | **String** | The ID of this audience in the third-party integration. | [optional] diff --git a/docs/NewRevisionVersion.md b/docs/NewRevisionVersion.md index dbcd3f8b..cae358ba 100644 --- a/docs/NewRevisionVersion.md +++ b/docs/NewRevisionVersion.md @@ -32,6 +32,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/NewReward.md b/docs/NewReward.md index aa736857..cfea691a 100644 --- a/docs/NewReward.md +++ b/docs/NewReward.md @@ -11,6 +11,10 @@ Name | Type | Description | Notes **description** | **String** | A description of the reward. | [optional] **applicationIds** | **List<Long>** | The IDs of the Applications this reward is connected to. **Note**: Currently, a reward can only be connected to one Application. | **sandbox** | **Boolean** | Indicates if this is a live or sandbox reward. Rewards of a given type can only be connected to Applications of the same type. | +**eligibilityConditions** | [**Rule**](Rule.md) | | [optional] +**rule** | [**Rule**](Rule.md) | | [optional] +**bindings** | [**List<Binding>**](Binding.md) | A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. | [optional] +**pointsRequired** | [**List<RewardPointsRequired>**](RewardPointsRequired.md) | The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. | [optional] diff --git a/docs/NewRiskNotification.md b/docs/NewRiskNotification.md new file mode 100644 index 00000000..0cd35191 --- /dev/null +++ b/docs/NewRiskNotification.md @@ -0,0 +1,45 @@ + + +# NewRiskNotification + +Data for creating a new risk notification. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**entity** | [**EntityEnum**](#EntityEnum) | The entity type to analyze within the given time frame. | +**activity** | [**ActivityEnum**](#ActivityEnum) | The activity metric to analyze within the given entity. | +**timeFrame** | [**TimeFrameEnum**](#TimeFrameEnum) | The rolling time window for risk evaluation. | + + + +## Enum: EntityEnum + +Name | Value +---- | ----- +PROFILE | "customer_profile" +SESSION | "customer_session" + + + +## Enum: ActivityEnum + +Name | Value +---- | ----- +LOYALTY_POINTS_EARNED | "loyalty_points_earned" +DISCOUNTED_AMOUNT | "discounted_amount" +COMPLETED_ORDERS | "completed_orders" +COUPON_ATTEMPTS | "coupon_attempts" + + + +## Enum: TimeFrameEnum + +Name | Value +---- | ----- +_1D | "1D" +_7D | "7D" +_30D | "30D" + + + diff --git a/docs/PassthroughBlock.md b/docs/PassthroughBlock.md new file mode 100644 index 00000000..5e4f0197 --- /dev/null +++ b/docs/PassthroughBlock.md @@ -0,0 +1,23 @@ + + +# PassthroughBlock + +A block representing a Talang expression that could not be mapped to a typed block. The expression is preserved in its raw Talang array form for diagnostic and round-trip purposes. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | [**TypeEnum**](#TypeEnum) | The type discriminator for this block. | +**expression** | **List<Object>** | The raw Talang expression as an array. For a function call, the first element is the function name and subsequent elements are its arguments. For any other expression (for example a bare attribute path or a literal value), this is a single-element array containing that value. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +PASSTHROUGH | "passthrough" + + + diff --git a/docs/RedeemLoyaltyPointsBlock.md b/docs/RedeemLoyaltyPointsBlock.md new file mode 100644 index 00000000..1b1fe140 --- /dev/null +++ b/docs/RedeemLoyaltyPointsBlock.md @@ -0,0 +1,20 @@ + + +# RedeemLoyaltyPointsBlock + +A block that deducts a specified amount of points from a customer's loyalty program balance, optionally from a named subledger. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**program** | [**RedeemLoyaltyPointsBlockProgram**](RedeemLoyaltyPointsBlockProgram.md) | | +**subledger** | **String** | The name of the subledger to deduct points from. Can be empty if this block deducts from the loyalty program's main ledger instead of a subledger. | +**value** | [**Object**](.md) | Number of points to deduct. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. | +**name** | **String** | A custom description recorded as the reason for the point deduction. | [optional] +**onFailure** | **List<Object>** | Promotion blocks evaluated when this block fails or returns false. | [optional] + + + diff --git a/docs/RedeemLoyaltyPointsBlockProgram.md b/docs/RedeemLoyaltyPointsBlockProgram.md new file mode 100644 index 00000000..539232c1 --- /dev/null +++ b/docs/RedeemLoyaltyPointsBlockProgram.md @@ -0,0 +1,15 @@ + + +# RedeemLoyaltyPointsBlockProgram + +The loyalty program whose balance points are deducted from. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the loyalty program. | +**name** | **String** | The internal name of the loyalty program. | +**title** | **String** | The display name of the loyalty program. | + + + diff --git a/docs/RedeemReferralEffectProps.md b/docs/RedeemReferralEffectProps.md index 150d11b9..db544286 100644 --- a/docs/RedeemReferralEffectProps.md +++ b/docs/RedeemReferralEffectProps.md @@ -2,7 +2,7 @@ # RedeemReferralEffectProps -This effect is **deprecated**. The properties specific to the \"redeemReferral\" effect. This gets triggered whenever the referral code is valid, and a rule was triggered that contains a \"redeem referral\" effect. +This effect is **deprecated**. It has been replaced by the `acceptReferral` effect. This effect indicates that the referral code is valid and has been redeemed. ## Properties Name | Type | Description | Notes diff --git a/docs/RedeemableCoupon.md b/docs/RedeemableCoupon.md new file mode 100644 index 00000000..6065a9a8 --- /dev/null +++ b/docs/RedeemableCoupon.md @@ -0,0 +1,16 @@ + + +# RedeemableCoupon + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**couponId** | **Long** | The internal ID of the coupon. | +**couponCode** | **String** | The coupon code. | +**usageCounter** | **Long** | The number of times the coupon has been successfully redeemed. | +**usageLimit** | **Long** | The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits still apply. | +**campaignName** | **String** | The name of the campaign that owns the coupon. | + + + diff --git a/docs/ReduceSelectorStep.md b/docs/ReduceSelectorStep.md new file mode 100644 index 00000000..279f5211 --- /dev/null +++ b/docs/ReduceSelectorStep.md @@ -0,0 +1,34 @@ + + +# ReduceSelectorStep + +Aggregates items into a single value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `reduce`. | +**operator** | [**OperatorEnum**](#OperatorEnum) | The aggregation operator applied to the items produced by the preceding step: - `max`, `min`, and `sum` operate on numeric values. - `count` returns the number of items. - `empty` reports whether the list is empty. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +REDUCE | "reduce" + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +MAX | "max" +MIN | "min" +SUM | "sum" +COUNT | "count" +EMPTY | "empty" + + + diff --git a/docs/ReferralCreatedEffectProps.md b/docs/ReferralCreatedEffectProps.md index aeceabeb..1c37d0bc 100644 --- a/docs/ReferralCreatedEffectProps.md +++ b/docs/ReferralCreatedEffectProps.md @@ -2,12 +2,12 @@ # ReferralCreatedEffectProps -The properties specific to the \"referralCreated\" effect. This gets triggered whenever a validated rule contained a \"create referral\" effect, and a referral code was created for a customer. See \"createdReferrals\" on the response for all details of this referral code. +The `referralCreated` effect behaves similarly to [couponCreated](https://docs.talon.one/docs/dev/integration-api/api-effects#couponcreated). If the `friendProfileIntegrationId` parameter is empty, the referral code can be redeemed by anyone. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**value** | **String** | The referral code that was created. | +**value** | **String** | The referral code provided in the session. | diff --git a/docs/RejectCouponEffectProps.md b/docs/RejectCouponEffectProps.md index 21e16c7b..d7962fc7 100644 --- a/docs/RejectCouponEffectProps.md +++ b/docs/RejectCouponEffectProps.md @@ -2,17 +2,17 @@ # RejectCouponEffectProps -The properties specific to the \"rejectCoupon\" effect. This gets triggered whenever the coupon was rejected. See rejectionReason for more info on why. +This effect indicates that the coupon code supplied couldn't be used. You should handle this effect by informing their user the coupon code is invalid. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **String** | The coupon code that was rejected. | -**rejectionReason** | **String** | The reason why this coupon was rejected. | +**rejectionReason** | **String** | The reason why the code was rejected. - `CampaignLimitReached`: The campaign-wide coupon code redemption limit has been reached. - `CouponExpired`: The coupon is expired. - `CouponLimitReached`: The coupon redemption limit or a campaign budget was reached. - `CouponNotFound`: The coupon code is incorrect. - `CouponPartOfNotRunningCampaign`: The campaign the coupon belongs to is currently not active. The campaignId field contains the ID of that campaign. - `CouponRecipientDoesNotMatch`: The given coupon value does not match the recipient or the coupon is linked to a `recipientIntegrationID` but there is no profile in the session. - `CouponRejectedByCondition`: Other conditions failed in the rule or all conditions passed but the `Coupon code is valid` condition is not present. - `CouponStartDateInFuture`: The coupon isn't active yet. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` cannot be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific coupon redemption limit has been reached. - `CouponPartOfNotTriggeredCampaign`: The campaign the coupon belongs to was not triggered during evaluation (an exclusive or stackable campaign). The `campaignId` field contains the ID of that campaign. - `CouponReservationRequired`: The coupon's `isReservationMandatory` property is `true`, but the profile does not have a reservation. - `ProfileRequired`: The coupon's `isReservationMandatory` property is `true` or a [campaign profile budget](https://docs.talon.one/docs/product/campaigns/settings/manage-campaign-budgets) was set, but no profile exists in the session. | **conditionIndex** | **Long** | The index of the condition that caused the rejection of the coupon. | [optional] **effectIndex** | **Long** | The index of the effect that caused the rejection of the coupon. | [optional] **details** | **String** | More details about the failure. | [optional] -**campaignExclusionReason** | **String** | The reason why the campaign was not applied. | [optional] +**campaignExclusionReason** | **String** | The reason why the campaign the coupon belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and coupon conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the coupon is part of an archived campaign. | [optional] diff --git a/docs/RejectReferralEffectProps.md b/docs/RejectReferralEffectProps.md index ec3e5eff..be3b3267 100644 --- a/docs/RejectReferralEffectProps.md +++ b/docs/RejectReferralEffectProps.md @@ -2,17 +2,17 @@ # RejectReferralEffectProps -The properties specific to the \"rejectReferral\" effect. This gets triggered whenever the referral code was rejected. See rejectionReason for more info on why. +This effect indicates that the provided referral code is invalid. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**value** | **String** | The referral code that was rejected. | -**rejectionReason** | **String** | The reason why this referral code was rejected. | +**value** | **String** | The referral code that was rejected | +**rejectionReason** | **String** | The reason why the code was rejected. - `AdvocateNotFound`: The advocate was not found. - `CampaignLimitReached`: The campaign-wide referral code redemption limit has been reached. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` can not be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific referral code redemption limit has been reached. - `ReferralCustomerAlreadyReferred`: The friend is already referred. - `ReferralExpired`: The transferred referral code is expired. - `ReferralLimitReached`: The referral code redemption limit has been reached. - `ReferralNotFound`: The transferred referral code is wrong. - `ReferralPartOfNotRunningCampaign`: The campaign the referral code belongs to is currently not active. The campaign ID field shows the ID of that campaign. - `ReferralRecipientDoesNotMatch`: The given referral code value does not match the recipient. - `ReferralRecipientIdSameAsAdvocate`: The recipient (friend) has the same id as the advocate. - `ReferralRejectedByCondition`: The referral code is valid and in an active campaign, but there were other conditions in that campaign's rules that were not met. - `ReferralStartDateInFuture`: The transferred referral code isn't active yet. - `ReferralPartOfNotTriggeredCampaign`: The campaign the referral code belongs to was not triggered during evaluation (an exclusive or stackable campaign). The campaign ID field shows the ID of that campaign. | **conditionIndex** | **Long** | The index of the condition that caused the rejection of the referral. | [optional] **effectIndex** | **Long** | The index of the effect that caused the rejection of the referral. | [optional] **details** | **String** | More details about the failure. | [optional] -**campaignExclusionReason** | **String** | The reason why the campaign was not applied. | [optional] +**campaignExclusionReason** | **String** | The reason why the campaign the referral belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and referral conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the referral is part of an archived campaign. | [optional] diff --git a/docs/RemoveFromAudienceEffectProps.md b/docs/RemoveFromAudienceEffectProps.md index 5c4b229e..8f21f1b1 100644 --- a/docs/RemoveFromAudienceEffectProps.md +++ b/docs/RemoveFromAudienceEffectProps.md @@ -2,7 +2,7 @@ # RemoveFromAudienceEffectProps -The properties specific to the \"removeFromAudience\" effect. This gets triggered whenever a validated rule contains a \"removeFromAudience\" effect. +This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Remove customer from an audience** selected is validated. It indicates that a customer was removed from an audience and is returned when a customer session is opened, updated, or closed. ## Properties Name | Type | Description | Notes diff --git a/docs/ReserveCouponBlock.md b/docs/ReserveCouponBlock.md new file mode 100644 index 00000000..972d9148 --- /dev/null +++ b/docs/ReserveCouponBlock.md @@ -0,0 +1,15 @@ + + +# ReserveCouponBlock + +A block that reserve a coupon during a customer session. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] + + + diff --git a/docs/ReserveCouponEffectProps.md b/docs/ReserveCouponEffectProps.md index caa0c1ce..d87da414 100644 --- a/docs/ReserveCouponEffectProps.md +++ b/docs/ReserveCouponEffectProps.md @@ -2,13 +2,13 @@ # ReserveCouponEffectProps -The properties specific to the \"reserveCoupon\" effect. This gets triggered whenever a validated rule contained a \"reserve coupon\" effect. This reserves the coupon currently on scope to the profile on scope. +This effect indicates that the given coupon code was reserved for the given customer. Talon.One provides soft and hard reservations. For more information, see [Reserve a coupon code](https://docs.talon.one/docs/product/rules/effects/use-effects#reserve-a-coupon-code). ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**couponValue** | **String** | The value of the coupon currently on scope. | -**profileIntegrationId** | **String** | The ID of this customer profile in the third-party integration. | +**couponValue** | **String** | The coupon code that was created. | +**profileIntegrationId** | **String** | The integration identifier of the customer for whom this coupon was reserved. | **isNewReservation** | **Boolean** | Indicates whether this is a new coupon reservation or not. | diff --git a/docs/ResponseContentObject.md b/docs/ResponseContentObject.md index 21624fc5..0e6cf283 100644 --- a/docs/ResponseContentObject.md +++ b/docs/ResponseContentObject.md @@ -20,6 +20,9 @@ LOYALTY | "loyalty" EVENT | "event" AWARDEDGIVEAWAYS | "awardedGiveaways" RULEFAILUREREASONS | "ruleFailureReasons" +CAMPAIGNELIGIBILITY | "campaignEligibility" +ACHIEVEMENTS | "achievements" +UNLOCKEDREWARDS | "unlockedRewards" diff --git a/docs/ReverseSelectorStep.md b/docs/ReverseSelectorStep.md new file mode 100644 index 00000000..54228be1 --- /dev/null +++ b/docs/ReverseSelectorStep.md @@ -0,0 +1,21 @@ + + +# ReverseSelectorStep + +Reverses the order of the items. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `reverse`. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +REVERSE | "reverse" + + + diff --git a/docs/ReviewRisksRequest.md b/docs/ReviewRisksRequest.md new file mode 100644 index 00000000..6cced52a --- /dev/null +++ b/docs/ReviewRisksRequest.md @@ -0,0 +1,12 @@ + + +# ReviewRisksRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**riskIds** | **List<Long>** | The IDs of the risks to move to `In review` status. | + + + diff --git a/docs/RevisionVersion.md b/docs/RevisionVersion.md index 32a6aae6..2df9b05d 100644 --- a/docs/RevisionVersion.md +++ b/docs/RevisionVersion.md @@ -40,6 +40,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/Reward.md b/docs/Reward.md index d73c0dd6..af8a2fef 100644 --- a/docs/Reward.md +++ b/docs/Reward.md @@ -14,6 +14,11 @@ Name | Type | Description | Notes **description** | **String** | A description of the reward. | [optional] **applicationIds** | **List<Long>** | The IDs of the Applications this reward is connected to. **Note**: Currently, a reward can only be connected to one Application. | **sandbox** | **Boolean** | Indicates if this is a live or sandbox reward. Rewards of a given type can only be connected to Applications of the same type. | +**eligibilityConditions** | [**Rule**](Rule.md) | | [optional] +**rule** | [**Rule**](Rule.md) | | [optional] +**bindings** | [**List<Binding>**](Binding.md) | A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. | [optional] +**pointsRequired** | [**List<RewardPointsRequired>**](RewardPointsRequired.md) | The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. | [optional] +**modified** | [**OffsetDateTime**](OffsetDateTime.md) | The timestamp when the reward was last updated in RFC3339 format. | [optional] **status** | [**StatusEnum**](#StatusEnum) | The status of the reward. | diff --git a/docs/RewardCatalogItem.md b/docs/RewardCatalogItem.md new file mode 100644 index 00000000..23731e9d --- /dev/null +++ b/docs/RewardCatalogItem.md @@ -0,0 +1,18 @@ + + +# RewardCatalogItem + +A reward returned by the rewards catalog Integration API endpoint. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The unique ID of the reward. | +**name** | **String** | The customer-facing name of the reward. | +**description** | **String** | The customer-facing description of the reward. | [optional] +**pointsRequired** | [**List<RewardPointsRequired>**](RewardPointsRequired.md) | The loyalty points required to activate the reward. | [optional] +**rule** | [**RuleMetadata**](RuleMetadata.md) | | +**eligibility** | [**RewardEligibility**](RewardEligibility.md) | | [optional] + + + diff --git a/docs/RewardEligibility.md b/docs/RewardEligibility.md new file mode 100644 index 00000000..d0c3f98f --- /dev/null +++ b/docs/RewardEligibility.md @@ -0,0 +1,14 @@ + + +# RewardEligibility + +The customer's eligibility for the reward based on the specified customer profile or loyalty card. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**passed** | **Boolean** | Indicates whether the customer is eligible for the reward. | +**details** | [**List<RewardEligibilityFailureDetails>**](RewardEligibilityFailureDetails.md) | The reasons the customer is not eligible for the reward. Empty when `passed` is `true`. | [optional] + + + diff --git a/docs/RewardEligibilityFailureDetails.md b/docs/RewardEligibilityFailureDetails.md new file mode 100644 index 00000000..e8efbad4 --- /dev/null +++ b/docs/RewardEligibilityFailureDetails.md @@ -0,0 +1,25 @@ + + +# RewardEligibilityFailureDetails + +The details about why the customer is not eligible for the reward. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**failureCode** | [**FailureCodeEnum**](#FailureCodeEnum) | A code identifying why the customer is not eligible for the reward. | +**conditionIndex** | **Long** | The index of the eligibility condition that the customer did not meet. Only applicable when `failureCode` is `CONDITION_NOT_MET`. | [optional] + + + +## Enum: FailureCodeEnum + +Name | Value +---- | ----- +CONDITION_NOT_MET | "CONDITION_NOT_MET" +INSUFFICIENT_BALANCE | "INSUFFICIENT_BALANCE" +CARD_REQUIRED | "CARD_REQUIRED" +PROFILE_REQUIRED | "PROFILE_REQUIRED" + + + diff --git a/docs/RewardPointsRequired.md b/docs/RewardPointsRequired.md new file mode 100644 index 00000000..eecdde04 --- /dev/null +++ b/docs/RewardPointsRequired.md @@ -0,0 +1,16 @@ + + +# RewardPointsRequired + +The loyalty points required to activate a reward. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the `pointsRequired` entry. When updating a reward, include this property to update an existing entry. Omit it to create a new one. | [optional] +**amount** | [**BigDecimal**](BigDecimal.md) | The number of loyalty points required to activate the reward. | +**loyaltyProgramId** | **Long** | The ID of the associated loyalty program. | +**subledgerId** | **String** | The ID of the subledger within the loyalty program from which points are deducted when activating the reward. To specify the main ledger, provide an empty string (\"\"). | + + + diff --git a/docs/RewardUnlockRejection.md b/docs/RewardUnlockRejection.md new file mode 100644 index 00000000..a9cc1b44 --- /dev/null +++ b/docs/RewardUnlockRejection.md @@ -0,0 +1,14 @@ + + +# RewardUnlockRejection + +Returned when a reward unlock is rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**message** | **String** | A human-readable summary of why the reward unlock was rejected. | +**ruleFailureReasons** | [**List<RuleFailureReason>**](RuleFailureReason.md) | The reasons why the reward could not be unlocked. | + + + diff --git a/docs/RewardWithUnlocks.md b/docs/RewardWithUnlocks.md new file mode 100644 index 00000000..8b07d234 --- /dev/null +++ b/docs/RewardWithUnlocks.md @@ -0,0 +1,18 @@ + + +# RewardWithUnlocks + +A reward and details of each time a customer profile has unlocked it. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The unique ID of the reward. | +**integrationId** | **String** | A unique identifier used to reference the reward in API integrations. | +**name** | **String** | The customer-facing name of the reward. | +**description** | **String** | Customer-facing description of the reward. | [optional] +**rule** | [**RuleMetadata**](RuleMetadata.md) | | +**unlocked** | [**List<CustomerReward>**](CustomerReward.md) | The customer profile's unlocks of this reward that are not yet `used`. | [optional] + + + diff --git a/docs/Risk.md b/docs/Risk.md new file mode 100644 index 00000000..f8f6c91a --- /dev/null +++ b/docs/Risk.md @@ -0,0 +1,90 @@ + + +# Risk + +A risk detected by the anomaly detection service for one Application group. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of this entity. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | +**notificationId** | **Long** | The ID of the risk notification rule that flagged this risk. | +**featureDate** | [**LocalDate**](LocalDate.md) | The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. | +**groupKey** | **String** | The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. | +**applicationId** | **Long** | The ID of the Application this risk belongs to. Absent for global metrics. | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The triage lifecycle status of this risk. | +**criticality** | [**CriticalityEnum**](#CriticalityEnum) | The critical classification bucket of this risk. | +**entity** | [**EntityEnum**](#EntityEnum) | The entity type the risk was detected in. | +**activity** | [**ActivityEnum**](#ActivityEnum) | The activity metric the risk was detected in. | +**timeFrame** | [**TimeFrameEnum**](#TimeFrameEnum) | The rolling time window of the risk evaluation. | +**reportedDate** | [**OffsetDateTime**](OffsetDateTime.md) | The time the ML service reported this risk. | +**affectedEntityCount** | **Long** | The total number of entities affected by this risk. | +**description** | **String** | Human-readable description of the detected anomaly. | [optional] +**discardReason** | [**DiscardReasonEnum**](#DiscardReasonEnum) | The reason this risk was discarded. Only present on discarded risks. | [optional] +**statusComment** | **String** | The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. | [optional] +**statusChangedBy** | **Long** | The ID of the user who performed the latest reclassification action. | [optional] +**statusChangedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The time of the latest reclassification action. | [optional] +**modified** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp of the most recent update. | + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +ACTIVE | "active" +IN_REVIEW | "in_review" +CONFIRMED | "confirmed" +DISCARDED | "discarded" + + + +## Enum: CriticalityEnum + +Name | Value +---- | ----- +CRITICAL | "critical" +NOT_CRITICAL | "not_critical" + + + +## Enum: EntityEnum + +Name | Value +---- | ----- +PROFILE | "customer_profile" +SESSION | "customer_session" + + + +## Enum: ActivityEnum + +Name | Value +---- | ----- +LOYALTY_POINTS_EARNED | "loyalty_points_earned" +DISCOUNTED_AMOUNT | "discounted_amount" +COMPLETED_ORDERS | "completed_orders" +COUPON_ATTEMPTS | "coupon_attempts" + + + +## Enum: TimeFrameEnum + +Name | Value +---- | ----- +_1D | "1D" +_7D | "7D" +_30D | "30D" + + + +## Enum: DiscardReasonEnum + +Name | Value +---- | ----- +EXPECTED_BEHAVIOR | "expected_behavior" +OTHER | "other" + + + diff --git a/docs/RiskAffectedEntityItem.md b/docs/RiskAffectedEntityItem.md new file mode 100644 index 00000000..b8c5ba7b --- /dev/null +++ b/docs/RiskAffectedEntityItem.md @@ -0,0 +1,26 @@ + + +# RiskAffectedEntityItem + +A single entity flagged as anomalous within a risk. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**entityId** | **String** | The integration ID of the affected entity. | +**activityValue** | **Double** | The observed value of the monitored activity metric for this entity. | +**threshold** | **Double** | The anomaly threshold computed for the entity's Application group. | +**severityRatio** | **Double** | The ratio of the observed value to the threshold. | +**criticality** | [**CriticalityEnum**](#CriticalityEnum) | The critical classification bucket of this entity. | + + + +## Enum: CriticalityEnum + +Name | Value +---- | ----- +CRITICAL | "critical" +NOT_CRITICAL | "not_critical" + + + diff --git a/docs/RiskCriticalityUpdate.md b/docs/RiskCriticalityUpdate.md new file mode 100644 index 00000000..16fefd0a --- /dev/null +++ b/docs/RiskCriticalityUpdate.md @@ -0,0 +1,21 @@ + + +# RiskCriticalityUpdate + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**riskIds** | **List<Long>** | The IDs of the risks to reclassify. | +**criticality** | [**CriticalityEnum**](#CriticalityEnum) | The criticality to assign to risks. Only `not_critical` is accepted: critical risks can be reclassified as non-critical, but not the other way around. | + + + +## Enum: CriticalityEnum + +Name | Value +---- | ----- +NOT_CRITICAL | "not_critical" + + + diff --git a/docs/RiskDetail.md b/docs/RiskDetail.md new file mode 100644 index 00000000..b5e9a539 --- /dev/null +++ b/docs/RiskDetail.md @@ -0,0 +1,91 @@ + + +# RiskDetail + +Details of a risk, including its most severely affected entities. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of this entity. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | +**notificationId** | **Long** | The ID of the risk notification rule that flagged this risk. | +**featureDate** | [**LocalDate**](LocalDate.md) | The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. | +**groupKey** | **String** | The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. | +**applicationId** | **Long** | The ID of the Application this risk belongs to. Absent for global metrics. | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The triage lifecycle status of this risk. | +**criticality** | [**CriticalityEnum**](#CriticalityEnum) | The critical classification bucket of this risk. | +**entity** | [**EntityEnum**](#EntityEnum) | The entity type the risk was detected in. | +**activity** | [**ActivityEnum**](#ActivityEnum) | The activity metric the risk was detected in. | +**timeFrame** | [**TimeFrameEnum**](#TimeFrameEnum) | The rolling time window of the risk evaluation. | +**reportedDate** | [**OffsetDateTime**](OffsetDateTime.md) | The time the ML service reported this risk. | +**affectedEntityCount** | **Long** | The total number of entities affected by this risk. | +**description** | **String** | Human-readable description of the detected anomaly. | [optional] +**discardReason** | [**DiscardReasonEnum**](#DiscardReasonEnum) | The reason this risk was discarded. Only present on discarded risks. | [optional] +**statusComment** | **String** | The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. | [optional] +**statusChangedBy** | **Long** | The ID of the user who performed the latest reclassification action. | [optional] +**statusChangedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The time of the latest reclassification action. | [optional] +**modified** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp of the most recent update. | +**affectedEntities** | [**List<RiskAffectedEntityItem>**](RiskAffectedEntityItem.md) | The affected entities with the highest severity ratios, in descending order. | + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +ACTIVE | "active" +IN_REVIEW | "in_review" +CONFIRMED | "confirmed" +DISCARDED | "discarded" + + + +## Enum: CriticalityEnum + +Name | Value +---- | ----- +CRITICAL | "critical" +NOT_CRITICAL | "not_critical" + + + +## Enum: EntityEnum + +Name | Value +---- | ----- +PROFILE | "customer_profile" +SESSION | "customer_session" + + + +## Enum: ActivityEnum + +Name | Value +---- | ----- +LOYALTY_POINTS_EARNED | "loyalty_points_earned" +DISCOUNTED_AMOUNT | "discounted_amount" +COMPLETED_ORDERS | "completed_orders" +COUPON_ATTEMPTS | "coupon_attempts" + + + +## Enum: TimeFrameEnum + +Name | Value +---- | ----- +_1D | "1D" +_7D | "7D" +_30D | "30D" + + + +## Enum: DiscardReasonEnum + +Name | Value +---- | ----- +EXPECTED_BEHAVIOR | "expected_behavior" +OTHER | "other" + + + diff --git a/docs/RiskNotification.md b/docs/RiskNotification.md new file mode 100644 index 00000000..86913b0f --- /dev/null +++ b/docs/RiskNotification.md @@ -0,0 +1,49 @@ + + +# RiskNotification + +A risk notification configuration rule. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of this entity. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | +**entity** | [**EntityEnum**](#EntityEnum) | The entity type to analyze within the given time frame. | +**activity** | [**ActivityEnum**](#ActivityEnum) | The activity metric to analyze within the given entity. | +**timeFrame** | [**TimeFrameEnum**](#TimeFrameEnum) | The rolling time window for risk evaluation. | +**active** | **Boolean** | Indicates whether this risk notification is active. | +**modified** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp of the most recent update. | + + + +## Enum: EntityEnum + +Name | Value +---- | ----- +PROFILE | "customer_profile" +SESSION | "customer_session" + + + +## Enum: ActivityEnum + +Name | Value +---- | ----- +LOYALTY_POINTS_EARNED | "loyalty_points_earned" +DISCOUNTED_AMOUNT | "discounted_amount" +COMPLETED_ORDERS | "completed_orders" +COUPON_ATTEMPTS | "coupon_attempts" + + + +## Enum: TimeFrameEnum + +Name | Value +---- | ----- +_1D | "1D" +_7D | "7D" +_30D | "30D" + + + diff --git a/docs/RoleV2ApplicationDetails.md b/docs/RoleV2ApplicationDetails.md index 6c293ab1..1c95cb96 100644 --- a/docs/RoleV2ApplicationDetails.md +++ b/docs/RoleV2ApplicationDetails.md @@ -10,7 +10,6 @@ Name | Type | Description | Notes **campaign** | **String** | Name of the campaign-related permission set for the given Application. | [optional] **draftCampaign** | **String** | Name of the draft campaign-related permission set for the given Application. | [optional] **tools** | **String** | Name of the tools-related permission set. | [optional] -**thresholds** | [**RolesV2Thresholds**](RolesV2Thresholds.md) | | [optional] diff --git a/docs/RoleV2Permissions.md b/docs/RoleV2Permissions.md index 270f4d01..fa6f910c 100644 --- a/docs/RoleV2Permissions.md +++ b/docs/RoleV2Permissions.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **permissionSets** | [**List<RoleV2PermissionSet>**](RoleV2PermissionSet.md) | List of grouped logical operations referenced by roles. | [optional] **roles** | [**RoleV2RolesGroup**](RoleV2RolesGroup.md) | | [optional] +**thresholds** | [**List<RolesV2Thresholds>**](RolesV2Thresholds.md) | Support user limits for actions that require admin approval within the given application. | [optional] diff --git a/docs/RolesV2Thresholds.md b/docs/RolesV2Thresholds.md index 367de202..6d1f7a61 100644 --- a/docs/RolesV2Thresholds.md +++ b/docs/RolesV2Thresholds.md @@ -6,6 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**loyaltyProgramId** | **Long** | Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | [optional] **loyaltyPointsLimit** | **Long** | Maximum number of loyalty points a support user can award without approval. | [optional] diff --git a/docs/RollbackAddedLoyaltyPointsEffectProps.md b/docs/RollbackAddedLoyaltyPointsEffectProps.md index 060f51d3..463efed3 100644 --- a/docs/RollbackAddedLoyaltyPointsEffectProps.md +++ b/docs/RollbackAddedLoyaltyPointsEffectProps.md @@ -2,18 +2,18 @@ # RollbackAddedLoyaltyPointsEffectProps -The properties specific to the \"rollbackAddedLoyaltyPoints\" effect. This gets triggered whenever previously a closed session with an addLoyaltyPoints effect is cancelled. +This effect is triggered in the following cases: - A session was cancelled in which loyalty points have been added. - A session was partially returned and loyalty point were added by the returned items. See [returning items](https://docs.talon.one/docs/dev/tutorials/partially-return-a-session). If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which items the loyalty points were rolled back for. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user for whom the loyalty points are rolled back. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points were originally added. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**programId** | **Long** | The ID of the loyalty program where the points were originally added. | -**subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were originally added. | +**programId** | **Long** | The ID of the loyalty program where these points were rolled back. | +**subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were rolled back. | **value** | [**BigDecimal**](BigDecimal.md) | The amount of points that were rolled back. | -**recipientIntegrationId** | **String** | The user for whom these points were originally added. | -**transactionUUID** | **String** | The identifier of 'deduction' entry added to the ledger as the `addLoyaltyPoints` effect is rolled back. | -**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item in the cart items for which the loyalty points were rolled back. | [optional] -**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | For cart items with `quantity` > 1, the sub-position indicates to which item the loyalty points were rolled back. | [optional] +**recipientIntegrationId** | **String** | The user for whom these points were rolled back. | +**transactionUUID** | **String** | The identifier of this loyalty point transaction. | +**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | (_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were rolled back. | [optional] +**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | (_Add points per cart item_ ) The index of the item unit in its line item. | [optional] **cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] diff --git a/docs/RollbackCouponEffectProps.md b/docs/RollbackCouponEffectProps.md index 8d2fde0b..bee14989 100644 --- a/docs/RollbackCouponEffectProps.md +++ b/docs/RollbackCouponEffectProps.md @@ -2,12 +2,12 @@ # RollbackCouponEffectProps -The properties specific to the \"rollbackCoupon\" effect. This gets triggered whenever previously closed session is now cancelled and a coupon redemption was cancelled on our internal usage limit counters. +This effect indicates that a coupon code redemption has been rolled back. The coupon becomes redeemable again. The effect is triggered when you [cancel](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state) a session where a coupon was accepted. See an example of use in the [cancelling a session tutorial](https://docs.talon.one/docs/dev/tutorials/roll-back-effects). ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**value** | **String** | The coupon code whose usage has been rolled back. | +**value** | **String** | The coupon code whose redemption has been rolled back. | diff --git a/docs/RollbackDeductedLoyaltyPointsEffectProps.md b/docs/RollbackDeductedLoyaltyPointsEffectProps.md index 4cc6f916..7a89b435 100644 --- a/docs/RollbackDeductedLoyaltyPointsEffectProps.md +++ b/docs/RollbackDeductedLoyaltyPointsEffectProps.md @@ -2,18 +2,18 @@ # RollbackDeductedLoyaltyPointsEffectProps -The properties specific to the \"rollbackDeductedLoyaltyPoints\" effect. This effect is triggered whenever a previously closed session is cancelled and a deductLoyaltyPoints effect was revoked. +This effect is triggered in the following cases: - A session is _cancelled_ and this session deducted loyalty points. The rollback action returns the redeemed loyalty points to the customer. - A session is impacted by a _partial return_. Only added loyalty points that are still **pending** are rolled back. - A session in which loyalty points were spent is reopened. See the [session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). If you set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/profile-based/profile-based-overview), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points are reimbursed. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **programId** | **Long** | The ID of the loyalty program where these points were reimbursed. | **subLedgerId** | **String** | The ID of the subledger within the loyalty program where these points were reimbursed. | -**value** | [**BigDecimal**](BigDecimal.md) | The amount of reimbursed points that were added. | +**value** | [**BigDecimal**](BigDecimal.md) | The amount of points that were reimbursed. | **recipientIntegrationId** | **String** | The user for whom these points were reimbursed. | -**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | Date after which the reimbursed points will be valid. | [optional] -**expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | Date after which the reimbursed points will expire. | [optional] -**transactionUUID** | **String** | The identifier of 'addition' entries added to the ledger as the `deductLoyaltyPoints` effect is rolled back. | +**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date after which the reimbursed points will be valid. | [optional] +**expiryDate** | [**OffsetDateTime**](OffsetDateTime.md) | The date after which the reimbursed points will expire. | [optional] +**transactionUUID** | **String** | The identifier of this loyalty point transaction. | **cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] diff --git a/docs/RollbackDiscountEffectProps.md b/docs/RollbackDiscountEffectProps.md index 604c0457..10013595 100644 --- a/docs/RollbackDiscountEffectProps.md +++ b/docs/RollbackDiscountEffectProps.md @@ -2,18 +2,18 @@ # RollbackDiscountEffectProps -The properties specific to the \"rollbackDiscount\" effect. This gets triggered whenever previously closed session is now cancelled or partially returned and a setDiscount effect was cancelled on our internal discount limit counters. +This effect indicates that a discounted session, cart item, or additional cost has been cancelled or partially returned. This effect can only happen when you set the status of a session to `cancel` or the status changes to `partially_returned`. If the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the specific item unit in its line item. See the example below. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name of the \"setDiscount\" effect that was rolled back. | -**value** | [**BigDecimal**](BigDecimal.md) | The value of the discount that was rolled back. | -**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item in the cart items for which the discount was rolled back. | [optional] -**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | For cart items with `quantity` > 1, the subposition returns the index of the item unit in its line item. | [optional] -**additionalCostId** | **Long** | The ID of the additional cost that was rolled back. | [optional] -**additionalCost** | **String** | The name of the additional cost that was rolled back. | [optional] -**scope** | **String** | The scope of the rolled back discount - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` | [optional] +**name** | **String** | The name of the discount effect that was rolled back. | +**value** | [**BigDecimal**](BigDecimal.md) | The monetary value of the discount that was rolled back. | +**cartItemPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item in the `cartItem` object whose discount was rolled back, or the unit containing the additional cost whose discount was rolled back. | [optional] +**cartItemSubPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item unit in its line item for which the discount was rolled back. | [optional] +**additionalCostId** | **Long** | _Only when rolling back [setDiscountPerAdditionalCost](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcost) and [setDiscountPerAdditionalCostPerItem](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcostperitem)_ The ID of the additional cost to be discounted. | [optional] +**additionalCost** | **String** | The API name of the additional cost whose discount was rolled back. | [optional] +**scope** | **String** | The scope of the rolled back discount. - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` | [optional] diff --git a/docs/RollbackIncreasedAchievementProgressEffectProps.md b/docs/RollbackIncreasedAchievementProgressEffectProps.md index 6d95ddf9..eccc8dd7 100644 --- a/docs/RollbackIncreasedAchievementProgressEffectProps.md +++ b/docs/RollbackIncreasedAchievementProgressEffectProps.md @@ -2,7 +2,7 @@ # RollbackIncreasedAchievementProgressEffectProps -The properties specific to the \"rollbackIncreasedAchievementProgress\" effect. This gets triggered whenever a closed session where the `increaseAchievementProgress` effect was triggered is cancelled. This is applicable only when the customer has not completed the achievement. +This effect indicates that the customer's progress in an achievement was rolled back. The Rule Engine triggers this effect when you cancel or [reopen a customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession) that previously validated the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect and triggered the [increaseAchievementProgress](https://docs.talon.one/docs/dev/integration-api/api-effects#increaseachievementprogress) API effect. The effect is also triggered for completed achievements if the **Allow progress rollback for completed achievements** setting is enabled. You can enable this through the [Campaign Manager](https://docs.talon.one/docs/product/achievements/manage-achievements) or the [Management API](https://docs.talon.one/management-api#tag/Achievements/operation/createAchievement) by setting the `achievementAllowRollbackAfterCompletion` property to `true`. This setting only applies to one-time and recurring on expiration achievements. ## Properties Name | Type | Description | Notes @@ -10,7 +10,7 @@ Name | Type | Description | Notes **achievementId** | **Long** | The internal ID of the achievement. | **achievementName** | **String** | The name of the achievement. | **progressTrackerId** | **Long** | The internal ID of the achievement progress tracker. | -**decreaseProgressBy** | [**BigDecimal**](BigDecimal.md) | The value by which the customer's current progress in the achievement is decreased. | +**decreaseProgressBy** | [**BigDecimal**](BigDecimal.md) | The value by which the customer's current progress in the achievement has decreased. | **currentProgress** | [**BigDecimal**](BigDecimal.md) | The current progress of the customer in the achievement. | **target** | [**BigDecimal**](BigDecimal.md) | The target value to complete the achievement. | diff --git a/docs/RollbackReferralEffectProps.md b/docs/RollbackReferralEffectProps.md index 9550b469..decd5515 100644 --- a/docs/RollbackReferralEffectProps.md +++ b/docs/RollbackReferralEffectProps.md @@ -2,12 +2,12 @@ # RollbackReferralEffectProps -The properties specific to the \"rollbackReferral\" effect. This gets triggered whenever previously closed session is now cancelled and a referral redemption was cancelled on our internal usage limit counters. +This effect indicates that the redemption of the referral code has been rolled back. It triggers when a closed session that redeemed a referral is gets cancelled. The code becomes redeemable again. For more information about session states, see [Managing states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**value** | **String** | The referral code whose usage has been rolled back. | +**value** | **String** | The referral code to be rolled back. | diff --git a/docs/RollbackUseRewardEffectProps.md b/docs/RollbackUseRewardEffectProps.md new file mode 100644 index 00000000..2dac3146 --- /dev/null +++ b/docs/RollbackUseRewardEffectProps.md @@ -0,0 +1,15 @@ + + +# RollbackUseRewardEffectProps + +This effect is triggered when a reward usage has been rolled back by a session cancellation. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The integration ID of the customer reward that was rolled back. | +**rewardId** | **Long** | The ID of the reward that was rolled back. | +**applicationId** | **Long** | The ID of the Application the reward belongs to. | + + + diff --git a/docs/RuleEligibility.md b/docs/RuleEligibility.md new file mode 100644 index 00000000..f49ed738 --- /dev/null +++ b/docs/RuleEligibility.md @@ -0,0 +1,15 @@ + + +# RuleEligibility + +The customer's eligibility for a rule in the current session, based on whether all of the rule's conditions were met. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**passed** | **Boolean** | Indicates whether the customer was eligible for the rule in the current session, based on whether all of the rule's conditions were met. | +**couponCode** | **String** | The coupon code used to check a customer's eligibility for the rule in the current session, if applicable. | [optional] +**details** | [**RuleEligibilityFailureDetails**](RuleEligibilityFailureDetails.md) | | [optional] + + + diff --git a/docs/RuleEligibilityFailureDetails.md b/docs/RuleEligibilityFailureDetails.md new file mode 100644 index 00000000..e1d99d1a --- /dev/null +++ b/docs/RuleEligibilityFailureDetails.md @@ -0,0 +1,29 @@ + + +# RuleEligibilityFailureDetails + +The details about why the customer was not eligible for the rule in the current session. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**failureCode** | [**FailureCodeEnum**](#FailureCodeEnum) | A code identifying why the customer was not eligible for the rule in the current session. | +**couponID** | **Long** | The ID of the coupon that was being evaluated when the rule failed. | [optional] +**couponValue** | **String** | The coupon code that was being evaluated when the rule failed. | [optional] +**referralID** | **Long** | The ID of the referral that was being evaluated when the rule failed. | [optional] +**referralValue** | **String** | The referral code that was being evaluated when the rule failed. | [optional] +**conditionIndex** | **Long** | The index of the condition that caused the rule to fail. | [optional] +**effectIndex** | **Long** | The index of the effect that caused the rule to fail. | [optional] +**details** | **String** | Additional details about the failure. | + + + +## Enum: FailureCodeEnum + +Name | Value +---- | ----- +CONDITION_NOT_MET | "CONDITION_NOT_MET" +EFFECT_FAILED | "EFFECT_FAILED" + + + diff --git a/docs/RuleFailureReason.md b/docs/RuleFailureReason.md index 04830bd8..bab61836 100644 --- a/docs/RuleFailureReason.md +++ b/docs/RuleFailureReason.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **couponValue** | **String** | The code of the coupon that was being evaluated at the time of the rule failure. | [optional] **referralID** | **Long** | The ID of the referral that was being evaluated at the time of the rule failure. | [optional] **referralValue** | **String** | The code of the referral that was being evaluated at the time of the rule failure. | [optional] +**rewardId** | **Long** | The ID of the reward that was being evaluated at the time of the rule failure. | [optional] +**rewardIntegrationId** | **String** | The integration ID of the reward that was being evaluated at the time of the rule failure. | [optional] **ruleIndex** | **Long** | The index of the rule that failed within the ruleset. | **ruleName** | **String** | The name of the rule that failed within the ruleset. | **conditionIndex** | **Long** | The index of the condition that failed. | [optional] diff --git a/docs/RuleMetadataEligibility.md b/docs/RuleMetadataEligibility.md new file mode 100644 index 00000000..60cc3b33 --- /dev/null +++ b/docs/RuleMetadataEligibility.md @@ -0,0 +1,16 @@ + + +# RuleMetadataEligibility + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **String** | A short description of the rule. | +**displayName** | **String** | A customer-facing name for the rule. | [optional] +**displayDescription** | **String** | A customer-facing description that explains the details of the rule. For example, this property can contain details about eligibility requirements, reward timelines, or terms and conditions. | [optional] +**relatedData** | **String** | Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. | [optional] +**eligibility** | [**List<RuleEligibility>**](RuleEligibility.md) | | + + + diff --git a/docs/RuleV2.md b/docs/RuleV2.md new file mode 100644 index 00000000..fcc6ebd3 --- /dev/null +++ b/docs/RuleV2.md @@ -0,0 +1,17 @@ + + +# RuleV2 + +Shared fields common to all V2 rule types. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier of the rule. | [optional] +**parentId** | **String** | ID of the parent rule, if any. | [optional] +**title** | **String** | A short description of the rule. | +**description** | **String** | A longer description of the rule. | [optional] +**blocks** | **List<Object>** | The condition and effect blocks that make up this rule. | + + + diff --git a/docs/RulesetV2.md b/docs/RulesetV2.md new file mode 100644 index 00000000..8f55d804 --- /dev/null +++ b/docs/RulesetV2.md @@ -0,0 +1,23 @@ + + +# RulesetV2 + +Ruleset in the V2 JSON block format. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | Internal ID of this entity. | [optional] [readonly] +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time this entity was created. | [optional] [readonly] +**userId** | **Long** | The ID of the user that created this ruleset. | [optional] [readonly] +**campaignId** | **Long** | The ID of the campaign that owns this entity. | [optional] [readonly] +**templateId** | **Long** | The ID of the campaign template that owns this entity. | [optional] [readonly] +**activatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp indicating when this ruleset was activated. | [optional] [readonly] +**promotionRules** | [**List<RuleV2>**](RuleV2.md) | Set of promotion rules. | +**strikethroughRules** | [**List<RuleV2>**](RuleV2.md) | Set of strikethrough rules. | [optional] +**selectors** | [**List<Selector>**](Selector.md) | Variable bindings of type selector. | [optional] [readonly] +**bundles** | [**List<Bundle>**](Bundle.md) | Variable bindings of type bundle. | [optional] [readonly] +**parameters** | [**List<TemplateParameter>**](TemplateParameter.md) | Variable bindings of type template parameter. | [optional] [readonly] + + + diff --git a/docs/SamlConnection.md b/docs/SamlConnection.md index 170c5267..732db417 100644 --- a/docs/SamlConnection.md +++ b/docs/SamlConnection.md @@ -8,6 +8,7 @@ A SAML 2.0 connection. Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **assertionConsumerServiceURL** | **String** | The location where the SAML assertion is sent with a HTTP POST. | +**certificateExpiry** | [**OffsetDateTime**](OffsetDateTime.md) | The expiry date of the X.509 certificate. | [optional] **accountId** | **Long** | The ID of the account that owns this entity. | **name** | **String** | ID of the SAML service. | **enabled** | **Boolean** | Determines if this SAML connection active. | diff --git a/docs/ScalarCheckAttributeBlock.md b/docs/ScalarCheckAttributeBlock.md new file mode 100644 index 00000000..a7498b6d --- /dev/null +++ b/docs/ScalarCheckAttributeBlock.md @@ -0,0 +1,38 @@ + + +# ScalarCheckAttributeBlock + +Variant of `CheckAttributeBlock` for operators that compare an attribute against a single value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The comparison operator applied to the attribute. | [optional] +**value** | [**Object**](.md) | The comparison value for this operator. | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +EQUALS | "equals" +NOT_EQUALS_ | "not(equals)" +LESSTHAN | "lessThan" +LESSTHANOREQUAL | "lessThanOrEqual" +GREATERTHAN | "greaterThan" +GREATERTHANOREQUAL | "greaterThanOrEqual" +CONTAINS | "contains" +NOT_CONTAINS_ | "not(contains)" +MATCHESREGEXP | "matchesRegexp" +STARTSWITH | "startsWith" +ENDSWITH | "endsWith" +ONEOF | "oneOf" +NOT_ONEOF_ | "not(oneOf)" +INCOLLECTION | "inCollection" +NOT_INCOLLECTION_ | "not(inCollection)" +AFTER | "after" +BEFORE | "before" + + + diff --git a/docs/ScimBaseUserName.md b/docs/ScimBaseUserName.md index d46c823c..6fa04d68 100644 --- a/docs/ScimBaseUserName.md +++ b/docs/ScimBaseUserName.md @@ -2,7 +2,7 @@ # ScimBaseUserName -The components of the user’s real name. +The components of the user's real name. ## Properties Name | Type | Description | Notes diff --git a/docs/SelectSelectorStep.md b/docs/SelectSelectorStep.md new file mode 100644 index 00000000..bb27b8de --- /dev/null +++ b/docs/SelectSelectorStep.md @@ -0,0 +1,37 @@ + + +# SelectSelectorStep + +Picks a subset of the items by count, range, or exact position. The `operator` determines which additional fields are required: - `many` selects items from `from` (`start` or `end`) and is limited by `count`. - `between` selects items between integer indices `from` and `to`. - `one` selects the single item at `index`. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `select`. | +**operator** | [**OperatorEnum**](#OperatorEnum) | The selection operator applied to the items. | +**from** | [**Object**](.md) | The starting value of the selection. For the `many` operator this is the string `start` or `end`; for the `between` operator this is an integer start index. No discriminator is needed since the string and integer branches are distinguishable by JSON type alone. | [optional] +**to** | **Integer** | The end index for the `between` operator. The item at this index is not included. | [optional] +**count** | **Integer** | The maximum number of items to select for the `many` operator. | [optional] +**index** | **Integer** | The exact position of the item to select for the `one` operator. | [optional] +**partial** | **Boolean** | Indicates if the step returns fewer items than requested when the source list is shorter than the range needs. Always `true` for the `many` and `between` operators; not present for `one`, which fails instead of returning a partial result. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +SELECT | "select" + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +MANY | "many" +BETWEEN | "between" +ONE | "one" + + + diff --git a/docs/Selector.md b/docs/Selector.md new file mode 100644 index 00000000..62aa1475 --- /dev/null +++ b/docs/Selector.md @@ -0,0 +1,24 @@ + + +# Selector + +A named pipeline of steps (filter, sort, map, etc.) that filters or transforms a list of cart items. Replaces `cartItemFilter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the selector binding. | +**type** | [**TypeEnum**](#TypeEnum) | A binding of type `selector`. | +**source** | **String** | The attribute path the pipeline draws items from. | +**steps** | **List<Object>** | Ordered pipeline steps applied to the source items. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +SELECTOR | "selector" + + + diff --git a/docs/SelectorValueMapRef.md b/docs/SelectorValueMapRef.md new file mode 100644 index 00000000..07883a0d --- /dev/null +++ b/docs/SelectorValueMapRef.md @@ -0,0 +1,13 @@ + + +# SelectorValueMapRef + +A reference to a value map by its internal ID. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of the referenced value map. | + + + diff --git a/docs/SetDiscountEffectProps.md b/docs/SetDiscountEffectProps.md index c57a8447..c05b7514 100644 --- a/docs/SetDiscountEffectProps.md +++ b/docs/SetDiscountEffectProps.md @@ -2,15 +2,15 @@ # SetDiscountEffectProps -The properties specific to the \"setDiscount\" effect. This gets triggered whenever a validated rule contained a \"set discount\" effect. This is a discount that should be applied on the scope of defined with it. +This effect indicates that a discount should be set on the total shopping cart value of the current order with the given label and amount. The discount should overwrite any existing discount with the same name. The most recent integration state update always returns the latest values for **all** effects, effectively overwriting any previous effects. Enabling [partial discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches `0`. Use the `desiredValue` property to identify the original value of the discount. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name / description of this discount | -**value** | [**BigDecimal**](BigDecimal.md) | The total monetary value of the discount. | -**scope** | **String** | The scope which the discount was applied on, can be one of (cartItems,additionalCosts,sessionTotal). | [optional] -**desiredValue** | [**BigDecimal**](BigDecimal.md) | The original value of the discount. | [optional] +**name** | **String** | The name or description of this discount. | +**value** | [**BigDecimal**](BigDecimal.md) | The monetary value of the effective discount. | +**scope** | **String** | What the discount applies to. Possible values: - `cartItems`: Discount on the price of the items. - `additionalCosts`: Discount on the [additional costs](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the items. - `sessionTotal`: Discount on the total value of the customer session. **Note:** [Cascading discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#cascading-discounts) must be enabled for this property to be returned. | [optional] +**desiredValue** | [**BigDecimal**](BigDecimal.md) | _(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations. | [optional] diff --git a/docs/SetDiscountPerAdditionalCostEffectProps.md b/docs/SetDiscountPerAdditionalCostEffectProps.md index d94246cf..7df30d5c 100644 --- a/docs/SetDiscountPerAdditionalCostEffectProps.md +++ b/docs/SetDiscountPerAdditionalCostEffectProps.md @@ -2,16 +2,16 @@ # SetDiscountPerAdditionalCostEffectProps -The properties specific to the \"setDiscountPerAdditionalCost\" effect. This gets triggered whenever a validated rule contained a \"set per additional cost discount\" effect. This is a discount that should be applied on a specific additional cost. +This effect indicates that a discount that should be applied on a specific additional cost. It is triggered whenever a rule containing a **Discount additional cost** effect is validated. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name / description of this discount | -**additionalCostId** | **Long** | The ID of the additional cost. | -**additionalCost** | **String** | The name of the additional cost. | -**value** | [**BigDecimal**](BigDecimal.md) | The total monetary value of the discount. | -**desiredValue** | [**BigDecimal**](BigDecimal.md) | The original value of the discount. | [optional] +**name** | **String** | The name of the discount. | +**additionalCostId** | **Long** | The identifier of the additional cost. | +**additionalCost** | **String** | The API name of the additional cost. | +**value** | [**BigDecimal**](BigDecimal.md) | The monetary value of the discount to apply. | +**desiredValue** | [**BigDecimal**](BigDecimal.md) | _(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations. | [optional] diff --git a/docs/SetDiscountPerAdditionalCostPerItemEffectProps.md b/docs/SetDiscountPerAdditionalCostPerItemEffectProps.md index c67eb5dd..707fc952 100644 --- a/docs/SetDiscountPerAdditionalCostPerItemEffectProps.md +++ b/docs/SetDiscountPerAdditionalCostPerItemEffectProps.md @@ -2,18 +2,18 @@ # SetDiscountPerAdditionalCostPerItemEffectProps -The properties specific to the \"setDiscountPerAdditionalCostPerItem\" effect. This gets triggered whenever a validated rule contained a \"set discount per additional cost per item\" effect. This is a discount that should be applied on a specific additional cost in a specific item. +This effect indicates that a discount of a specific additional cost within a specific item should be applied. It gets triggered whenever a rule containing a **Discount additional cost per item** effect is validated. Use this effect when **all** items in the cart have an additional cost. If one of more items do not have an additional cost, the rule will fail. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name / description of this discount | -**additionalCostId** | **Long** | The ID of the additional cost. | -**value** | [**BigDecimal**](BigDecimal.md) | The total monetary value of the discount. | -**position** | [**BigDecimal**](BigDecimal.md) | The index of the item in the cart item list containing the additional cost to be discounted. | -**subPosition** | [**BigDecimal**](BigDecimal.md) | For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. | [optional] -**additionalCost** | **String** | The name of the additional cost. | -**desiredValue** | [**BigDecimal**](BigDecimal.md) | Only with [partial discounts enabled](https://docs.talon.one/docs/product/campaigns/campaign-evaluation/#partial-discounts). Represents the monetary value of the discount to be applied to additional discount without considering budget limitations. | [optional] +**name** | **String** | The description of this discount. `#number` is appended to the name. It is equal to the `position` property. | +**additionalCostId** | **Long** | The identifier of the additional cost to be discounted. | +**value** | [**BigDecimal**](BigDecimal.md) | The monetary value of the effective discount applied to the item's additional cost. | +**position** | [**BigDecimal**](BigDecimal.md) | The index of the item in the `cartItem` object containing the additional cost that this discount applies to. | +**subPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item unit in its line item. | [optional] +**additionalCost** | **String** | The API name of the additional cost to be discounted. | +**desiredValue** | [**BigDecimal**](BigDecimal.md) | _[(Partial discounts enabled only)](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts)_. The monetary value of the discount to be applied to the additional cost without considering budget limitations. | [optional] diff --git a/docs/SetDiscountPerItemEffectProps.md b/docs/SetDiscountPerItemEffectProps.md index 6c41b043..c48d3884 100644 --- a/docs/SetDiscountPerItemEffectProps.md +++ b/docs/SetDiscountPerItemEffectProps.md @@ -2,23 +2,23 @@ # SetDiscountPerItemEffectProps -The properties specific to the `setDiscountPerItem` effect, triggered whenever a validated rule contained a \"set per item discount\" effect. This is a discount that will be applied either on a specific item, on a specific item + additional cost or on all additional costs per item. This depends on the chosen scope. +This effect schema is returned when you use the **Discount individual items**, **Discount individual items pro rata**, or **Discount individual item in bundles** effect in a rule. It indicates that a discount per item should be applied on the specific item specified in the effect. The properties it contains depends on: - Whether you used a pro rata effect or not. - Whether you used an effect with bundles or not. - Whether the partial discount feature is enabled. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The name of the discount. Contains a hashtag character indicating the index of the position of the item the discount applies to. It is identical to the value of the `position` property. | -**value** | [**BigDecimal**](BigDecimal.md) | The total monetary value of the discount. | -**position** | [**BigDecimal**](BigDecimal.md) | The index of the item in the cart items list on which this discount should be applied. | -**subPosition** | [**BigDecimal**](BigDecimal.md) | For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. | [optional] -**desiredValue** | [**BigDecimal**](BigDecimal.md) | The original value of the discount. | [optional] -**scope** | **String** | The scope of the discount: - `additionalCosts`: The discount applies to all the additional costs of the item. - `itemTotal`: The discount applies to the price of the item + the additional costs of the item. - `price`: The discount applies to the price of the item. | [optional] -**totalDiscount** | [**BigDecimal**](BigDecimal.md) | The total discount given if this effect is a result of a prorated discount. | [optional] -**desiredTotalDiscount** | [**BigDecimal**](BigDecimal.md) | The original total discount to give if this effect is a result of a prorated discount. | [optional] -**bundleIndex** | **Long** | The position of the bundle in a list of item bundles created from the same bundle definition. | [optional] -**bundleName** | **String** | The name of the bundle definition. | [optional] -**targetedItemPosition** | [**BigDecimal**](BigDecimal.md) | The index of the targeted bundle item on which the applied discount is based. | [optional] -**targetedItemSubPosition** | [**BigDecimal**](BigDecimal.md) | The sub-position of the targeted bundle item on which the applied discount is based. | [optional] +**name** | **String** | The description of this discount. `#number` is equal to the `position` property. | +**value** | [**BigDecimal**](BigDecimal.md) | The monetary value of the effective discount applied to the item. | +**position** | [**BigDecimal**](BigDecimal.md) | The index of the item in the `cartItem` object on which this discount should be applied. | +**subPosition** | [**BigDecimal**](BigDecimal.md) | The index of the item unit in its line item. | [optional] +**desiredValue** | [**BigDecimal**](BigDecimal.md) | _(Partial discounts enabled only)_ The monetary value of the discount to be applied to the item without considering budget limitations. | [optional] +**scope** | **String** | What the discount applies to. Possible values: - `price`: discount on the price of the item. - `additionalCosts`: discount on the [additional cost](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the item. - `itemTotal`: discount on the sum of price + additional cost of the item. | [optional] +**totalDiscount** | [**BigDecimal**](BigDecimal.md) | _(Pro rata discounts only)_ The monetary value of the total effective discount | [optional] +**desiredTotalDiscount** | [**BigDecimal**](BigDecimal.md) | _(Pro rata discounts only)_ The monetary value of the total discount to be applied without considering budget limitations | [optional] +**bundleIndex** | **Long** | _(Discounts with bundles only)_ The position of the specific item bundle in the list of bundles created from the same bundle definition. | [optional] +**bundleName** | **String** | _(Discounts with bundles only)_ The name of the bundle definition. | [optional] +**targetedItemPosition** | [**BigDecimal**](BigDecimal.md) | _(Discounting individual item in bundles only)_ The index of the targeted bundle item on which the applied discount is based. | [optional] +**targetedItemSubPosition** | [**BigDecimal**](BigDecimal.md) | _(Discounting individual item in bundles only)_ The sub-position of the targeted bundle item on which the applied discount is based. | [optional] **excludedFromPriceHistory** | **Boolean** | When set to `true`, the applied discount is excluded from the item's price history. | [optional] diff --git a/docs/SetLoyaltyPointsExpiryDateEffectProps.md b/docs/SetLoyaltyPointsExpiryDateEffectProps.md index 0c003185..350b50a5 100644 --- a/docs/SetLoyaltyPointsExpiryDateEffectProps.md +++ b/docs/SetLoyaltyPointsExpiryDateEffectProps.md @@ -2,7 +2,7 @@ # SetLoyaltyPointsExpiryDateEffectProps -The properties specific to the \"setLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"set expiry date\" effect. The current expiry date gets set to the date given in the effect. +This effect updates the expiry date of all active, pending, and unlimited point transactions to a specific date. ## Properties Name | Type | Description | Notes diff --git a/docs/ShowBundleMetadataEffectProps.md b/docs/ShowBundleMetadataEffectProps.md index c156468f..cf49bb5f 100644 --- a/docs/ShowBundleMetadataEffectProps.md +++ b/docs/ShowBundleMetadataEffectProps.md @@ -2,7 +2,7 @@ # ShowBundleMetadataEffectProps -This effect is **deprecated**. The properties specific to the \"ShowBundleMetadata\" effect. This effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle. +This effect is **deprecated**. The `ShowBundleMetadata` effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle. ## Properties Name | Type | Description | Notes diff --git a/docs/ShowNotificationBlock.md b/docs/ShowNotificationBlock.md new file mode 100644 index 00000000..2095ab70 --- /dev/null +++ b/docs/ShowNotificationBlock.md @@ -0,0 +1,20 @@ + + +# ShowNotificationBlock + +A block that displays a notification to the customer with a configurable type, title, and optional body message. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**notificationType** | **String** | The type of notification to display. | +**title** | **String** | The notification heading shown to the customer. | +**body** | **String** | The notification body text. Supports template placeholders (e.g. \"{{$Session.Total}}\") evaluated at rule execution time. | [optional] +**onFailure** | **List<Object>** | Blocks evaluated when this block fails or returns false. | [optional] +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + diff --git a/docs/ShowNotificationEffectProps.md b/docs/ShowNotificationEffectProps.md index de631aa1..ea215b4e 100644 --- a/docs/ShowNotificationEffectProps.md +++ b/docs/ShowNotificationEffectProps.md @@ -2,14 +2,14 @@ # ShowNotificationEffectProps -The properties specific to the \"showNotification\" effect. This gets triggered whenever a validated rule contained a \"show notification\" effect. +You can use notifications to inform customers of certain events. There are four types of notification messages: - `Info` - `Offer` - `Error` - `Misc` It is up to you to use the Rule Builder to decide why and when to show notifications. Notifications can be used as both rule effects and failure effects. A common use case is to display the notification at the top of the cart view in your web app. You can use the notification type to vary the styling of the notification message. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**notificationType** | **String** | The type of notification that should be shown (e.g. error/warning/info). | -**title** | **String** | Title of the notification. | -**body** | **String** | Body of the notification. | +**notificationType** | **String** | The type of notification. | +**title** | **String** | The title of the notification. | +**body** | **String** | The body of the notification. | diff --git a/docs/SortSelectorStep.md b/docs/SortSelectorStep.md new file mode 100644 index 00000000..70f577b7 --- /dev/null +++ b/docs/SortSelectorStep.md @@ -0,0 +1,22 @@ + + +# SortSelectorStep + +Sorts items by one or more field expressions. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | A step discriminator of type `sort`. | +**fields** | [**List<SortSelectorStepField>**](SortSelectorStepField.md) | One or more fields to sort by, applied in order. Each field has its own direction. | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +SORT | "sort" + + + diff --git a/docs/SortSelectorStepField.md b/docs/SortSelectorStepField.md new file mode 100644 index 00000000..a7810d7b --- /dev/null +++ b/docs/SortSelectorStepField.md @@ -0,0 +1,22 @@ + + +# SortSelectorStepField + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**expression** | **String** | The attribute path the items are sorted by. | +**direction** | [**DirectionEnum**](#DirectionEnum) | The sort direction for this field. | + + + +## Enum: DirectionEnum + +Name | Value +---- | ----- +ASC | "asc" +DESC | "desc" + + + diff --git a/docs/StartAchievementProgressEffectProps.md b/docs/StartAchievementProgressEffectProps.md new file mode 100644 index 00000000..fdc4a50b --- /dev/null +++ b/docs/StartAchievementProgressEffectProps.md @@ -0,0 +1,18 @@ + + +# StartAchievementProgressEffectProps + +This effect indicates that the customer's progress in an achievement was started during the current session. The progress value is set to 0. It is triggered when a rule using the [Start achievement progress](https://docs.talon.one/docs/product/rules/effects/use-effects#start-achievement-progress) effect is successfully validated. This effect only marks the start of progress tracking. It can fire together with `increaseAchievementProgress` when progress starts and increases at the same time. In that case, both effects share the same `progressTrackerId`, `startDate`, and `endDate`. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), each iteration also gets its own `startDate` and `endDate`. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**achievementId** | **Long** | The ID of the achievement. | +**achievementName** | **String** | The name of the achievement. | +**progressTrackerId** | **Long** | The ID of the customer's progress tracker for this achievement. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. | [optional] +**target** | [**BigDecimal**](BigDecimal.md) | The target value to complete the achievement. | +**startDate** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp at which the customer's progress started. | +**endDate** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp at which this progress period ends. Only returned for achievements that have a fixed end date. [On-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements) have no end date. | [optional] + + + diff --git a/docs/StrikethroughLabelingNotification.md b/docs/StrikethroughLabelingNotification.md index fbbfd1d6..81ccaff0 100644 --- a/docs/StrikethroughLabelingNotification.md +++ b/docs/StrikethroughLabelingNotification.md @@ -7,7 +7,7 @@ The strikethrough labels notification for an application. Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**version** | [**VersionEnum**](#VersionEnum) | The version of the strikethrough pricing notification. | [optional] +**version** | [**VersionEnum**](#VersionEnum) | The version of the strikethrough pricing notification. Set for **scheduled** strikethrough pricing updates only. | [optional] **validFrom** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp at which the strikethrough pricing update becomes valid. Set for **scheduled** strikethrough pricing updates (version: v2) only. | [optional] **applicationId** | **Long** | The ID of the Application to which the catalog items labels belongs. | **currentBatch** | **Long** | The batch number of the notification. Notifications might be sent in different batches. | diff --git a/docs/StrikethroughSetDiscountPerItemEffectProps.md b/docs/StrikethroughSetDiscountPerItemEffectProps.md index d0dc9cb1..c1c6ebd2 100644 --- a/docs/StrikethroughSetDiscountPerItemEffectProps.md +++ b/docs/StrikethroughSetDiscountPerItemEffectProps.md @@ -7,9 +7,9 @@ setDiscountPerItem effect in strikethrough pricing payload. Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | effect name. | -**value** | [**Object**](.md) | discount value. | -**excludedFromPriceHistory** | **Boolean** | | [optional] +**name** | **String** | The effect name. | +**value** | [**Object**](.md) | The discount value. | +**excludedFromPriceHistory** | **Boolean** | When set to `true`, the applied discount is excluded from the item's price history. | [optional] diff --git a/docs/StrikethroughSetDiscountPerItemMemberEffectProps.md b/docs/StrikethroughSetDiscountPerItemMemberEffectProps.md index 17c8ec8e..0e6b2fa6 100644 --- a/docs/StrikethroughSetDiscountPerItemMemberEffectProps.md +++ b/docs/StrikethroughSetDiscountPerItemMemberEffectProps.md @@ -7,8 +7,8 @@ setDiscountPerItem member effect in strikethrough pricing payload. Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | effect name. | -**value** | [**Object**](.md) | discount value. | +**name** | **String** | The effect name. | +**value** | [**Object**](.md) | The discount value. | diff --git a/docs/SupportCustomerProfile.md b/docs/SupportCustomerProfile.md new file mode 100644 index 00000000..9cf531f7 --- /dev/null +++ b/docs/SupportCustomerProfile.md @@ -0,0 +1,16 @@ + + +# SupportCustomerProfile + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of the customer profile. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The time the customer profile was created. | +**integrationId** | **String** | The integration ID set by your integration layer. | +**attributes** | [**Object**](.md) | Arbitrary properties associated with this item. | +**applicationMemberships** | [**List<ApplicationMembership>**](ApplicationMembership.md) | The applications the customer belongs to. | + + + diff --git a/docs/SupportRequest.md b/docs/SupportRequest.md new file mode 100644 index 00000000..d1716eee --- /dev/null +++ b/docs/SupportRequest.md @@ -0,0 +1,50 @@ + + +# SupportRequest + +Summary of a support request created by a customer support agent. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | Identifier of the support request. | +**applicationId** | **Long** | Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL. | +**campaignId** | **Long** | Identifier of the campaign where the coupon or gift card is created. | [optional] +**loyaltyProgramId** | **Long** | Identifier of the loyalty program where the points are added or deducted. | [optional] +**subledgerId** | **Long** | Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically. | [optional] +**createdByUser** | **String** | Email address of the customer support agent who created the support request. | +**createdAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the request was made. | +**customerProfileId** | **String** | Integration ID of the customer profile linked to the support request. | +**requestType** | [**RequestTypeEnum**](#RequestTypeEnum) | Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. | +**requestValue** | **Float** | Requested monetary balance of the gift card or the number of loyalty points to be added or deducted. | [optional] +**requestNote** | **String** | Notes attached to the support request. | +**requestStatus** | [**RequestStatusEnum**](#RequestStatusEnum) | Current status of the support request. | +**processedAt** | [**OffsetDateTime**](OffsetDateTime.md) | Timestamp when the request was approved or rejected. | [optional] +**processingNote** | **String** | Notes attached by the admin when rejecting or approving a request. | [optional] +**processedByUser** | **String** | Email address of the admin who approved or rejected the support request. | [optional] +**couponCode** | **String** | Coupon code associated with the approved support request. | [optional] + + + +## Enum: RequestTypeEnum + +Name | Value +---- | ----- +GIFT_CARD | "gift_card" +PERSONAL_COUPON | "personal_coupon" +LOYALTY_POINTS_ADDED | "loyalty_points_added" +LOYALTY_POINTS_DEDUCTED | "loyalty_points_deducted" + + + +## Enum: RequestStatusEnum + +Name | Value +---- | ----- +PENDING_APPROVAL | "pending_approval" +APPROVED | "approved" +REJECTED | "rejected" +EXPIRED | "expired" + + + diff --git a/docs/SupportRequestInput.md b/docs/SupportRequestInput.md new file mode 100644 index 00000000..a7e7123c --- /dev/null +++ b/docs/SupportRequestInput.md @@ -0,0 +1,30 @@ + + +# SupportRequestInput + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applicationId** | **Long** | Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL. | +**campaignId** | **Long** | Identifier of the campaign where the coupon or gift card is created. | [optional] +**loyaltyProgramId** | **Long** | Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | [optional] +**subledgerId** | **Long** | Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically. | [optional] +**customerProfileId** | **String** | Integration ID of the customer profile linked to the support request. | +**requestType** | [**RequestTypeEnum**](#RequestTypeEnum) | Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. | +**requestValue** | **Float** | Requested monetary balance of the gift card or the number of loyalty points to be added or deducted. | [optional] +**requestNote** | **String** | Notes attached to the support request. | + + + +## Enum: RequestTypeEnum + +Name | Value +---- | ----- +GIFT_CARD | "gift_card" +PERSONAL_COUPON | "personal_coupon" +LOYALTY_POINTS_ADDED | "loyalty_points_added" +LOYALTY_POINTS_DEDUCTED | "loyalty_points_deducted" + + + diff --git a/docs/TalangAttribute.md b/docs/TalangAttribute.md index 5125f78e..1992977b 100644 --- a/docs/TalangAttribute.md +++ b/docs/TalangAttribute.md @@ -42,6 +42,8 @@ REFERRAL | "Referral" SESSION | "Session" STORE | "Store" ACHIEVEMENTS | "Achievements" +ADVANCEDEVENT | "AdvancedEvent" +ADVANCEDEVENTCONNECTEDSESSION | "AdvancedEventConnectedSession" diff --git a/docs/TemplateParameter.md b/docs/TemplateParameter.md new file mode 100644 index 00000000..eda1e5d2 --- /dev/null +++ b/docs/TemplateParameter.md @@ -0,0 +1,19 @@ + + +# TemplateParameter + +A named parameter definition that exposes a configurable value in a campaign template. Replaces `templateParameter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the template parameter. | +**value** | [**Object**](.md) | The parameter's bound value. Its type depends on the `valueType`. | +**valueType** | **String** | The data type of the value, derived from the bound expression (for example `number`, `string`, `boolean`, `percent`, `time`, `(list string)`, or `(list number)`). | +**minValue** | [**BigDecimal**](BigDecimal.md) | The minimum value allowed for this parameter. | [optional] +**maxValue** | [**BigDecimal**](BigDecimal.md) | The maximum value allowed for this parameter. | [optional] +**description** | **String** | A human-readable description of the parameter shown when creating campaigns from the template. | +**attribute** | **Long** | The ID of the attribute linked to this parameter. Omitted when the parameter is not linked to an attribute. | [optional] + + + diff --git a/docs/TriggerCustomEffectBlock.md b/docs/TriggerCustomEffectBlock.md new file mode 100644 index 00000000..c3e03716 --- /dev/null +++ b/docs/TriggerCustomEffectBlock.md @@ -0,0 +1,19 @@ + + +# TriggerCustomEffectBlock + +A block that triggers a configured custom effect and passes its required parameters. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**customEffect** | [**TriggerCustomEffectBlockCustomEffect**](TriggerCustomEffectBlockCustomEffect.md) | | +**params** | [**Object**](.md) | The custom effect's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another. | [optional] +**target** | [**TriggerCustomEffectBlockTarget**](TriggerCustomEffectBlockTarget.md) | | +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + diff --git a/docs/TriggerCustomEffectBlockCustomEffect.md b/docs/TriggerCustomEffectBlockCustomEffect.md new file mode 100644 index 00000000..0884c9a5 --- /dev/null +++ b/docs/TriggerCustomEffectBlockCustomEffect.md @@ -0,0 +1,15 @@ + + +# TriggerCustomEffectBlockCustomEffect + +The custom effect to trigger. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The unique identifier of the custom effect. | +**name** | **String** | The name of the custom effect, as used in API requests. | +**title** | **String** | The display name of the custom effect. | + + + diff --git a/docs/TriggerCustomEffectBlockTarget.md b/docs/TriggerCustomEffectBlockTarget.md new file mode 100644 index 00000000..93ab7f6b --- /dev/null +++ b/docs/TriggerCustomEffectBlockTarget.md @@ -0,0 +1,26 @@ + + +# TriggerCustomEffectBlockTarget + +The target scope of this effect. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | The scope the custom effect applies to: - `cart` applies once to the whole cart. - `allItems` applies once per cart item. - `selector` applies once per item matched by the named selector. - `globalFilter` applies once per item matched by the named global item filter. - `bundle` applies once per item in the named bundle. | +**name** | **String** | The name of the targeted selector or bundle. Only set when `type` is `selector`, `globalFilter`, or `bundle`. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +CART | "cart" +ALLITEMS | "allItems" +SELECTOR | "selector" +GLOBALFILTER | "globalFilter" +BUNDLE | "bundle" + + + diff --git a/docs/TriggerWebhookBlock.md b/docs/TriggerWebhookBlock.md new file mode 100644 index 00000000..63430abc --- /dev/null +++ b/docs/TriggerWebhookBlock.md @@ -0,0 +1,18 @@ + + +# TriggerWebhookBlock + +A block that triggers a configured webhook and passes its required parameters. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**webhook** | [**TriggerWebhookBlockWebhook**](TriggerWebhookBlockWebhook.md) | | +**params** | [**Object**](.md) | The webhook's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another. | [optional] +**onError** | [**Map<String, List<Object>>**](List.md) | Named error handlers evaluated when a specific error occurs. | [optional] + + + diff --git a/docs/TriggerWebhookBlockWebhook.md b/docs/TriggerWebhookBlockWebhook.md new file mode 100644 index 00000000..175f612c --- /dev/null +++ b/docs/TriggerWebhookBlockWebhook.md @@ -0,0 +1,14 @@ + + +# TriggerWebhookBlockWebhook + +The webhook to trigger. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The unique identifier of the webhook. | +**title** | **String** | The display name of the webhook. | + + + diff --git a/docs/TriggerWebhookEffectProps.md b/docs/TriggerWebhookEffectProps.md index f9211f76..e079b606 100644 --- a/docs/TriggerWebhookEffectProps.md +++ b/docs/TriggerWebhookEffectProps.md @@ -2,13 +2,13 @@ # TriggerWebhookEffectProps -The properties specific to the \"triggerWebhook\" effect. This gets triggered whenever a validated rule contained a \"trigger webhook\" effect. This is communicated as an FYI and should usually not require action on your side. +This effect is triggered when a rule containing a [webhook effect](https://docs.talon.one/docs/product/rules/effects/available-effects#webhooks) is validated. The details are shared with you for your information only. It usually doesn't require an action on your side. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**webhookId** | [**BigDecimal**](BigDecimal.md) | The ID of the webhook that was triggered. | -**webhookName** | **String** | The name of the webhook that was triggered. | +**webhookId** | [**BigDecimal**](BigDecimal.md) | The internal ID of the webhook. | +**webhookName** | **String** | The name of the webhook. | diff --git a/docs/UnaryCheckAttributeBlock.md b/docs/UnaryCheckAttributeBlock.md new file mode 100644 index 00000000..3c3d6027 --- /dev/null +++ b/docs/UnaryCheckAttributeBlock.md @@ -0,0 +1,26 @@ + + +# UnaryCheckAttributeBlock + +Variant of `CheckAttributeBlock` for operators that test a property of the attribute itself with no comparison value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The unary operator applied to the attribute. These operators require no comparison value. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +EMPTY | "empty" +NOT_EMPTY_ | "not(empty)" +EXISTS | "exists" +NOT_EXISTS_ | "not(exists)" +ISTRUE | "isTrue" +ISFALSE | "isFalse" + + + diff --git a/docs/UnlockRewardEffectProps.md b/docs/UnlockRewardEffectProps.md new file mode 100644 index 00000000..5b784392 --- /dev/null +++ b/docs/UnlockRewardEffectProps.md @@ -0,0 +1,18 @@ + + +# UnlockRewardEffectProps + +The properties specific to the \"unlockReward\" effect. This gets triggered whenever a validated rule unlocks a reward for a customer profile. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The integration ID assigned to the customer reward unlock. | +**rewardId** | **Long** | The internal ID of the reward that was unlocked. | +**applicationId** | **Long** | The internal ID of the application the reward belongs to. | +**profileIntegrationId** | **String** | The integration ID of the customer profile that unlocked the reward. | +**unlockedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The time the reward was unlocked. | +**cardIdentifier** | **String** | The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. | [optional] + + + diff --git a/docs/UpdateAchievementProgressBlock.md b/docs/UpdateAchievementProgressBlock.md new file mode 100644 index 00000000..9009156d --- /dev/null +++ b/docs/UpdateAchievementProgressBlock.md @@ -0,0 +1,26 @@ + + +# UpdateAchievementProgressBlock + +A block that updates the progress of a customer in an achievement. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | | +**value** | **String** | The value to update the progress by. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities. | +**achievement** | [**UpdateAchievementProgressBlockAchievement**](UpdateAchievementProgressBlockAchievement.md) | | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +INCREASEBY | "increaseBy" + + + diff --git a/docs/UpdateAchievementProgressBlockAchievement.md b/docs/UpdateAchievementProgressBlockAchievement.md new file mode 100644 index 00000000..e856ab98 --- /dev/null +++ b/docs/UpdateAchievementProgressBlockAchievement.md @@ -0,0 +1,16 @@ + + +# UpdateAchievementProgressBlockAchievement + +The achievement to update. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the achievement. | +**name** | **String** | The internal name of the achievement used in API requests. | +**title** | **String** | The display name of the achievement in the Campaign Manager. | +**target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | + + + diff --git a/docs/UpdateAchievementV2.md b/docs/UpdateAchievementV2.md index f4cf12a6..7005dcc2 100644 --- a/docs/UpdateAchievementV2.md +++ b/docs/UpdateAchievementV2.md @@ -6,19 +6,17 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **String** | The internal name of the achievement used in API requests. **Note**: The name should start with a letter. This cannot be changed after the achievement has been created. | [optional] -**title** | **String** | The display name for the achievement in the Campaign Manager. | [optional] -**description** | **String** | A description of the achievement. | [optional] -**target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | [optional] +**name** | **String** | The internal name of the achievement used in API requests. **Note**: The name should start with a letter. This cannot be changed after the achievement has been created. | +**title** | **String** | The display name for the achievement in the Campaign Manager. | +**description** | **String** | A description of the achievement. | +**target** | [**BigDecimal**](BigDecimal.md) | The required number of actions or the transactional milestone to complete the achievement. | **period** | **String** | The relative duration after which the achievement ends and resets for a particular customer profile. **Note**: The `period` does not start when the achievement is created. The period is a **positive real number** followed by one letter indicating the time unit. Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can also round certain units down to the beginning of period and up to the end of period.: - `_D` for rounding down days only. Signifies the start of the day. Example: `30D_D` - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. Example: `23W_U` **Note**: You can either use the round down and round up option or set an absolute period. | [optional] **recurrencePolicy** | [**RecurrencePolicyEnum**](#RecurrencePolicyEnum) | 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. | [optional] **activationPolicy** | [**ActivationPolicyEnum**](#ActivationPolicyEnum) | 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. | [optional] **fixedStartDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's start date when `activationPolicy` is set to `fixed_schedule`. **Note:** It must be an RFC3339 timestamp string. | [optional] **endDate** | [**OffsetDateTime**](OffsetDateTime.md) | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It must be an RFC3339 timestamp string. | [optional] **allowRollbackAfterCompletion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | [optional] -**sandbox** | **Boolean** | Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. | [optional] -**subscribedApplications** | **List<Long>** | A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. | [optional] -**timezone** | **String** | A string containing an IANA timezone descriptor. | [optional] +**subscribedApplications** | **List<Long>** | A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. | diff --git a/docs/UpdateApplication.md b/docs/UpdateApplication.md index 41a96bdc..53a6b418 100644 --- a/docs/UpdateApplication.md +++ b/docs/UpdateApplication.md @@ -23,6 +23,7 @@ Name | Type | Description | Notes **defaultEvaluationGroupId** | **Long** | The ID of the default campaign evaluation group to which new campaigns will be added unless a different group is selected when creating the campaign. | [optional] **defaultCartItemFilterId** | **Long** | The ID of the default Cart-Item-Filter for this application. | [optional] **enableCampaignStateManagement** | **Boolean** | Indicates whether the campaign staging and revisions feature is enabled for the Application. **Important:** After this feature is enabled, it cannot be disabled. | [optional] +**bestPriorPriceSettings** | [**BestPriorPriceSettings**](BestPriorPriceSettings.md) | | [optional] diff --git a/docs/UpdateAttributeEffectProps.md b/docs/UpdateAttributeEffectProps.md index b3a29243..61e377b8 100644 --- a/docs/UpdateAttributeEffectProps.md +++ b/docs/UpdateAttributeEffectProps.md @@ -2,13 +2,13 @@ # UpdateAttributeEffectProps -The properties specific to the \"updateAttribute\" effect. This gets triggered whenever a validated rule contained an \"update an attribute\" effect. +This effect indicates that a rule containing an [Update attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) or [Update cart item attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) was validated. You should update the value of the attribute in your system based on the content of the returned effect. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**path** | **String** | The exact path of the attribute that was updated. | -**value** | [**Object**](.md) | The new value of this attribute. The value can be of the following types: - boolean - location - number - string - time - list of any of those types | +**path** | **String** | The entity type and the attribute name. | +**value** | [**Object**](.md) | The new value of the attribute. | diff --git a/docs/UpdateAttributeValueBlock.md b/docs/UpdateAttributeValueBlock.md new file mode 100644 index 00000000..63de7a05 --- /dev/null +++ b/docs/UpdateAttributeValueBlock.md @@ -0,0 +1,34 @@ + + +# UpdateAttributeValueBlock + +A block that sets or updates an attribute. The `type` may be empty for [built-in attributes](https://docs.talon.one/docs/dev/concepts/attributes). +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The update operation applied to the attribute. | +**attribute** | [**UpdateAttributeValueBlockAttribute**](UpdateAttributeValueBlockAttribute.md) | | +**value** | [**Object**](.md) | The value of the attribute. Omitted when operator is set to `toggle`. | [optional] +**target** | [**UpdateAttributeValueBlockTarget**](UpdateAttributeValueBlockTarget.md) | | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +SETTO | "setTo" +INCREASEBY | "increaseBy" +DECREASEBY | "decreaseBy" +MULTIPLYBY | "multiplyBy" +DIVIDEBY | "divideBy" +TOGGLE | "toggle" +LATERBY | "laterBy" +EARLIERBY | "earlierBy" + + + diff --git a/docs/UpdateAttributeValueBlockAttribute.md b/docs/UpdateAttributeValueBlockAttribute.md new file mode 100644 index 00000000..e4798487 --- /dev/null +++ b/docs/UpdateAttributeValueBlockAttribute.md @@ -0,0 +1,17 @@ + + +# UpdateAttributeValueBlockAttribute + +The attribute being updated. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The internal ID of the attribute. Reverts to `0` when the attribute is deleted or does not exist. | +**entity** | **String** | The entity type that owns the attribute. Reverts to an empty string when the attribute is deleted or does not exist. | +**name** | **String** | The attribute name as used in API requests. | +**title** | **String** | The human-readable name of the attribute. | +**type** | **String** | The data type of the attribute. | + + + diff --git a/docs/UpdateAttributeValueBlockTarget.md b/docs/UpdateAttributeValueBlockTarget.md new file mode 100644 index 00000000..2cbe4320 --- /dev/null +++ b/docs/UpdateAttributeValueBlockTarget.md @@ -0,0 +1,31 @@ + + +# UpdateAttributeValueBlockTarget + +The entity or item scope that this effect operates on. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | [**TypeEnum**](#TypeEnum) | Identifies the target scope of the attribute update. | +**name** | **String** | Identifies the name of the target when its type is set to `selector` or `globalFilter`. | [optional] + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +SESSION | "session" +PROFILE | "profile" +ADVOCATEPROFILE | "advocateProfile" +COUPON | "coupon" +REFERRAL | "referral" +EVENT | "event" +LOYALTYCARD | "loyaltyCard" +ALLITEMS | "allItems" +SELECTOR | "selector" +GLOBALFILTER | "globalFilter" + + + diff --git a/docs/UpdateAudience.md b/docs/UpdateAudience.md index 2643a56a..b5be1ac8 100644 --- a/docs/UpdateAudience.md +++ b/docs/UpdateAudience.md @@ -7,6 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **name** | **String** | The human-friendly display name for this audience. | +**subscribedApplicationsIds** | **List<Long>** | A list of the IDs of the Applications that are connected to this audience. | [optional] diff --git a/docs/UpdateAudienceMembershipBlock.md b/docs/UpdateAudienceMembershipBlock.md new file mode 100644 index 00000000..2b77f319 --- /dev/null +++ b/docs/UpdateAudienceMembershipBlock.md @@ -0,0 +1,36 @@ + + +# UpdateAudienceMembershipBlock + +A block that adds a customer to or removes them from an audience. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | Unique identifier for this block. | [optional] [readonly] +**type** | **String** | Identifies the block variant and determines which additional properties are present in it. | +**tags** | **List<String>** | Semantic labels attached to this block. | [optional] [readonly] +**operator** | [**OperatorEnum**](#OperatorEnum) | The action to perform. | +**profile** | [**ProfileEnum**](#ProfileEnum) | The customer profile to add or remove from the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. | +**audience** | [**UpdateAudienceMembershipBlockAudience**](UpdateAudienceMembershipBlockAudience.md) | | + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +ADD | "add" +REMOVE | "remove" + + + +## Enum: ProfileEnum + +Name | Value +---- | ----- +CURRENT | "Current" +ADVOCATE | "Advocate" + + + diff --git a/docs/UpdateAudienceMembershipBlockAudience.md b/docs/UpdateAudienceMembershipBlockAudience.md new file mode 100644 index 00000000..e12738d1 --- /dev/null +++ b/docs/UpdateAudienceMembershipBlockAudience.md @@ -0,0 +1,16 @@ + + +# UpdateAudienceMembershipBlockAudience + +The audience to add the customer to or remove them from. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **Long** | The ID of the audience. | +**name** | **String** | The display name of the audience. | +**integration** | **String** | The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. | [optional] +**integrationId** | **String** | The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. | [optional] + + + diff --git a/docs/UpdateCampaign.md b/docs/UpdateCampaign.md index afe4e861..6358d09d 100644 --- a/docs/UpdateCampaign.md +++ b/docs/UpdateCampaign.md @@ -47,6 +47,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/UpdateCampaignTemplate.md b/docs/UpdateCampaignTemplate.md index b81bc83d..4a07fccb 100644 --- a/docs/UpdateCampaignTemplate.md +++ b/docs/UpdateCampaignTemplate.md @@ -48,6 +48,7 @@ LOYALTY | "loyalty" GIVEAWAYS | "giveaways" STRIKETHROUGH | "strikethrough" ACHIEVEMENTS | "achievements" +ADVANCEDEVENTS | "advancedEvents" diff --git a/docs/UpdateExperiment.md b/docs/UpdateExperiment.md index b4fda975..d8bf10a0 100644 --- a/docs/UpdateExperiment.md +++ b/docs/UpdateExperiment.md @@ -8,6 +8,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **isVariantAssignmentExternal** | **Boolean** | The source of the assignment. - false - The variant assignment is handled internally by Talon.One. - true - The variant assignment is handled externally. | **campaign** | [**UpdateCampaign**](UpdateCampaign.md) | | +**goalType** | [**GoalTypeEnum**](#GoalTypeEnum) | The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the current value is preserved. | [optional] +**goalDescription** | **String** | A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the current value is preserved. | [optional] + + + +## Enum: GoalTypeEnum + +Name | Value +---- | ----- +OTHER | "other" +MAXIMIZE_REVENUE | "maximize_revenue" +MAXIMIZE_ITEMS_SOLD | "maximize_items_sold" +OPTIMIZE_DISCOUNT_EFFICIENCY | "optimize_discount_efficiency" diff --git a/docs/UpdateReward.md b/docs/UpdateReward.md new file mode 100644 index 00000000..41b1088e --- /dev/null +++ b/docs/UpdateReward.md @@ -0,0 +1,27 @@ + + +# UpdateReward + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the reward. | +**description** | **String** | A description of the reward. | [optional] +**status** | [**StatusEnum**](#StatusEnum) | The status of the reward. | +**eligibilityConditions** | [**Rule**](Rule.md) | | [optional] +**rule** | [**Rule**](Rule.md) | | [optional] +**bindings** | [**List<Binding>**](Binding.md) | A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. | [optional] +**pointsRequired** | [**List<RewardPointsRequired>**](RewardPointsRequired.md) | The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** - Objects with an `id` are updated. - Objects without an `id` are created. - Existing objects omitted from the payload are deleted. | [optional] + + + +## Enum: StatusEnum + +Name | Value +---- | ----- +ACTIVE | "active" +INACTIVE | "inactive" + + + diff --git a/docs/UpdateRiskNotification.md b/docs/UpdateRiskNotification.md new file mode 100644 index 00000000..efc15ae6 --- /dev/null +++ b/docs/UpdateRiskNotification.md @@ -0,0 +1,46 @@ + + +# UpdateRiskNotification + +Data for updating a risk notification. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**entity** | [**EntityEnum**](#EntityEnum) | The entity type to analyze within the given time frame. | +**activity** | [**ActivityEnum**](#ActivityEnum) | The activity metric to analyze within the given entity. | +**timeFrame** | [**TimeFrameEnum**](#TimeFrameEnum) | The rolling time window for risk evaluation. | +**active** | **Boolean** | Indicates whether this risk notification is active. | + + + +## Enum: EntityEnum + +Name | Value +---- | ----- +PROFILE | "customer_profile" +SESSION | "customer_session" + + + +## Enum: ActivityEnum + +Name | Value +---- | ----- +LOYALTY_POINTS_EARNED | "loyalty_points_earned" +DISCOUNTED_AMOUNT | "discounted_amount" +COMPLETED_ORDERS | "completed_orders" +COUPON_ATTEMPTS | "coupon_attempts" + + + +## Enum: TimeFrameEnum + +Name | Value +---- | ----- +_1D | "1D" +_7D | "7D" +_30D | "30D" + + + diff --git a/docs/UpdateSupportRequest.md b/docs/UpdateSupportRequest.md new file mode 100644 index 00000000..31edf58e --- /dev/null +++ b/docs/UpdateSupportRequest.md @@ -0,0 +1,23 @@ + + +# UpdateSupportRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**requestStatus** | [**RequestStatusEnum**](#RequestStatusEnum) | Current status of the support request. | +**processingNote** | **String** | Notes attached by the admin when rejecting or approving a request. | [optional] + + + +## Enum: RequestStatusEnum + +Name | Value +---- | ----- +APPROVED | "approved" +REJECTED | "rejected" +EXPIRED | "expired" + + + diff --git a/docs/UseRewardEffectProps.md b/docs/UseRewardEffectProps.md new file mode 100644 index 00000000..0b228ef4 --- /dev/null +++ b/docs/UseRewardEffectProps.md @@ -0,0 +1,15 @@ + + +# UseRewardEffectProps + +This effect is triggered when a rule that uses a customer's unlocked reward is validated during session evaluation. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**integrationId** | **String** | The integration ID of the customer reward that was used. | +**rewardId** | **Long** | The ID of the reward that was used. | +**applicationId** | **Long** | The ID of the Application the reward belongs to. | + + + diff --git a/docs/WebhookAuthenticationBaseBasic.md b/docs/WebhookAuthenticationBaseBasic.md new file mode 100644 index 00000000..d0b19ba3 --- /dev/null +++ b/docs/WebhookAuthenticationBaseBasic.md @@ -0,0 +1,23 @@ + + +# WebhookAuthenticationBaseBasic + +Authenticates the webhook with Basic HTTP authentication. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the webhook authentication. | +**type** | [**TypeEnum**](#TypeEnum) | A webhook authentication discriminator of type `basic`. | +**data** | [**WebhookAuthenticationDataBasic**](WebhookAuthenticationDataBasic.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +BASIC | "basic" + + + diff --git a/docs/WebhookAuthenticationBaseCustom.md b/docs/WebhookAuthenticationBaseCustom.md new file mode 100644 index 00000000..af025c06 --- /dev/null +++ b/docs/WebhookAuthenticationBaseCustom.md @@ -0,0 +1,23 @@ + + +# WebhookAuthenticationBaseCustom + +Authenticates the webhook with a custom set of HTTP headers. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | The name of the webhook authentication. | +**type** | [**TypeEnum**](#TypeEnum) | A webhook authentication discriminator of type `custom`. | +**data** | [**WebhookAuthenticationDataCustom**](WebhookAuthenticationDataCustom.md) | | + + + +## Enum: TypeEnum + +Name | Value +---- | ----- +CUSTOM | "custom" + + + diff --git a/docs/WillAwardGiveawayEffectProps.md b/docs/WillAwardGiveawayEffectProps.md index fc643303..b8fe6dd6 100644 --- a/docs/WillAwardGiveawayEffectProps.md +++ b/docs/WillAwardGiveawayEffectProps.md @@ -2,14 +2,14 @@ # WillAwardGiveawayEffectProps -The properties specific to the \"awardGiveaway\" effect when the session is not closed yet. This effect replaces \"awardGiveaway\" only when updating a session with any state other than \"closed\". This is to ensure no giveaway codes are leaked when they are still not guaranteed to be awarded. +The equivalent of the `awardGiveaway` effect but returned when updating a session with any state other than `closed`. This ensures no giveaway codes are leaked when they are still not guaranteed to be awarded. For more information about session states, see [Manage the session's state](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state). ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**poolId** | **Long** | The ID of the giveaways pool the code will be taken from. | -**poolName** | **String** | The name of the giveaways pool the code will be taken from. | -**recipientIntegrationId** | **String** | The integration ID of the profile that will be awarded the giveaway. | +**poolId** | **Long** | The internal ID of the giveaway pool. | +**poolName** | **String** | The name of the giveaway pool. | +**recipientIntegrationId** | **String** | The integration ID of the customer that receives the giveaway. | diff --git a/docs/WithinCheckAttributeBlock.md b/docs/WithinCheckAttributeBlock.md new file mode 100644 index 00000000..f44f7665 --- /dev/null +++ b/docs/WithinCheckAttributeBlock.md @@ -0,0 +1,27 @@ + + +# WithinCheckAttributeBlock + +Variant of `CheckAttributeBlock` for the `within` and `not(within)` operators, which require both a start and end value. +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**operator** | [**OperatorEnum**](#OperatorEnum) | The range comparison operator. Must be `within` or `not(within)`. | [optional] +**start** | [**Object**](.md) | The start value for the `within` operator. | +**end** | [**Object**](.md) | The end value for the `within` operator. | +**startInclusive** | **Boolean** | When `true`, the `start` value is included in the range for the `within` operator. | [optional] +**endInclusive** | **Boolean** | When `true`, the `end` value is included in the range for the `within` operator. | [optional] +**timezoneInsensitive** | **Boolean** | Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. | [optional] + + + +## Enum: OperatorEnum + +Name | Value +---- | ----- +WITHIN | "within" +NOT_WITHIN_ | "not(within)" + + + diff --git a/pom.xml b/pom.xml index 6bcce658..8f13b4b7 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ talon-one-client jar talon-one-client - 15.0.0 + 16.0.0 https://github.com/talon-one/maven-artefacts Talon.One unified JAVA SDK. It allows for programmatic access to the integration and management API with their respective authentication strategies diff --git a/src/main/java/one/talon/ApiClient.java b/src/main/java/one/talon/ApiClient.java index 976f2da5..9170d07b 100644 --- a/src/main/java/one/talon/ApiClient.java +++ b/src/main/java/one/talon/ApiClient.java @@ -132,7 +132,7 @@ private void init() { json = new JSON(); // Set default User-Agent. - setUserAgent("OpenAPI-Generator/15.0.0/java"); + setUserAgent("OpenAPI-Generator/16.0.0/java"); authentications = new HashMap(); } diff --git a/src/main/java/one/talon/JSON.java b/src/main/java/one/talon/JSON.java index 5469e3e9..4761a04f 100644 --- a/src/main/java/one/talon/JSON.java +++ b/src/main/java/one/talon/JSON.java @@ -52,6 +52,24 @@ public class JSON { public static GsonBuilder createGson() { GsonFireBuilder fireBuilder = new GsonFireBuilder() + .registerTypeSelector(CatalogAction.class, new TypeSelector() { + @Override + public Class getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = new HashMap(); + classByDiscriminatorValue.put("CatalogAction", CatalogAction.class); + return getClassByDiscriminator(classByDiscriminatorValue, + getDiscriminatorValue(readElement, "type")); + } + }) + .registerTypeSelector(CheckAttributeBlock.class, new TypeSelector() { + @Override + public Class getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = new HashMap(); + classByDiscriminatorValue.put("CheckAttributeBlock", CheckAttributeBlock.class); + return getClassByDiscriminator(classByDiscriminatorValue, + getDiscriminatorValue(readElement, "operator")); + } + }) ; GsonBuilder builder = fireBuilder.createGsonBuilder(); return builder; diff --git a/src/main/java/one/talon/api/IntegrationApi.java b/src/main/java/one/talon/api/IntegrationApi.java index 501708f3..4e024bd2 100644 --- a/src/main/java/one/talon/api/IntegrationApi.java +++ b/src/main/java/one/talon/api/IntegrationApi.java @@ -32,6 +32,7 @@ import one.talon.model.Audience; import one.talon.model.BestPriorPrice; import one.talon.model.BestPriorPriceRequest; +import java.math.BigDecimal; import one.talon.model.Catalog; import one.talon.model.CatalogSyncRequest; import one.talon.model.Coupon; @@ -43,6 +44,7 @@ import one.talon.model.DeleteLoyaltyTransactionsRequest; import one.talon.model.ErrorResponse; import one.talon.model.ErrorResponseWithStatus; +import one.talon.model.EventV3; import one.talon.model.GenerateLoyaltyCard; import one.talon.model.InlineResponse200; import one.talon.model.InlineResponse2001; @@ -50,14 +52,18 @@ import one.talon.model.InlineResponse2003; import one.talon.model.InlineResponse2004; import one.talon.model.InlineResponse2005; +import one.talon.model.InlineResponse20056; import one.talon.model.InlineResponse2006; import one.talon.model.InlineResponse2007; import one.talon.model.InlineResponse201; import one.talon.model.IntegrationCustomerSessionResponse; import one.talon.model.IntegrationEventV2Request; import one.talon.model.IntegrationEventV2Response; +import one.talon.model.IntegrationEventV3Request; +import one.talon.model.IntegrationEventV3Response; import one.talon.model.IntegrationRequest; import one.talon.model.IntegrationStateV2; +import one.talon.model.IntegrationUnlockRewardRequest; import one.talon.model.LoyaltyBalancesWithTiers; import one.talon.model.LoyaltyCard; import one.talon.model.LoyaltyCardBalances; @@ -71,6 +77,7 @@ import one.talon.model.Referral; import one.talon.model.ReopenSessionResponse; import one.talon.model.ReturnIntegrationRequest; +import one.talon.model.RewardUnlockRejection; import one.talon.model.UpdateAudience; import java.lang.reflect.Type; @@ -970,6 +977,7 @@ public okhttp3.Call deleteAudienceMembershipsV2Async(Long audienceId, final ApiC 400 Bad request - 401 Unauthorized - 404 Not found - + 409 Conflict. The audience is used by one or more experiments. Each `errors[].source.resource` value contains the Campaign Manager path of a blocking experiment. - */ public okhttp3.Call deleteAudienceV2Call(Long audienceId, final ApiCallback _callback) throws ApiException { @@ -1018,7 +1026,7 @@ private okhttp3.Call deleteAudienceV2ValidateBeforeCall(Long audienceId, final A /** * Delete audience - * Delete an audience created by a third-party integration. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). + * Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). The audience isn't deleted if any experiment variant uses it. The response identifies each blocking experiment by its Campaign Manager path. * @param audienceId The ID of the audience. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -1028,6 +1036,7 @@ private okhttp3.Call deleteAudienceV2ValidateBeforeCall(Long audienceId, final A 400 Bad request - 401 Unauthorized - 404 Not found - + 409 Conflict. The audience is used by one or more experiments. Each `errors[].source.resource` value contains the Campaign Manager path of a blocking experiment. - */ public void deleteAudienceV2(Long audienceId) throws ApiException { @@ -1036,7 +1045,7 @@ public void deleteAudienceV2(Long audienceId) throws ApiException { /** * Delete audience - * Delete an audience created by a third-party integration. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). + * Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). The audience isn't deleted if any experiment variant uses it. The response identifies each blocking experiment by its Campaign Manager path. * @param audienceId The ID of the audience. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -1047,6 +1056,7 @@ public void deleteAudienceV2(Long audienceId) throws ApiException { 400 Bad request - 401 Unauthorized - 404 Not found - + 409 Conflict. The audience is used by one or more experiments. Each `errors[].source.resource` value contains the Campaign Manager path of a blocking experiment. - */ public ApiResponse deleteAudienceV2WithHttpInfo(Long audienceId) throws ApiException { @@ -1056,7 +1066,7 @@ public ApiResponse deleteAudienceV2WithHttpInfo(Long audienceId) throws Ap /** * Delete audience (asynchronously) - * Delete an audience created by a third-party integration. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). + * Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). The audience isn't deleted if any experiment variant uses it. The response identifies each blocking experiment by its Campaign Manager path. * @param audienceId The ID of the audience. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -1068,6 +1078,7 @@ public ApiResponse deleteAudienceV2WithHttpInfo(Long audienceId) throws Ap 400 Bad request - 401 Unauthorized - 404 Not found - + 409 Conflict. The audience is used by one or more experiments. Each `errors[].source.resource` value contains the Campaign Manager path of a blocking experiment. - */ public okhttp3.Call deleteAudienceV2Async(Long audienceId, final ApiCallback _callback) throws ApiException { @@ -1938,6 +1949,7 @@ public okhttp3.Call getCustomerAchievementsAsync(String integrationId, List 404 Not found - */ - public okhttp3.Call getCustomerInventoryCall(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getCustomerInventoryCall(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, Boolean unlockedRewards, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -1982,6 +1994,10 @@ public okhttp3.Call getCustomerInventoryCall(String integrationId, Boolean profi localVarQueryParams.addAll(localVarApiClient.parameterToPair("achievements", achievements)); } + if (unlockedRewards != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("unlockedRewards", unlockedRewards)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -2004,7 +2020,7 @@ public okhttp3.Call getCustomerInventoryCall(String integrationId, Boolean profi } @SuppressWarnings("rawtypes") - private okhttp3.Call getCustomerInventoryValidateBeforeCall(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getCustomerInventoryValidateBeforeCall(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, Boolean unlockedRewards, final ApiCallback _callback) throws ApiException { // verify the required parameter 'integrationId' is set if (integrationId == null) { @@ -2012,7 +2028,7 @@ private okhttp3.Call getCustomerInventoryValidateBeforeCall(String integrationId } - okhttp3.Call localVarCall = getCustomerInventoryCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, _callback); + okhttp3.Call localVarCall = getCustomerInventoryCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards, _callback); return localVarCall; } @@ -2027,6 +2043,7 @@ private okhttp3.Call getCustomerInventoryValidateBeforeCall(String integrationId * @param loyalty Set to `true` to include loyalty information in the response. (optional) * @param giveaways Set to `true` to include giveaways information in the response. (optional) * @param achievements Set to `true` to include achievement information in the response. (optional) + * @param unlockedRewards Set to `true` to include `unlocked` rewards that have not been `used` in the response. (optional) * @return CustomerInventory * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -2037,8 +2054,8 @@ private okhttp3.Call getCustomerInventoryValidateBeforeCall(String integrationId 404 Not found - */ - public CustomerInventory getCustomerInventory(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements) throws ApiException { - ApiResponse localVarResp = getCustomerInventoryWithHttpInfo(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements); + public CustomerInventory getCustomerInventory(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, Boolean unlockedRewards) throws ApiException { + ApiResponse localVarResp = getCustomerInventoryWithHttpInfo(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards); return localVarResp.getData(); } @@ -2052,6 +2069,7 @@ public CustomerInventory getCustomerInventory(String integrationId, Boolean prof * @param loyalty Set to `true` to include loyalty information in the response. (optional) * @param giveaways Set to `true` to include giveaways information in the response. (optional) * @param achievements Set to `true` to include achievement information in the response. (optional) + * @param unlockedRewards Set to `true` to include `unlocked` rewards that have not been `used` in the response. (optional) * @return ApiResponse<CustomerInventory> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -2062,8 +2080,8 @@ public CustomerInventory getCustomerInventory(String integrationId, Boolean prof 404 Not found - */ - public ApiResponse getCustomerInventoryWithHttpInfo(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements) throws ApiException { - okhttp3.Call localVarCall = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, null); + public ApiResponse getCustomerInventoryWithHttpInfo(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, Boolean unlockedRewards) throws ApiException { + okhttp3.Call localVarCall = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -2078,6 +2096,7 @@ public ApiResponse getCustomerInventoryWithHttpInfo(String in * @param loyalty Set to `true` to include loyalty information in the response. (optional) * @param giveaways Set to `true` to include giveaways information in the response. (optional) * @param achievements Set to `true` to include achievement information in the response. (optional) + * @param unlockedRewards Set to `true` to include `unlocked` rewards that have not been `used` in the response. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -2089,16 +2108,16 @@ public ApiResponse getCustomerInventoryWithHttpInfo(String in 404 Not found - */ - public okhttp3.Call getCustomerInventoryAsync(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getCustomerInventoryAsync(String integrationId, Boolean profile, Boolean referrals, Boolean coupons, Boolean loyalty, Boolean giveaways, Boolean achievements, Boolean unlockedRewards, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, _callback); + okhttp3.Call localVarCall = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** * Build call for getCustomerSession - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2157,7 +2176,7 @@ private okhttp3.Call getCustomerSessionValidateBeforeCall(String customerSession /** * Get customer session * Get the details of the given customer session. You can get the same data via other endpoints that also apply changes, which can help you save requests and increase performance. See: - [Update customer session](#tag/Customer-sessions/operation/updateCustomerSessionV2) - [Update customer profile](#tag/Customer-profiles/operation/updateCustomerProfileV2) - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @return IntegrationCustomerSessionResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -2176,7 +2195,7 @@ public IntegrationCustomerSessionResponse getCustomerSession(String customerSess /** * Get customer session * Get the details of the given customer session. You can get the same data via other endpoints that also apply changes, which can help you save requests and increase performance. See: - [Update customer session](#tag/Customer-sessions/operation/updateCustomerSessionV2) - [Update customer profile](#tag/Customer-profiles/operation/updateCustomerProfileV2) - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @return ApiResponse<IntegrationCustomerSessionResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -2196,7 +2215,7 @@ public ApiResponse getCustomerSessionWithHtt /** * Get customer session (asynchronously) * Get the details of the given customer session. You can get the same data via other endpoints that also apply changes, which can help you save requests and increase performance. See: - [Update customer session](#tag/Customer-sessions/operation/updateCustomerSessionV2) - [Update customer profile](#tag/Customer-profiles/operation/updateCustomerProfileV2) - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -2215,6 +2234,121 @@ public okhttp3.Call getCustomerSessionAsync(String customerSessionId, final ApiC localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for getEventV3 + * @param integrationId The unique ID of the advanced event. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + +
Status Code Description Response Headers
200 OK -
404 Not found -
+ */ + public okhttp3.Call getEventV3Call(String integrationId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v3/events/{integrationId}" + .replaceAll("\\{" + "integrationId" + "\\}", localVarApiClient.escapeString(integrationId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getEventV3ValidateBeforeCall(String integrationId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'integrationId' is set + if (integrationId == null) { + throw new ApiException("Missing the required parameter 'integrationId' when calling getEventV3(Async)"); + } + + + okhttp3.Call localVarCall = getEventV3Call(integrationId, _callback); + return localVarCall; + + } + + /** + * Get advanced event + * Retrieve an advanced event by its identifier. + * @param integrationId The unique ID of the advanced event. (required) + * @return EventV3 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + +
Status Code Description Response Headers
200 OK -
404 Not found -
+ */ + public EventV3 getEventV3(String integrationId) throws ApiException { + ApiResponse localVarResp = getEventV3WithHttpInfo(integrationId); + return localVarResp.getData(); + } + + /** + * Get advanced event + * Retrieve an advanced event by its identifier. + * @param integrationId The unique ID of the advanced event. (required) + * @return ApiResponse<EventV3> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + +
Status Code Description Response Headers
200 OK -
404 Not found -
+ */ + public ApiResponse getEventV3WithHttpInfo(String integrationId) throws ApiException { + okhttp3.Call localVarCall = getEventV3ValidateBeforeCall(integrationId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Get advanced event (asynchronously) + * Retrieve an advanced event by its identifier. + * @param integrationId The unique ID of the advanced event. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + +
Status Code Description Response Headers
200 OK -
404 Not found -
+ */ + public okhttp3.Call getEventV3Async(String integrationId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getEventV3ValidateBeforeCall(integrationId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for getLoyaltyBalances * @param loyaltyProgramId 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. (required) @@ -2928,12 +3062,12 @@ public okhttp3.Call getLoyaltyCardTransactionsAsync(Long loyaltyProgramId, Strin * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param status Filter points based on their status. (optional, default to active) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) - * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) - * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) + * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) + * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) + * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2946,7 +3080,7 @@ public okhttp3.Call getLoyaltyCardTransactionsAsync(Long loyaltyProgramId, Strin 404 Not found - */ - public okhttp3.Call getLoyaltyProgramProfilePointsCall(Long loyaltyProgramId, String integrationId, String status, String subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getLoyaltyProgramProfilePointsCall(Long loyaltyProgramId, String integrationId, String status, List subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -2961,7 +3095,7 @@ public okhttp3.Call getLoyaltyProgramProfilePointsCall(Long loyaltyProgramId, St } if (subledgerId != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("subledgerId", subledgerId)); + localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "subledgerId", subledgerId)); } if (customerSessionIDs != null) { @@ -3006,7 +3140,7 @@ public okhttp3.Call getLoyaltyProgramProfilePointsCall(Long loyaltyProgramId, St } @SuppressWarnings("rawtypes") - private okhttp3.Call getLoyaltyProgramProfilePointsValidateBeforeCall(Long loyaltyProgramId, String integrationId, String status, String subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getLoyaltyProgramProfilePointsValidateBeforeCall(Long loyaltyProgramId, String integrationId, String status, List subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { // verify the required parameter 'loyaltyProgramId' is set if (loyaltyProgramId == null) { @@ -3030,12 +3164,12 @@ private okhttp3.Call getLoyaltyProgramProfilePointsValidateBeforeCall(Long loyal * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param status Filter points based on their status. (optional, default to active) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) - * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) - * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) + * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) + * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) + * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) * @return InlineResponse2007 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3047,7 +3181,7 @@ private okhttp3.Call getLoyaltyProgramProfilePointsValidateBeforeCall(Long loyal 404 Not found - */ - public InlineResponse2007 getLoyaltyProgramProfilePoints(Long loyaltyProgramId, String integrationId, String status, String subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort) throws ApiException { + public InlineResponse2007 getLoyaltyProgramProfilePoints(Long loyaltyProgramId, String integrationId, String status, List subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort) throws ApiException { ApiResponse localVarResp = getLoyaltyProgramProfilePointsWithHttpInfo(loyaltyProgramId, integrationId, status, subledgerId, customerSessionIDs, transactionUUIDs, pageSize, skip, sort); return localVarResp.getData(); } @@ -3058,12 +3192,12 @@ public InlineResponse2007 getLoyaltyProgramProfilePoints(Long loyaltyProgramId, * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param status Filter points based on their status. (optional, default to active) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) - * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) - * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) + * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) + * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) + * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) * @return ApiResponse<InlineResponse2007> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3075,7 +3209,7 @@ public InlineResponse2007 getLoyaltyProgramProfilePoints(Long loyaltyProgramId, 404 Not found - */ - public ApiResponse getLoyaltyProgramProfilePointsWithHttpInfo(Long loyaltyProgramId, String integrationId, String status, String subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort) throws ApiException { + public ApiResponse getLoyaltyProgramProfilePointsWithHttpInfo(Long loyaltyProgramId, String integrationId, String status, List subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort) throws ApiException { okhttp3.Call localVarCall = getLoyaltyProgramProfilePointsValidateBeforeCall(loyaltyProgramId, integrationId, status, subledgerId, customerSessionIDs, transactionUUIDs, pageSize, skip, sort, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); @@ -3087,12 +3221,12 @@ public ApiResponse getLoyaltyProgramProfilePointsWithHttpInf * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param status Filter points based on their status. (optional, default to active) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) - * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) - * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) + * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) + * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) + * @param sort The field by which results should be sorted. You can enter one of the following values: - `startDate`: Sorts the results by the start date of the points. - `expiryDate`: Sorts the results by the expiry date of the points. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You can only sort by one field at a time. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -3105,7 +3239,7 @@ public ApiResponse getLoyaltyProgramProfilePointsWithHttpInf 404 Not found - */ - public okhttp3.Call getLoyaltyProgramProfilePointsAsync(Long loyaltyProgramId, String integrationId, String status, String subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getLoyaltyProgramProfilePointsAsync(Long loyaltyProgramId, String integrationId, String status, List subledgerId, List customerSessionIDs, List transactionUUIDs, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getLoyaltyProgramProfilePointsValidateBeforeCall(loyaltyProgramId, integrationId, status, subledgerId, customerSessionIDs, transactionUUIDs, pageSize, skip, sort, _callback); Type localVarReturnType = new TypeToken(){}.getType(); @@ -3118,7 +3252,7 @@ public okhttp3.Call getLoyaltyProgramProfilePointsAsync(Long loyaltyProgramId, S * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) * @param loyaltyTransactionType Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. (optional) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) * @param endDate Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -3137,7 +3271,7 @@ public okhttp3.Call getLoyaltyProgramProfilePointsAsync(Long loyaltyProgramId, S 404 Not found - */ - public okhttp3.Call getLoyaltyProgramProfileTransactionsCall(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, String subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getLoyaltyProgramProfileTransactionsCall(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, List subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -3156,7 +3290,7 @@ public okhttp3.Call getLoyaltyProgramProfileTransactionsCall(Long loyaltyProgram } if (subledgerId != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("subledgerId", subledgerId)); + localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "subledgerId", subledgerId)); } if (loyaltyTransactionType != null) { @@ -3205,7 +3339,7 @@ public okhttp3.Call getLoyaltyProgramProfileTransactionsCall(Long loyaltyProgram } @SuppressWarnings("rawtypes") - private okhttp3.Call getLoyaltyProgramProfileTransactionsValidateBeforeCall(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, String subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getLoyaltyProgramProfileTransactionsValidateBeforeCall(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, List subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { // verify the required parameter 'loyaltyProgramId' is set if (loyaltyProgramId == null) { @@ -3230,7 +3364,7 @@ private okhttp3.Call getLoyaltyProgramProfileTransactionsValidateBeforeCall(Long * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) * @param loyaltyTransactionType Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. (optional) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) * @param endDate Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -3248,7 +3382,7 @@ private okhttp3.Call getLoyaltyProgramProfileTransactionsValidateBeforeCall(Long 404 Not found - */ - public InlineResponse2005 getLoyaltyProgramProfileTransactions(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, String subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation) throws ApiException { + public InlineResponse2005 getLoyaltyProgramProfileTransactions(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, List subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation) throws ApiException { ApiResponse localVarResp = getLoyaltyProgramProfileTransactionsWithHttpInfo(loyaltyProgramId, integrationId, customerSessionIDs, transactionUUIDs, subledgerId, loyaltyTransactionType, startDate, endDate, pageSize, skip, awaitsActivation); return localVarResp.getData(); } @@ -3260,7 +3394,7 @@ public InlineResponse2005 getLoyaltyProgramProfileTransactions(Long loyaltyProgr * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) * @param loyaltyTransactionType Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. (optional) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) * @param endDate Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -3278,7 +3412,7 @@ public InlineResponse2005 getLoyaltyProgramProfileTransactions(Long loyaltyProgr 404 Not found - */ - public ApiResponse getLoyaltyProgramProfileTransactionsWithHttpInfo(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, String subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation) throws ApiException { + public ApiResponse getLoyaltyProgramProfileTransactionsWithHttpInfo(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, List subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation) throws ApiException { okhttp3.Call localVarCall = getLoyaltyProgramProfileTransactionsValidateBeforeCall(loyaltyProgramId, integrationId, customerSessionIDs, transactionUUIDs, subledgerId, loyaltyTransactionType, startDate, endDate, pageSize, skip, awaitsActivation, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); @@ -3291,7 +3425,7 @@ public ApiResponse getLoyaltyProgramProfileTransactionsWithH * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) * @param transactionUUIDs Filter the results by a list of transaction UUIDs. To include multiple IDs, repeat the parameter for each one, for example, `?transactionUUIDs=uuid1&transactionUUIDs=uuid2`. The response contains only data associated with the specified transactions. (optional) - * @param subledgerId The ID of the subledger by which we filter the data. (optional) + * @param subledgerId Filter the results by a list of subledger IDs. To include multiple IDs, repeat the parameter for each one, for example, `?subledgerId=id1&subledgerId=id2`. The response contains only data associated with the specified subledgers. (optional) * @param loyaltyTransactionType Filter results by loyalty transaction type: - `manual`: Loyalty transaction that was done manually. - `session`: Loyalty transaction that resulted from a customer session. - `import`: Loyalty transaction that was imported from a CSV file. (optional) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) * @param endDate Date and time by which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -3310,7 +3444,7 @@ public ApiResponse getLoyaltyProgramProfileTransactionsWithH 404 Not found - */ - public okhttp3.Call getLoyaltyProgramProfileTransactionsAsync(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, String subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getLoyaltyProgramProfileTransactionsAsync(Long loyaltyProgramId, String integrationId, List customerSessionIDs, List transactionUUIDs, List subledgerId, String loyaltyTransactionType, OffsetDateTime startDate, OffsetDateTime endDate, Long pageSize, Long skip, Boolean awaitsActivation, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getLoyaltyProgramProfileTransactionsValidateBeforeCall(loyaltyProgramId, integrationId, customerSessionIDs, transactionUUIDs, subledgerId, loyaltyTransactionType, startDate, endDate, pageSize, skip, awaitsActivation, _callback); Type localVarReturnType = new TypeToken(){}.getType(); @@ -3319,7 +3453,7 @@ public okhttp3.Call getLoyaltyProgramProfileTransactionsAsync(Long loyaltyProgra } /** * Build call for getReservedCustomers - * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) + * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3379,7 +3513,7 @@ private okhttp3.Call getReservedCustomersValidateBeforeCall(String couponValue, /** * List customers that have this coupon reserved * Return all customers that have this coupon marked as reserved. This includes hard and soft reservations. - * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) + * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) * @return InlineResponse2001 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3399,7 +3533,7 @@ public InlineResponse2001 getReservedCustomers(String couponValue) throws ApiExc /** * List customers that have this coupon reserved * Return all customers that have this coupon marked as reserved. This includes hard and soft reservations. - * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) + * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) * @return ApiResponse<InlineResponse2001> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3420,7 +3554,7 @@ public ApiResponse getReservedCustomersWithHttpInfo(String c /** * List customers that have this coupon reserved (asynchronously) * Return all customers that have this coupon marked as reserved. This includes hard and soft reservations. - * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) + * @param couponValue The code of the coupon. **Important:** The coupon code requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `SUMMER25%OFF` as `SUMMER25%25OFF`. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -3449,6 +3583,8 @@ public okhttp3.Call getReservedCustomersAsync(String couponValue, final ApiCallb * @param startBefore 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) * @param endAfter 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) * @param endBefore 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) + * @param storeId Filter results to campaigns linked to the specified store ID. (optional) + * @param audienceId Filter results to campaigns linked to the specified audience ID. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3461,7 +3597,7 @@ public okhttp3.Call getReservedCustomersAsync(String couponValue, final ApiCallb 404 Not found - */ - public okhttp3.Call integrationGetAllCampaignsCall(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, final ApiCallback _callback) throws ApiException { + public okhttp3.Call integrationGetAllCampaignsCall(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, Long storeId, Long audienceId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -3497,6 +3633,14 @@ public okhttp3.Call integrationGetAllCampaignsCall(Long pageSize, Long skip, Lis localVarQueryParams.addAll(localVarApiClient.parameterToPair("endBefore", endBefore)); } + if (storeId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("storeId", storeId)); + } + + if (audienceId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("audienceId", audienceId)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -3519,10 +3663,10 @@ public okhttp3.Call integrationGetAllCampaignsCall(Long pageSize, Long skip, Lis } @SuppressWarnings("rawtypes") - private okhttp3.Call integrationGetAllCampaignsValidateBeforeCall(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, final ApiCallback _callback) throws ApiException { + private okhttp3.Call integrationGetAllCampaignsValidateBeforeCall(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, Long storeId, Long audienceId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = integrationGetAllCampaignsCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, _callback); + okhttp3.Call localVarCall = integrationGetAllCampaignsCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId, _callback); return localVarCall; } @@ -3537,6 +3681,8 @@ private okhttp3.Call integrationGetAllCampaignsValidateBeforeCall(Long pageSize, * @param startBefore 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) * @param endAfter 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) * @param endBefore 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) + * @param storeId Filter results to campaigns linked to the specified store ID. (optional) + * @param audienceId Filter results to campaigns linked to the specified audience ID. (optional) * @return InlineResponse200 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3548,8 +3694,8 @@ private okhttp3.Call integrationGetAllCampaignsValidateBeforeCall(Long pageSize, 404 Not found - */ - public InlineResponse200 integrationGetAllCampaigns(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore) throws ApiException { - ApiResponse localVarResp = integrationGetAllCampaignsWithHttpInfo(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore); + public InlineResponse200 integrationGetAllCampaigns(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, Long storeId, Long audienceId) throws ApiException { + ApiResponse localVarResp = integrationGetAllCampaignsWithHttpInfo(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId); return localVarResp.getData(); } @@ -3563,6 +3709,8 @@ public InlineResponse200 integrationGetAllCampaigns(Long pageSize, Long skip, Li * @param startBefore 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) * @param endAfter 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) * @param endBefore 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) + * @param storeId Filter results to campaigns linked to the specified store ID. (optional) + * @param audienceId Filter results to campaigns linked to the specified audience ID. (optional) * @return ApiResponse<InlineResponse200> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3574,8 +3722,8 @@ public InlineResponse200 integrationGetAllCampaigns(Long pageSize, Long skip, Li 404 Not found - */ - public ApiResponse integrationGetAllCampaignsWithHttpInfo(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore) throws ApiException { - okhttp3.Call localVarCall = integrationGetAllCampaignsValidateBeforeCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, null); + public ApiResponse integrationGetAllCampaignsWithHttpInfo(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, Long storeId, Long audienceId) throws ApiException { + okhttp3.Call localVarCall = integrationGetAllCampaignsValidateBeforeCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -3590,6 +3738,8 @@ public ApiResponse integrationGetAllCampaignsWithHttpInfo(Lon * @param startBefore 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) * @param endAfter 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) * @param endBefore 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) + * @param storeId Filter results to campaigns linked to the specified store ID. (optional) + * @param audienceId Filter results to campaigns linked to the specified audience ID. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -3602,18 +3752,24 @@ public ApiResponse integrationGetAllCampaignsWithHttpInfo(Lon 404 Not found - */ - public okhttp3.Call integrationGetAllCampaignsAsync(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, final ApiCallback _callback) throws ApiException { + public okhttp3.Call integrationGetAllCampaignsAsync(Long pageSize, Long skip, List campaignIds, OffsetDateTime startAfter, OffsetDateTime startBefore, OffsetDateTime endAfter, OffsetDateTime endBefore, Long storeId, Long audienceId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = integrationGetAllCampaignsValidateBeforeCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, _callback); + okhttp3.Call localVarCall = integrationGetAllCampaignsValidateBeforeCall(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for linkLoyaltyCardToProfile - * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) - * @param body body (required) + * Build call for integrationRewardsCatalog + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param pointsFrom Return only rewards whose points required is greater than or equal to this value. (optional) + * @param pointsTo Return only rewards whose points required is less than or equal to this value. (optional) + * @param includeFree Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. (optional, default to true) + * @param loyaltyProgramId Return only rewards available in this loyalty program. (optional) + * @param subledgerId Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). (optional) + * @param profileIntegrationId The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @param loyaltyCardId The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3626,16 +3782,50 @@ public okhttp3.Call integrationGetAllCampaignsAsync(Long pageSize, Long skip, Li 404 Not found - */ - public okhttp3.Call linkLoyaltyCardToProfileCall(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = body; + public okhttp3.Call integrationRewardsCatalogCall(Long pageSize, Long skip, BigDecimal pointsFrom, BigDecimal pointsTo, Boolean includeFree, Long loyaltyProgramId, String subledgerId, String profileIntegrationId, String loyaltyCardId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile" - .replaceAll("\\{" + "loyaltyProgramId" + "\\}", localVarApiClient.escapeString(loyaltyProgramId.toString())) - .replaceAll("\\{" + "loyaltyCardId" + "\\}", localVarApiClient.escapeString(loyaltyCardId.toString())); + String localVarPath = "/v1/rewards/catalog"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); + } + + if (pointsFrom != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pointsFrom", pointsFrom)); + } + + if (pointsTo != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pointsTo", pointsTo)); + } + + if (includeFree != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("includeFree", includeFree)); + } + + if (loyaltyProgramId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("loyaltyProgramId", loyaltyProgramId)); + } + + if (subledgerId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("subledgerId", subledgerId)); + } + + if (profileIntegrationId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("profileIntegrationId", profileIntegrationId)); + } + + if (loyaltyCardId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("loyaltyCardId", loyaltyCardId)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -3648,46 +3838,37 @@ public okhttp3.Call linkLoyaltyCardToProfileCall(Long loyaltyProgramId, String l } final String[] localVarContentTypes = { - "application/json" + }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { "api_key_v1" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call linkLoyaltyCardToProfileValidateBeforeCall(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'loyaltyProgramId' is set - if (loyaltyProgramId == null) { - throw new ApiException("Missing the required parameter 'loyaltyProgramId' when calling linkLoyaltyCardToProfile(Async)"); - } - - // verify the required parameter 'loyaltyCardId' is set - if (loyaltyCardId == null) { - throw new ApiException("Missing the required parameter 'loyaltyCardId' when calling linkLoyaltyCardToProfile(Async)"); - } - - // verify the required parameter 'body' is set - if (body == null) { - throw new ApiException("Missing the required parameter 'body' when calling linkLoyaltyCardToProfile(Async)"); - } + private okhttp3.Call integrationRewardsCatalogValidateBeforeCall(Long pageSize, Long skip, BigDecimal pointsFrom, BigDecimal pointsTo, Boolean includeFree, Long loyaltyProgramId, String subledgerId, String profileIntegrationId, String loyaltyCardId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = linkLoyaltyCardToProfileCall(loyaltyProgramId, loyaltyCardId, body, _callback); + okhttp3.Call localVarCall = integrationRewardsCatalogCall(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId, _callback); return localVarCall; } /** - * Link customer profile to card - * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. - * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) - * @param body body (required) - * @return LoyaltyCard + * List rewards in the catalog + * Retrieve the rewards catalog for the Application. Returns a paginated list of rewards. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param pointsFrom Return only rewards whose points required is greater than or equal to this value. (optional) + * @param pointsTo Return only rewards whose points required is less than or equal to this value. (optional) + * @param includeFree Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. (optional, default to true) + * @param loyaltyProgramId Return only rewards available in this loyalty program. (optional) + * @param subledgerId Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). (optional) + * @param profileIntegrationId The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @param loyaltyCardId The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @return InlineResponse20056 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3698,18 +3879,24 @@ private okhttp3.Call linkLoyaltyCardToProfileValidateBeforeCall(Long loyaltyProg
404 Not found -
*/ - public LoyaltyCard linkLoyaltyCardToProfile(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body) throws ApiException { - ApiResponse localVarResp = linkLoyaltyCardToProfileWithHttpInfo(loyaltyProgramId, loyaltyCardId, body); + public InlineResponse20056 integrationRewardsCatalog(Long pageSize, Long skip, BigDecimal pointsFrom, BigDecimal pointsTo, Boolean includeFree, Long loyaltyProgramId, String subledgerId, String profileIntegrationId, String loyaltyCardId) throws ApiException { + ApiResponse localVarResp = integrationRewardsCatalogWithHttpInfo(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId); return localVarResp.getData(); } /** - * Link customer profile to card - * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. - * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) - * @param body body (required) - * @return ApiResponse<LoyaltyCard> + * List rewards in the catalog + * Retrieve the rewards catalog for the Application. Returns a paginated list of rewards. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param pointsFrom Return only rewards whose points required is greater than or equal to this value. (optional) + * @param pointsTo Return only rewards whose points required is less than or equal to this value. (optional) + * @param includeFree Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. (optional, default to true) + * @param loyaltyProgramId Return only rewards available in this loyalty program. (optional) + * @param subledgerId Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). (optional) + * @param profileIntegrationId The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @param loyaltyCardId The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @return ApiResponse<InlineResponse20056> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3720,18 +3907,24 @@ public LoyaltyCard linkLoyaltyCardToProfile(Long loyaltyProgramId, String loyalt
404 Not found -
*/ - public ApiResponse linkLoyaltyCardToProfileWithHttpInfo(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body) throws ApiException { - okhttp3.Call localVarCall = linkLoyaltyCardToProfileValidateBeforeCall(loyaltyProgramId, loyaltyCardId, body, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse integrationRewardsCatalogWithHttpInfo(Long pageSize, Long skip, BigDecimal pointsFrom, BigDecimal pointsTo, Boolean includeFree, Long loyaltyProgramId, String subledgerId, String profileIntegrationId, String loyaltyCardId) throws ApiException { + okhttp3.Call localVarCall = integrationRewardsCatalogValidateBeforeCall(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Link customer profile to card (asynchronously) - * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. - * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) - * @param body body (required) + * List rewards in the catalog (asynchronously) + * Retrieve the rewards catalog for the Application. Returns a paginated list of rewards. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param pointsFrom Return only rewards whose points required is greater than or equal to this value. (optional) + * @param pointsTo Return only rewards whose points required is less than or equal to this value. (optional) + * @param includeFree Whether to include rewards that have no `pointsRequired`. These rewards are treated as free and available to all customers. (optional, default to true) + * @param loyaltyProgramId Return only rewards available in this loyalty program. (optional) + * @param subledgerId Return only rewards available in this subledger. Must be combined with `loyaltyProgramId`. To specify the main ledger, provide an empty string (\"\"). (optional) + * @param profileIntegrationId The integration ID of the customer profile whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) + * @param loyaltyCardId The identifier of the loyalty card whose loyalty balances to include in the response. Balances are returned only when `loyaltyProgramId` is also provided. **Note:** `profileIntegrationId` and `loyaltyCardId` are mutually exclusive. Do not send both in the same request. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -3744,16 +3937,17 @@ public ApiResponse linkLoyaltyCardToProfileWithHttpInfo(Long loyalt 404 Not found - */ - public okhttp3.Call linkLoyaltyCardToProfileAsync(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { + public okhttp3.Call integrationRewardsCatalogAsync(Long pageSize, Long skip, BigDecimal pointsFrom, BigDecimal pointsTo, Boolean includeFree, Long loyaltyProgramId, String subledgerId, String profileIntegrationId, String loyaltyCardId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = linkLoyaltyCardToProfileValidateBeforeCall(loyaltyProgramId, loyaltyCardId, body, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = integrationRewardsCatalogValidateBeforeCall(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for reopenCustomerSession - * @param customerSessionId 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. (required) + * Build call for joinLoyaltyProgram + * @param loyaltyProgramId 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. (required) + * @param integrationId 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. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3762,15 +3956,17 @@ public okhttp3.Call linkLoyaltyCardToProfileAsync(Long loyaltyProgramId, String Status Code Description Response Headers 200 OK - 400 Bad request - - 401 Unauthorized - Invalid API key - + 401 Unauthorized - + 404 Not found - */ - public okhttp3.Call reopenCustomerSessionCall(String customerSessionId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call joinLoyaltyProgramCall(Long loyaltyProgramId, String integrationId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v2/customer_sessions/{customerSessionId}/reopen" - .replaceAll("\\{" + "customerSessionId" + "\\}", localVarApiClient.escapeString(customerSessionId.toString())); + String localVarPath = "/v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join" + .replaceAll("\\{" + "loyaltyProgramId" + "\\}", localVarApiClient.escapeString(loyaltyProgramId.toString())) + .replaceAll("\\{" + "integrationId" + "\\}", localVarApiClient.escapeString(integrationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3792,47 +3988,315 @@ public okhttp3.Call reopenCustomerSessionCall(String customerSessionId, final Ap localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { "api_key_v1" }; - return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call reopenCustomerSessionValidateBeforeCall(String customerSessionId, final ApiCallback _callback) throws ApiException { + private okhttp3.Call joinLoyaltyProgramValidateBeforeCall(Long loyaltyProgramId, String integrationId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'customerSessionId' is set - if (customerSessionId == null) { - throw new ApiException("Missing the required parameter 'customerSessionId' when calling reopenCustomerSession(Async)"); + // verify the required parameter 'loyaltyProgramId' is set + if (loyaltyProgramId == null) { + throw new ApiException("Missing the required parameter 'loyaltyProgramId' when calling joinLoyaltyProgram(Async)"); + } + + // verify the required parameter 'integrationId' is set + if (integrationId == null) { + throw new ApiException("Missing the required parameter 'integrationId' when calling joinLoyaltyProgram(Async)"); } - okhttp3.Call localVarCall = reopenCustomerSessionCall(customerSessionId, _callback); + okhttp3.Call localVarCall = joinLoyaltyProgramCall(loyaltyProgramId, integrationId, _callback); return localVarCall; } /** - * Reopen customer session - * Reopen a closed [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). For example, if a session has been completed but still needs to be edited, you can reopen it with this endpoint. A reopen session is treated like a standard open session. When reopening a session: - The `talon_session_reopened` event is triggered. You can see it in the **Events** view in the Campaign Manager. - The session state is updated to `open`. - Any modified budgets and triggered effects are rolled back when the session closes. - Depending on the [return policy](https://docs.talon.one/docs/product/loyalty-programs/managing-loyalty-programs#return-policy) in your loyalty programs, points are rolled back in the following ways: - Pending points are rolled back automatically. - If **Active points deduction** setting is enabled, any points that were earned and activated when the session closed are rolled back. - If **Negative balance** is enabled, the rollback can create a negative points balance. <details> <summary><strong>Effects and budgets unimpacted by a session reopening</strong></summary> <div> <p>The following effects and budgets remain in the state they were in when the session closed:</p> <ul> <li>Add free item effect</li> <li>Award giveaway</li> <li>Coupon and referral creation</li> <li>Coupon reservation</li> <li>Custom effect</li> <li>Update attribute value</li> <li>Update cart item attribute value</li> </ul> </div> </details> To see an example of a rollback, see the [Cancelling a session with campaign budgets](https://docs.talon.one/docs/dev/tutorials/rolling-back-effects) tutorial. > [!note] If your order workflow requires you to create a new session > instead of reopening a session, use the > [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) > endpoint to cancel a closed session and create a new one. - * @param customerSessionId 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. (required) - * @return ReopenSessionResponse + * Join customer profile to loyalty program + * 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. + * @param loyaltyProgramId 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. (required) + * @param integrationId 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. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
401 Unauthorized -
404 Not found -
*/ - public ReopenSessionResponse reopenCustomerSession(String customerSessionId) throws ApiException { - ApiResponse localVarResp = reopenCustomerSessionWithHttpInfo(customerSessionId); - return localVarResp.getData(); + public void joinLoyaltyProgram(Long loyaltyProgramId, String integrationId) throws ApiException { + joinLoyaltyProgramWithHttpInfo(loyaltyProgramId, integrationId); } /** - * Reopen customer session - * Reopen a closed [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). For example, if a session has been completed but still needs to be edited, you can reopen it with this endpoint. A reopen session is treated like a standard open session. When reopening a session: - The `talon_session_reopened` event is triggered. You can see it in the **Events** view in the Campaign Manager. - The session state is updated to `open`. - Any modified budgets and triggered effects are rolled back when the session closes. - Depending on the [return policy](https://docs.talon.one/docs/product/loyalty-programs/managing-loyalty-programs#return-policy) in your loyalty programs, points are rolled back in the following ways: - Pending points are rolled back automatically. - If **Active points deduction** setting is enabled, any points that were earned and activated when the session closed are rolled back. - If **Negative balance** is enabled, the rollback can create a negative points balance. <details> <summary><strong>Effects and budgets unimpacted by a session reopening</strong></summary> <div> <p>The following effects and budgets remain in the state they were in when the session closed:</p> <ul> <li>Add free item effect</li> <li>Award giveaway</li> <li>Coupon and referral creation</li> <li>Coupon reservation</li> <li>Custom effect</li> <li>Update attribute value</li> <li>Update cart item attribute value</li> </ul> </div> </details> To see an example of a rollback, see the [Cancelling a session with campaign budgets](https://docs.talon.one/docs/dev/tutorials/rolling-back-effects) tutorial. > [!note] If your order workflow requires you to create a new session > instead of reopening a session, use the > [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) > endpoint to cancel a closed session and create a new one. - * @param customerSessionId 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. (required) - * @return ApiResponse<ReopenSessionResponse> + * Join customer profile to loyalty program + * 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. + * @param loyaltyProgramId 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. (required) + * @param integrationId 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. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public ApiResponse joinLoyaltyProgramWithHttpInfo(Long loyaltyProgramId, String integrationId) throws ApiException { + okhttp3.Call localVarCall = joinLoyaltyProgramValidateBeforeCall(loyaltyProgramId, integrationId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Join customer profile to loyalty program (asynchronously) + * 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. + * @param loyaltyProgramId 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. (required) + * @param integrationId 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. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call joinLoyaltyProgramAsync(Long loyaltyProgramId, String integrationId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = joinLoyaltyProgramValidateBeforeCall(loyaltyProgramId, integrationId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + /** + * Build call for linkLoyaltyCardToProfile + * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) + * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) + * @param body body (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call linkLoyaltyCardToProfileCall(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile" + .replaceAll("\\{" + "loyaltyProgramId" + "\\}", localVarApiClient.escapeString(loyaltyProgramId.toString())) + .replaceAll("\\{" + "loyaltyCardId" + "\\}", localVarApiClient.escapeString(loyaltyCardId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call linkLoyaltyCardToProfileValidateBeforeCall(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'loyaltyProgramId' is set + if (loyaltyProgramId == null) { + throw new ApiException("Missing the required parameter 'loyaltyProgramId' when calling linkLoyaltyCardToProfile(Async)"); + } + + // verify the required parameter 'loyaltyCardId' is set + if (loyaltyCardId == null) { + throw new ApiException("Missing the required parameter 'loyaltyCardId' when calling linkLoyaltyCardToProfile(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling linkLoyaltyCardToProfile(Async)"); + } + + + okhttp3.Call localVarCall = linkLoyaltyCardToProfileCall(loyaltyProgramId, loyaltyCardId, body, _callback); + return localVarCall; + + } + + /** + * Link customer profile to card + * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. + * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) + * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) + * @param body body (required) + * @return LoyaltyCard + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public LoyaltyCard linkLoyaltyCardToProfile(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body) throws ApiException { + ApiResponse localVarResp = linkLoyaltyCardToProfileWithHttpInfo(loyaltyProgramId, loyaltyCardId, body); + return localVarResp.getData(); + } + + /** + * Link customer profile to card + * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. + * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) + * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) + * @param body body (required) + * @return ApiResponse<LoyaltyCard> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public ApiResponse linkLoyaltyCardToProfileWithHttpInfo(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body) throws ApiException { + okhttp3.Call localVarCall = linkLoyaltyCardToProfileValidateBeforeCall(loyaltyProgramId, loyaltyCardId, body, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Link customer profile to card (asynchronously) + * [Loyalty cards](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) allow customers to collect and spend loyalty points within a [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types). They are useful to gamify loyalty programs and can be used with or without customer profiles linked to them. Link a customer profile to a given loyalty card for the card to be set as **Registered**. This affects how it can be used. See the [docs](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards#linking-customer-profiles-to-a-loyalty-card). > [!note] You can link as many customer profiles to a given loyalty card as the > [**card user limit**](https://docs.talon.one/docs/product/loyalty-programs/card-based/creating-cb-programs) > allows. + * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) + * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) + * @param body body (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call linkLoyaltyCardToProfileAsync(Long loyaltyProgramId, String loyaltyCardId, LoyaltyCardRegistration body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = linkLoyaltyCardToProfileValidateBeforeCall(loyaltyProgramId, loyaltyCardId, body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for reopenCustomerSession + * @param customerSessionId 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. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
+ */ + public okhttp3.Call reopenCustomerSessionCall(String customerSessionId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v2/customer_sessions/{customerSessionId}/reopen" + .replaceAll("\\{" + "customerSessionId" + "\\}", localVarApiClient.escapeString(customerSessionId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1" }; + return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call reopenCustomerSessionValidateBeforeCall(String customerSessionId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'customerSessionId' is set + if (customerSessionId == null) { + throw new ApiException("Missing the required parameter 'customerSessionId' when calling reopenCustomerSession(Async)"); + } + + + okhttp3.Call localVarCall = reopenCustomerSessionCall(customerSessionId, _callback); + return localVarCall; + + } + + /** + * Reopen customer session + * Reopen a closed [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). For example, if a session has been completed but still needs to be edited, you can reopen it with this endpoint. A reopen session is treated like a standard open session. When reopening a session: - The `talon_session_reopened` event is triggered. You can see it in the **Events** view in the Campaign Manager. - The session state is updated to `open`. - Any modified budgets and triggered effects are rolled back when the session closes. - Depending on the [return policy](https://docs.talon.one/docs/product/loyalty-programs/managing-loyalty-programs#return-policy) in your loyalty programs, points are rolled back in the following ways: - Pending points are rolled back automatically. - If **Active points deduction** setting is enabled, any points that were earned and activated when the session closed are rolled back. - If **Negative balance** is enabled, the rollback can create a negative points balance. <details> <summary><strong>Effects and budgets unimpacted by a session reopening</strong></summary> <div> <p>The following effects and budgets remain in the state they were in when the session closed:</p> <ul> <li>Add free item effect</li> <li>Award giveaway</li> <li>Coupon and referral creation</li> <li>Coupon reservation</li> <li>Custom effect</li> <li>Update attribute value</li> <li>Update cart item attribute value</li> </ul> </div> </details> To see an example of a rollback, see the [Cancelling a session with campaign budgets](https://docs.talon.one/docs/dev/tutorials/rolling-back-effects) tutorial. > [!note] If your order workflow requires you to create a new session > instead of reopening a session, use the > [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) > endpoint to cancel a closed session and create a new one. + * @param customerSessionId 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. (required) + * @return ReopenSessionResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
+ */ + public ReopenSessionResponse reopenCustomerSession(String customerSessionId) throws ApiException { + ApiResponse localVarResp = reopenCustomerSessionWithHttpInfo(customerSessionId); + return localVarResp.getData(); + } + + /** + * Reopen customer session + * Reopen a closed [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). For example, if a session has been completed but still needs to be edited, you can reopen it with this endpoint. A reopen session is treated like a standard open session. When reopening a session: - The `talon_session_reopened` event is triggered. You can see it in the **Events** view in the Campaign Manager. - The session state is updated to `open`. - Any modified budgets and triggered effects are rolled back when the session closes. - Depending on the [return policy](https://docs.talon.one/docs/product/loyalty-programs/managing-loyalty-programs#return-policy) in your loyalty programs, points are rolled back in the following ways: - Pending points are rolled back automatically. - If **Active points deduction** setting is enabled, any points that were earned and activated when the session closed are rolled back. - If **Negative balance** is enabled, the rollback can create a negative points balance. <details> <summary><strong>Effects and budgets unimpacted by a session reopening</strong></summary> <div> <p>The following effects and budgets remain in the state they were in when the session closed:</p> <ul> <li>Add free item effect</li> <li>Award giveaway</li> <li>Coupon and referral creation</li> <li>Coupon reservation</li> <li>Custom effect</li> <li>Update attribute value</li> <li>Update cart item attribute value</li> </ul> </div> </details> To see an example of a rollback, see the [Cancelling a session with campaign budgets](https://docs.talon.one/docs/dev/tutorials/rolling-back-effects) tutorial. > [!note] If your order workflow requires you to create a new session > instead of reopening a session, use the > [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) > endpoint to cancel a closed session and create a new one. + * @param customerSessionId 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. (required) + * @return ApiResponse<ReopenSessionResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -3946,7 +4410,7 @@ private okhttp3.Call returnCartItemsValidateBeforeCall(String customerSessionId, /** * Return cart items - * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. + * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). * @param customerSessionId 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. (required) * @param body body (required) * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -3968,7 +4432,7 @@ public IntegrationStateV2 returnCartItems(String customerSessionId, ReturnIntegr /** * Return cart items - * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. + * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). * @param customerSessionId 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. (required) * @param body body (required) * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -3991,7 +4455,7 @@ public ApiResponse returnCartItemsWithHttpInfo(String custom /** * Return cart items (asynchronously) - * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. + * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). * @param customerSessionId 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. (required) * @param body body (required) * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -4081,7 +4545,7 @@ private okhttp3.Call syncCatalogValidateBeforeCall(Long catalogId, CatalogSyncRe /** * Sync cart item catalog - * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. ### Payload examples Synchronization actions are sent as `PUT` requests. See the structure for each action: <details> <summary><strong>Adding an item to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Adding multiple items to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241027\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" }, { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of an item in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"age\": 11, \"origin\": \"germany\" }, \"createIfNotExists\": false, \"sku\": \"SKU1241028\", \"product\": { \"name\": \"sneakers\" } }, \"type\": \"PATCH\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of multiple items in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"red\" }, \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"PATCH_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing an item from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"sku\": \"SKU1241028\" }, \"type\": \"REMOVE\" } ] } ``` </div> </details> <details> <summary><strong>Removing multiple items from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing shoes of sizes above 45 from the catalog</strong></summary> <div> <p> Let's imagine that we have a shoe store and we have decided to stop selling shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 with a single action:</p> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"size\", \"op\": \"GT\", \"value\": \"45\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> + * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. For request examples of each action, see the **Request Body** examples. * @param catalogId The ID of the catalog. You can find the ID in the Campaign Manager in **Account** > **Tools** > **Cart item catalogs**. (required) * @param body body (required) * @return Catalog @@ -4102,7 +4566,7 @@ public Catalog syncCatalog(Long catalogId, CatalogSyncRequest body) throws ApiEx /** * Sync cart item catalog - * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. ### Payload examples Synchronization actions are sent as `PUT` requests. See the structure for each action: <details> <summary><strong>Adding an item to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Adding multiple items to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241027\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" }, { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of an item in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"age\": 11, \"origin\": \"germany\" }, \"createIfNotExists\": false, \"sku\": \"SKU1241028\", \"product\": { \"name\": \"sneakers\" } }, \"type\": \"PATCH\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of multiple items in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"red\" }, \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"PATCH_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing an item from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"sku\": \"SKU1241028\" }, \"type\": \"REMOVE\" } ] } ``` </div> </details> <details> <summary><strong>Removing multiple items from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing shoes of sizes above 45 from the catalog</strong></summary> <div> <p> Let's imagine that we have a shoe store and we have decided to stop selling shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 with a single action:</p> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"size\", \"op\": \"GT\", \"value\": \"45\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> + * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. For request examples of each action, see the **Request Body** examples. * @param catalogId The ID of the catalog. You can find the ID in the Campaign Manager in **Account** > **Tools** > **Cart item catalogs**. (required) * @param body body (required) * @return ApiResponse<Catalog> @@ -4124,7 +4588,7 @@ public ApiResponse syncCatalogWithHttpInfo(Long catalogId, CatalogSyncR /** * Sync cart item catalog (asynchronously) - * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. ### Payload examples Synchronization actions are sent as `PUT` requests. See the structure for each action: <details> <summary><strong>Adding an item to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Adding multiple items to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241027\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" }, { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of an item in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"age\": 11, \"origin\": \"germany\" }, \"createIfNotExists\": false, \"sku\": \"SKU1241028\", \"product\": { \"name\": \"sneakers\" } }, \"type\": \"PATCH\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of multiple items in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"red\" }, \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"PATCH_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing an item from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"sku\": \"SKU1241028\" }, \"type\": \"REMOVE\" } ] } ``` </div> </details> <details> <summary><strong>Removing multiple items from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing shoes of sizes above 45 from the catalog</strong></summary> <div> <p> Let's imagine that we have a shoe store and we have decided to stop selling shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 with a single action:</p> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"size\", \"op\": \"GT\", \"value\": \"45\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> + * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. For request examples of each action, see the **Request Body** examples. * @param catalogId The ID of the catalog. You can find the ID in the Campaign Manager in **Account** > **Tools** > **Cart item catalogs**. (required) * @param body body (required) * @param _callback The callback to be executed when the API call finishes @@ -4159,9 +4623,10 @@ public okhttp3.Call syncCatalogAsync(Long catalogId, CatalogSyncRequest body, fi
+ - +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
*/ public okhttp3.Call trackEventV2Call(IntegrationEventV2Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation, final ApiCallback _callback) throws ApiException { @@ -4221,7 +4686,7 @@ private okhttp3.Call trackEventV2ValidateBeforeCall(IntegrationEventV2Request bo /** * Track event - * Triggers a custom event. To use this endpoint: 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) in the Campaign Manager. 1. Update or create a rule to check for this event. 1. Trigger the event with this endpoint. After you have successfully sent an event to Talon.One, you can list the received events in the **Events** view in the Campaign Manager. Talon.One also offers a set of [built-in events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure you do not create a custom event when you can use a built-in event. For example, use this endpoint to trigger an event when a customer shares a link to a product. See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. + * Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to trigger an event when a customer shares a link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. * @param body body (required) * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -4232,9 +4697,10 @@ private okhttp3.Call trackEventV2ValidateBeforeCall(IntegrationEventV2Request bo + - +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
*/ public IntegrationEventV2Response trackEventV2(IntegrationEventV2Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation) throws ApiException { @@ -4244,7 +4710,7 @@ public IntegrationEventV2Response trackEventV2(IntegrationEventV2Request body, S /** * Track event - * Triggers a custom event. To use this endpoint: 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) in the Campaign Manager. 1. Update or create a rule to check for this event. 1. Trigger the event with this endpoint. After you have successfully sent an event to Talon.One, you can list the received events in the **Events** view in the Campaign Manager. Talon.One also offers a set of [built-in events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure you do not create a custom event when you can use a built-in event. For example, use this endpoint to trigger an event when a customer shares a link to a product. See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. + * Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to trigger an event when a customer shares a link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. * @param body body (required) * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -4255,9 +4721,10 @@ public IntegrationEventV2Response trackEventV2(IntegrationEventV2Request body, S + - +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
*/ public ApiResponse trackEventV2WithHttpInfo(IntegrationEventV2Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation) throws ApiException { @@ -4268,7 +4735,7 @@ public ApiResponse trackEventV2WithHttpInfo(Integrat /** * Track event (asynchronously) - * Triggers a custom event. To use this endpoint: 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) in the Campaign Manager. 1. Update or create a rule to check for this event. 1. Trigger the event with this endpoint. After you have successfully sent an event to Talon.One, you can list the received events in the **Events** view in the Campaign Manager. Talon.One also offers a set of [built-in events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure you do not create a custom event when you can use a built-in event. For example, use this endpoint to trigger an event when a customer shares a link to a product. See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. + * Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to trigger an event when a customer shares a link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. * @param body body (required) * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) @@ -4280,9 +4747,10 @@ public ApiResponse trackEventV2WithHttpInfo(Integrat + - +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#managing-parallel-requests). -
409 Too many requests or limit reached - Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
*/ public okhttp3.Call trackEventV2Async(IntegrationEventV2Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation, final ApiCallback _callback) throws ApiException { @@ -4292,6 +4760,152 @@ public okhttp3.Call trackEventV2Async(IntegrationEventV2Request body, String sil localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for trackEventV3 + * @param body body (required) + * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") + * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) + * @param forceCompleteEvaluation Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. (optional, default to false) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
409 An advanced event already exists, too many requests, or limit reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
+ */ + public okhttp3.Call trackEventV3Call(IntegrationEventV3Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v3/events"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (silent != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("silent", silent)); + } + + if (dry != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("dry", dry)); + } + + if (forceCompleteEvaluation != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("forceCompleteEvaluation", forceCompleteEvaluation)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call trackEventV3ValidateBeforeCall(IntegrationEventV3Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling trackEventV3(Async)"); + } + + + okhttp3.Call localVarCall = trackEventV3Call(body, silent, dry, forceCompleteEvaluation, _callback); + return localVarCall; + + } + + /** + * Track advanced event + * Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). Advanced events are idempotent, uniquely identifiable events. They can also reference a previously closed session to add more context for rule evaluation. To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to award loyalty points after an order is delivered. See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). > [!note] **Note** > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + * @param body body (required) + * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") + * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) + * @param forceCompleteEvaluation Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. (optional, default to false) + * @return IntegrationEventV3Response + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
409 An advanced event already exists, too many requests, or limit reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
+ */ + public IntegrationEventV3Response trackEventV3(IntegrationEventV3Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation) throws ApiException { + ApiResponse localVarResp = trackEventV3WithHttpInfo(body, silent, dry, forceCompleteEvaluation); + return localVarResp.getData(); + } + + /** + * Track advanced event + * Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). Advanced events are idempotent, uniquely identifiable events. They can also reference a previously closed session to add more context for rule evaluation. To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to award loyalty points after an order is delivered. See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). > [!note] **Note** > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + * @param body body (required) + * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") + * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) + * @param forceCompleteEvaluation Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. (optional, default to false) + * @return ApiResponse<IntegrationEventV3Response> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
409 An advanced event already exists, too many requests, or limit reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
+ */ + public ApiResponse trackEventV3WithHttpInfo(IntegrationEventV3Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation) throws ApiException { + okhttp3.Call localVarCall = trackEventV3ValidateBeforeCall(body, silent, dry, forceCompleteEvaluation, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Track advanced event (asynchronously) + * Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). Advanced events are idempotent, uniquely identifiable events. They can also reference a previously closed session to add more context for rule evaluation. To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to award loyalty points after an order is delivered. See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). > [!note] **Note** > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + * @param body body (required) + * @param silent Possible values: `yes` or `no`. - `yes`: Increases the performance of the API call by returning a 204 response. - `no`: Returns a 200 response that contains the updated customer profiles. (optional, default to "yes") + * @param dry Indicates whether to persist the changes. Changes are ignored when `dry=true`. (optional) + * @param forceCompleteEvaluation Forces evaluation for all matching campaigns regardless of the [campaign evaluation mode](https://docs.talon.one/docs/product/applications/managing-campaign-evaluation#setting-campaign-evaluation-mode). Requires `dry=true`. (optional, default to false) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized - Invalid API key -
409 An advanced event already exists, too many requests, or limit reached. Avoid parallel requests. See the [docs](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one#manage-parallel-requests). -
+ */ + public okhttp3.Call trackEventV3Async(IntegrationEventV3Request body, String silent, Boolean dry, Boolean forceCompleteEvaluation, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = trackEventV3ValidateBeforeCall(body, silent, dry, forceCompleteEvaluation, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for unlinkLoyaltyCardFromProfile * @param loyaltyProgramId The identifier of the card-based loyalty program containing the loyalty card. You can get this ID using the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) @@ -4434,6 +5048,158 @@ public okhttp3.Call unlinkLoyaltyCardFromProfileAsync(Long loyaltyProgramId, Str localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for unlockReward + * @param rewardId The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. (required) + * @param body (required) + * @param dry When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. (optional) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not found -
409 Conflict. A reward unlock with this integration ID already exists. -
422 Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. -
+ */ + public okhttp3.Call unlockRewardCall(Long rewardId, IntegrationUnlockRewardRequest body, Boolean dry, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v1/rewards/{rewardId}/unlock" + .replaceAll("\\{" + "rewardId" + "\\}", localVarApiClient.escapeString(rewardId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (dry != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("dry", dry)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call unlockRewardValidateBeforeCall(Long rewardId, IntegrationUnlockRewardRequest body, Boolean dry, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'rewardId' is set + if (rewardId == null) { + throw new ApiException("Missing the required parameter 'rewardId' when calling unlockReward(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling unlockReward(Async)"); + } + + + okhttp3.Call localVarCall = unlockRewardCall(rewardId, body, dry, _callback); + return localVarCall; + + } + + /** + * Unlock a reward + * Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + * @param rewardId The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. (required) + * @param body (required) + * @param dry When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. (optional) + * @return IntegrationStateV2 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not found -
409 Conflict. A reward unlock with this integration ID already exists. -
422 Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. -
+ */ + public IntegrationStateV2 unlockReward(Long rewardId, IntegrationUnlockRewardRequest body, Boolean dry) throws ApiException { + ApiResponse localVarResp = unlockRewardWithHttpInfo(rewardId, body, dry); + return localVarResp.getData(); + } + + /** + * Unlock a reward + * Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + * @param rewardId The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. (required) + * @param body (required) + * @param dry When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. (optional) + * @return ApiResponse<IntegrationStateV2> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not found -
409 Conflict. A reward unlock with this integration ID already exists. -
422 Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. -
+ */ + public ApiResponse unlockRewardWithHttpInfo(Long rewardId, IntegrationUnlockRewardRequest body, Boolean dry) throws ApiException { + okhttp3.Call localVarCall = unlockRewardValidateBeforeCall(rewardId, body, dry, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Unlock a reward (asynchronously) + * Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + * @param rewardId The ID of the reward. You can get the ID with the [List rewards](#tag/Rewards/operation/listRewards) endpoint. (required) + * @param body (required) + * @param dry When set to `true`, the rule evaluation is performed but no changes are persisted. Use this to preview the outcome of an unlocking. (optional) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
404 Not found -
409 Conflict. A reward unlock with this integration ID already exists. -
422 Unprocessable entity. The reward unlock was rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. -
+ */ + public okhttp3.Call unlockRewardAsync(Long rewardId, IntegrationUnlockRewardRequest body, Boolean dry, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = unlockRewardValidateBeforeCall(rewardId, body, dry, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for updateAudienceCustomersAttributes * @param audienceId The ID of the audience. (required) @@ -4806,7 +5572,7 @@ public okhttp3.Call updateCustomerProfileAudiencesAsync(CustomerProfileAudienceR } /** * Build call for updateCustomerProfileV2 - * @param integrationId 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. (required) + * @param integrationId 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). (required) * @param body body (required) * @param runRuleEngine 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) * @param dry (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) @@ -4881,8 +5647,8 @@ private okhttp3.Call updateCustomerProfileV2ValidateBeforeCall(String integratio /** * Update customer profile - * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. - * @param integrationId 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. (required) + * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. + * @param integrationId 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). (required) * @param body body (required) * @param runRuleEngine 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) * @param dry (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) @@ -4904,8 +5670,8 @@ public CustomerProfileIntegrationResponseV2 updateCustomerProfileV2(String integ /** * Update customer profile - * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. - * @param integrationId 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. (required) + * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. + * @param integrationId 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). (required) * @param body body (required) * @param runRuleEngine 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) * @param dry (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) @@ -4928,8 +5694,8 @@ public ApiResponse updateCustomerProfileV2 /** * Update customer profile (asynchronously) - * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. - * @param integrationId 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. (required) + * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. + * @param integrationId 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). (required) * @param body body (required) * @param runRuleEngine 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) * @param dry (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) @@ -4963,6 +5729,7 @@ public okhttp3.Call updateCustomerProfileV2Async(String integrationId, CustomerP +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
@@ -5025,6 +5792,7 @@ private okhttp3.Call updateCustomerProfilesV2ValidateBeforeCall(MultipleCustomer +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
@@ -5045,6 +5813,7 @@ public MultipleCustomerProfileIntegrationResponseV2 updateCustomerProfilesV2(Mul +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
@@ -5067,6 +5836,7 @@ public ApiResponse updateCustomerP +
Status Code Description Response Headers
200 OK -
204 No content -
400 Bad request -
401 Unauthorized - Invalid API key -
@@ -5080,7 +5850,7 @@ public okhttp3.Call updateCustomerProfilesV2Async(MultipleCustomerProfileIntegra } /** * Build call for updateCustomerSessionV2 - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param body body (required) * @param dry 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) * @param now 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) @@ -5156,7 +5926,7 @@ private okhttp3.Call updateCustomerSessionV2ValidateBeforeCall(String customerSe /** * Update customer session * Update or create a [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). The endpoint responds with the potential promotion rule [effects](https://docs.talon.one/docs/dev/integration-api/api-effects) that match the current cart. For example, use this endpoint to share the contents of a customer's cart with Talon.One. > [!note] **Note** > - The currency for the session and the cart items in it is the currency set for the Application linked to this session. > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered for rule evaluation. ### Session management To use this endpoint, start by learning about [customer sessions](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions) and their states and refer to the `state` parameter documentation the request body schema docs below. ### Sessions and customer profiles - To link a session to a customer profile, set the `profileId` parameter in the request body to a customer profile's `integrationId`. - While you can create an anonymous session with `profileId=\"\"`, we recommend you use a guest ID instead. - A profile can be linked to simultaneous sessions in different Applications. Either: - Use unique session integration IDs or, - Use the same session integration ID across all of the Applications. > [!note] **Note** > - If the specified profile does not exist, an empty profile is **created automatically**. > You can update it with [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2). > - Updating a customer session returns a response with the new integration state. Use the `responseContent` property to save yourself extra API calls. > For example, you can get the customer profile details directly without extra requests. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). For more information, see: - The introductory video in [Getting started](https://docs.talon.one/docs/dev/getting-started/overview). - The [integration tutorial](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one). - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param body body (required) * @param dry 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) * @param now 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) @@ -5179,7 +5949,7 @@ public IntegrationStateV2 updateCustomerSessionV2(String customerSessionId, Inte /** * Update customer session * Update or create a [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). The endpoint responds with the potential promotion rule [effects](https://docs.talon.one/docs/dev/integration-api/api-effects) that match the current cart. For example, use this endpoint to share the contents of a customer's cart with Talon.One. > [!note] **Note** > - The currency for the session and the cart items in it is the currency set for the Application linked to this session. > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered for rule evaluation. ### Session management To use this endpoint, start by learning about [customer sessions](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions) and their states and refer to the `state` parameter documentation the request body schema docs below. ### Sessions and customer profiles - To link a session to a customer profile, set the `profileId` parameter in the request body to a customer profile's `integrationId`. - While you can create an anonymous session with `profileId=\"\"`, we recommend you use a guest ID instead. - A profile can be linked to simultaneous sessions in different Applications. Either: - Use unique session integration IDs or, - Use the same session integration ID across all of the Applications. > [!note] **Note** > - If the specified profile does not exist, an empty profile is **created automatically**. > You can update it with [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2). > - Updating a customer session returns a response with the new integration state. Use the `responseContent` property to save yourself extra API calls. > For example, you can get the customer profile details directly without extra requests. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). For more information, see: - The introductory video in [Getting started](https://docs.talon.one/docs/dev/getting-started/overview). - The [integration tutorial](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one). - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param body body (required) * @param dry 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) * @param now 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) @@ -5203,7 +5973,7 @@ public ApiResponse updateCustomerSessionV2WithHttpInfo(Strin /** * Update customer session (asynchronously) * Update or create a [customer session](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). The endpoint responds with the potential promotion rule [effects](https://docs.talon.one/docs/dev/integration-api/api-effects) that match the current cart. For example, use this endpoint to share the contents of a customer's cart with Talon.One. > [!note] **Note** > - The currency for the session and the cart items in it is the currency set for the Application linked to this session. > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered for rule evaluation. ### Session management To use this endpoint, start by learning about [customer sessions](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions) and their states and refer to the `state` parameter documentation the request body schema docs below. ### Sessions and customer profiles - To link a session to a customer profile, set the `profileId` parameter in the request body to a customer profile's `integrationId`. - While you can create an anonymous session with `profileId=\"\"`, we recommend you use a guest ID instead. - A profile can be linked to simultaneous sessions in different Applications. Either: - Use unique session integration IDs or, - Use the same session integration ID across all of the Applications. > [!note] **Note** > - If the specified profile does not exist, an empty profile is **created automatically**. > You can update it with [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2). > - Updating a customer session returns a response with the new integration state. Use the `responseContent` property to save yourself extra API calls. > For example, you can get the customer profile details directly without extra requests. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). For more information, see: - The introductory video in [Getting started](https://docs.talon.one/docs/dev/getting-started/overview). - The [integration tutorial](https://docs.talon.one/docs/dev/tutorials/integrating-talon-one). - * @param customerSessionId 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. (required) + * @param customerSessionId 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). (required) * @param body body (required) * @param dry 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) * @param now 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) diff --git a/src/main/java/one/talon/api/ManagementApi.java b/src/main/java/one/talon/api/ManagementApi.java index 2b31cd88..e4a5e8d2 100644 --- a/src/main/java/one/talon/api/ManagementApi.java +++ b/src/main/java/one/talon/api/ManagementApi.java @@ -31,6 +31,7 @@ import one.talon.model.AccountAdditionalCost; import one.talon.model.AccountAnalytics; import one.talon.model.Achievement; +import one.talon.model.AchievementV2; import one.talon.model.AddLoyaltyPoints; import one.talon.model.Application; import one.talon.model.ApplicationApiHealth; @@ -48,6 +49,7 @@ import one.talon.model.Collection; import one.talon.model.Coupon; import one.talon.model.CreateAchievement; +import one.talon.model.CreateAchievementV2; import one.talon.model.CreateTemplateCampaign; import one.talon.model.CreateTemplateCampaignResponse; import one.talon.model.CustomerActivityReport; @@ -58,6 +60,7 @@ import one.talon.model.DeleteUserRequest; import one.talon.model.ErrorResponse; import one.talon.model.ErrorResponseWithStatus; +import one.talon.model.ExcludePriceObservationsRequest; import one.talon.model.Experiment; import one.talon.model.InlineResponse20010; import one.talon.model.InlineResponse20011; @@ -104,6 +107,8 @@ import one.talon.model.InlineResponse20051; import one.talon.model.InlineResponse20052; import one.talon.model.InlineResponse20053; +import one.talon.model.InlineResponse20054; +import one.talon.model.InlineResponse20055; import one.talon.model.InlineResponse2008; import one.talon.model.InlineResponse2009; import one.talon.model.LoginParams; @@ -138,6 +143,7 @@ import one.talon.model.RoleV2; import one.talon.model.RoleV2Base; import one.talon.model.Ruleset; +import one.talon.model.RulesetV2; import one.talon.model.ScimBaseGroup; import one.talon.model.ScimGroup; import one.talon.model.ScimGroupsListResponse; @@ -152,6 +158,7 @@ import one.talon.model.Store; import one.talon.model.TransferLoyaltyCard; import one.talon.model.UpdateAchievement; +import one.talon.model.UpdateAchievementV2; import one.talon.model.UpdateCampaign; import one.talon.model.UpdateCampaignCollection; import one.talon.model.UpdateCollection; @@ -838,7 +845,9 @@ public okhttp3.Call createAccountCollectionAsync(NewCollection body, final ApiCa 401 Unauthorized - 409 Conflict. An achievement with this name or title already exists. - + * @deprecated */ + @Deprecated public okhttp3.Call createAchievementCall(Long applicationId, Long campaignId, CreateAchievement body, final ApiCallback _callback) throws ApiException { Object localVarPostBody = body; @@ -870,6 +879,7 @@ public okhttp3.Call createAchievementCall(Long applicationId, Long campaignId, C return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } + @Deprecated @SuppressWarnings("rawtypes") private okhttp3.Call createAchievementValidateBeforeCall(Long applicationId, Long campaignId, CreateAchievement body, final ApiCallback _callback) throws ApiException { @@ -910,7 +920,9 @@ private okhttp3.Call createAchievementValidateBeforeCall(Long applicationId, Lon 401 Unauthorized - 409 Conflict. An achievement with this name or title already exists. - + * @deprecated */ + @Deprecated public Achievement createAchievement(Long applicationId, Long campaignId, CreateAchievement body) throws ApiException { ApiResponse localVarResp = createAchievementWithHttpInfo(applicationId, campaignId, body); return localVarResp.getData(); @@ -932,7 +944,9 @@ public Achievement createAchievement(Long applicationId, Long campaignId, Create 401 Unauthorized - 409 Conflict. An achievement with this name or title already exists. - + * @deprecated */ + @Deprecated public ApiResponse createAchievementWithHttpInfo(Long applicationId, Long campaignId, CreateAchievement body) throws ApiException { okhttp3.Call localVarCall = createAchievementValidateBeforeCall(applicationId, campaignId, body, null); Type localVarReturnType = new TypeToken(){}.getType(); @@ -956,7 +970,9 @@ public ApiResponse createAchievementWithHttpInfo(Long applicationId 401 Unauthorized - 409 Conflict. An achievement with this name or title already exists. - + * @deprecated */ + @Deprecated public okhttp3.Call createAchievementAsync(Long applicationId, Long campaignId, CreateAchievement body, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = createAchievementValidateBeforeCall(applicationId, campaignId, body, _callback); @@ -964,6 +980,128 @@ public okhttp3.Call createAchievementAsync(Long applicationId, Long campaignId, localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for createAchievementV2 + * @param body body (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
409 Conflict. An achievement with this name already exists. -
+ */ + public okhttp3.Call createAchievementV2Call(CreateAchievementV2 body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v2/achievements"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createAchievementV2ValidateBeforeCall(CreateAchievementV2 body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling createAchievementV2(Async)"); + } + + + okhttp3.Call localVarCall = createAchievementV2Call(body, _callback); + return localVarCall; + + } + + /** + * Create achievement + * Create a new account-level achievement. + * @param body body (required) + * @return AchievementV2 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
409 Conflict. An achievement with this name already exists. -
+ */ + public AchievementV2 createAchievementV2(CreateAchievementV2 body) throws ApiException { + ApiResponse localVarResp = createAchievementV2WithHttpInfo(body); + return localVarResp.getData(); + } + + /** + * Create achievement + * Create a new account-level achievement. + * @param body body (required) + * @return ApiResponse<AchievementV2> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
409 Conflict. An achievement with this name already exists. -
+ */ + public ApiResponse createAchievementV2WithHttpInfo(CreateAchievementV2 body) throws ApiException { + okhttp3.Call localVarCall = createAchievementV2ValidateBeforeCall(body, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create achievement (asynchronously) + * Create a new account-level achievement. + * @param body body (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
409 Conflict. An achievement with this name already exists. -
+ */ + public okhttp3.Call createAchievementV2Async(CreateAchievementV2 body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = createAchievementV2ValidateBeforeCall(body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for createAdditionalCost * @param body body (required) @@ -2574,6 +2712,140 @@ public okhttp3.Call createPasswordRecoveryEmailAsync(NewPasswordEmail body, fina localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for createRulesetV2 + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
+ */ + public okhttp3.Call createRulesetV2Call(Long applicationId, Long campaignId, RulesetV2 body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v2/applications/{applicationId}/campaigns/{campaignId}/rulesets" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createRulesetV2ValidateBeforeCall(Long applicationId, Long campaignId, RulesetV2 body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling createRulesetV2(Async)"); + } + + // verify the required parameter 'campaignId' is set + if (campaignId == null) { + throw new ApiException("Missing the required parameter 'campaignId' when calling createRulesetV2(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling createRulesetV2(Async)"); + } + + + okhttp3.Call localVarCall = createRulesetV2Call(applicationId, campaignId, body, _callback); + return localVarCall; + + } + + /** + * Create ruleset (V2) + * Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @return RulesetV2 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
+ */ + public RulesetV2 createRulesetV2(Long applicationId, Long campaignId, RulesetV2 body) throws ApiException { + ApiResponse localVarResp = createRulesetV2WithHttpInfo(applicationId, campaignId, body); + return localVarResp.getData(); + } + + /** + * Create ruleset (V2) + * Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @return ApiResponse<RulesetV2> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
+ */ + public ApiResponse createRulesetV2WithHttpInfo(Long applicationId, Long campaignId, RulesetV2 body) throws ApiException { + okhttp3.Call localVarCall = createRulesetV2ValidateBeforeCall(applicationId, campaignId, body, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create ruleset (V2) (asynchronously) + * Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
+ */ + public okhttp3.Call createRulesetV2Async(Long applicationId, Long campaignId, RulesetV2 body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = createRulesetV2ValidateBeforeCall(applicationId, campaignId, body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for createSession * @param body body (required) @@ -3182,7 +3454,9 @@ public okhttp3.Call deleteAccountCollectionAsync(Long collectionId, final ApiCal 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call deleteAchievementCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; @@ -3215,6 +3489,7 @@ public okhttp3.Call deleteAchievementCall(Long applicationId, Long campaignId, L return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } + @Deprecated @SuppressWarnings("rawtypes") private okhttp3.Call deleteAchievementValidateBeforeCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { @@ -3253,7 +3528,9 @@ private okhttp3.Call deleteAchievementValidateBeforeCall(Long applicationId, Lon 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public void deleteAchievement(Long applicationId, Long campaignId, Long achievementId) throws ApiException { deleteAchievementWithHttpInfo(applicationId, campaignId, achievementId); } @@ -3273,7 +3550,9 @@ public void deleteAchievement(Long applicationId, Long campaignId, Long achievem 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public ApiResponse deleteAchievementWithHttpInfo(Long applicationId, Long campaignId, Long achievementId) throws ApiException { okhttp3.Call localVarCall = deleteAchievementValidateBeforeCall(applicationId, campaignId, achievementId, null); return localVarApiClient.execute(localVarCall); @@ -3295,7 +3574,9 @@ public ApiResponse deleteAchievementWithHttpInfo(Long applicationId, Long 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call deleteAchievementAsync(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = deleteAchievementValidateBeforeCall(applicationId, campaignId, achievementId, _callback); @@ -3303,9 +3584,8 @@ public okhttp3.Call deleteAchievementAsync(Long applicationId, Long campaignId, return localVarCall; } /** - * Build call for deleteCampaign - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * Build call for deleteAchievementV2 + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3313,15 +3593,16 @@ public okhttp3.Call deleteAchievementAsync(Long applicationId, Long campaignId, + +
Status Code Description Response Headers
204 No Content -
401 Unauthorized -
404 Not found -
*/ - public okhttp3.Call deleteCampaignCall(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call deleteAchievementV2Call(Long achievementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}" - .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) - .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + String localVarPath = "/v2/achievements/{achievementId}" + .replaceAll("\\{" + "achievementId" + "\\}", localVarApiClient.escapeString(achievementId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3329,7 +3610,7 @@ public okhttp3.Call deleteCampaignCall(Long applicationId, Long campaignId, fina Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); final String[] localVarAccepts = { - + "application/json" }; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -3347,29 +3628,144 @@ public okhttp3.Call deleteCampaignCall(Long applicationId, Long campaignId, fina } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteCampaignValidateBeforeCall(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { + private okhttp3.Call deleteAchievementV2ValidateBeforeCall(Long achievementId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'applicationId' is set - if (applicationId == null) { - throw new ApiException("Missing the required parameter 'applicationId' when calling deleteCampaign(Async)"); - } - - // verify the required parameter 'campaignId' is set - if (campaignId == null) { - throw new ApiException("Missing the required parameter 'campaignId' when calling deleteCampaign(Async)"); + // verify the required parameter 'achievementId' is set + if (achievementId == null) { + throw new ApiException("Missing the required parameter 'achievementId' when calling deleteAchievementV2(Async)"); } - okhttp3.Call localVarCall = deleteCampaignCall(applicationId, campaignId, _callback); + okhttp3.Call localVarCall = deleteAchievementV2Call(achievementId, _callback); return localVarCall; } /** - * Delete campaign - * Delete the given campaign. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * Delete achievement + * Delete a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + +
Status Code Description Response Headers
204 No Content -
401 Unauthorized -
404 Not found -
+ */ + public void deleteAchievementV2(Long achievementId) throws ApiException { + deleteAchievementV2WithHttpInfo(achievementId); + } + + /** + * Delete achievement + * Delete a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + +
Status Code Description Response Headers
204 No Content -
401 Unauthorized -
404 Not found -
+ */ + public ApiResponse deleteAchievementV2WithHttpInfo(Long achievementId) throws ApiException { + okhttp3.Call localVarCall = deleteAchievementV2ValidateBeforeCall(achievementId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete achievement (asynchronously) + * Delete a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + +
Status Code Description Response Headers
204 No Content -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call deleteAchievementV2Async(Long achievementId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = deleteAchievementV2ValidateBeforeCall(achievementId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + /** + * Build call for deleteCampaign + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + +
Status Code Description Response Headers
204 No Content -
+ */ + public okhttp3.Call deleteCampaignCall(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteCampaignValidateBeforeCall(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling deleteCampaign(Async)"); + } + + // verify the required parameter 'campaignId' is set + if (campaignId == null) { + throw new ApiException("Missing the required parameter 'campaignId' when calling deleteCampaign(Async)"); + } + + + okhttp3.Call localVarCall = deleteCampaignCall(applicationId, campaignId, _callback); + return localVarCall; + + } + + /** + * Delete campaign + * Delete the given campaign. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -4847,6 +5243,122 @@ public okhttp3.Call disconnectCampaignStoresAsync(Long applicationId, Long campa localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } + /** + * Build call for excludePriceHistory + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details +
+ + +
Status Code Description Response Headers
200 Ok -
+ */ + public okhttp3.Call excludePriceHistoryCall(Long applicationId, ExcludePriceObservationsRequest body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v1/applications/{applicationId}/price_history/exclusions" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call excludePriceHistoryValidateBeforeCall(Long applicationId, ExcludePriceObservationsRequest body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling excludePriceHistory(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling excludePriceHistory(Async)"); + } + + + okhttp3.Call localVarCall = excludePriceHistoryCall(applicationId, body, _callback); + return localVarCall; + + } + + /** + * Exclude price records from price history + * Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 Ok -
+ */ + public void excludePriceHistory(Long applicationId, ExcludePriceObservationsRequest body) throws ApiException { + excludePriceHistoryWithHttpInfo(applicationId, body); + } + + /** + * Exclude price records from price history + * Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 Ok -
+ */ + public ApiResponse excludePriceHistoryWithHttpInfo(Long applicationId, ExcludePriceObservationsRequest body) throws ApiException { + okhttp3.Call localVarCall = excludePriceHistoryValidateBeforeCall(applicationId, body, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Exclude price records from price history (asynchronously) + * Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 Ok -
+ */ + public okhttp3.Call excludePriceHistoryAsync(Long applicationId, ExcludePriceObservationsRequest body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = excludePriceHistoryValidateBeforeCall(applicationId, body, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } /** * Build call for exportAccountCollectionItems * @param collectionId The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. (required) @@ -4967,10 +5479,8 @@ public okhttp3.Call exportAccountCollectionItemsAsync(Long collectionId, final A return localVarCall; } /** - * Build call for exportAchievements - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * Build call for exportAchievementV2 + * @param achievementId The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4983,13 +5493,11 @@ public okhttp3.Call exportAccountCollectionItemsAsync(Long collectionId, final A 404 Not found - */ - public okhttp3.Call exportAchievementsCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportAchievementV2Call(Long achievementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}/export" - .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) - .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())) + String localVarPath = "/v2/achievements/{achievementId}/export" .replaceAll("\\{" + "achievementId" + "\\}", localVarApiClient.escapeString(achievementId.toString())); List localVarQueryParams = new ArrayList(); @@ -5016,25 +5524,15 @@ public okhttp3.Call exportAchievementsCall(Long applicationId, Long campaignId, } @SuppressWarnings("rawtypes") - private okhttp3.Call exportAchievementsValidateBeforeCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'applicationId' is set - if (applicationId == null) { - throw new ApiException("Missing the required parameter 'applicationId' when calling exportAchievements(Async)"); - } - - // verify the required parameter 'campaignId' is set - if (campaignId == null) { - throw new ApiException("Missing the required parameter 'campaignId' when calling exportAchievements(Async)"); - } + private okhttp3.Call exportAchievementV2ValidateBeforeCall(Long achievementId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'achievementId' is set if (achievementId == null) { - throw new ApiException("Missing the required parameter 'achievementId' when calling exportAchievements(Async)"); + throw new ApiException("Missing the required parameter 'achievementId' when calling exportAchievementV2(Async)"); } - okhttp3.Call localVarCall = exportAchievementsCall(applicationId, campaignId, achievementId, _callback); + okhttp3.Call localVarCall = exportAchievementV2Call(achievementId, _callback); return localVarCall; } @@ -5042,9 +5540,7 @@ private okhttp3.Call exportAchievementsValidateBeforeCall(Long applicationId, Lo /** * Export achievement customer data * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @return String * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -5056,17 +5552,15 @@ private okhttp3.Call exportAchievementsValidateBeforeCall(Long applicationId, Lo 404 Not found - */ - public String exportAchievements(Long applicationId, Long campaignId, Long achievementId) throws ApiException { - ApiResponse localVarResp = exportAchievementsWithHttpInfo(applicationId, campaignId, achievementId); + public String exportAchievementV2(Long achievementId) throws ApiException { + ApiResponse localVarResp = exportAchievementV2WithHttpInfo(achievementId); return localVarResp.getData(); } /** * Export achievement customer data * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @return ApiResponse<String> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -5078,8 +5572,8 @@ public String exportAchievements(Long applicationId, Long campaignId, Long achie 404 Not found - */ - public ApiResponse exportAchievementsWithHttpInfo(Long applicationId, Long campaignId, Long achievementId) throws ApiException { - okhttp3.Call localVarCall = exportAchievementsValidateBeforeCall(applicationId, campaignId, achievementId, null); + public ApiResponse exportAchievementV2WithHttpInfo(Long achievementId) throws ApiException { + okhttp3.Call localVarCall = exportAchievementV2ValidateBeforeCall(achievementId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -5087,9 +5581,7 @@ public ApiResponse exportAchievementsWithHttpInfo(Long applicationId, Lo /** * Export achievement customer data (asynchronously) * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievements](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -5102,19 +5594,18 @@ public ApiResponse exportAchievementsWithHttpInfo(Long applicationId, Lo 404 Not found - */ - public okhttp3.Call exportAchievementsAsync(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportAchievementV2Async(Long achievementId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportAchievementsValidateBeforeCall(applicationId, campaignId, achievementId, _callback); + okhttp3.Call localVarCall = exportAchievementV2ValidateBeforeCall(achievementId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for exportApplicationCampaignAnalytics + * Build call for exportAchievements * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param rangeStart Only return results from after this timestamp. > [!note] **Note** > - This 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. (required) - * @param rangeEnd Only return results from before this timestamp. > [!note] **Note** > - This 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. (required) - * @param campaignIds Filter by one or more Campaign IDs, separated by a comma. **Note:** If no campaigns are specified, data for all the campaigns in the Application is returned. (optional) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5122,9 +5613,162 @@ public okhttp3.Call exportAchievementsAsync(Long applicationId, Long campaignId, + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ * @deprecated */ - public okhttp3.Call exportApplicationCampaignAnalyticsCall(Long applicationId, OffsetDateTime rangeStart, OffsetDateTime rangeEnd, List campaignIds, final ApiCallback _callback) throws ApiException { + @Deprecated + public okhttp3.Call exportAchievementsCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/achievements/{achievementId}/export" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())) + .replaceAll("\\{" + "achievementId" + "\\}", localVarApiClient.escapeString(achievementId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/csv" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @Deprecated + @SuppressWarnings("rawtypes") + private okhttp3.Call exportAchievementsValidateBeforeCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling exportAchievements(Async)"); + } + + // verify the required parameter 'campaignId' is set + if (campaignId == null) { + throw new ApiException("Missing the required parameter 'campaignId' when calling exportAchievements(Async)"); + } + + // verify the required parameter 'achievementId' is set + if (achievementId == null) { + throw new ApiException("Missing the required parameter 'achievementId' when calling exportAchievements(Async)"); + } + + + okhttp3.Call localVarCall = exportAchievementsCall(applicationId, campaignId, achievementId, _callback); + return localVarCall; + + } + + /** + * Export achievement customer data + * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @return String + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ * @deprecated + */ + @Deprecated + public String exportAchievements(Long applicationId, Long campaignId, Long achievementId) throws ApiException { + ApiResponse localVarResp = exportAchievementsWithHttpInfo(applicationId, campaignId, achievementId); + return localVarResp.getData(); + } + + /** + * Export achievement customer data + * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @return ApiResponse<String> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ * @deprecated + */ + @Deprecated + public ApiResponse exportAchievementsWithHttpInfo(Long applicationId, Long campaignId, Long achievementId) throws ApiException { + okhttp3.Call localVarCall = exportAchievementsValidateBeforeCall(applicationId, campaignId, achievementId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Export achievement customer data (asynchronously) + * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ * @deprecated + */ + @Deprecated + public okhttp3.Call exportAchievementsAsync(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = exportAchievementsValidateBeforeCall(applicationId, campaignId, achievementId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for exportApplicationCampaignAnalytics + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param rangeStart Only return results from after this timestamp. > [!note] **Note** > - This 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. (required) + * @param rangeEnd Only return results from before this timestamp. > [!note] **Note** > - This 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. (required) + * @param campaignIds Filter by one or more Campaign IDs, separated by a comma. **Note:** If no campaigns are specified, data for all the campaigns in the Application is returned. (optional) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call exportApplicationCampaignAnalyticsCall(Long applicationId, OffsetDateTime rangeStart, OffsetDateTime rangeEnd, List campaignIds, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -5958,6 +6602,8 @@ public okhttp3.Call exportCollectionItemsAsync(Long applicationId, Long campaign * @param dateFormat Determines the format of dates in the export document. (optional) * @param campaignState 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) * @param valuesOnly Filter results to only return the coupon codes (`value` column) without the associated coupon data. (optional, default to false) + * @param deletedBefore 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) + * @param deletedAfter 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) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5967,7 +6613,7 @@ public okhttp3.Call exportCollectionItemsAsync(Long applicationId, Long campaign 200 OK - */ - public okhttp3.Call exportCouponsCall(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportCouponsCall(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, OffsetDateTime deletedBefore, OffsetDateTime deletedAfter, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -6032,6 +6678,14 @@ public okhttp3.Call exportCouponsCall(Long applicationId, BigDecimal campaignId, localVarQueryParams.addAll(localVarApiClient.parameterToPair("valuesOnly", valuesOnly)); } + if (deletedBefore != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("deletedBefore", deletedBefore)); + } + + if (deletedAfter != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("deletedAfter", deletedAfter)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -6054,7 +6708,7 @@ public okhttp3.Call exportCouponsCall(Long applicationId, BigDecimal campaignId, } @SuppressWarnings("rawtypes") - private okhttp3.Call exportCouponsValidateBeforeCall(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, final ApiCallback _callback) throws ApiException { + private okhttp3.Call exportCouponsValidateBeforeCall(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, OffsetDateTime deletedBefore, OffsetDateTime deletedAfter, final ApiCallback _callback) throws ApiException { // verify the required parameter 'applicationId' is set if (applicationId == null) { @@ -6062,7 +6716,7 @@ private okhttp3.Call exportCouponsValidateBeforeCall(Long applicationId, BigDeci } - okhttp3.Call localVarCall = exportCouponsCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, _callback); + okhttp3.Call localVarCall = exportCouponsCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter, _callback); return localVarCall; } @@ -6085,6 +6739,8 @@ private okhttp3.Call exportCouponsValidateBeforeCall(Long applicationId, BigDeci * @param dateFormat Determines the format of dates in the export document. (optional) * @param campaignState 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) * @param valuesOnly Filter results to only return the coupon codes (`value` column) without the associated coupon data. (optional, default to false) + * @param deletedBefore 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) + * @param deletedAfter 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) * @return String * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6093,8 +6749,8 @@ private okhttp3.Call exportCouponsValidateBeforeCall(Long applicationId, BigDeci 200 OK - */ - public String exportCoupons(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly) throws ApiException { - ApiResponse localVarResp = exportCouponsWithHttpInfo(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly); + public String exportCoupons(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, OffsetDateTime deletedBefore, OffsetDateTime deletedAfter) throws ApiException { + ApiResponse localVarResp = exportCouponsWithHttpInfo(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter); return localVarResp.getData(); } @@ -6116,6 +6772,8 @@ public String exportCoupons(Long applicationId, BigDecimal campaignId, String so * @param dateFormat Determines the format of dates in the export document. (optional) * @param campaignState 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) * @param valuesOnly Filter results to only return the coupon codes (`value` column) without the associated coupon data. (optional, default to false) + * @param deletedBefore 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) + * @param deletedAfter 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) * @return ApiResponse<String> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6124,8 +6782,8 @@ public String exportCoupons(Long applicationId, BigDecimal campaignId, String so 200 OK - */ - public ApiResponse exportCouponsWithHttpInfo(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly) throws ApiException { - okhttp3.Call localVarCall = exportCouponsValidateBeforeCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, null); + public ApiResponse exportCouponsWithHttpInfo(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, OffsetDateTime deletedBefore, OffsetDateTime deletedAfter) throws ApiException { + okhttp3.Call localVarCall = exportCouponsValidateBeforeCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -6148,6 +6806,8 @@ public ApiResponse exportCouponsWithHttpInfo(Long applicationId, BigDeci * @param dateFormat Determines the format of dates in the export document. (optional) * @param campaignState 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) * @param valuesOnly Filter results to only return the coupon codes (`value` column) without the associated coupon data. (optional, default to false) + * @param deletedBefore 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) + * @param deletedAfter 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) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -6157,9 +6817,9 @@ public ApiResponse exportCouponsWithHttpInfo(Long applicationId, BigDeci 200 OK - */ - public okhttp3.Call exportCouponsAsync(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportCouponsAsync(Long applicationId, BigDecimal campaignId, String sort, String value, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String valid, String usable, Long referralId, String recipientIntegrationId, String batchId, Boolean exactMatch, String dateFormat, String campaignState, Boolean valuesOnly, OffsetDateTime deletedBefore, OffsetDateTime deletedAfter, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportCouponsValidateBeforeCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, _callback); + okhttp3.Call localVarCall = exportCouponsValidateBeforeCall(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -6169,6 +6829,8 @@ public okhttp3.Call exportCouponsAsync(Long applicationId, BigDecimal campaignId * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param profileIntegrationId Only return sessions for the customer that matches this customer integration ID. (optional) * @param dateFormat Determines the format of dates in the export document. (optional) * @param customerSessionState Filter results by state. (optional) @@ -6181,7 +6843,7 @@ public okhttp3.Call exportCouponsAsync(Long applicationId, BigDecimal campaignId 200 OK - */ - public okhttp3.Call exportCustomerSessionsCall(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportCustomerSessionsCall(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime updatedBefore, OffsetDateTime updatedAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -6198,6 +6860,14 @@ public okhttp3.Call exportCustomerSessionsCall(Long applicationId, OffsetDateTim localVarQueryParams.addAll(localVarApiClient.parameterToPair("createdAfter", createdAfter)); } + if (updatedBefore != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("updatedBefore", updatedBefore)); + } + + if (updatedAfter != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("updatedAfter", updatedAfter)); + } + if (profileIntegrationId != null) { localVarQueryParams.addAll(localVarApiClient.parameterToPair("profileIntegrationId", profileIntegrationId)); } @@ -6232,7 +6902,7 @@ public okhttp3.Call exportCustomerSessionsCall(Long applicationId, OffsetDateTim } @SuppressWarnings("rawtypes") - private okhttp3.Call exportCustomerSessionsValidateBeforeCall(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { + private okhttp3.Call exportCustomerSessionsValidateBeforeCall(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime updatedBefore, OffsetDateTime updatedAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { // verify the required parameter 'applicationId' is set if (applicationId == null) { @@ -6240,7 +6910,7 @@ private okhttp3.Call exportCustomerSessionsValidateBeforeCall(Long applicationId } - okhttp3.Call localVarCall = exportCustomerSessionsCall(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState, _callback); + okhttp3.Call localVarCall = exportCustomerSessionsCall(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState, _callback); return localVarCall; } @@ -6251,6 +6921,8 @@ private okhttp3.Call exportCustomerSessionsValidateBeforeCall(Long applicationId * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param profileIntegrationId Only return sessions for the customer that matches this customer integration ID. (optional) * @param dateFormat Determines the format of dates in the export document. (optional) * @param customerSessionState Filter results by state. (optional) @@ -6262,8 +6934,8 @@ private okhttp3.Call exportCustomerSessionsValidateBeforeCall(Long applicationId 200 OK - */ - public String exportCustomerSessions(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String profileIntegrationId, String dateFormat, String customerSessionState) throws ApiException { - ApiResponse localVarResp = exportCustomerSessionsWithHttpInfo(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState); + public String exportCustomerSessions(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime updatedBefore, OffsetDateTime updatedAfter, String profileIntegrationId, String dateFormat, String customerSessionState) throws ApiException { + ApiResponse localVarResp = exportCustomerSessionsWithHttpInfo(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState); return localVarResp.getData(); } @@ -6273,6 +6945,8 @@ public String exportCustomerSessions(Long applicationId, OffsetDateTime createdB * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param profileIntegrationId Only return sessions for the customer that matches this customer integration ID. (optional) * @param dateFormat Determines the format of dates in the export document. (optional) * @param customerSessionState Filter results by state. (optional) @@ -6284,8 +6958,8 @@ public String exportCustomerSessions(Long applicationId, OffsetDateTime createdB 200 OK - */ - public ApiResponse exportCustomerSessionsWithHttpInfo(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String profileIntegrationId, String dateFormat, String customerSessionState) throws ApiException { - okhttp3.Call localVarCall = exportCustomerSessionsValidateBeforeCall(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState, null); + public ApiResponse exportCustomerSessionsWithHttpInfo(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime updatedBefore, OffsetDateTime updatedAfter, String profileIntegrationId, String dateFormat, String customerSessionState) throws ApiException { + okhttp3.Call localVarCall = exportCustomerSessionsValidateBeforeCall(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -6296,6 +6970,8 @@ public ApiResponse exportCustomerSessionsWithHttpInfo(Long applicationId * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) + * @param updatedAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string. (optional) * @param profileIntegrationId Only return sessions for the customer that matches this customer integration ID. (optional) * @param dateFormat Determines the format of dates in the export document. (optional) * @param customerSessionState Filter results by state. (optional) @@ -6308,9 +6984,9 @@ public ApiResponse exportCustomerSessionsWithHttpInfo(Long applicationId 200 OK - */ - public okhttp3.Call exportCustomerSessionsAsync(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportCustomerSessionsAsync(Long applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime updatedBefore, OffsetDateTime updatedAfter, String profileIntegrationId, String dateFormat, String customerSessionState, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportCustomerSessionsValidateBeforeCall(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState, _callback); + okhttp3.Call localVarCall = exportCustomerSessionsValidateBeforeCall(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -6589,6 +7265,7 @@ public okhttp3.Call exportEffectsAsync(Long applicationId, BigDecimal campaignId * Build call for exportLoyaltyBalance * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6602,7 +7279,7 @@ public okhttp3.Call exportEffectsAsync(Long applicationId, BigDecimal campaignId * @deprecated */ @Deprecated - public okhttp3.Call exportLoyaltyBalanceCall(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyBalanceCall(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -6615,6 +7292,10 @@ public okhttp3.Call exportLoyaltyBalanceCall(String loyaltyProgramId, OffsetDate localVarQueryParams.addAll(localVarApiClient.parameterToPair("endDate", endDate)); } + if (balances != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("balances", balances)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -6638,7 +7319,7 @@ public okhttp3.Call exportLoyaltyBalanceCall(String loyaltyProgramId, OffsetDate @Deprecated @SuppressWarnings("rawtypes") - private okhttp3.Call exportLoyaltyBalanceValidateBeforeCall(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + private okhttp3.Call exportLoyaltyBalanceValidateBeforeCall(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { // verify the required parameter 'loyaltyProgramId' is set if (loyaltyProgramId == null) { @@ -6646,7 +7327,7 @@ private okhttp3.Call exportLoyaltyBalanceValidateBeforeCall(String loyaltyProgra } - okhttp3.Call localVarCall = exportLoyaltyBalanceCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyBalanceCall(loyaltyProgramId, endDate, balances, _callback); return localVarCall; } @@ -6656,6 +7337,7 @@ private okhttp3.Call exportLoyaltyBalanceValidateBeforeCall(String loyaltyProgra * To export customer loyalty balances to CSV, use the [Export customer loyalty balances to CSV](/management-api#tag/Loyalty/operation/exportLoyaltyBalances) endpoint. Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @return String * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6668,8 +7350,8 @@ private okhttp3.Call exportLoyaltyBalanceValidateBeforeCall(String loyaltyProgra * @deprecated */ @Deprecated - public String exportLoyaltyBalance(String loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - ApiResponse localVarResp = exportLoyaltyBalanceWithHttpInfo(loyaltyProgramId, endDate); + public String exportLoyaltyBalance(String loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + ApiResponse localVarResp = exportLoyaltyBalanceWithHttpInfo(loyaltyProgramId, endDate, balances); return localVarResp.getData(); } @@ -6678,6 +7360,7 @@ public String exportLoyaltyBalance(String loyaltyProgramId, OffsetDateTime endDa * To export customer loyalty balances to CSV, use the [Export customer loyalty balances to CSV](/management-api#tag/Loyalty/operation/exportLoyaltyBalances) endpoint. Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @return ApiResponse<String> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6690,8 +7373,8 @@ public String exportLoyaltyBalance(String loyaltyProgramId, OffsetDateTime endDa * @deprecated */ @Deprecated - public ApiResponse exportLoyaltyBalanceWithHttpInfo(String loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyBalanceValidateBeforeCall(loyaltyProgramId, endDate, null); + public ApiResponse exportLoyaltyBalanceWithHttpInfo(String loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + okhttp3.Call localVarCall = exportLoyaltyBalanceValidateBeforeCall(loyaltyProgramId, endDate, balances, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -6701,6 +7384,7 @@ public ApiResponse exportLoyaltyBalanceWithHttpInfo(String loyaltyProgra * To export customer loyalty balances to CSV, use the [Export customer loyalty balances to CSV](/management-api#tag/Loyalty/operation/exportLoyaltyBalances) endpoint. Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -6714,9 +7398,9 @@ public ApiResponse exportLoyaltyBalanceWithHttpInfo(String loyaltyProgra * @deprecated */ @Deprecated - public okhttp3.Call exportLoyaltyBalanceAsync(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyBalanceAsync(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyBalanceValidateBeforeCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyBalanceValidateBeforeCall(loyaltyProgramId, endDate, balances, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -6725,6 +7409,7 @@ public okhttp3.Call exportLoyaltyBalanceAsync(String loyaltyProgramId, OffsetDat * Build call for exportLoyaltyBalances * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. (optional) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6736,7 +7421,7 @@ public okhttp3.Call exportLoyaltyBalanceAsync(String loyaltyProgramId, OffsetDat 401 Unauthorized - */ - public okhttp3.Call exportLoyaltyBalancesCall(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyBalancesCall(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -6749,6 +7434,10 @@ public okhttp3.Call exportLoyaltyBalancesCall(String loyaltyProgramId, OffsetDat localVarQueryParams.addAll(localVarApiClient.parameterToPair("endDate", endDate)); } + if (balances != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("balances", balances)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -6771,7 +7460,7 @@ public okhttp3.Call exportLoyaltyBalancesCall(String loyaltyProgramId, OffsetDat } @SuppressWarnings("rawtypes") - private okhttp3.Call exportLoyaltyBalancesValidateBeforeCall(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + private okhttp3.Call exportLoyaltyBalancesValidateBeforeCall(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { // verify the required parameter 'loyaltyProgramId' is set if (loyaltyProgramId == null) { @@ -6779,7 +7468,7 @@ private okhttp3.Call exportLoyaltyBalancesValidateBeforeCall(String loyaltyProgr } - okhttp3.Call localVarCall = exportLoyaltyBalancesCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyBalancesCall(loyaltyProgramId, endDate, balances, _callback); return localVarCall; } @@ -6789,6 +7478,7 @@ private okhttp3.Call exportLoyaltyBalancesValidateBeforeCall(String loyaltyProgr * Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The generated file can contain the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subledger, when applicable. - `profileIntegrationID`: The integration ID of the customer profile. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. - `currentTier`: The tier that the customer is in at the time of the export. * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. (optional) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @return String * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6799,8 +7489,8 @@ private okhttp3.Call exportLoyaltyBalancesValidateBeforeCall(String loyaltyProgr 401 Unauthorized - */ - public String exportLoyaltyBalances(String loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - ApiResponse localVarResp = exportLoyaltyBalancesWithHttpInfo(loyaltyProgramId, endDate); + public String exportLoyaltyBalances(String loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + ApiResponse localVarResp = exportLoyaltyBalancesWithHttpInfo(loyaltyProgramId, endDate, balances); return localVarResp.getData(); } @@ -6809,6 +7499,7 @@ public String exportLoyaltyBalances(String loyaltyProgramId, OffsetDateTime endD * Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The generated file can contain the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subledger, when applicable. - `profileIntegrationID`: The integration ID of the customer profile. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. - `currentTier`: The tier that the customer is in at the time of the export. * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. (optional) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @return ApiResponse<String> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6819,8 +7510,8 @@ public String exportLoyaltyBalances(String loyaltyProgramId, OffsetDateTime endD 401 Unauthorized - */ - public ApiResponse exportLoyaltyBalancesWithHttpInfo(String loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyBalancesValidateBeforeCall(loyaltyProgramId, endDate, null); + public ApiResponse exportLoyaltyBalancesWithHttpInfo(String loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + okhttp3.Call localVarCall = exportLoyaltyBalancesValidateBeforeCall(loyaltyProgramId, endDate, balances, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -6830,6 +7521,7 @@ public ApiResponse exportLoyaltyBalancesWithHttpInfo(String loyaltyProgr * Download a CSV file containing the balance of each customer in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The generated file can contain the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subledger, when applicable. - `profileIntegrationID`: The integration ID of the customer profile. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. - `currentTier`: The tier that the customer is in at the time of the export. * @param loyaltyProgramId The identifier for the loyalty program. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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. > - This parameter does not affect the `currentTier` field in the CSV file, which shows the customer's tier at the time of export. (optional) + * @param balances Filters which balance fields are included in the CSV export. `currentBalance` is always returned. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -6841,9 +7533,9 @@ public ApiResponse exportLoyaltyBalancesWithHttpInfo(String loyaltyProgr 401 Unauthorized - */ - public okhttp3.Call exportLoyaltyBalancesAsync(String loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyBalancesAsync(String loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyBalancesValidateBeforeCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyBalancesValidateBeforeCall(loyaltyProgramId, endDate, balances, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -6852,6 +7544,7 @@ public okhttp3.Call exportLoyaltyBalancesAsync(String loyaltyProgramId, OffsetDa * Build call for exportLoyaltyCardBalances * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6863,7 +7556,7 @@ public okhttp3.Call exportLoyaltyBalancesAsync(String loyaltyProgramId, OffsetDa 401 Unauthorized - */ - public okhttp3.Call exportLoyaltyCardBalancesCall(Long loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyCardBalancesCall(Long loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -6876,6 +7569,10 @@ public okhttp3.Call exportLoyaltyCardBalancesCall(Long loyaltyProgramId, OffsetD localVarQueryParams.addAll(localVarApiClient.parameterToPair("endDate", endDate)); } + if (balances != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("balances", balances)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -6898,7 +7595,7 @@ public okhttp3.Call exportLoyaltyCardBalancesCall(Long loyaltyProgramId, OffsetD } @SuppressWarnings("rawtypes") - private okhttp3.Call exportLoyaltyCardBalancesValidateBeforeCall(Long loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + private okhttp3.Call exportLoyaltyCardBalancesValidateBeforeCall(Long loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { // verify the required parameter 'loyaltyProgramId' is set if (loyaltyProgramId == null) { @@ -6906,7 +7603,7 @@ private okhttp3.Call exportLoyaltyCardBalancesValidateBeforeCall(Long loyaltyPro } - okhttp3.Call localVarCall = exportLoyaltyCardBalancesCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyCardBalancesCall(loyaltyProgramId, endDate, balances, _callback); return localVarCall; } @@ -6916,6 +7613,7 @@ private okhttp3.Call exportLoyaltyCardBalancesValidateBeforeCall(Long loyaltyPro * Download a CSV file containing the balances of all cards in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subdleger, when applicatble. - `cardIdentifier`: The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `cardState`:The state of the loyalty card. It can be `active` or `inactive`. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. (optional) * @return String * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6926,8 +7624,8 @@ private okhttp3.Call exportLoyaltyCardBalancesValidateBeforeCall(Long loyaltyPro 401 Unauthorized - */ - public String exportLoyaltyCardBalances(Long loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - ApiResponse localVarResp = exportLoyaltyCardBalancesWithHttpInfo(loyaltyProgramId, endDate); + public String exportLoyaltyCardBalances(Long loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + ApiResponse localVarResp = exportLoyaltyCardBalancesWithHttpInfo(loyaltyProgramId, endDate, balances); return localVarResp.getData(); } @@ -6936,6 +7634,7 @@ public String exportLoyaltyCardBalances(Long loyaltyProgramId, OffsetDateTime en * Download a CSV file containing the balances of all cards in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subdleger, when applicatble. - `cardIdentifier`: The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `cardState`:The state of the loyalty card. It can be `active` or `inactive`. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. (optional) * @return ApiResponse<String> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -6946,8 +7645,8 @@ public String exportLoyaltyCardBalances(Long loyaltyProgramId, OffsetDateTime en 401 Unauthorized - */ - public ApiResponse exportLoyaltyCardBalancesWithHttpInfo(Long loyaltyProgramId, OffsetDateTime endDate) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyCardBalancesValidateBeforeCall(loyaltyProgramId, endDate, null); + public ApiResponse exportLoyaltyCardBalancesWithHttpInfo(Long loyaltyProgramId, OffsetDateTime endDate, String balances) throws ApiException { + okhttp3.Call localVarCall = exportLoyaltyCardBalancesValidateBeforeCall(loyaltyProgramId, endDate, balances, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -6957,6 +7656,7 @@ public ApiResponse exportLoyaltyCardBalancesWithHttpInfo(Long loyaltyPro * Download a CSV file containing the balances of all cards in the loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `loyaltyProgramID`: The ID of the loyalty program. - `loyaltySubledger`: The name of the subdleger, when applicatble. - `cardIdentifier`: The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `cardState`:The state of the loyalty card. It can be `active` or `inactive`. - `currentBalance`: The current point balance. - `pendingBalance`: The number of pending points. - `expiredBalance`: The number of expired points. - `spentBalance`: The number of spent points. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) + * @param balances Filters which balance fields are included in the CSV export. By default, all balance fields are included. When this parameter is provided, only the listed fields contain values and the rest are returned empty. Accepted values: - `currentBalance` - `pendingBalance` - `expiredBalance` - `spentBalance` - `negativeBalance` Multiple values must be provided as a comma-separated list. **Note:** - The `negativeBalance` value is not supported for card balance exports. - Providing an unsupported or invalid value returns a `400 Bad Request` error. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -6968,9 +7668,9 @@ public ApiResponse exportLoyaltyCardBalancesWithHttpInfo(Long loyaltyPro 401 Unauthorized - */ - public okhttp3.Call exportLoyaltyCardBalancesAsync(Long loyaltyProgramId, OffsetDateTime endDate, final ApiCallback _callback) throws ApiException { + public okhttp3.Call exportLoyaltyCardBalancesAsync(Long loyaltyProgramId, OffsetDateTime endDate, String balances, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = exportLoyaltyCardBalancesValidateBeforeCall(loyaltyProgramId, endDate, _callback); + okhttp3.Call localVarCall = exportLoyaltyCardBalancesValidateBeforeCall(loyaltyProgramId, endDate, balances, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -7218,7 +7918,7 @@ private okhttp3.Call exportLoyaltyCardsValidateBeforeCall(Long loyaltyProgramId, /** * Export loyalty cards - * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. + * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param batchId Filter results by loyalty card batch ID. (optional) * @param createdBefore Only return loyalty cards created before this timestamp. **Note:** This must be an RFC3339 timestamp string. (optional) @@ -7241,7 +7941,7 @@ public String exportLoyaltyCards(Long loyaltyProgramId, String batchId, OffsetDa /** * Export loyalty cards - * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. + * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param batchId Filter results by loyalty card batch ID. (optional) * @param createdBefore Only return loyalty cards created before this timestamp. **Note:** This must be an RFC3339 timestamp string. (optional) @@ -7265,7 +7965,7 @@ public ApiResponse exportLoyaltyCardsWithHttpInfo(Long loyaltyProgramId, /** * Export loyalty cards (asynchronously) - * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. + * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param batchId Filter results by loyalty card batch ID. (optional) * @param createdBefore Only return loyalty cards created before this timestamp. **Note:** This must be an RFC3339 timestamp string. (optional) @@ -7942,7 +8642,7 @@ private okhttp3.Call generateCouponRejectionsValidateBeforeCall(String sessionIn * @param applicationId Filter results by Application ID. (optional) * @param language The [ISO-639](https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes) code of the language in which the summary will be generated. (optional) * @param couponCode The coupon code for which to get the rejection reason. (optional) - * @return InlineResponse20053 + * @return InlineResponse20055 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -7950,8 +8650,8 @@ private okhttp3.Call generateCouponRejectionsValidateBeforeCall(String sessionIn
200 OK -
*/ - public InlineResponse20053 generateCouponRejections(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode) throws ApiException { - ApiResponse localVarResp = generateCouponRejectionsWithHttpInfo(sessionIntegrationId, applicationId, language, couponCode); + public InlineResponse20055 generateCouponRejections(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode) throws ApiException { + ApiResponse localVarResp = generateCouponRejectionsWithHttpInfo(sessionIntegrationId, applicationId, language, couponCode); return localVarResp.getData(); } @@ -7962,7 +8662,7 @@ public InlineResponse20053 generateCouponRejections(String sessionIntegrationId, * @param applicationId Filter results by Application ID. (optional) * @param language The [ISO-639](https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes) code of the language in which the summary will be generated. (optional) * @param couponCode The coupon code for which to get the rejection reason. (optional) - * @return ApiResponse<InlineResponse20053> + * @return ApiResponse<InlineResponse20055> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -7970,9 +8670,9 @@ public InlineResponse20053 generateCouponRejections(String sessionIntegrationId,
200 OK -
*/ - public ApiResponse generateCouponRejectionsWithHttpInfo(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode) throws ApiException { + public ApiResponse generateCouponRejectionsWithHttpInfo(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode) throws ApiException { okhttp3.Call localVarCall = generateCouponRejectionsValidateBeforeCall(sessionIntegrationId, applicationId, language, couponCode, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -7992,10 +8692,10 @@ public ApiResponse generateCouponRejectionsWithHttpInfo(Str 200 OK - */ - public okhttp3.Call generateCouponRejectionsAsync(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode, final ApiCallback _callback) throws ApiException { + public okhttp3.Call generateCouponRejectionsAsync(String sessionIntegrationId, BigDecimal applicationId, String language, String couponCode, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = generateCouponRejectionsValidateBeforeCall(sessionIntegrationId, applicationId, language, couponCode, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -8536,7 +9236,9 @@ public okhttp3.Call getAccountCollectionAsync(Long collectionId, final ApiCallba 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call getAchievementCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; @@ -8569,6 +9271,7 @@ public okhttp3.Call getAchievementCall(Long applicationId, Long campaignId, Long return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } + @Deprecated @SuppressWarnings("rawtypes") private okhttp3.Call getAchievementValidateBeforeCall(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { @@ -8608,7 +9311,9 @@ private okhttp3.Call getAchievementValidateBeforeCall(Long applicationId, Long c 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public Achievement getAchievement(Long applicationId, Long campaignId, Long achievementId) throws ApiException { ApiResponse localVarResp = getAchievementWithHttpInfo(applicationId, campaignId, achievementId); return localVarResp.getData(); @@ -8629,7 +9334,9 @@ public Achievement getAchievement(Long applicationId, Long campaignId, Long achi 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public ApiResponse getAchievementWithHttpInfo(Long applicationId, Long campaignId, Long achievementId) throws ApiException { okhttp3.Call localVarCall = getAchievementValidateBeforeCall(applicationId, campaignId, achievementId, null); Type localVarReturnType = new TypeToken(){}.getType(); @@ -8652,7 +9359,9 @@ public ApiResponse getAchievementWithHttpInfo(Long applicationId, L 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call getAchievementAsync(Long applicationId, Long campaignId, Long achievementId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getAchievementValidateBeforeCall(applicationId, campaignId, achievementId, _callback); @@ -8661,8 +9370,8 @@ public okhttp3.Call getAchievementAsync(Long applicationId, Long campaignId, Lon return localVarCall; } /** - * Build call for getAdditionalCost - * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) + * Build call for getAchievementV2 + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8670,14 +9379,16 @@ public okhttp3.Call getAchievementAsync(Long applicationId, Long campaignId, Lon + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
404 Not found -
*/ - public okhttp3.Call getAdditionalCostCall(Long additionalCostId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAchievementV2Call(Long achievementId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/additional_costs/{additionalCostId}" - .replaceAll("\\{" + "additionalCostId" + "\\}", localVarApiClient.escapeString(additionalCostId.toString())); + String localVarPath = "/v2/achievements/{achievementId}" + .replaceAll("\\{" + "achievementId" + "\\}", localVarApiClient.escapeString(achievementId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8703,58 +9414,62 @@ public okhttp3.Call getAdditionalCostCall(Long additionalCostId, final ApiCallba } @SuppressWarnings("rawtypes") - private okhttp3.Call getAdditionalCostValidateBeforeCall(Long additionalCostId, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getAchievementV2ValidateBeforeCall(Long achievementId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'additionalCostId' is set - if (additionalCostId == null) { - throw new ApiException("Missing the required parameter 'additionalCostId' when calling getAdditionalCost(Async)"); + // verify the required parameter 'achievementId' is set + if (achievementId == null) { + throw new ApiException("Missing the required parameter 'achievementId' when calling getAchievementV2(Async)"); } - okhttp3.Call localVarCall = getAdditionalCostCall(additionalCostId, _callback); + okhttp3.Call localVarCall = getAchievementV2Call(achievementId, _callback); return localVarCall; } /** - * Get additional cost - * Returns the additional cost. - * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) - * @return AccountAdditionalCost + * Get achievement + * Retrieve the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @return AchievementV2 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
404 Not found -
*/ - public AccountAdditionalCost getAdditionalCost(Long additionalCostId) throws ApiException { - ApiResponse localVarResp = getAdditionalCostWithHttpInfo(additionalCostId); + public AchievementV2 getAchievementV2(Long achievementId) throws ApiException { + ApiResponse localVarResp = getAchievementV2WithHttpInfo(achievementId); return localVarResp.getData(); } /** - * Get additional cost - * Returns the additional cost. - * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) - * @return ApiResponse<AccountAdditionalCost> + * Get achievement + * Retrieve the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @return ApiResponse<AchievementV2> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
404 Not found -
*/ - public ApiResponse getAdditionalCostWithHttpInfo(Long additionalCostId) throws ApiException { - okhttp3.Call localVarCall = getAdditionalCostValidateBeforeCall(additionalCostId, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse getAchievementV2WithHttpInfo(Long achievementId) throws ApiException { + okhttp3.Call localVarCall = getAchievementV2ValidateBeforeCall(achievementId, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get additional cost (asynchronously) - * Returns the additional cost. - * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) + * Get achievement (asynchronously) + * Retrieve the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -8762,20 +9477,20 @@ public ApiResponse getAdditionalCostWithHttpInfo(Long add + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
404 Not found -
*/ - public okhttp3.Call getAdditionalCostAsync(Long additionalCostId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAchievementV2Async(Long achievementId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getAdditionalCostValidateBeforeCall(additionalCostId, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = getAchievementV2ValidateBeforeCall(achievementId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getAdditionalCosts - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) + * Build call for getAdditionalCost + * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8785,26 +9500,15 @@ public okhttp3.Call getAdditionalCostAsync(Long additionalCostId, final ApiCallb 200 OK - */ - public okhttp3.Call getAdditionalCostsCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAdditionalCostCall(Long additionalCostId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/additional_costs"; + String localVarPath = "/v1/additional_costs/{additionalCostId}" + .replaceAll("\\{" + "additionalCostId" + "\\}", localVarApiClient.escapeString(additionalCostId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); - if (pageSize != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); - } - - if (skip != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); - } - - if (sort != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); - } - Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -8827,21 +9531,145 @@ public okhttp3.Call getAdditionalCostsCall(Long pageSize, Long skip, String sort } @SuppressWarnings("rawtypes") - private okhttp3.Call getAdditionalCostsValidateBeforeCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getAdditionalCostValidateBeforeCall(Long additionalCostId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'additionalCostId' is set + if (additionalCostId == null) { + throw new ApiException("Missing the required parameter 'additionalCostId' when calling getAdditionalCost(Async)"); + } - okhttp3.Call localVarCall = getAdditionalCostsCall(pageSize, skip, sort, _callback); + okhttp3.Call localVarCall = getAdditionalCostCall(additionalCostId, _callback); return localVarCall; } /** - * List additional costs - * Returns all the defined additional costs for the account. - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) + * Get additional cost + * Returns the additional cost. + * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) + * @return AccountAdditionalCost + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public AccountAdditionalCost getAdditionalCost(Long additionalCostId) throws ApiException { + ApiResponse localVarResp = getAdditionalCostWithHttpInfo(additionalCostId); + return localVarResp.getData(); + } + + /** + * Get additional cost + * Returns the additional cost. + * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) + * @return ApiResponse<AccountAdditionalCost> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public ApiResponse getAdditionalCostWithHttpInfo(Long additionalCostId) throws ApiException { + okhttp3.Call localVarCall = getAdditionalCostValidateBeforeCall(additionalCostId, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Get additional cost (asynchronously) + * Returns the additional cost. + * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call getAdditionalCostAsync(Long additionalCostId, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getAdditionalCostValidateBeforeCall(additionalCostId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for getAdditionalCosts + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return InlineResponse20040 + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call getAdditionalCostsCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/additional_costs"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); + } + + if (sort != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getAdditionalCostsValidateBeforeCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + + + okhttp3.Call localVarCall = getAdditionalCostsCall(pageSize, skip, sort, _callback); + return localVarCall; + + } + + /** + * List additional costs + * Returns all the defined additional costs for the account. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @return InlineResponse20041 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -8849,8 +9677,8 @@ private okhttp3.Call getAdditionalCostsValidateBeforeCall(Long pageSize, Long sk
200 OK -
*/ - public InlineResponse20040 getAdditionalCosts(Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getAdditionalCostsWithHttpInfo(pageSize, skip, sort); + public InlineResponse20041 getAdditionalCosts(Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getAdditionalCostsWithHttpInfo(pageSize, skip, sort); return localVarResp.getData(); } @@ -8860,7 +9688,7 @@ public InlineResponse20040 getAdditionalCosts(Long pageSize, Long skip, String s * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return ApiResponse<InlineResponse20040> + * @return ApiResponse<InlineResponse20041> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -8868,9 +9696,9 @@ public InlineResponse20040 getAdditionalCosts(Long pageSize, Long skip, String s
200 OK -
*/ - public ApiResponse getAdditionalCostsWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { + public ApiResponse getAdditionalCostsWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { okhttp3.Call localVarCall = getAdditionalCostsValidateBeforeCall(pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -8889,10 +9717,10 @@ public ApiResponse getAdditionalCostsWithHttpInfo(Long page 200 OK - */ - public okhttp3.Call getAdditionalCostsAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAdditionalCostsAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getAdditionalCostsValidateBeforeCall(pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -9462,7 +10290,7 @@ private okhttp3.Call getApplicationCustomerFriendsValidateBeforeCall(Long applic * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) - * @return InlineResponse20037 + * @return InlineResponse20038 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -9470,8 +10298,8 @@ private okhttp3.Call getApplicationCustomerFriendsValidateBeforeCall(Long applic
200 OK -
*/ - public InlineResponse20037 getApplicationCustomerFriends(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { - ApiResponse localVarResp = getApplicationCustomerFriendsWithHttpInfo(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); + public InlineResponse20038 getApplicationCustomerFriends(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { + ApiResponse localVarResp = getApplicationCustomerFriendsWithHttpInfo(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); return localVarResp.getData(); } @@ -9484,7 +10312,7 @@ public InlineResponse20037 getApplicationCustomerFriends(Long applicationId, Str * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) - * @return ApiResponse<InlineResponse20037> + * @return ApiResponse<InlineResponse20038> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -9492,9 +10320,9 @@ public InlineResponse20037 getApplicationCustomerFriends(Long applicationId, Str
200 OK -
*/ - public ApiResponse getApplicationCustomerFriendsWithHttpInfo(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { + public ApiResponse getApplicationCustomerFriendsWithHttpInfo(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { okhttp3.Call localVarCall = getApplicationCustomerFriendsValidateBeforeCall(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -9516,10 +10344,10 @@ public ApiResponse getApplicationCustomerFriendsWithHttpInf 200 OK - */ - public okhttp3.Call getApplicationCustomerFriendsAsync(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getApplicationCustomerFriendsAsync(Long applicationId, String integrationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getApplicationCustomerFriendsValidateBeforeCall(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -9888,7 +10716,7 @@ private okhttp3.Call getApplicationEventTypesValidateBeforeCall(Long application * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return InlineResponse20033 + * @return InlineResponse20034 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -9896,8 +10724,8 @@ private okhttp3.Call getApplicationEventTypesValidateBeforeCall(Long application
200 OK -
*/ - public InlineResponse20033 getApplicationEventTypes(Long applicationId, Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getApplicationEventTypesWithHttpInfo(applicationId, pageSize, skip, sort); + public InlineResponse20034 getApplicationEventTypes(Long applicationId, Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getApplicationEventTypesWithHttpInfo(applicationId, pageSize, skip, sort); return localVarResp.getData(); } @@ -9908,7 +10736,7 @@ public InlineResponse20033 getApplicationEventTypes(Long applicationId, Long pag * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return ApiResponse<InlineResponse20033> + * @return ApiResponse<InlineResponse20034> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -9916,9 +10744,9 @@ public InlineResponse20033 getApplicationEventTypes(Long applicationId, Long pag
200 OK -
*/ - public ApiResponse getApplicationEventTypesWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort) throws ApiException { + public ApiResponse getApplicationEventTypesWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort) throws ApiException { okhttp3.Call localVarCall = getApplicationEventTypesValidateBeforeCall(applicationId, pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -9938,10 +10766,10 @@ public ApiResponse getApplicationEventTypesWithHttpInfo(Lon 200 OK - */ - public okhttp3.Call getApplicationEventTypesAsync(Long applicationId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getApplicationEventTypesAsync(Long applicationId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getApplicationEventTypesValidateBeforeCall(applicationId, pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -10095,7 +10923,7 @@ private okhttp3.Call getApplicationEventsWithoutTotalCountValidateBeforeCall(Lon * @param ruleQuery Rule name filter for events (optional) * @param campaignQuery Campaign name filter for events (optional) * @param effectType The type of effect that was triggered. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). (optional) - * @return InlineResponse20032 + * @return InlineResponse20033 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10103,8 +10931,8 @@ private okhttp3.Call getApplicationEventsWithoutTotalCountValidateBeforeCall(Lon
200 OK -
*/ - public InlineResponse20032 getApplicationEventsWithoutTotalCount(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType) throws ApiException { - ApiResponse localVarResp = getApplicationEventsWithoutTotalCountWithHttpInfo(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); + public InlineResponse20033 getApplicationEventsWithoutTotalCount(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType) throws ApiException { + ApiResponse localVarResp = getApplicationEventsWithoutTotalCountWithHttpInfo(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); return localVarResp.getData(); } @@ -10127,7 +10955,7 @@ public InlineResponse20032 getApplicationEventsWithoutTotalCount(Long applicatio * @param ruleQuery Rule name filter for events (optional) * @param campaignQuery Campaign name filter for events (optional) * @param effectType The type of effect that was triggered. See [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). (optional) - * @return ApiResponse<InlineResponse20032> + * @return ApiResponse<InlineResponse20033> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10135,9 +10963,9 @@ public InlineResponse20032 getApplicationEventsWithoutTotalCount(Long applicatio
200 OK -
*/ - public ApiResponse getApplicationEventsWithoutTotalCountWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType) throws ApiException { + public ApiResponse getApplicationEventsWithoutTotalCountWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType) throws ApiException { okhttp3.Call localVarCall = getApplicationEventsWithoutTotalCountValidateBeforeCall(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -10169,10 +10997,10 @@ public ApiResponse getApplicationEventsWithoutTotalCountWit 200 OK - */ - public okhttp3.Call getApplicationEventsWithoutTotalCountAsync(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getApplicationEventsWithoutTotalCountAsync(Long applicationId, Long pageSize, Long skip, String sort, String type, OffsetDateTime createdBefore, OffsetDateTime createdAfter, String session, String profile, String customerName, String customerEmail, String couponCode, String referralCode, String ruleQuery, String campaignQuery, String effectType, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getApplicationEventsWithoutTotalCountValidateBeforeCall(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -10505,10 +11333,12 @@ public okhttp3.Call getApplicationSessionsAsync(Long applicationId, Long pageSiz return localVarCall; } /** - * Build call for getApplications + * Build call for getApplicationSessionsByCustomerAttributes + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) + * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10518,11 +11348,12 @@ public okhttp3.Call getApplicationSessionsAsync(Long applicationId, Long pageSiz 200 OK - */ - public okhttp3.Call getApplicationsCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { - Object localVarPostBody = null; + public okhttp3.Call getApplicationSessionsByCustomerAttributesCall(Long applicationId, CustomerProfileSearchQuery body, Long pageSize, Long skip, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; // create path and map variables - String localVarPath = "/v1/applications"; + String localVarPath = "/v1/applications/{applicationId}/sessions_search" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -10534,8 +11365,8 @@ public okhttp3.Call getApplicationsCall(Long pageSize, Long skip, String sort, f localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); } - if (sort != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); + if (withTotalResultSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("withTotalResultSize", withTotalResultSize)); } Map localVarHeaderParams = new HashMap(); @@ -10550,31 +11381,43 @@ public okhttp3.Call getApplicationsCall(Long pageSize, Long skip, String sort, f } final String[] localVarContentTypes = { - + "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); localVarHeaderParams.put("Content-Type", localVarContentType); String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") - private okhttp3.Call getApplicationsValidateBeforeCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getApplicationSessionsByCustomerAttributesValidateBeforeCall(Long applicationId, CustomerProfileSearchQuery body, Long pageSize, Long skip, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling getApplicationSessionsByCustomerAttributes(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling getApplicationSessionsByCustomerAttributes(Async)"); + } - okhttp3.Call localVarCall = getApplicationsCall(pageSize, skip, sort, _callback); + okhttp3.Call localVarCall = getApplicationSessionsByCustomerAttributesCall(applicationId, body, pageSize, skip, withTotalResultSize, _callback); return localVarCall; } /** - * List Applications - * List all the Applications in the current account. + * List Application sessions matching the given customer attributes + * Get a list of the Application sessions matching the provided customer profile attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) - * @return InlineResponse2008 + * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) + * @return InlineResponse20032 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10582,18 +11425,20 @@ private okhttp3.Call getApplicationsValidateBeforeCall(Long pageSize, Long skip,
200 OK -
*/ - public InlineResponse2008 getApplications(Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getApplicationsWithHttpInfo(pageSize, skip, sort); + public InlineResponse20032 getApplicationSessionsByCustomerAttributes(Long applicationId, CustomerProfileSearchQuery body, Long pageSize, Long skip, Boolean withTotalResultSize) throws ApiException { + ApiResponse localVarResp = getApplicationSessionsByCustomerAttributesWithHttpInfo(applicationId, body, pageSize, skip, withTotalResultSize); return localVarResp.getData(); } /** - * List Applications - * List all the Applications in the current account. + * List Application sessions matching the given customer attributes + * Get a list of the Application sessions matching the provided customer profile attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) - * @return ApiResponse<InlineResponse2008> + * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) + * @return ApiResponse<InlineResponse20032> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10601,18 +11446,20 @@ public InlineResponse2008 getApplications(Long pageSize, Long skip, String sort)
200 OK -
*/ - public ApiResponse getApplicationsWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { - okhttp3.Call localVarCall = getApplicationsValidateBeforeCall(pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse getApplicationSessionsByCustomerAttributesWithHttpInfo(Long applicationId, CustomerProfileSearchQuery body, Long pageSize, Long skip, Boolean withTotalResultSize) throws ApiException { + okhttp3.Call localVarCall = getApplicationSessionsByCustomerAttributesValidateBeforeCall(applicationId, body, pageSize, skip, withTotalResultSize, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List Applications (asynchronously) - * List all the Applications in the current account. + * List Application sessions matching the given customer attributes (asynchronously) + * Get a list of the Application sessions matching the provided customer profile attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param body body (required) * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) + * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -10622,16 +11469,18 @@ public ApiResponse getApplicationsWithHttpInfo(Long pageSize 200 OK - */ - public okhttp3.Call getApplicationsAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getApplicationSessionsByCustomerAttributesAsync(Long applicationId, CustomerProfileSearchQuery body, Long pageSize, Long skip, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getApplicationsValidateBeforeCall(pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = getApplicationSessionsByCustomerAttributesValidateBeforeCall(applicationId, body, pageSize, skip, withTotalResultSize, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getAttribute - * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) + * Build call for getApplications + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10641,15 +11490,26 @@ public okhttp3.Call getApplicationsAsync(Long pageSize, Long skip, String sort, 200 OK - */ - public okhttp3.Call getAttributeCall(Long attributeId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getApplicationsCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/attributes/{attributeId}" - .replaceAll("\\{" + "attributeId" + "\\}", localVarApiClient.escapeString(attributeId.toString())); + String localVarPath = "/v1/applications"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); + } + + if (sort != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -10672,24 +11532,21 @@ public okhttp3.Call getAttributeCall(Long attributeId, final ApiCallback _callba } @SuppressWarnings("rawtypes") - private okhttp3.Call getAttributeValidateBeforeCall(Long attributeId, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'attributeId' is set - if (attributeId == null) { - throw new ApiException("Missing the required parameter 'attributeId' when calling getAttribute(Async)"); - } + private okhttp3.Call getApplicationsValidateBeforeCall(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getAttributeCall(attributeId, _callback); + okhttp3.Call localVarCall = getApplicationsCall(pageSize, skip, sort, _callback); return localVarCall; } /** - * Get custom attribute - * Retrieve the specified custom attribute. - * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) - * @return Attribute + * List Applications + * List all the Applications in the current account. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @return InlineResponse2008 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10697,9 +11554,124 @@ private okhttp3.Call getAttributeValidateBeforeCall(Long attributeId, final ApiC
200 OK -
*/ - public Attribute getAttribute(Long attributeId) throws ApiException { - ApiResponse localVarResp = getAttributeWithHttpInfo(attributeId); - return localVarResp.getData(); + public InlineResponse2008 getApplications(Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getApplicationsWithHttpInfo(pageSize, skip, sort); + return localVarResp.getData(); + } + + /** + * List Applications + * List all the Applications in the current account. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @return ApiResponse<InlineResponse2008> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public ApiResponse getApplicationsWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { + okhttp3.Call localVarCall = getApplicationsValidateBeforeCall(pageSize, skip, sort, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * List Applications (asynchronously) + * List all the Applications in the current account. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call getApplicationsAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getApplicationsValidateBeforeCall(pageSize, skip, sort, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for getAttribute + * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call getAttributeCall(Long attributeId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/attributes/{attributeId}" + .replaceAll("\\{" + "attributeId" + "\\}", localVarApiClient.escapeString(attributeId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getAttributeValidateBeforeCall(Long attributeId, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'attributeId' is set + if (attributeId == null) { + throw new ApiException("Missing the required parameter 'attributeId' when calling getAttribute(Async)"); + } + + + okhttp3.Call localVarCall = getAttributeCall(attributeId, _callback); + return localVarCall; + + } + + /** + * Get custom attribute + * Retrieve the specified custom attribute. + * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) + * @return Attribute + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public Attribute getAttribute(Long attributeId) throws ApiException { + ApiResponse localVarResp = getAttributeWithHttpInfo(attributeId); + return localVarResp.getData(); } /** @@ -10747,6 +11719,7 @@ public okhttp3.Call getAttributeAsync(Long attributeId, final ApiCallback 200 OK - */ - public okhttp3.Call getAttributesCall(Long pageSize, Long skip, String sort, String entity, String applicationIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAttributesCall(Long pageSize, Long skip, String sort, String entity, String applicationIds, String loyaltyProgramIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -10787,6 +11760,10 @@ public okhttp3.Call getAttributesCall(Long pageSize, Long skip, String sort, Str localVarQueryParams.addAll(localVarApiClient.parameterToPair("applicationIds", applicationIds)); } + if (loyaltyProgramIds != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("loyaltyProgramIds", loyaltyProgramIds)); + } + if (type != null) { localVarQueryParams.addAll(localVarApiClient.parameterToPair("type", type)); } @@ -10821,10 +11798,10 @@ public okhttp3.Call getAttributesCall(Long pageSize, Long skip, String sort, Str } @SuppressWarnings("rawtypes") - private okhttp3.Call getAttributesValidateBeforeCall(Long pageSize, Long skip, String sort, String entity, String applicationIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getAttributesValidateBeforeCall(Long pageSize, Long skip, String sort, String entity, String applicationIds, String loyaltyProgramIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getAttributesCall(pageSize, skip, sort, entity, applicationIds, type, kind, search, _callback); + okhttp3.Call localVarCall = getAttributesCall(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search, _callback); return localVarCall; } @@ -10837,10 +11814,11 @@ private okhttp3.Call getAttributesValidateBeforeCall(Long pageSize, Long skip, S * @param sort 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) * @param entity Returned attributes will be filtered by supplied entity. (optional) * @param applicationIds Returned attributes will be filtered by supplied application ids (optional) + * @param loyaltyProgramIds 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) * @param type Returned attributes will be filtered by supplied type (optional) * @param kind Returned attributes will be filtered by supplied kind (builtin or custom) (optional) * @param search Returned attributes will be filtered by searching case insensitive through Attribute name, description and type (optional) - * @return InlineResponse20038 + * @return InlineResponse20039 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10848,8 +11826,8 @@ private okhttp3.Call getAttributesValidateBeforeCall(Long pageSize, Long skip, S
200 OK -
*/ - public InlineResponse20038 getAttributes(Long pageSize, Long skip, String sort, String entity, String applicationIds, String type, String kind, String search) throws ApiException { - ApiResponse localVarResp = getAttributesWithHttpInfo(pageSize, skip, sort, entity, applicationIds, type, kind, search); + public InlineResponse20039 getAttributes(Long pageSize, Long skip, String sort, String entity, String applicationIds, String loyaltyProgramIds, String type, String kind, String search) throws ApiException { + ApiResponse localVarResp = getAttributesWithHttpInfo(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search); return localVarResp.getData(); } @@ -10861,10 +11839,11 @@ public InlineResponse20038 getAttributes(Long pageSize, Long skip, String sort, * @param sort 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) * @param entity Returned attributes will be filtered by supplied entity. (optional) * @param applicationIds Returned attributes will be filtered by supplied application ids (optional) + * @param loyaltyProgramIds 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) * @param type Returned attributes will be filtered by supplied type (optional) * @param kind Returned attributes will be filtered by supplied kind (builtin or custom) (optional) * @param search Returned attributes will be filtered by searching case insensitive through Attribute name, description and type (optional) - * @return ApiResponse<InlineResponse20038> + * @return ApiResponse<InlineResponse20039> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10872,9 +11851,9 @@ public InlineResponse20038 getAttributes(Long pageSize, Long skip, String sort,
200 OK -
*/ - public ApiResponse getAttributesWithHttpInfo(Long pageSize, Long skip, String sort, String entity, String applicationIds, String type, String kind, String search) throws ApiException { - okhttp3.Call localVarCall = getAttributesValidateBeforeCall(pageSize, skip, sort, entity, applicationIds, type, kind, search, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse getAttributesWithHttpInfo(Long pageSize, Long skip, String sort, String entity, String applicationIds, String loyaltyProgramIds, String type, String kind, String search) throws ApiException { + okhttp3.Call localVarCall = getAttributesValidateBeforeCall(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -10886,6 +11865,7 @@ public ApiResponse getAttributesWithHttpInfo(Long pageSize, * @param sort 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) * @param entity Returned attributes will be filtered by supplied entity. (optional) * @param applicationIds Returned attributes will be filtered by supplied application ids (optional) + * @param loyaltyProgramIds 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) * @param type Returned attributes will be filtered by supplied type (optional) * @param kind Returned attributes will be filtered by supplied kind (builtin or custom) (optional) * @param search Returned attributes will be filtered by searching case insensitive through Attribute name, description and type (optional) @@ -10898,10 +11878,10 @@ public ApiResponse getAttributesWithHttpInfo(Long pageSize, 200 OK - */ - public okhttp3.Call getAttributesAsync(Long pageSize, Long skip, String sort, String entity, String applicationIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAttributesAsync(Long pageSize, Long skip, String sort, String entity, String applicationIds, String loyaltyProgramIds, String type, String kind, String search, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getAttributesValidateBeforeCall(pageSize, skip, sort, entity, applicationIds, type, kind, search, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = getAttributesValidateBeforeCall(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -10990,7 +11970,7 @@ private okhttp3.Call getAudienceMembershipsValidateBeforeCall(Long audienceId, L * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param profileQuery The filter to select a profile. (optional) - * @return InlineResponse20036 + * @return InlineResponse20037 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -10999,8 +11979,8 @@ private okhttp3.Call getAudienceMembershipsValidateBeforeCall(Long audienceId, L
404 Not found -
*/ - public InlineResponse20036 getAudienceMemberships(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery) throws ApiException { - ApiResponse localVarResp = getAudienceMembershipsWithHttpInfo(audienceId, pageSize, skip, sort, profileQuery); + public InlineResponse20037 getAudienceMemberships(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery) throws ApiException { + ApiResponse localVarResp = getAudienceMembershipsWithHttpInfo(audienceId, pageSize, skip, sort, profileQuery); return localVarResp.getData(); } @@ -11012,7 +11992,7 @@ public InlineResponse20036 getAudienceMemberships(Long audienceId, Long pageSize * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param profileQuery The filter to select a profile. (optional) - * @return ApiResponse<InlineResponse20036> + * @return ApiResponse<InlineResponse20037> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -11021,9 +12001,9 @@ public InlineResponse20036 getAudienceMemberships(Long audienceId, Long pageSize
404 Not found -
*/ - public ApiResponse getAudienceMembershipsWithHttpInfo(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery) throws ApiException { + public ApiResponse getAudienceMembershipsWithHttpInfo(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery) throws ApiException { okhttp3.Call localVarCall = getAudienceMembershipsValidateBeforeCall(audienceId, pageSize, skip, sort, profileQuery, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -11045,10 +12025,10 @@ public ApiResponse getAudienceMembershipsWithHttpInfo(Long 404 Not found - */ - public okhttp3.Call getAudienceMembershipsAsync(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAudienceMembershipsAsync(Long audienceId, Long pageSize, Long skip, String sort, String profileQuery, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getAudienceMembershipsValidateBeforeCall(audienceId, pageSize, skip, sort, profileQuery, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -11128,7 +12108,7 @@ private okhttp3.Call getAudiencesValidateBeforeCall(Long pageSize, Long skip, St * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) - * @return InlineResponse20034 + * @return InlineResponse20035 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -11136,8 +12116,8 @@ private okhttp3.Call getAudiencesValidateBeforeCall(Long pageSize, Long skip, St
200 OK -
*/ - public InlineResponse20034 getAudiences(Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { - ApiResponse localVarResp = getAudiencesWithHttpInfo(pageSize, skip, sort, withTotalResultSize); + public InlineResponse20035 getAudiences(Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { + ApiResponse localVarResp = getAudiencesWithHttpInfo(pageSize, skip, sort, withTotalResultSize); return localVarResp.getData(); } @@ -11148,7 +12128,7 @@ public InlineResponse20034 getAudiences(Long pageSize, Long skip, String sort, B * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) - * @return ApiResponse<InlineResponse20034> + * @return ApiResponse<InlineResponse20035> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -11156,9 +12136,9 @@ public InlineResponse20034 getAudiences(Long pageSize, Long skip, String sort, B
200 OK -
*/ - public ApiResponse getAudiencesWithHttpInfo(Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { + public ApiResponse getAudiencesWithHttpInfo(Long pageSize, Long skip, String sort, Boolean withTotalResultSize) throws ApiException { okhttp3.Call localVarCall = getAudiencesValidateBeforeCall(pageSize, skip, sort, withTotalResultSize, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -11178,16 +12158,16 @@ public ApiResponse getAudiencesWithHttpInfo(Long pageSize, 200 OK - */ - public okhttp3.Call getAudiencesAsync(Long pageSize, Long skip, String sort, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAudiencesAsync(Long pageSize, Long skip, String sort, Boolean withTotalResultSize, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getAudiencesValidateBeforeCall(pageSize, skip, sort, withTotalResultSize, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** * Build call for getAudiencesAnalytics - * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. (required) + * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. (required) * @param sort 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) * @param _callback Callback for upload/download progress * @return Call to execute @@ -11252,9 +12232,9 @@ private okhttp3.Call getAudiencesAnalyticsValidateBeforeCall(String audienceIds, /** * List audience analytics * Get a list of audience IDs and their member count. - * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. (required) + * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. (required) * @param sort 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) - * @return InlineResponse20035 + * @return InlineResponse20036 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -11262,17 +12242,17 @@ private okhttp3.Call getAudiencesAnalyticsValidateBeforeCall(String audienceIds,
200 OK -
*/ - public InlineResponse20035 getAudiencesAnalytics(String audienceIds, String sort) throws ApiException { - ApiResponse localVarResp = getAudiencesAnalyticsWithHttpInfo(audienceIds, sort); + public InlineResponse20036 getAudiencesAnalytics(String audienceIds, String sort) throws ApiException { + ApiResponse localVarResp = getAudiencesAnalyticsWithHttpInfo(audienceIds, sort); return localVarResp.getData(); } /** * List audience analytics * Get a list of audience IDs and their member count. - * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. (required) + * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. (required) * @param sort 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) - * @return ApiResponse<InlineResponse20035> + * @return ApiResponse<InlineResponse20036> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -11280,16 +12260,16 @@ public InlineResponse20035 getAudiencesAnalytics(String audienceIds, String sort
200 OK -
*/ - public ApiResponse getAudiencesAnalyticsWithHttpInfo(String audienceIds, String sort) throws ApiException { + public ApiResponse getAudiencesAnalyticsWithHttpInfo(String audienceIds, String sort) throws ApiException { okhttp3.Call localVarCall = getAudiencesAnalyticsValidateBeforeCall(audienceIds, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** * List audience analytics (asynchronously) * Get a list of audience IDs and their member count. - * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. (required) + * @param audienceIds The IDs of one or more audiences, separated by commas, by which to filter results. Do not provide more than 1000 audience IDs. (required) * @param sort 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) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -11300,10 +12280,10 @@ public ApiResponse getAudiencesAnalyticsWithHttpInfo(String 200 OK - */ - public okhttp3.Call getAudiencesAnalyticsAsync(String audienceIds, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getAudiencesAnalyticsAsync(String audienceIds, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getAudiencesAnalyticsValidateBeforeCall(audienceIds, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -12136,7 +13116,7 @@ public okhttp3.Call getCampaignTemplatesAsync(Long pageSize, Long skip, String s * @param sort 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) * @param campaignState 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) * @param name Filter results performing case-insensitive matching against the name of the campaign. (optional) - * @param tags Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values (optional) + * @param tags Filter results performing case-insensitive matching against the tags of the campaign. (optional) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param startBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) @@ -12156,7 +13136,7 @@ public okhttp3.Call getCampaignTemplatesAsync(Long pageSize, Long skip, String s 400 Bad request - */ - public okhttp3.Call getCampaignsCall(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, String tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getCampaignsCall(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, List tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -12186,7 +13166,7 @@ public okhttp3.Call getCampaignsCall(Long applicationId, Long pageSize, Long ski } if (tags != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("tags", tags)); + localVarCollectionQueryParams.addAll(localVarApiClient.parameterToPairs("multi", "tags", tags)); } if (createdBefore != null) { @@ -12247,7 +13227,7 @@ public okhttp3.Call getCampaignsCall(Long applicationId, Long pageSize, Long ski } @SuppressWarnings("rawtypes") - private okhttp3.Call getCampaignsValidateBeforeCall(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, String tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getCampaignsValidateBeforeCall(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, List tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'applicationId' is set if (applicationId == null) { @@ -12269,7 +13249,7 @@ private okhttp3.Call getCampaignsValidateBeforeCall(Long applicationId, Long pag * @param sort 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) * @param campaignState 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) * @param name Filter results performing case-insensitive matching against the name of the campaign. (optional) - * @param tags Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values (optional) + * @param tags Filter results performing case-insensitive matching against the tags of the campaign. (optional) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param startBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) @@ -12288,7 +13268,7 @@ private okhttp3.Call getCampaignsValidateBeforeCall(Long applicationId, Long pag 400 Bad request - */ - public InlineResponse2009 getCampaigns(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, String tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId) throws ApiException { + public InlineResponse2009 getCampaigns(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, List tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId) throws ApiException { ApiResponse localVarResp = getCampaignsWithHttpInfo(applicationId, pageSize, skip, sort, campaignState, name, tags, createdBefore, createdAfter, startBefore, startAfter, endBefore, endAfter, campaignGroupId, templateId, storeId); return localVarResp.getData(); } @@ -12302,7 +13282,7 @@ public InlineResponse2009 getCampaigns(Long applicationId, Long pageSize, Long s * @param sort 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) * @param campaignState 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) * @param name Filter results performing case-insensitive matching against the name of the campaign. (optional) - * @param tags Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values (optional) + * @param tags Filter results performing case-insensitive matching against the tags of the campaign. (optional) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param startBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) @@ -12321,7 +13301,7 @@ public InlineResponse2009 getCampaigns(Long applicationId, Long pageSize, Long s 400 Bad request - */ - public ApiResponse getCampaignsWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, String tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId) throws ApiException { + public ApiResponse getCampaignsWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, List tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId) throws ApiException { okhttp3.Call localVarCall = getCampaignsValidateBeforeCall(applicationId, pageSize, skip, sort, campaignState, name, tags, createdBefore, createdAfter, startBefore, startAfter, endBefore, endAfter, campaignGroupId, templateId, storeId, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); @@ -12336,7 +13316,7 @@ public ApiResponse getCampaignsWithHttpInfo(Long application * @param sort 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) * @param campaignState 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) * @param name Filter results performing case-insensitive matching against the name of the campaign. (optional) - * @param tags Filter results performing case-insensitive matching against the tags of the campaign. When used in conjunction with the \"name\" query parameter, a logical OR will be performed to search both tags and name for the provided values (optional) + * @param tags Filter results performing case-insensitive matching against the tags of the campaign. (optional) * @param createdBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign creation timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) * @param startBefore Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the campaign start time timestamp. You can use any time zone setting. Talon.One will convert to UTC internally. (optional) @@ -12356,7 +13336,7 @@ public ApiResponse getCampaignsWithHttpInfo(Long application 400 Bad request - */ - public okhttp3.Call getCampaignsAsync(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, String tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getCampaignsAsync(Long applicationId, Long pageSize, Long skip, String sort, String campaignState, String name, List tags, OffsetDateTime createdBefore, OffsetDateTime createdAfter, OffsetDateTime startBefore, OffsetDateTime startAfter, OffsetDateTime endBefore, OffsetDateTime endAfter, Long campaignGroupId, Long templateId, Long storeId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getCampaignsValidateBeforeCall(applicationId, pageSize, skip, sort, campaignState, name, tags, createdBefore, createdAfter, startBefore, startAfter, endBefore, endAfter, campaignGroupId, templateId, storeId, _callback); Type localVarReturnType = new TypeToken(){}.getType(); @@ -12481,7 +13461,7 @@ private okhttp3.Call getChangesValidateBeforeCall(Long pageSize, Long skip, Stri * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param managementKeyId Filter results that match the given management key ID. (optional) * @param includeOld When this flag is set to false, the state without the change will not be returned. The default value is true. (optional) - * @return InlineResponse20044 + * @return InlineResponse20045 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -12489,8 +13469,8 @@ private okhttp3.Call getChangesValidateBeforeCall(Long pageSize, Long skip, Stri
200 OK -
*/ - public InlineResponse20044 getChanges(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld) throws ApiException { - ApiResponse localVarResp = getChangesWithHttpInfo(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); + public InlineResponse20045 getChanges(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld) throws ApiException { + ApiResponse localVarResp = getChangesWithHttpInfo(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); return localVarResp.getData(); } @@ -12508,7 +13488,7 @@ public InlineResponse20044 getChanges(Long pageSize, Long skip, String sort, Big * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param managementKeyId Filter results that match the given management key ID. (optional) * @param includeOld When this flag is set to false, the state without the change will not be returned. The default value is true. (optional) - * @return ApiResponse<InlineResponse20044> + * @return ApiResponse<InlineResponse20045> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -12516,9 +13496,9 @@ public InlineResponse20044 getChanges(Long pageSize, Long skip, String sort, Big
200 OK -
*/ - public ApiResponse getChangesWithHttpInfo(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld) throws ApiException { + public ApiResponse getChangesWithHttpInfo(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld) throws ApiException { okhttp3.Call localVarCall = getChangesValidateBeforeCall(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -12545,10 +13525,10 @@ public ApiResponse getChangesWithHttpInfo(Long pageSize, Lo 200 OK - */ - public okhttp3.Call getChangesAsync(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getChangesAsync(Long pageSize, Long skip, String sort, BigDecimal applicationId, String entityPath, Long userId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Long managementKeyId, Boolean includeOld, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getChangesValidateBeforeCall(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -13789,7 +14769,7 @@ private okhttp3.Call getCustomerProfileAchievementProgressValidateBeforeCall(Lon * @param skip The number of items to skip when paging through large result sets. (optional) * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (optional) * @param title Filter results by the `title` of an achievement. (optional) - * @return InlineResponse20052 + * @return InlineResponse20054 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -13799,8 +14779,8 @@ private okhttp3.Call getCustomerProfileAchievementProgressValidateBeforeCall(Lon
401 Unauthorized -
*/ - public InlineResponse20052 getCustomerProfileAchievementProgress(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title) throws ApiException { - ApiResponse localVarResp = getCustomerProfileAchievementProgressWithHttpInfo(applicationId, integrationId, pageSize, skip, achievementId, title); + public InlineResponse20054 getCustomerProfileAchievementProgress(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title) throws ApiException { + ApiResponse localVarResp = getCustomerProfileAchievementProgressWithHttpInfo(applicationId, integrationId, pageSize, skip, achievementId, title); return localVarResp.getData(); } @@ -13813,7 +14793,7 @@ public InlineResponse20052 getCustomerProfileAchievementProgress(Long applicatio * @param skip The number of items to skip when paging through large result sets. (optional) * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievements) endpoint. (optional) * @param title Filter results by the `title` of an achievement. (optional) - * @return ApiResponse<InlineResponse20052> + * @return ApiResponse<InlineResponse20054> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -13823,9 +14803,9 @@ public InlineResponse20052 getCustomerProfileAchievementProgress(Long applicatio
401 Unauthorized -
*/ - public ApiResponse getCustomerProfileAchievementProgressWithHttpInfo(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title) throws ApiException { + public ApiResponse getCustomerProfileAchievementProgressWithHttpInfo(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title) throws ApiException { okhttp3.Call localVarCall = getCustomerProfileAchievementProgressValidateBeforeCall(applicationId, integrationId, pageSize, skip, achievementId, title, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -13849,10 +14829,10 @@ public ApiResponse getCustomerProfileAchievementProgressWit 401 Unauthorized - */ - public okhttp3.Call getCustomerProfileAchievementProgressAsync(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getCustomerProfileAchievementProgressAsync(Long applicationId, String integrationId, Long pageSize, Long skip, Long achievementId, String title, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getCustomerProfileAchievementProgressValidateBeforeCall(applicationId, integrationId, pageSize, skip, achievementId, title, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -14342,7 +15322,7 @@ private okhttp3.Call getEventTypesValidateBeforeCall(String name, Boolean includ * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return InlineResponse20042 + * @return InlineResponse20043 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -14350,8 +15330,8 @@ private okhttp3.Call getEventTypesValidateBeforeCall(String name, Boolean includ
200 OK -
*/ - public InlineResponse20042 getEventTypes(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getEventTypesWithHttpInfo(name, includeOldVersions, pageSize, skip, sort); + public InlineResponse20043 getEventTypes(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getEventTypesWithHttpInfo(name, includeOldVersions, pageSize, skip, sort); return localVarResp.getData(); } @@ -14363,7 +15343,7 @@ public InlineResponse20042 getEventTypes(String name, Boolean includeOldVersions * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return ApiResponse<InlineResponse20042> + * @return ApiResponse<InlineResponse20043> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -14371,9 +15351,9 @@ public InlineResponse20042 getEventTypes(String name, Boolean includeOldVersions
200 OK -
*/ - public ApiResponse getEventTypesWithHttpInfo(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort) throws ApiException { + public ApiResponse getEventTypesWithHttpInfo(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort) throws ApiException { okhttp3.Call localVarCall = getEventTypesValidateBeforeCall(name, includeOldVersions, pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -14394,10 +15374,10 @@ public ApiResponse getEventTypesWithHttpInfo(String name, B 200 OK - */ - public okhttp3.Call getEventTypesAsync(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getEventTypesAsync(String name, Boolean includeOldVersions, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getEventTypesValidateBeforeCall(name, includeOldVersions, pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -14604,7 +15584,7 @@ private okhttp3.Call getExportsValidateBeforeCall(Long pageSize, Long skip, BigD * @param applicationId Filter results by Application ID. (optional) * @param campaignId Filter by the campaign ID on which the limit counters are used. (optional) * @param entity The name of the entity type that was exported. (optional) - * @return InlineResponse20045 + * @return InlineResponse20046 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -14612,8 +15592,8 @@ private okhttp3.Call getExportsValidateBeforeCall(Long pageSize, Long skip, BigD
200 OK -
*/ - public InlineResponse20045 getExports(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity) throws ApiException { - ApiResponse localVarResp = getExportsWithHttpInfo(pageSize, skip, applicationId, campaignId, entity); + public InlineResponse20046 getExports(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity) throws ApiException { + ApiResponse localVarResp = getExportsWithHttpInfo(pageSize, skip, applicationId, campaignId, entity); return localVarResp.getData(); } @@ -14625,7 +15605,7 @@ public InlineResponse20045 getExports(Long pageSize, Long skip, BigDecimal appli * @param applicationId Filter results by Application ID. (optional) * @param campaignId Filter by the campaign ID on which the limit counters are used. (optional) * @param entity The name of the entity type that was exported. (optional) - * @return ApiResponse<InlineResponse20045> + * @return ApiResponse<InlineResponse20046> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -14633,9 +15613,9 @@ public InlineResponse20045 getExports(Long pageSize, Long skip, BigDecimal appli
200 OK -
*/ - public ApiResponse getExportsWithHttpInfo(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity) throws ApiException { + public ApiResponse getExportsWithHttpInfo(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity) throws ApiException { okhttp3.Call localVarCall = getExportsValidateBeforeCall(pageSize, skip, applicationId, campaignId, entity, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -14656,10 +15636,10 @@ public ApiResponse getExportsWithHttpInfo(Long pageSize, Lo 200 OK - */ - public okhttp3.Call getExportsAsync(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getExportsAsync(Long pageSize, Long skip, BigDecimal applicationId, Long campaignId, String entity, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getExportsValidateBeforeCall(pageSize, skip, applicationId, campaignId, entity, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -14897,8 +15877,8 @@ private okhttp3.Call getLoyaltyCardTransactionLogsValidateBeforeCall(Long loyalt } /** - * List card's transactions - * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. + * List card's transactions (Management API) + * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -14924,8 +15904,8 @@ public InlineResponse20021 getLoyaltyCardTransactionLogs(Long loyaltyProgramId, } /** - * List card's transactions - * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. + * List card's transactions (Management API) + * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -14952,8 +15932,8 @@ public ApiResponse getLoyaltyCardTransactionLogsWithHttpInf } /** - * List card's transactions (asynchronously) - * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. + * List card's transactions (Management API) (asynchronously) + * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param loyaltyCardId Identifier of the loyalty card. You can get the identifier with the [List loyalty cards](https://docs.talon.one/management-api#tag/Loyalty-cards/operation/getLoyaltyCards) endpoint. **Important**: The loyalty card ID requires [URL encoding](https://www.w3schools.com/tags//ref_urlencode.asp) if it contains special characters. For example, you must encode `NewCard2026%` as `NewCard2026%25`. (required) * @param startDate Date and time from which results are returned. Results are filtered by transaction creation date. > [!note] **Note** > - This 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) @@ -15235,8 +16215,8 @@ private okhttp3.Call getLoyaltyLedgerBalancesValidateBeforeCall(Long loyaltyProg } /** - * Get customer's loyalty balances - * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] If no filtering options are applied, you retrieve all loyalty > balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) + * Get customer's loyalty balances (Management API) + * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) @@ -15260,8 +16240,8 @@ public LoyaltyBalancesWithTiers getLoyaltyLedgerBalances(Long loyaltyProgramId, } /** - * Get customer's loyalty balances - * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] If no filtering options are applied, you retrieve all loyalty > balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) + * Get customer's loyalty balances (Management API) + * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) @@ -15286,8 +16266,8 @@ public ApiResponse getLoyaltyLedgerBalancesWithHttpInf } /** - * Get customer's loyalty balances (asynchronously) - * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] If no filtering options are applied, you retrieve all loyalty > balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) + * Get customer's loyalty balances (Management API) (asynchronously) + * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param endDate Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. > [!note] **Note** > - This 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) @@ -15666,8 +16646,8 @@ private okhttp3.Call getLoyaltyProgramProfileLedgerTransactionsValidateBeforeCal } /** - * List customer's loyalty transactions - * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] To retrieve all loyalty program transaction logs in a given > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) > endpoint. + * List customer's loyalty transactions (Management API) + * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). > - To retrieve all loyalty program transaction logs in a given loyalty program, use the > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) @@ -15696,8 +16676,8 @@ public InlineResponse2005 getLoyaltyProgramProfileLedgerTransactions(Long loyalt } /** - * List customer's loyalty transactions - * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] To retrieve all loyalty program transaction logs in a given > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) > endpoint. + * List customer's loyalty transactions (Management API) + * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). > - To retrieve all loyalty program transaction logs in a given loyalty program, use the > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) @@ -15727,8 +16707,8 @@ public ApiResponse getLoyaltyProgramProfileLedgerTransaction } /** - * List customer's loyalty transactions (asynchronously) - * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] To retrieve all loyalty program transaction logs in a given > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) > endpoint. + * List customer's loyalty transactions (Management API) (asynchronously) + * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). > - To retrieve all loyalty program transaction logs in a given loyalty program, use the > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. * @param loyaltyProgramId 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. (required) * @param integrationId 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. (required) * @param customerSessionIDs Filter the results by a list of customer session IDs. To include multiple IDs, repeat the parameter for each one, for example, `?customerSessionIDs=id1&customerSessionIDs=id2`. The response contains only data associated with the specified sessions. (optional) @@ -16116,7 +17096,7 @@ private okhttp3.Call getLoyaltyStatisticsValidateBeforeCall(Long loyaltyProgramI /** * Get loyalty program statistics - * > [warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. + * > [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @return LoyaltyDashboardData * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -16135,7 +17115,7 @@ public LoyaltyDashboardData getLoyaltyStatistics(Long loyaltyProgramId) throws A /** * Get loyalty program statistics - * > [warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. + * > [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @return ApiResponse<LoyaltyDashboardData> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -16155,7 +17135,7 @@ public ApiResponse getLoyaltyStatisticsWithHttpInfo(Long l /** * Get loyalty program statistics (asynchronously) - * > [warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. + * > [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -16184,6 +17164,7 @@ public okhttp3.Call getLoyaltyStatisticsAsync(Long loyaltyProgramId, final ApiCa * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param cursor A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. (optional) + * @param pageSize The maximum number of message log entries to return. (optional, default to 50l) * @param period Filter results by time period. Choose between the available relative time frames. (optional) * @param isSuccessful Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. (optional) * @param applicationId Filter results by Application ID. (optional) @@ -16200,7 +17181,7 @@ public okhttp3.Call getLoyaltyStatisticsAsync(Long loyaltyProgramId, final ApiCa 200 OK - */ - public okhttp3.Call getMessageLogsCall(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getMessageLogsCall(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, Long pageSize, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -16232,6 +17213,10 @@ public okhttp3.Call getMessageLogsCall(String entityType, String messageID, Stri localVarQueryParams.addAll(localVarApiClient.parameterToPair("cursor", cursor)); } + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + if (period != null) { localVarQueryParams.addAll(localVarApiClient.parameterToPair("period", period)); } @@ -16286,7 +17271,7 @@ public okhttp3.Call getMessageLogsCall(String entityType, String messageID, Stri } @SuppressWarnings("rawtypes") - private okhttp3.Call getMessageLogsValidateBeforeCall(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getMessageLogsValidateBeforeCall(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, Long pageSize, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { // verify the required parameter 'entityType' is set if (entityType == null) { @@ -16294,7 +17279,7 @@ private okhttp3.Call getMessageLogsValidateBeforeCall(String entityType, String } - okhttp3.Call localVarCall = getMessageLogsCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, _callback); + okhttp3.Call localVarCall = getMessageLogsCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, _callback); return localVarCall; } @@ -16309,6 +17294,7 @@ private okhttp3.Call getMessageLogsValidateBeforeCall(String entityType, String * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param cursor A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. (optional) + * @param pageSize The maximum number of message log entries to return. (optional, default to 50l) * @param period Filter results by time period. Choose between the available relative time frames. (optional) * @param isSuccessful Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. (optional) * @param applicationId Filter results by Application ID. (optional) @@ -16324,8 +17310,8 @@ private okhttp3.Call getMessageLogsValidateBeforeCall(String entityType, String 200 OK - */ - public MessageLogEntries getMessageLogs(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs) throws ApiException { - ApiResponse localVarResp = getMessageLogsWithHttpInfo(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); + public MessageLogEntries getMessageLogs(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, Long pageSize, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs) throws ApiException { + ApiResponse localVarResp = getMessageLogsWithHttpInfo(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); return localVarResp.getData(); } @@ -16339,6 +17325,7 @@ public MessageLogEntries getMessageLogs(String entityType, String messageID, Str * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param cursor A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. (optional) + * @param pageSize The maximum number of message log entries to return. (optional, default to 50l) * @param period Filter results by time period. Choose between the available relative time frames. (optional) * @param isSuccessful Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. (optional) * @param applicationId Filter results by Application ID. (optional) @@ -16354,8 +17341,8 @@ public MessageLogEntries getMessageLogs(String entityType, String messageID, Str 200 OK - */ - public ApiResponse getMessageLogsWithHttpInfo(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs) throws ApiException { - okhttp3.Call localVarCall = getMessageLogsValidateBeforeCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, null); + public ApiResponse getMessageLogsWithHttpInfo(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, Long pageSize, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs) throws ApiException { + okhttp3.Call localVarCall = getMessageLogsValidateBeforeCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, null); Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -16370,6 +17357,7 @@ public ApiResponse getMessageLogsWithHttpInfo(String entityTy * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. Use UTC time. (optional) * @param cursor A specific unique value in the database. If this value is not given, the server fetches results starting with the first record. (optional) + * @param pageSize The maximum number of message log entries to return. (optional, default to 50l) * @param period Filter results by time period. Choose between the available relative time frames. (optional) * @param isSuccessful Indicates whether to return log entries with either successful or unsuccessful HTTP response codes. When set to`true`, only log entries with `2xx` response codes are returned. When set to `false`, only log entries with `4xx` and `5xx` response codes are returned. (optional) * @param applicationId Filter results by Application ID. (optional) @@ -16386,9 +17374,9 @@ public ApiResponse getMessageLogsWithHttpInfo(String entityTy 200 OK - */ - public okhttp3.Call getMessageLogsAsync(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getMessageLogsAsync(String entityType, String messageID, String changeType, String notificationIDs, OffsetDateTime createdBefore, OffsetDateTime createdAfter, byte[] cursor, Long pageSize, String period, Boolean isSuccessful, BigDecimal applicationId, BigDecimal campaignId, Long loyaltyProgramId, Long responseCode, String webhookIDs, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getMessageLogsValidateBeforeCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, _callback); + okhttp3.Call localVarCall = getMessageLogsValidateBeforeCall(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs, _callback); Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; @@ -16829,12 +17817,10 @@ public okhttp3.Call getRulesetAsync(Long applicationId, Long campaignId, Long ru return localVarCall; } /** - * Build call for getRulesets + * Build call for getRulesetV2 * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) + * @param rulesetId The ID of the ruleset. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16844,28 +17830,17 @@ public okhttp3.Call getRulesetAsync(Long applicationId, Long campaignId, Long ru 200 OK - */ - public okhttp3.Call getRulesetsCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getRulesetV2Call(Long applicationId, Long campaignId, Long rulesetId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/rulesets" + String localVarPath = "/v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId}" .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) - .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())) + .replaceAll("\\{" + "rulesetId" + "\\}", localVarApiClient.escapeString(rulesetId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); - if (pageSize != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); - } - - if (skip != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); - } - - if (sort != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); - } - Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -16888,33 +17863,36 @@ public okhttp3.Call getRulesetsCall(Long applicationId, Long campaignId, Long pa } @SuppressWarnings("rawtypes") - private okhttp3.Call getRulesetsValidateBeforeCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + private okhttp3.Call getRulesetV2ValidateBeforeCall(Long applicationId, Long campaignId, Long rulesetId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'applicationId' is set if (applicationId == null) { - throw new ApiException("Missing the required parameter 'applicationId' when calling getRulesets(Async)"); + throw new ApiException("Missing the required parameter 'applicationId' when calling getRulesetV2(Async)"); } // verify the required parameter 'campaignId' is set if (campaignId == null) { - throw new ApiException("Missing the required parameter 'campaignId' when calling getRulesets(Async)"); + throw new ApiException("Missing the required parameter 'campaignId' when calling getRulesetV2(Async)"); + } + + // verify the required parameter 'rulesetId' is set + if (rulesetId == null) { + throw new ApiException("Missing the required parameter 'rulesetId' when calling getRulesetV2(Async)"); } - okhttp3.Call localVarCall = getRulesetsCall(applicationId, campaignId, pageSize, skip, sort, _callback); + okhttp3.Call localVarCall = getRulesetV2Call(applicationId, campaignId, rulesetId, _callback); return localVarCall; } /** - * List campaign rulesets - * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * Get ruleset (V2) + * Retrieve the specified ruleset as a JSON object. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) - * @return InlineResponse20010 + * @param rulesetId The ID of the ruleset. (required) + * @return RulesetV2 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -16922,20 +17900,18 @@ private okhttp3.Call getRulesetsValidateBeforeCall(Long applicationId, Long camp
200 OK -
*/ - public InlineResponse20010 getRulesets(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getRulesetsWithHttpInfo(applicationId, campaignId, pageSize, skip, sort); + public RulesetV2 getRulesetV2(Long applicationId, Long campaignId, Long rulesetId) throws ApiException { + ApiResponse localVarResp = getRulesetV2WithHttpInfo(applicationId, campaignId, rulesetId); return localVarResp.getData(); } /** - * List campaign rulesets - * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * Get ruleset (V2) + * Retrieve the specified ruleset as a JSON object. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) - * @return ApiResponse<InlineResponse20010> + * @param rulesetId The ID of the ruleset. (required) + * @return ApiResponse<RulesetV2> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -16943,20 +17919,18 @@ public InlineResponse20010 getRulesets(Long applicationId, Long campaignId, Long
200 OK -
*/ - public ApiResponse getRulesetsWithHttpInfo(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort) throws ApiException { - okhttp3.Call localVarCall = getRulesetsValidateBeforeCall(applicationId, campaignId, pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse getRulesetV2WithHttpInfo(Long applicationId, Long campaignId, Long rulesetId) throws ApiException { + okhttp3.Call localVarCall = getRulesetV2ValidateBeforeCall(applicationId, campaignId, rulesetId, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List campaign rulesets (asynchronously) - * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * Get ruleset (V2) (asynchronously) + * Retrieve the specified ruleset as a JSON object. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param pageSize The number of items in the response. (optional, default to 1000l) - * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) + * @param rulesetId The ID of the ruleset. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -16966,17 +17940,20 @@ public ApiResponse getRulesetsWithHttpInfo(Long application 200 OK - */ - public okhttp3.Call getRulesetsAsync(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getRulesetV2Async(Long applicationId, Long campaignId, Long rulesetId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getRulesetsValidateBeforeCall(applicationId, campaignId, pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = getRulesetV2ValidateBeforeCall(applicationId, campaignId, rulesetId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getStore + * Build call for getRulesets * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param storeId The ID of the store. You can get this ID with the [List stores](#tag/Stores/operation/listStores) endpoint. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16984,16 +17961,158 @@ public okhttp3.Call getRulesetsAsync(Long applicationId, Long campaignId, Long p -
Status Code Description Response Headers
200 OK -
404 Not found -
*/ - public okhttp3.Call getStoreCall(Long applicationId, String storeId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getRulesetsCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/applications/{applicationId}/stores/{storeId}" + String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/rulesets" .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) - .replaceAll("\\{" + "storeId" + "\\}", localVarApiClient.escapeString(storeId.toString())); + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); + } + + if (sort != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getRulesetsValidateBeforeCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling getRulesets(Async)"); + } + + // verify the required parameter 'campaignId' is set + if (campaignId == null) { + throw new ApiException("Missing the required parameter 'campaignId' when calling getRulesets(Async)"); + } + + + okhttp3.Call localVarCall = getRulesetsCall(applicationId, campaignId, pageSize, skip, sort, _callback); + return localVarCall; + + } + + /** + * List campaign rulesets + * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @return InlineResponse20010 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public InlineResponse20010 getRulesets(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getRulesetsWithHttpInfo(applicationId, campaignId, pageSize, skip, sort); + return localVarResp.getData(); + } + + /** + * List campaign rulesets + * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @return ApiResponse<InlineResponse20010> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public ApiResponse getRulesetsWithHttpInfo(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort) throws ApiException { + okhttp3.Call localVarCall = getRulesetsValidateBeforeCall(applicationId, campaignId, pageSize, skip, sort, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * List campaign rulesets (asynchronously) + * List all rulesets of this campaign. A ruleset is a revision of the rules of a campaign. **Important:** The response also includes deleted rules. You should only consider the latest revision of the returned rulesets. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ */ + public okhttp3.Call getRulesetsAsync(Long applicationId, Long campaignId, Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getRulesetsValidateBeforeCall(applicationId, campaignId, pageSize, skip, sort, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for getStore + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param storeId The ID of the store. You can get this ID with the [List stores](#tag/Stores/operation/listStores) endpoint. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + +
Status Code Description Response Headers
200 OK -
404 Not found -
+ */ + public okhttp3.Call getStoreCall(Long applicationId, String storeId, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/applications/{applicationId}/stores/{storeId}" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) + .replaceAll("\\{" + "storeId" + "\\}", localVarApiClient.escapeString(storeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17279,7 +18398,7 @@ private okhttp3.Call getUsersValidateBeforeCall(Long pageSize, Long skip, String * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return InlineResponse20043 + * @return InlineResponse20044 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17287,8 +18406,8 @@ private okhttp3.Call getUsersValidateBeforeCall(Long pageSize, Long skip, String
200 OK -
*/ - public InlineResponse20043 getUsers(Long pageSize, Long skip, String sort) throws ApiException { - ApiResponse localVarResp = getUsersWithHttpInfo(pageSize, skip, sort); + public InlineResponse20044 getUsers(Long pageSize, Long skip, String sort) throws ApiException { + ApiResponse localVarResp = getUsersWithHttpInfo(pageSize, skip, sort); return localVarResp.getData(); } @@ -17298,7 +18417,7 @@ public InlineResponse20043 getUsers(Long pageSize, Long skip, String sort) throw * @param pageSize The number of items in the response. (optional, default to 1000l) * @param skip The number of items to skip when paging through large result sets. (optional) * @param sort 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) - * @return ApiResponse<InlineResponse20043> + * @return ApiResponse<InlineResponse20044> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17306,9 +18425,9 @@ public InlineResponse20043 getUsers(Long pageSize, Long skip, String sort) throw
200 OK -
*/ - public ApiResponse getUsersWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { + public ApiResponse getUsersWithHttpInfo(Long pageSize, Long skip, String sort) throws ApiException { okhttp3.Call localVarCall = getUsersValidateBeforeCall(pageSize, skip, sort, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -17327,10 +18446,10 @@ public ApiResponse getUsersWithHttpInfo(Long pageSize, Long 200 OK - */ - public okhttp3.Call getUsersAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getUsersAsync(Long pageSize, Long skip, String sort, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getUsersValidateBeforeCall(pageSize, skip, sort, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -17545,7 +18664,7 @@ private okhttp3.Call getWebhooksValidateBeforeCall(String applicationIds, String * @param visibility Filter results by visibility. (optional) * @param outgoingIntegrationsTypeId Filter results by outgoing integration type ID. (optional) * @param title Filter results performing case-insensitive matching against the webhook title. (optional) - * @return InlineResponse20041 + * @return InlineResponse20042 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17553,8 +18672,8 @@ private okhttp3.Call getWebhooksValidateBeforeCall(String applicationIds, String
200 OK -
*/ - public InlineResponse20041 getWebhooks(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title) throws ApiException { - ApiResponse localVarResp = getWebhooksWithHttpInfo(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); + public InlineResponse20042 getWebhooks(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title) throws ApiException { + ApiResponse localVarResp = getWebhooksWithHttpInfo(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); return localVarResp.getData(); } @@ -17569,7 +18688,7 @@ public InlineResponse20041 getWebhooks(String applicationIds, String sort, Long * @param visibility Filter results by visibility. (optional) * @param outgoingIntegrationsTypeId Filter results by outgoing integration type ID. (optional) * @param title Filter results performing case-insensitive matching against the webhook title. (optional) - * @return ApiResponse<InlineResponse20041> + * @return ApiResponse<InlineResponse20042> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17577,9 +18696,9 @@ public InlineResponse20041 getWebhooks(String applicationIds, String sort, Long
200 OK -
*/ - public ApiResponse getWebhooksWithHttpInfo(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title) throws ApiException { + public ApiResponse getWebhooksWithHttpInfo(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title) throws ApiException { okhttp3.Call localVarCall = getWebhooksValidateBeforeCall(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -17603,17 +18722,17 @@ public ApiResponse getWebhooksWithHttpInfo(String applicati 200 OK - */ - public okhttp3.Call getWebhooksAsync(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call getWebhooksAsync(String applicationIds, String sort, Long pageSize, Long skip, String creationType, String visibility, Long outgoingIntegrationsTypeId, String title, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = getWebhooksValidateBeforeCall(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** * Build call for importAccountCollection * @param collectionId The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17677,7 +18796,7 @@ private okhttp3.Call importAccountCollectionValidateBeforeCall(Long collectionId * Import data into existing account-level collection * Upload a CSV file containing the collection of string values that should be attached as payload for collection. The file should be sent as multipart data. The import **replaces** the initial content of the collection. The CSV file **must** only contain the following column: - `item`: the values in your collection. A collection is limited to 500,000 items. ## Example ``` item Adidas Nike Asics ``` > [!note] Before sending a request to this endpoint, ensure the data in the > CSV to import is different from the data currently stored in the collection. * @param collectionId The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17697,7 +18816,7 @@ public ModelImport importAccountCollection(Long collectionId, String upFile) thr * Import data into existing account-level collection * Upload a CSV file containing the collection of string values that should be attached as payload for collection. The file should be sent as multipart data. The import **replaces** the initial content of the collection. The CSV file **must** only contain the following column: - `item`: the values in your collection. A collection is limited to 500,000 items. ## Example ``` item Adidas Nike Asics ``` > [!note] Before sending a request to this endpoint, ensure the data in the > CSV to import is different from the data currently stored in the collection. * @param collectionId The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17718,7 +18837,7 @@ public ApiResponse importAccountCollectionWithHttpInfo(Long collect * Import data into existing account-level collection (asynchronously) * Upload a CSV file containing the collection of string values that should be attached as payload for collection. The file should be sent as multipart data. The import **replaces** the initial content of the collection. The CSV file **must** only contain the following column: - `item`: the values in your collection. A collection is limited to 500,000 items. ## Example ``` item Adidas Nike Asics ``` > [!note] Before sending a request to this endpoint, ensure the data in the > CSV to import is different from the data currently stored in the collection. * @param collectionId The ID of the collection. You can get it with the [List collections in account](#tag/Collections/operation/listAccountCollections) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -17740,7 +18859,7 @@ public okhttp3.Call importAccountCollectionAsync(Long collectionId, String upFil /** * Build call for importAllowedList * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17805,7 +18924,7 @@ private okhttp3.Call importAllowedListValidateBeforeCall(Long attributeId, Strin * Import allowed values for attribute * Upload a CSV file containing a list of [picklist values](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#picklist-values) for the specified attribute. The file should be sent as multipart data. The import **replaces** the previous list of allowed values for this attribute, if any. The CSV file **must** only contain the following column: - `item`: The values in your allowed list, for example a list of SKUs. An allowed list is limited to 500,000 items. ## Example ```text item CS-VG-04032021-UP-50D-10 CS-DV-04042021-UP-49D-12 CS-DG-02082021-UP-50G-07 ``` * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17826,7 +18945,7 @@ public ModelImport importAllowedList(Long attributeId, String upFile) throws Api * Import allowed values for attribute * Upload a CSV file containing a list of [picklist values](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#picklist-values) for the specified attribute. The file should be sent as multipart data. The import **replaces** the previous list of allowed values for this attribute, if any. The CSV file **must** only contain the following column: - `item`: The values in your allowed list, for example a list of SKUs. An allowed list is limited to 500,000 items. ## Example ```text item CS-VG-04032021-UP-50D-10 CS-DV-04042021-UP-49D-12 CS-DG-02082021-UP-50G-07 ``` * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17848,7 +18967,7 @@ public ApiResponse importAllowedListWithHttpInfo(Long attributeId, * Import allowed values for attribute (asynchronously) * Upload a CSV file containing a list of [picklist values](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#picklist-values) for the specified attribute. The file should be sent as multipart data. The import **replaces** the previous list of allowed values for this attribute, if any. The CSV file **must** only contain the following column: - `item`: The values in your allowed list, for example a list of SKUs. An allowed list is limited to 500,000 items. ## Example ```text item CS-VG-04032021-UP-50D-10 CS-DV-04042021-UP-49D-12 CS-DG-02082021-UP-50G-07 ``` * @param attributeId The ID of the attribute. You can find the ID in the Campaign Manager's URL when you display the details of an attribute in **Account** > **Tools** > **Attributes**. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -17871,7 +18990,7 @@ public okhttp3.Call importAllowedListAsync(Long attributeId, String upFile, fina /** * Build call for importAudiencesMemberships * @param audienceId The ID of the audience. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17936,7 +19055,7 @@ private okhttp3.Call importAudiencesMembershipsValidateBeforeCall(Long audienceI * Import audience members * Upload a CSV file containing the integration IDs of the members you want to add to an audience. The file should be sent as multipart data and should contain only the following column (required): - `profileintegrationid`: The integration ID of the customer profile. The import **replaces** the previous list of audience members. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text profileintegrationid charles alexa ``` * @param audienceId The ID of the audience. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17957,7 +19076,7 @@ public ModelImport importAudiencesMemberships(Long audienceId, String upFile) th * Import audience members * Upload a CSV file containing the integration IDs of the members you want to add to an audience. The file should be sent as multipart data and should contain only the following column (required): - `profileintegrationid`: The integration ID of the customer profile. The import **replaces** the previous list of audience members. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text profileintegrationid charles alexa ``` * @param audienceId The ID of the audience. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -17979,7 +19098,7 @@ public ApiResponse importAudiencesMembershipsWithHttpInfo(Long audi * Import audience members (asynchronously) * Upload a CSV file containing the integration IDs of the members you want to add to an audience. The file should be sent as multipart data and should contain only the following column (required): - `profileintegrationid`: The integration ID of the customer profile. The import **replaces** the previous list of audience members. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text profileintegrationid charles alexa ``` * @param audienceId The ID of the audience. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18005,7 +19124,7 @@ public okhttp3.Call importAudiencesMembershipsAsync(Long audienceId, String upFi * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18085,7 +19204,7 @@ private okhttp3.Call importCampaignStoreBudgetValidateBeforeCall(Long applicatio * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18107,7 +19226,7 @@ public ModelImport importCampaignStoreBudget(Long applicationId, Long campaignId * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18130,7 +19249,7 @@ public ApiResponse importCampaignStoreBudgetWithHttpInfo(Long appli * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18152,7 +19271,7 @@ public okhttp3.Call importCampaignStoreBudgetAsync(Long applicationId, Long camp * Build call for importCampaignStores * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18224,7 +19343,7 @@ private okhttp3.Call importCampaignStoresValidateBeforeCall(Long applicationId, * Upload a CSV file containing the stores you want to link to a specific campaign. Send the file as multipart data. The CSV file **must** only contain the following column: - `store_integration_id`: The identifier of the store. The import **replaces** the previous list of stores linked to the campaign. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18246,7 +19365,7 @@ public ModelImport importCampaignStores(Long applicationId, Long campaignId, Str * Upload a CSV file containing the stores you want to link to a specific campaign. Send the file as multipart data. The CSV file **must** only contain the following column: - `store_integration_id`: The identifier of the store. The import **replaces** the previous list of stores linked to the campaign. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18269,7 +19388,7 @@ public ApiResponse importCampaignStoresWithHttpInfo(Long applicatio * Upload a CSV file containing the stores you want to link to a specific campaign. Send the file as multipart data. The CSV file **must** only contain the following column: - `store_integration_id`: The identifier of the store. The import **replaces** the previous list of stores linked to the campaign. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18294,7 +19413,7 @@ public okhttp3.Call importCampaignStoresAsync(Long applicationId, Long campaignI * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param collectionId The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18371,7 +19490,7 @@ private okhttp3.Call importCollectionValidateBeforeCall(Long applicationId, Long * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param collectionId The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18392,7 +19511,7 @@ public ModelImport importCollection(Long applicationId, Long campaignId, Long co * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param collectionId The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18414,7 +19533,7 @@ public ApiResponse importCollectionWithHttpInfo(Long applicationId, * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param collectionId The ID of the collection. You can get it with the [List collections in Application](#tag/Collections/operation/listCollectionsInApplication) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18437,7 +19556,7 @@ public okhttp3.Call importCollectionAsync(Long applicationId, Long campaignId, L * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param skipDuplicates An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18511,7 +19630,7 @@ private okhttp3.Call importCouponsValidateBeforeCall(Long applicationId, Long ca * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param skipDuplicates An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18531,7 +19650,7 @@ public ModelImport importCoupons(Long applicationId, Long campaignId, Boolean sk * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param skipDuplicates An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18552,7 +19671,7 @@ public ApiResponse importCouponsWithHttpInfo(Long applicationId, Lo * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param skipDuplicates An indicator of whether to skip duplicate coupon values instead of causing an error. Duplicate values are ignored when `skipDuplicates=true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18572,7 +19691,7 @@ public okhttp3.Call importCouponsAsync(Long applicationId, Long campaignId, Bool /** * Build call for importLoyaltyCards * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18634,9 +19753,9 @@ private okhttp3.Call importLoyaltyCardsValidateBeforeCall(Long loyaltyProgramId, /** * Import loyalty cards - * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). > [!note] We recommend limiting your file size to 500MB. ## Example ```csv identifier,state,customerprofileids 123-456-789AT,active,Alexa001;UserA ``` + * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). - `attributes` (optional): A JSON object that contains the loyalty card's custom attributes and their values. These attributes must be created and connected to this loyalty program before they can be assigned to the cards through this endpoint. > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv identifier,state,customerprofileids,attributes 123-456-789AT,active,Alexa001;UserA,'{\"\"my_attributes\"\": \"\"10_off\"\"}\" ``` * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18654,9 +19773,9 @@ public ModelImport importLoyaltyCards(Long loyaltyProgramId, String upFile) thro /** * Import loyalty cards - * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). > [!note] We recommend limiting your file size to 500MB. ## Example ```csv identifier,state,customerprofileids 123-456-789AT,active,Alexa001;UserA ``` + * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). - `attributes` (optional): A JSON object that contains the loyalty card's custom attributes and their values. These attributes must be created and connected to this loyalty program before they can be assigned to the cards through this endpoint. > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv identifier,state,customerprofileids,attributes 123-456-789AT,active,Alexa001;UserA,'{\"\"my_attributes\"\": \"\"10_off\"\"}\" ``` * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18675,9 +19794,9 @@ public ApiResponse importLoyaltyCardsWithHttpInfo(Long loyaltyProgr /** * Import loyalty cards (asynchronously) - * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). > [!note] We recommend limiting your file size to 500MB. ## Example ```csv identifier,state,customerprofileids 123-456-789AT,active,Alexa001;UserA ``` + * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). - `attributes` (optional): A JSON object that contains the loyalty card's custom attributes and their values. These attributes must be created and connected to this loyalty program before they can be assigned to the cards through this endpoint. > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv identifier,state,customerprofileids,attributes 123-456-789AT,active,Alexa001;UserA,'{\"\"my_attributes\"\": \"\"10_off\"\"}\" ``` * @param loyaltyProgramId Identifier of the card-based loyalty program containing the loyalty card. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18699,7 +19818,7 @@ public okhttp3.Call importLoyaltyCardsAsync(Long loyaltyProgramId, String upFile /** * Build call for importLoyaltyCustomersTiers * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18762,9 +19881,9 @@ private okhttp3.Call importLoyaltyCustomersTiersValidateBeforeCall(Long loyaltyP /** * Import customers into loyalty tiers - * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiration date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiration date is updated. > [!note] We recommend not using this endpoint to update the tier of a customer. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` + * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiry date is updated. > [!note] We recommend importing customers into the tier that matches their > current balance. If a customer is imported into a lower tier, any session > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18783,9 +19902,9 @@ public ModelImport importLoyaltyCustomersTiers(Long loyaltyProgramId, String upF /** * Import customers into loyalty tiers - * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiration date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiration date is updated. > [!note] We recommend not using this endpoint to update the tier of a customer. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` + * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiry date is updated. > [!note] We recommend importing customers into the tier that matches their > current balance. If a customer is imported into a lower tier, any session > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18805,9 +19924,9 @@ public ApiResponse importLoyaltyCustomersTiersWithHttpInfo(Long loy /** * Import customers into loyalty tiers (asynchronously) - * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiration date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiration date is updated. > [!note] We recommend not using this endpoint to update the tier of a customer. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` + * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiry date is updated. > [!note] We recommend importing customers into the tier that matches their > current balance. If a customer is imported into a lower tier, any session > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18827,11 +19946,142 @@ public okhttp3.Call importLoyaltyCustomersTiersAsync(Long loyaltyProgramId, Stri localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for importLoyaltyJoinDates + * @param loyaltyProgramId 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. (required) + * @param upFile The CSV file containing the data that is being imported. (optional) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call importLoyaltyJoinDatesCall(Long loyaltyProgramId, String upFile, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/loyalty_programs/{loyaltyProgramId}/import_join_dates" + .replaceAll("\\{" + "loyaltyProgramId" + "\\}", localVarApiClient.escapeString(loyaltyProgramId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + if (upFile != null) { + localVarFormParams.put("upFile", upFile); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "multipart/form-data" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call importLoyaltyJoinDatesValidateBeforeCall(Long loyaltyProgramId, String upFile, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'loyaltyProgramId' is set + if (loyaltyProgramId == null) { + throw new ApiException("Missing the required parameter 'loyaltyProgramId' when calling importLoyaltyJoinDates(Async)"); + } + + + okhttp3.Call localVarCall = importLoyaltyJoinDatesCall(loyaltyProgramId, upFile, _callback); + return localVarCall; + + } + + /** + * Import join dates for a loyalty program + * Upload a CSV file containing customer profile IDs and their join dates for the specified loyalty program. Send the file as multipart data. > [!important] This endpoint only works with profile-based loyalty programs. The CSV file **must** contain the following columns: - `customerprofileid`: The integration ID of the customer profile whose join date you want to update. - `newjoindate`: The new join date for the customer in RFC3339 format. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. **Note**: - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. - If a join date already exists for a profile, the uploaded date replaces it. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv customerprofileid,newjoindate customer1,2024-03-21T07:32:14Z customer2,2025-04-16T21:12:37Z customer3,2026-05-03T11:47:01Z ``` + * @param loyaltyProgramId 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. (required) + * @param upFile The CSV file containing the data that is being imported. (optional) + * @return ModelImport + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public ModelImport importLoyaltyJoinDates(Long loyaltyProgramId, String upFile) throws ApiException { + ApiResponse localVarResp = importLoyaltyJoinDatesWithHttpInfo(loyaltyProgramId, upFile); + return localVarResp.getData(); + } + + /** + * Import join dates for a loyalty program + * Upload a CSV file containing customer profile IDs and their join dates for the specified loyalty program. Send the file as multipart data. > [!important] This endpoint only works with profile-based loyalty programs. The CSV file **must** contain the following columns: - `customerprofileid`: The integration ID of the customer profile whose join date you want to update. - `newjoindate`: The new join date for the customer in RFC3339 format. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. **Note**: - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. - If a join date already exists for a profile, the uploaded date replaces it. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv customerprofileid,newjoindate customer1,2024-03-21T07:32:14Z customer2,2025-04-16T21:12:37Z customer3,2026-05-03T11:47:01Z ``` + * @param loyaltyProgramId 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. (required) + * @param upFile The CSV file containing the data that is being imported. (optional) + * @return ApiResponse<ModelImport> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public ApiResponse importLoyaltyJoinDatesWithHttpInfo(Long loyaltyProgramId, String upFile) throws ApiException { + okhttp3.Call localVarCall = importLoyaltyJoinDatesValidateBeforeCall(loyaltyProgramId, upFile, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Import join dates for a loyalty program (asynchronously) + * Upload a CSV file containing customer profile IDs and their join dates for the specified loyalty program. Send the file as multipart data. > [!important] This endpoint only works with profile-based loyalty programs. The CSV file **must** contain the following columns: - `customerprofileid`: The integration ID of the customer profile whose join date you want to update. - `newjoindate`: The new join date for the customer in RFC3339 format. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. **Note**: - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. - If a join date already exists for a profile, the uploaded date replaces it. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv customerprofileid,newjoindate customer1,2024-03-21T07:32:14Z customer2,2025-04-16T21:12:37Z customer3,2026-05-03T11:47:01Z ``` + * @param loyaltyProgramId 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. (required) + * @param upFile The CSV file containing the data that is being imported. (optional) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call importLoyaltyJoinDatesAsync(Long loyaltyProgramId, String upFile, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = importLoyaltyJoinDatesValidateBeforeCall(loyaltyProgramId, upFile, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for importLoyaltyPoints * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param notificationsEnabled Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18898,7 +20148,7 @@ private okhttp3.Call importLoyaltyPointsValidateBeforeCall(Long loyaltyProgramId * Upload a CSV file containing the loyalty points you want to import into a given loyalty program. Send the file as multipart data. Depending on the type of loyalty program, you can import points into a given customer profile or loyalty card. The CSV file contains the following columns: - `customerprofileid` (optional): For profile-based loyalty programs, the integration ID of the customer profile where the loyalty points are imported. **Note**: If the customer profile does not exist, it will be created. The profile will not be visible in any Application until a session or profile update is received for that profile. - `identifier` (optional): For card-based loyalty programs, the identifier of the loyalty card where the loyalty points are imported. - `amount`: The amount of points to award to the customer profile. - `startdate` (optional): The earliest date when the points can be redeemed. The points are `active` from this date until the expiration date. This parameter accepts one of the following values: - A timestamp string in RFC3339 format. - `immediate` - `on_action` **Note**: Empty or missing values default to `immediate`. - `expirydate` (optional): The latest date when the points can be redeemed. The points are `expired` after this date. **Note**: It must be an RFC3339 timestamp string or string `unlimited`. Empty or missing values are considered `unlimited`. If passed, `validityDuration` should be omitted. - `validityDuration` (optional): The duration for which the points remain active, relative to the activation date. The time format is an **integer** followed by one letter indicating the time unit.<br /> Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `expirydate` should be omitted. - `subledgerid` (optional): The ID of the subledger that should received the points. - `reason` (optional): The reason why these points are awarded. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] For existing customer profiles and loyalty cards, the imported > points are added to any previous active or pending points, depending on the > value provided for `startdate`. If `startdate` matches the current date, the > imported points are _active_. If it is later, the points are _pending_ until > the date provided for `startdate` is reached. > [!note] We recommend limiting your file size to 500 MB. ## Example for profile-based programs ```text customerprofileid,amount,startdate,expirydate,subledgerid,reason URNGV8294NV,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` ## Example for card-based programs ```text identifier,amount,startdate,expirydate,subledgerid,reason summer-loyalty-card-0543,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param notificationsEnabled Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18917,7 +20167,7 @@ public ModelImport importLoyaltyPoints(Long loyaltyProgramId, Boolean notificati * Upload a CSV file containing the loyalty points you want to import into a given loyalty program. Send the file as multipart data. Depending on the type of loyalty program, you can import points into a given customer profile or loyalty card. The CSV file contains the following columns: - `customerprofileid` (optional): For profile-based loyalty programs, the integration ID of the customer profile where the loyalty points are imported. **Note**: If the customer profile does not exist, it will be created. The profile will not be visible in any Application until a session or profile update is received for that profile. - `identifier` (optional): For card-based loyalty programs, the identifier of the loyalty card where the loyalty points are imported. - `amount`: The amount of points to award to the customer profile. - `startdate` (optional): The earliest date when the points can be redeemed. The points are `active` from this date until the expiration date. This parameter accepts one of the following values: - A timestamp string in RFC3339 format. - `immediate` - `on_action` **Note**: Empty or missing values default to `immediate`. - `expirydate` (optional): The latest date when the points can be redeemed. The points are `expired` after this date. **Note**: It must be an RFC3339 timestamp string or string `unlimited`. Empty or missing values are considered `unlimited`. If passed, `validityDuration` should be omitted. - `validityDuration` (optional): The duration for which the points remain active, relative to the activation date. The time format is an **integer** followed by one letter indicating the time unit.<br /> Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `expirydate` should be omitted. - `subledgerid` (optional): The ID of the subledger that should received the points. - `reason` (optional): The reason why these points are awarded. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] For existing customer profiles and loyalty cards, the imported > points are added to any previous active or pending points, depending on the > value provided for `startdate`. If `startdate` matches the current date, the > imported points are _active_. If it is later, the points are _pending_ until > the date provided for `startdate` is reached. > [!note] We recommend limiting your file size to 500 MB. ## Example for profile-based programs ```text customerprofileid,amount,startdate,expirydate,subledgerid,reason URNGV8294NV,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` ## Example for card-based programs ```text identifier,amount,startdate,expirydate,subledgerid,reason summer-loyalty-card-0543,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param notificationsEnabled Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -18937,7 +20187,7 @@ public ApiResponse importLoyaltyPointsWithHttpInfo(Long loyaltyProg * Upload a CSV file containing the loyalty points you want to import into a given loyalty program. Send the file as multipart data. Depending on the type of loyalty program, you can import points into a given customer profile or loyalty card. The CSV file contains the following columns: - `customerprofileid` (optional): For profile-based loyalty programs, the integration ID of the customer profile where the loyalty points are imported. **Note**: If the customer profile does not exist, it will be created. The profile will not be visible in any Application until a session or profile update is received for that profile. - `identifier` (optional): For card-based loyalty programs, the identifier of the loyalty card where the loyalty points are imported. - `amount`: The amount of points to award to the customer profile. - `startdate` (optional): The earliest date when the points can be redeemed. The points are `active` from this date until the expiration date. This parameter accepts one of the following values: - A timestamp string in RFC3339 format. - `immediate` - `on_action` **Note**: Empty or missing values default to `immediate`. - `expirydate` (optional): The latest date when the points can be redeemed. The points are `expired` after this date. **Note**: It must be an RFC3339 timestamp string or string `unlimited`. Empty or missing values are considered `unlimited`. If passed, `validityDuration` should be omitted. - `validityDuration` (optional): The duration for which the points remain active, relative to the activation date. The time format is an **integer** followed by one letter indicating the time unit.<br /> Examples: `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `expirydate` should be omitted. - `subledgerid` (optional): The ID of the subledger that should received the points. - `reason` (optional): The reason why these points are awarded. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] For existing customer profiles and loyalty cards, the imported > points are added to any previous active or pending points, depending on the > value provided for `startdate`. If `startdate` matches the current date, the > imported points are _active_. If it is later, the points are _pending_ until > the date provided for `startdate` is reached. > [!note] We recommend limiting your file size to 500 MB. ## Example for profile-based programs ```text customerprofileid,amount,startdate,expirydate,subledgerid,reason URNGV8294NV,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` ## Example for card-based programs ```text identifier,amount,startdate,expirydate,subledgerid,reason summer-loyalty-card-0543,100,2009-11-10T23:00:00Z,2009-11-11T23:00:00Z,subledger1,appeasement ``` * @param loyaltyProgramId Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. (required) * @param notificationsEnabled Indicates whether the points import triggers notifications about its effects. For example, a notification is sent if the import upgrades a customer's tier or offsets their negative points balance. This parameter is optional and defaults to `true`. (optional) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -18957,7 +20207,7 @@ public okhttp3.Call importLoyaltyPointsAsync(Long loyaltyProgramId, Boolean noti /** * Build call for importPoolGiveaways * @param poolId The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19019,7 +20269,7 @@ private okhttp3.Call importPoolGiveawaysValidateBeforeCall(Long poolId, String u * Import giveaway codes into a giveaway pool * Upload a CSV file containing the giveaway codes that should be created. Send the file as multipart data. The CSV file contains the following columns: - `code` (required): The code of your giveaway, for instance, a gift card redemption code. - `startdate`: The start date in RFC3339 of the code redemption period. - `enddate`: The last date in RFC3339 of the code redemption period. - `attributes`: A JSON object describing _custom_ giveaway attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `provider` associated with the giveaway entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"provider\": \"myPartnerCompany\"}\"`. The `startdate` and `enddate` have nothing to do with the _validity_ of the codes. They are only used by the Rule Engine to award the codes or not. You can use the time zone setting of your choice. The values are converted to UTC internally by Talon.One. > [!note] **Note** > - We recommend limiting your file size to 500MB. > - You can import the same code multiple times. Duplicate codes are treated and distributed to customers as unique codes. ## Example ```text code,startdate,enddate,attributes GIVEAWAY1,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY2,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY3,2021-01-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Aliexpress\"\"}\" ``` * @param poolId The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19037,7 +20287,7 @@ public ModelImport importPoolGiveaways(Long poolId, String upFile) throws ApiExc * Import giveaway codes into a giveaway pool * Upload a CSV file containing the giveaway codes that should be created. Send the file as multipart data. The CSV file contains the following columns: - `code` (required): The code of your giveaway, for instance, a gift card redemption code. - `startdate`: The start date in RFC3339 of the code redemption period. - `enddate`: The last date in RFC3339 of the code redemption period. - `attributes`: A JSON object describing _custom_ giveaway attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `provider` associated with the giveaway entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"provider\": \"myPartnerCompany\"}\"`. The `startdate` and `enddate` have nothing to do with the _validity_ of the codes. They are only used by the Rule Engine to award the codes or not. You can use the time zone setting of your choice. The values are converted to UTC internally by Talon.One. > [!note] **Note** > - We recommend limiting your file size to 500MB. > - You can import the same code multiple times. Duplicate codes are treated and distributed to customers as unique codes. ## Example ```text code,startdate,enddate,attributes GIVEAWAY1,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY2,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY3,2021-01-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Aliexpress\"\"}\" ``` * @param poolId The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19056,7 +20306,7 @@ public ApiResponse importPoolGiveawaysWithHttpInfo(Long poolId, Str * Import giveaway codes into a giveaway pool (asynchronously) * Upload a CSV file containing the giveaway codes that should be created. Send the file as multipart data. The CSV file contains the following columns: - `code` (required): The code of your giveaway, for instance, a gift card redemption code. - `startdate`: The start date in RFC3339 of the code redemption period. - `enddate`: The last date in RFC3339 of the code redemption period. - `attributes`: A JSON object describing _custom_ giveaway attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `provider` associated with the giveaway entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"provider\": \"myPartnerCompany\"}\"`. The `startdate` and `enddate` have nothing to do with the _validity_ of the codes. They are only used by the Rule Engine to award the codes or not. You can use the time zone setting of your choice. The values are converted to UTC internally by Talon.One. > [!note] **Note** > - We recommend limiting your file size to 500MB. > - You can import the same code multiple times. Duplicate codes are treated and distributed to customers as unique codes. ## Example ```text code,startdate,enddate,attributes GIVEAWAY1,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY2,2020-11-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Amazon\"\"}\" GIVEAWAY3,2021-01-10T23:00:00Z,2022-11-11T23:00:00Z,\"{\"\"provider\"\": \"\"Aliexpress\"\"}\" ``` * @param poolId The ID of the pool. You can find it in the Campaign Manager, in the **Giveaways** section. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -19077,7 +20327,7 @@ public okhttp3.Call importPoolGiveawaysAsync(Long poolId, String upFile, final A * Build call for importReferrals * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19146,7 +20396,7 @@ private okhttp3.Call importReferralsValidateBeforeCall(Long applicationId, Long * Upload a CSV file containing the referrals that should be created. The file should be sent as multipart data. The CSV file contains the following columns: - `code` (required): The referral code. - `advocateprofileintegrationid` (required): The profile ID of the advocate. - `startdate`: The start date in RFC3339 of the code redemption period. - `expirydate`: The end date in RFC3339 of the code redemption period. - `limitval`: The maximum number of redemptions of this code. Defaults to `1` when left blank. - `attributes`: A JSON object describing _custom_ referral attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `category` associated with the referral entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"category\": \"10_off\"}\"`. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!important] When you import a CSV file with referrals, > a [customer profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles) > is **not** automatically created for each `advocateprofileintegrationid` > column value. Use the [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2) > endpoint or the [Update multiple customer profiles](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfilesV2) > endpoint to create the customer profiles. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text code,startdate,expirydate,advocateprofileintegrationid,limitval,attributes REFERRAL_CODE1,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid_4,1,\"{\"\"my_attribute\"\": \"\"10_off\"\"}\" REFERRAL_CODE2,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid1,1,\"{\"\"my_attribute\"\": \"\"20_off\"\"}\" ``` * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ModelImport * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19165,7 +20415,7 @@ public ModelImport importReferrals(Long applicationId, Long campaignId, String u * Upload a CSV file containing the referrals that should be created. The file should be sent as multipart data. The CSV file contains the following columns: - `code` (required): The referral code. - `advocateprofileintegrationid` (required): The profile ID of the advocate. - `startdate`: The start date in RFC3339 of the code redemption period. - `expirydate`: The end date in RFC3339 of the code redemption period. - `limitval`: The maximum number of redemptions of this code. Defaults to `1` when left blank. - `attributes`: A JSON object describing _custom_ referral attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `category` associated with the referral entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"category\": \"10_off\"}\"`. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!important] When you import a CSV file with referrals, > a [customer profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles) > is **not** automatically created for each `advocateprofileintegrationid` > column value. Use the [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2) > endpoint or the [Update multiple customer profiles](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfilesV2) > endpoint to create the customer profiles. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text code,startdate,expirydate,advocateprofileintegrationid,limitval,attributes REFERRAL_CODE1,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid_4,1,\"{\"\"my_attribute\"\": \"\"10_off\"\"}\" REFERRAL_CODE2,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid1,1,\"{\"\"my_attribute\"\": \"\"20_off\"\"}\" ``` * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @return ApiResponse<ModelImport> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19185,7 +20435,7 @@ public ApiResponse importReferralsWithHttpInfo(Long applicationId, * Upload a CSV file containing the referrals that should be created. The file should be sent as multipart data. The CSV file contains the following columns: - `code` (required): The referral code. - `advocateprofileintegrationid` (required): The profile ID of the advocate. - `startdate`: The start date in RFC3339 of the code redemption period. - `expirydate`: The end date in RFC3339 of the code redemption period. - `limitval`: The maximum number of redemptions of this code. Defaults to `1` when left blank. - `attributes`: A JSON object describing _custom_ referral attribute names and their values, enclosed with double quotation marks.<br /> For example, if you created a [custom attribute](https://docs.talon.one/docs/dev/concepts/attributes#custom-attributes) called `category` associated with the referral entity, the object in the CSV file, when opened in a text editor, must be: `\"{\"category\": \"10_off\"}\"`. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!important] When you import a CSV file with referrals, > a [customer profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles) > is **not** automatically created for each `advocateprofileintegrationid` > column value. Use the [Update customer profile](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfileV2) > endpoint or the [Update multiple customer profiles](https://docs.talon.one/integration-api#tag/Customer-profiles/operation/updateCustomerProfilesV2) > endpoint to create the customer profiles. > [!note] We recommend limiting your file size to 500 MB. ## Example ```text code,startdate,expirydate,advocateprofileintegrationid,limitval,attributes REFERRAL_CODE1,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid_4,1,\"{\"\"my_attribute\"\": \"\"10_off\"\"}\" REFERRAL_CODE2,2020-11-10T23:00:00Z,2021-11-11T23:00:00Z,integid1,1,\"{\"\"my_attribute\"\": \"\"20_off\"\"}\" ``` * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @param upFile The file containing the data that is being imported. (optional) + * @param upFile The CSV file containing the data that is being imported. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -19435,13 +20685,168 @@ public ApiResponse listAccountCollectionsWithHttpInfo(Long } /** - * List collections in account (asynchronously) - * List account-level collections in the account. - * @param pageSize The number of items in the response. (optional, default to 1000l) + * List collections in account (asynchronously) + * List account-level collections in the account. + * @param pageSize The number of items in the response. (optional, default to 1000l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param sort 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) + * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) + * @param name Filter by collection name. (optional) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call listAccountCollectionsAsync(Long pageSize, Long skip, String sort, Boolean withTotalResultSize, String name, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = listAccountCollectionsValidateBeforeCall(pageSize, skip, sort, withTotalResultSize, name, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Build call for listAchievements + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 50l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ * @deprecated + */ + @Deprecated + public okhttp3.Call listAchievementsCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/achievements" + .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) + .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); + } + + if (title != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("title", title)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @Deprecated + @SuppressWarnings("rawtypes") + private okhttp3.Call listAchievementsValidateBeforeCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'applicationId' is set + if (applicationId == null) { + throw new ApiException("Missing the required parameter 'applicationId' when calling listAchievements(Async)"); + } + + // verify the required parameter 'campaignId' is set + if (campaignId == null) { + throw new ApiException("Missing the required parameter 'campaignId' when calling listAchievements(Async)"); + } + + + okhttp3.Call localVarCall = listAchievementsCall(applicationId, campaignId, pageSize, skip, title, _callback); + return localVarCall; + + } + + /** + * List achievements + * List all the achievements for a specific campaign. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 50l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) + * @return InlineResponse20052 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ * @deprecated + */ + @Deprecated + public InlineResponse20052 listAchievements(Long applicationId, Long campaignId, Long pageSize, Long skip, String title) throws ApiException { + ApiResponse localVarResp = listAchievementsWithHttpInfo(applicationId, campaignId, pageSize, skip, title); + return localVarResp.getData(); + } + + /** + * List achievements + * List all the achievements for a specific campaign. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 50l) + * @param skip The number of items to skip when paging through large result sets. (optional) + * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) + * @return ApiResponse<InlineResponse20052> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + +
Status Code Description Response Headers
200 OK -
+ * @deprecated + */ + @Deprecated + public ApiResponse listAchievementsWithHttpInfo(Long applicationId, Long campaignId, Long pageSize, Long skip, String title) throws ApiException { + okhttp3.Call localVarCall = listAchievementsValidateBeforeCall(applicationId, campaignId, pageSize, skip, title, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * List achievements (asynchronously) + * List all the achievements for a specific campaign. + * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) + * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param sort 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) - * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) - * @param name Filter by collection name. (optional) + * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -19449,25 +20854,24 @@ public ApiResponse listAccountCollectionsWithHttpInfo(Long - - -
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ * @deprecated */ - public okhttp3.Call listAccountCollectionsAsync(Long pageSize, Long skip, String sort, Boolean withTotalResultSize, String name, final ApiCallback _callback) throws ApiException { + @Deprecated + public okhttp3.Call listAchievementsAsync(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listAccountCollectionsValidateBeforeCall(pageSize, skip, sort, withTotalResultSize, name, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = listAchievementsValidateBeforeCall(applicationId, campaignId, pageSize, skip, title, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listAchievements - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * Build call for listAchievementsV2 * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) + * @param sort 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) + * @param title Filter by the display name of the achievement. (optional) + * @param applicationId Filter by the ID of an Application connected to the achievement. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19475,15 +20879,15 @@ public okhttp3.Call listAccountCollectionsAsync(Long pageSize, Long skip, String + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
*/ - public okhttp3.Call listAchievementsCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listAchievementsV2Call(Long pageSize, Long skip, String sort, String title, Long applicationId, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/applications/{applicationId}/campaigns/{campaignId}/achievements" - .replaceAll("\\{" + "applicationId" + "\\}", localVarApiClient.escapeString(applicationId.toString())) - .replaceAll("\\{" + "campaignId" + "\\}", localVarApiClient.escapeString(campaignId.toString())); + String localVarPath = "/v2/achievements"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19495,10 +20899,18 @@ public okhttp3.Call listAchievementsCall(Long applicationId, Long campaignId, Lo localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); } + if (sort != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sort", sort)); + } + if (title != null) { localVarQueryParams.addAll(localVarApiClient.parameterToPair("title", title)); } + if (applicationId != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("applicationId", applicationId)); + } + Map localVarHeaderParams = new HashMap(); Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); @@ -19521,75 +20933,69 @@ public okhttp3.Call listAchievementsCall(Long applicationId, Long campaignId, Lo } @SuppressWarnings("rawtypes") - private okhttp3.Call listAchievementsValidateBeforeCall(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { - - // verify the required parameter 'applicationId' is set - if (applicationId == null) { - throw new ApiException("Missing the required parameter 'applicationId' when calling listAchievements(Async)"); - } - - // verify the required parameter 'campaignId' is set - if (campaignId == null) { - throw new ApiException("Missing the required parameter 'campaignId' when calling listAchievements(Async)"); - } + private okhttp3.Call listAchievementsV2ValidateBeforeCall(Long pageSize, Long skip, String sort, String title, Long applicationId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listAchievementsCall(applicationId, campaignId, pageSize, skip, title, _callback); + okhttp3.Call localVarCall = listAchievementsV2Call(pageSize, skip, sort, title, applicationId, _callback); return localVarCall; } /** * List achievements - * List all the achievements for a specific campaign. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * List all achievements. * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) - * @return InlineResponse20051 + * @param sort 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) + * @param title Filter by the display name of the achievement. (optional) + * @param applicationId Filter by the ID of an Application connected to the achievement. (optional) + * @return InlineResponse20053 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
*/ - public InlineResponse20051 listAchievements(Long applicationId, Long campaignId, Long pageSize, Long skip, String title) throws ApiException { - ApiResponse localVarResp = listAchievementsWithHttpInfo(applicationId, campaignId, pageSize, skip, title); + public InlineResponse20053 listAchievementsV2(Long pageSize, Long skip, String sort, String title, Long applicationId) throws ApiException { + ApiResponse localVarResp = listAchievementsV2WithHttpInfo(pageSize, skip, sort, title, applicationId); return localVarResp.getData(); } /** * List achievements - * List all the achievements for a specific campaign. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * List all achievements. * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) - * @return ApiResponse<InlineResponse20051> + * @param sort 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) + * @param title Filter by the display name of the achievement. (optional) + * @param applicationId Filter by the ID of an Application connected to the achievement. (optional) + * @return ApiResponse<InlineResponse20053> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
*/ - public ApiResponse listAchievementsWithHttpInfo(Long applicationId, Long campaignId, Long pageSize, Long skip, String title) throws ApiException { - okhttp3.Call localVarCall = listAchievementsValidateBeforeCall(applicationId, campaignId, pageSize, skip, title, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse listAchievementsV2WithHttpInfo(Long pageSize, Long skip, String sort, String title, Long applicationId) throws ApiException { + okhttp3.Call localVarCall = listAchievementsV2ValidateBeforeCall(pageSize, skip, sort, title, applicationId, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** * List achievements (asynchronously) - * List all the achievements for a specific campaign. - * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) - * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) + * List all achievements. * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name for the achievement in the campaign manager. **Note**: If no `title` is provided, all the achievements from the campaign are returned. (optional) + * @param sort 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) + * @param title Filter by the display name of the achievement. (optional) + * @param applicationId Filter by the ID of an Application connected to the achievement. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -19597,12 +21003,14 @@ public ApiResponse listAchievementsWithHttpInfo(Long applic + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
*/ - public okhttp3.Call listAchievementsAsync(Long applicationId, Long campaignId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listAchievementsV2Async(Long pageSize, Long skip, String sort, String title, Long applicationId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listAchievementsValidateBeforeCall(applicationId, campaignId, pageSize, skip, title, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = listAchievementsV2ValidateBeforeCall(pageSize, skip, sort, title, applicationId, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -19658,7 +21066,7 @@ private okhttp3.Call listAllRolesV2ValidateBeforeCall(final ApiCallback _callbac /** * List roles * List all roles. - * @return InlineResponse20046 + * @return InlineResponse20047 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19666,15 +21074,15 @@ private okhttp3.Call listAllRolesV2ValidateBeforeCall(final ApiCallback _callbac
200 OK -
*/ - public InlineResponse20046 listAllRolesV2() throws ApiException { - ApiResponse localVarResp = listAllRolesV2WithHttpInfo(); + public InlineResponse20047 listAllRolesV2() throws ApiException { + ApiResponse localVarResp = listAllRolesV2WithHttpInfo(); return localVarResp.getData(); } /** * List roles * List all roles. - * @return ApiResponse<InlineResponse20046> + * @return ApiResponse<InlineResponse20047> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19682,9 +21090,9 @@ public InlineResponse20046 listAllRolesV2() throws ApiException {
200 OK -
*/ - public ApiResponse listAllRolesV2WithHttpInfo() throws ApiException { + public ApiResponse listAllRolesV2WithHttpInfo() throws ApiException { okhttp3.Call localVarCall = listAllRolesV2ValidateBeforeCall(null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -19700,10 +21108,10 @@ public ApiResponse listAllRolesV2WithHttpInfo() throws ApiE 200 OK - */ - public okhttp3.Call listAllRolesV2Async(final ApiCallback _callback) throws ApiException { + public okhttp3.Call listAllRolesV2Async(final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = listAllRolesV2ValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -19712,7 +21120,7 @@ public okhttp3.Call listAllRolesV2Async(final ApiCallback _ * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. (optional) + * @param name Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19722,7 +21130,7 @@ public okhttp3.Call listAllRolesV2Async(final ApiCallback _ 200 OK - */ - public okhttp3.Call listApplicationCartItemFiltersCall(Long applicationId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listApplicationCartItemFiltersCall(Long applicationId, Long pageSize, Long skip, String name, final ApiCallback _callback) throws ApiException { Object localVarPostBody = null; // create path and map variables @@ -19739,8 +21147,8 @@ public okhttp3.Call listApplicationCartItemFiltersCall(Long applicationId, Long localVarQueryParams.addAll(localVarApiClient.parameterToPair("skip", skip)); } - if (title != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("title", title)); + if (name != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("name", name)); } Map localVarHeaderParams = new HashMap(); @@ -19765,7 +21173,7 @@ public okhttp3.Call listApplicationCartItemFiltersCall(Long applicationId, Long } @SuppressWarnings("rawtypes") - private okhttp3.Call listApplicationCartItemFiltersValidateBeforeCall(Long applicationId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + private okhttp3.Call listApplicationCartItemFiltersValidateBeforeCall(Long applicationId, Long pageSize, Long skip, String name, final ApiCallback _callback) throws ApiException { // verify the required parameter 'applicationId' is set if (applicationId == null) { @@ -19773,7 +21181,7 @@ private okhttp3.Call listApplicationCartItemFiltersValidateBeforeCall(Long appli } - okhttp3.Call localVarCall = listApplicationCartItemFiltersCall(applicationId, pageSize, skip, title, _callback); + okhttp3.Call localVarCall = listApplicationCartItemFiltersCall(applicationId, pageSize, skip, name, _callback); return localVarCall; } @@ -19784,8 +21192,8 @@ private okhttp3.Call listApplicationCartItemFiltersValidateBeforeCall(Long appli * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. (optional) - * @return InlineResponse20048 + * @param name Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. (optional) + * @return InlineResponse20049 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19793,8 +21201,8 @@ private okhttp3.Call listApplicationCartItemFiltersValidateBeforeCall(Long appli
200 OK -
*/ - public InlineResponse20048 listApplicationCartItemFilters(Long applicationId, Long pageSize, Long skip, String title) throws ApiException { - ApiResponse localVarResp = listApplicationCartItemFiltersWithHttpInfo(applicationId, pageSize, skip, title); + public InlineResponse20049 listApplicationCartItemFilters(Long applicationId, Long pageSize, Long skip, String name) throws ApiException { + ApiResponse localVarResp = listApplicationCartItemFiltersWithHttpInfo(applicationId, pageSize, skip, name); return localVarResp.getData(); } @@ -19804,8 +21212,8 @@ public InlineResponse20048 listApplicationCartItemFilters(Long applicationId, Lo * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. (optional) - * @return ApiResponse<InlineResponse20048> + * @param name Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. (optional) + * @return ApiResponse<InlineResponse20049> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19813,9 +21221,9 @@ public InlineResponse20048 listApplicationCartItemFilters(Long applicationId, Lo
200 OK -
*/ - public ApiResponse listApplicationCartItemFiltersWithHttpInfo(Long applicationId, Long pageSize, Long skip, String title) throws ApiException { - okhttp3.Call localVarCall = listApplicationCartItemFiltersValidateBeforeCall(applicationId, pageSize, skip, title, null); - Type localVarReturnType = new TypeToken(){}.getType(); + public ApiResponse listApplicationCartItemFiltersWithHttpInfo(Long applicationId, Long pageSize, Long skip, String name) throws ApiException { + okhttp3.Call localVarCall = listApplicationCartItemFiltersValidateBeforeCall(applicationId, pageSize, skip, name, null); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -19825,7 +21233,7 @@ public ApiResponse listApplicationCartItemFiltersWithHttpIn * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param pageSize The number of items in the response. (optional, default to 50l) * @param skip The number of items to skip when paging through large result sets. (optional) - * @param title Filter by the display name of the Application cart item filter in the Application. **Note**: If no `title` is provided, all the Application cart item filters in the Application are returned. (optional) + * @param name Filter by the display name of the Application cart item filter in the Application. **Note**: If no `name` is provided, all the Application cart item filters in the Application are returned. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object @@ -19835,10 +21243,10 @@ public ApiResponse listApplicationCartItemFiltersWithHttpIn 200 OK - */ - public okhttp3.Call listApplicationCartItemFiltersAsync(Long applicationId, Long pageSize, Long skip, String title, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listApplicationCartItemFiltersAsync(Long applicationId, Long pageSize, Long skip, String name, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listApplicationCartItemFiltersValidateBeforeCall(applicationId, pageSize, skip, title, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + okhttp3.Call localVarCall = listApplicationCartItemFiltersValidateBeforeCall(applicationId, pageSize, skip, name, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -19925,7 +21333,7 @@ private okhttp3.Call listCampaignStoreBudgetLimitsValidateBeforeCall(Long applic * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @return InlineResponse20049 + * @return InlineResponse20050 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19936,8 +21344,8 @@ private okhttp3.Call listCampaignStoreBudgetLimitsValidateBeforeCall(Long applic
404 Not found -
*/ - public InlineResponse20049 listCampaignStoreBudgetLimits(Long applicationId, Long campaignId, String action, String period) throws ApiException { - ApiResponse localVarResp = listCampaignStoreBudgetLimitsWithHttpInfo(applicationId, campaignId, action, period); + public InlineResponse20050 listCampaignStoreBudgetLimits(Long applicationId, Long campaignId, String action, String period) throws ApiException { + ApiResponse localVarResp = listCampaignStoreBudgetLimitsWithHttpInfo(applicationId, campaignId, action, period); return localVarResp.getData(); } @@ -19948,7 +21356,7 @@ public InlineResponse20049 listCampaignStoreBudgetLimits(Long applicationId, Lon * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) * @param action The action that this budget is limiting. (optional) * @param period The period to which the limit applies. **Note**: For budgets with no period, set this to `overall`. (optional) - * @return ApiResponse<InlineResponse20049> + * @return ApiResponse<InlineResponse20050> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -19959,9 +21367,9 @@ public InlineResponse20049 listCampaignStoreBudgetLimits(Long applicationId, Lon
404 Not found -
*/ - public ApiResponse listCampaignStoreBudgetLimitsWithHttpInfo(Long applicationId, Long campaignId, String action, String period) throws ApiException { + public ApiResponse listCampaignStoreBudgetLimitsWithHttpInfo(Long applicationId, Long campaignId, String action, String period) throws ApiException { okhttp3.Call localVarCall = listCampaignStoreBudgetLimitsValidateBeforeCall(applicationId, campaignId, action, period, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -19984,10 +21392,10 @@ public ApiResponse listCampaignStoreBudgetLimitsWithHttpInf 404 Not found - */ - public okhttp3.Call listCampaignStoreBudgetLimitsAsync(Long applicationId, Long campaignId, String action, String period, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listCampaignStoreBudgetLimitsAsync(Long applicationId, Long campaignId, String action, String period, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = listCampaignStoreBudgetLimitsValidateBeforeCall(applicationId, campaignId, action, period, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -20081,7 +21489,7 @@ private okhttp3.Call listCatalogItemsValidateBeforeCall(Long catalogId, Long pag * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param sku Filter results by one or more SKUs. Must be exact match. (optional) * @param productNames Filter results by one or more product names. Must be exact match. (optional) - * @return InlineResponse20039 + * @return InlineResponse20040 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -20089,8 +21497,8 @@ private okhttp3.Call listCatalogItemsValidateBeforeCall(Long catalogId, Long pag
200 OK -
*/ - public InlineResponse20039 listCatalogItems(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames) throws ApiException { - ApiResponse localVarResp = listCatalogItemsWithHttpInfo(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); + public InlineResponse20040 listCatalogItems(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames) throws ApiException { + ApiResponse localVarResp = listCatalogItemsWithHttpInfo(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); return localVarResp.getData(); } @@ -20103,7 +21511,7 @@ public InlineResponse20039 listCatalogItems(Long catalogId, Long pageSize, Long * @param withTotalResultSize When this flag is set, the result includes the total number of results for this query. This might decrease performance on large data sets. - When `true`: `totalResultSize` contains the total number of results for this query. - When `false`: Only `hasMore` is returned, and it is set to `true` when there are more results than shown on the page. (optional) * @param sku Filter results by one or more SKUs. Must be exact match. (optional) * @param productNames Filter results by one or more product names. Must be exact match. (optional) - * @return ApiResponse<InlineResponse20039> + * @return ApiResponse<InlineResponse20040> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -20111,9 +21519,9 @@ public InlineResponse20039 listCatalogItems(Long catalogId, Long pageSize, Long
200 OK -
*/ - public ApiResponse listCatalogItemsWithHttpInfo(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames) throws ApiException { + public ApiResponse listCatalogItemsWithHttpInfo(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames) throws ApiException { okhttp3.Call localVarCall = listCatalogItemsValidateBeforeCall(catalogId, pageSize, skip, withTotalResultSize, sku, productNames, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -20135,10 +21543,10 @@ public ApiResponse listCatalogItemsWithHttpInfo(Long catalo 200 OK - */ - public okhttp3.Call listCatalogItemsAsync(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listCatalogItemsAsync(Long catalogId, Long pageSize, Long skip, Boolean withTotalResultSize, List sku, List productNames, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = listCatalogItemsValidateBeforeCall(catalogId, pageSize, skip, withTotalResultSize, sku, productNames, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -20705,7 +22113,7 @@ private okhttp3.Call listStoresValidateBeforeCall(Long applicationId, Long pageS * @param name The name of the store. (optional) * @param integrationId The integration ID of the store. (optional) * @param query Filter results by `name` or `integrationId`. (optional) - * @return InlineResponse20047 + * @return InlineResponse20048 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -20713,8 +22121,8 @@ private okhttp3.Call listStoresValidateBeforeCall(Long applicationId, Long pageS
200 OK -
*/ - public InlineResponse20047 listStores(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query) throws ApiException { - ApiResponse localVarResp = listStoresWithHttpInfo(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); + public InlineResponse20048 listStores(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query) throws ApiException { + ApiResponse localVarResp = listStoresWithHttpInfo(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); return localVarResp.getData(); } @@ -20730,7 +22138,7 @@ public InlineResponse20047 listStores(Long applicationId, Long pageSize, Long sk * @param name The name of the store. (optional) * @param integrationId The integration ID of the store. (optional) * @param query Filter results by `name` or `integrationId`. (optional) - * @return ApiResponse<InlineResponse20047> + * @return ApiResponse<InlineResponse20048> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -20738,9 +22146,9 @@ public InlineResponse20047 listStores(Long applicationId, Long pageSize, Long sk
200 OK -
*/ - public ApiResponse listStoresWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query) throws ApiException { + public ApiResponse listStoresWithHttpInfo(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query) throws ApiException { okhttp3.Call localVarCall = listStoresValidateBeforeCall(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -20765,10 +22173,10 @@ public ApiResponse listStoresWithHttpInfo(Long applicationI 200 OK - */ - public okhttp3.Call listStoresAsync(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query, final ApiCallback _callback) throws ApiException { + public okhttp3.Call listStoresAsync(Long applicationId, Long pageSize, Long skip, String sort, Boolean withTotalResultSize, BigDecimal campaignId, String name, String integrationId, String query, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = listStoresValidateBeforeCall(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -23399,7 +24807,7 @@ private okhttp3.Call summarizeCampaignStoreBudgetValidateBeforeCall(Long applica * Fetch a summary of all store budget information for a given campaign. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @return InlineResponse20050 + * @return InlineResponse20051 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -23410,8 +24818,8 @@ private okhttp3.Call summarizeCampaignStoreBudgetValidateBeforeCall(Long applica
404 Not found -
*/ - public InlineResponse20050 summarizeCampaignStoreBudget(Long applicationId, Long campaignId) throws ApiException { - ApiResponse localVarResp = summarizeCampaignStoreBudgetWithHttpInfo(applicationId, campaignId); + public InlineResponse20051 summarizeCampaignStoreBudget(Long applicationId, Long campaignId) throws ApiException { + ApiResponse localVarResp = summarizeCampaignStoreBudgetWithHttpInfo(applicationId, campaignId); return localVarResp.getData(); } @@ -23420,7 +24828,7 @@ public InlineResponse20050 summarizeCampaignStoreBudget(Long applicationId, Long * Fetch a summary of all store budget information for a given campaign. * @param applicationId The ID of the Application. It is displayed in your Talon.One deployment URL. (required) * @param campaignId The ID of the campaign. It is displayed in your Talon.One deployment URL. (required) - * @return ApiResponse<InlineResponse20050> + * @return ApiResponse<InlineResponse20051> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details @@ -23431,9 +24839,9 @@ public InlineResponse20050 summarizeCampaignStoreBudget(Long applicationId, Long
404 Not found -
*/ - public ApiResponse summarizeCampaignStoreBudgetWithHttpInfo(Long applicationId, Long campaignId) throws ApiException { + public ApiResponse summarizeCampaignStoreBudgetWithHttpInfo(Long applicationId, Long campaignId) throws ApiException { okhttp3.Call localVarCall = summarizeCampaignStoreBudgetValidateBeforeCall(applicationId, campaignId, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } @@ -23454,10 +24862,10 @@ public ApiResponse summarizeCampaignStoreBudgetWithHttpInfo 404 Not found - */ - public okhttp3.Call summarizeCampaignStoreBudgetAsync(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { + public okhttp3.Call summarizeCampaignStoreBudgetAsync(Long applicationId, Long campaignId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = summarizeCampaignStoreBudgetValidateBeforeCall(applicationId, campaignId, _callback); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } @@ -23748,7 +25156,9 @@ public okhttp3.Call updateAccountCollectionAsync(Long collectionId, UpdateCollec 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call updateAchievementCall(Long applicationId, Long campaignId, Long achievementId, UpdateAchievement body, final ApiCallback _callback) throws ApiException { Object localVarPostBody = body; @@ -23781,6 +25191,7 @@ public okhttp3.Call updateAchievementCall(Long applicationId, Long campaignId, L return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } + @Deprecated @SuppressWarnings("rawtypes") private okhttp3.Call updateAchievementValidateBeforeCall(Long applicationId, Long campaignId, Long achievementId, UpdateAchievement body, final ApiCallback _callback) throws ApiException { @@ -23827,7 +25238,9 @@ private okhttp3.Call updateAchievementValidateBeforeCall(Long applicationId, Lon 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public Achievement updateAchievement(Long applicationId, Long campaignId, Long achievementId, UpdateAchievement body) throws ApiException { ApiResponse localVarResp = updateAchievementWithHttpInfo(applicationId, campaignId, achievementId, body); return localVarResp.getData(); @@ -23850,7 +25263,9 @@ public Achievement updateAchievement(Long applicationId, Long campaignId, Long a 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public ApiResponse updateAchievementWithHttpInfo(Long applicationId, Long campaignId, Long achievementId, UpdateAchievement body) throws ApiException { okhttp3.Call localVarCall = updateAchievementValidateBeforeCall(applicationId, campaignId, achievementId, body, null); Type localVarReturnType = new TypeToken(){}.getType(); @@ -23875,7 +25290,9 @@ public ApiResponse updateAchievementWithHttpInfo(Long applicationId 401 Unauthorized - 404 Not found - + * @deprecated */ + @Deprecated public okhttp3.Call updateAchievementAsync(Long applicationId, Long campaignId, Long achievementId, UpdateAchievement body, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = updateAchievementValidateBeforeCall(applicationId, campaignId, achievementId, body, _callback); @@ -23883,6 +25300,138 @@ public okhttp3.Call updateAchievementAsync(Long applicationId, Long campaignId, localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } + /** + * Build call for updateAchievementV2 + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @param body body (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call updateAchievementV2Call(Long achievementId, UpdateAchievementV2 body, final ApiCallback _callback) throws ApiException { + Object localVarPostBody = body; + + // create path and map variables + String localVarPath = "/v2/achievements/{achievementId}" + .replaceAll("\\{" + "achievementId" + "\\}", localVarApiClient.escapeString(achievementId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + String[] localVarAuthNames = new String[] { "api_key_v1", "management_key", "manager_auth" }; + return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call updateAchievementV2ValidateBeforeCall(Long achievementId, UpdateAchievementV2 body, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'achievementId' is set + if (achievementId == null) { + throw new ApiException("Missing the required parameter 'achievementId' when calling updateAchievementV2(Async)"); + } + + // verify the required parameter 'body' is set + if (body == null) { + throw new ApiException("Missing the required parameter 'body' when calling updateAchievementV2(Async)"); + } + + + okhttp3.Call localVarCall = updateAchievementV2Call(achievementId, body, _callback); + return localVarCall; + + } + + /** + * Update achievement + * Update the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @param body body (required) + * @return AchievementV2 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public AchievementV2 updateAchievementV2(Long achievementId, UpdateAchievementV2 body) throws ApiException { + ApiResponse localVarResp = updateAchievementV2WithHttpInfo(achievementId, body); + return localVarResp.getData(); + } + + /** + * Update achievement + * Update the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @param body body (required) + * @return ApiResponse<AchievementV2> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public ApiResponse updateAchievementV2WithHttpInfo(Long achievementId, UpdateAchievementV2 body) throws ApiException { + okhttp3.Call localVarCall = updateAchievementV2ValidateBeforeCall(achievementId, body, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Update achievement (asynchronously) + * Update the details of a specific achievement. + * @param achievementId The ID of the achievement. You can get this ID with the [List achievement](https://docs.talon.one/management-api#tag/Achievements/operation/listAchievementsV2) endpoint. (required) + * @param body body (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
404 Not found -
+ */ + public okhttp3.Call updateAchievementV2Async(Long achievementId, UpdateAchievementV2 body, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = updateAchievementV2ValidateBeforeCall(achievementId, body, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } /** * Build call for updateAdditionalCost * @param additionalCostId The ID of the additional cost. You can find the ID the the Campaign Manager's URL when you display the details of the cost in **Account** > **Tools** > **Additional costs**. (required) diff --git a/src/main/java/one/talon/model/AcceptCouponEffectProps.java b/src/main/java/one/talon/model/AcceptCouponEffectProps.java index b80129a9..b0114d92 100644 --- a/src/main/java/one/talon/model/AcceptCouponEffectProps.java +++ b/src/main/java/one/talon/model/AcceptCouponEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"acceptCoupon\" effect. This gets triggered whenever the coupon is valid and all other conditions in the rules of its campaign are met. + * This effect indicates that the coupon code supplied was valid. You should handle this effect by clearing any messages from previous `rejectCoupon` effects and informing the user that the coupon is valid. The code is automatically redeemed when you close the session. Other effects, such as [setDiscount](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscount), provide more information about the actual rewards received. */ -@ApiModel(description = "The properties specific to the \"acceptCoupon\" effect. This gets triggered whenever the coupon is valid and all other conditions in the rules of its campaign are met.") +@ApiModel(description = "This effect indicates that the coupon code supplied was valid. You should handle this effect by clearing any messages from previous `rejectCoupon` effects and informing the user that the coupon is valid. The code is automatically redeemed when you close the session. Other effects, such as [setDiscount](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscount), provide more information about the actual rewards received.") public class AcceptCouponEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; diff --git a/src/main/java/one/talon/model/AcceptReferralEffectProps.java b/src/main/java/one/talon/model/AcceptReferralEffectProps.java index 38daa661..9d4b45c8 100644 --- a/src/main/java/one/talon/model/AcceptReferralEffectProps.java +++ b/src/main/java/one/talon/model/AcceptReferralEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"acceptReferral\" effect. TThis gets triggered whenever the referral code is valid and all other conditions in the rules of its campaign are met. + * This effect indicates that the referral code supplied is valid. You should handle this effect by informing the user that the referral code is valid. The code is automatically redeemed when you close the session. Other effects will provide more information about the actual reward. */ -@ApiModel(description = "The properties specific to the \"acceptReferral\" effect. TThis gets triggered whenever the referral code is valid and all other conditions in the rules of its campaign are met.") +@ApiModel(description = "This effect indicates that the referral code supplied is valid. You should handle this effect by informing the user that the referral code is valid. The code is automatically redeemed when you close the session. Other effects will provide more information about the actual reward.") public class AcceptReferralEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -42,10 +42,10 @@ public AcceptReferralEffectProps value(String value) { } /** - * The referral code that was accepted. + * The referral code provided in the session. * @return value **/ - @ApiModelProperty(required = true, value = "The referral code that was accepted.") + @ApiModelProperty(required = true, value = "The referral code provided in the session.") public String getValue() { return value; diff --git a/src/main/java/one/talon/model/AchievementAdditionalPropertiesV2.java b/src/main/java/one/talon/model/AchievementAdditionalPropertiesV2.java index 5bbc040e..4d79a9a9 100644 --- a/src/main/java/one/talon/model/AchievementAdditionalPropertiesV2.java +++ b/src/main/java/one/talon/model/AchievementAdditionalPropertiesV2.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.TimePoint; /** * AchievementAdditionalPropertiesV2 @@ -37,22 +38,24 @@ public class AchievementAdditionalPropertiesV2 { @SerializedName(SERIALIZED_NAME_CREATED_BY) private String createdBy; + public static final String SERIALIZED_NAME_PERIOD_END_OVERRIDE = "periodEndOverride"; + @SerializedName(SERIALIZED_NAME_PERIOD_END_OVERRIDE) + private TimePoint periodEndOverride; + public static final String SERIALIZED_NAME_HAS_PROGRESS = "hasProgress"; @SerializedName(SERIALIZED_NAME_HAS_PROGRESS) private Boolean hasProgress; /** - * The status of the achievement. + * The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. */ @JsonAdapter(StatusEnum.Adapter.class) public enum StatusEnum { - INPROGRESS("inprogress"), - - EXPIRED("expired"), + ACTIVE("active"), - NOT_STARTED("not_started"), + SCHEDULED("scheduled"), - COMPLETED("completed"); + EXPIRED("expired"); private String value; @@ -142,6 +145,29 @@ public void setCreatedBy(String createdBy) { } + public AchievementAdditionalPropertiesV2 periodEndOverride(TimePoint periodEndOverride) { + + this.periodEndOverride = periodEndOverride; + return this; + } + + /** + * Get periodEndOverride + * @return periodEndOverride + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public TimePoint getPeriodEndOverride() { + return periodEndOverride; + } + + + public void setPeriodEndOverride(TimePoint periodEndOverride) { + this.periodEndOverride = periodEndOverride; + } + + public AchievementAdditionalPropertiesV2 hasProgress(Boolean hasProgress) { this.hasProgress = hasProgress; @@ -172,11 +198,11 @@ public AchievementAdditionalPropertiesV2 status(StatusEnum status) { } /** - * The status of the achievement. + * The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. * @return status **/ @javax.annotation.Nullable - @ApiModelProperty(example = "inprogress", value = "The status of the achievement.") + @ApiModelProperty(example = "active", value = "The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. ") public StatusEnum getStatus() { return status; @@ -199,13 +225,14 @@ public boolean equals(java.lang.Object o) { AchievementAdditionalPropertiesV2 achievementAdditionalPropertiesV2 = (AchievementAdditionalPropertiesV2) o; return Objects.equals(this.userId, achievementAdditionalPropertiesV2.userId) && Objects.equals(this.createdBy, achievementAdditionalPropertiesV2.createdBy) && + Objects.equals(this.periodEndOverride, achievementAdditionalPropertiesV2.periodEndOverride) && Objects.equals(this.hasProgress, achievementAdditionalPropertiesV2.hasProgress) && Objects.equals(this.status, achievementAdditionalPropertiesV2.status); } @Override public int hashCode() { - return Objects.hash(userId, createdBy, hasProgress, status); + return Objects.hash(userId, createdBy, periodEndOverride, hasProgress, status); } @@ -215,6 +242,7 @@ public String toString() { sb.append("class AchievementAdditionalPropertiesV2 {\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); sb.append(" createdBy: ").append(toIndentedString(createdBy)).append("\n"); + sb.append(" periodEndOverride: ").append(toIndentedString(periodEndOverride)).append("\n"); sb.append(" hasProgress: ").append(toIndentedString(hasProgress)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/AchievementBaseV2.java b/src/main/java/one/talon/model/AchievementBaseV2.java index fb1f4a82..ee04d88d 100644 --- a/src/main/java/one/talon/model/AchievementBaseV2.java +++ b/src/main/java/one/talon/model/AchievementBaseV2.java @@ -169,18 +169,10 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION) private Boolean allowRollbackAfterCompletion; - public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; - @SerializedName(SERIALIZED_NAME_SANDBOX) - private Boolean sandbox; - public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS = "subscribedApplications"; @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS) private List subscribedApplications = null; - public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; - @SerializedName(SERIALIZED_NAME_TIMEZONE) - private String timezone; - public AchievementBaseV2 name(String name) { @@ -412,29 +404,6 @@ public void setAllowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion } - public AchievementBaseV2 sandbox(Boolean sandbox) { - - this.sandbox = sandbox; - return this; - } - - /** - * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. - * @return sandbox - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") - - public Boolean getSandbox() { - return sandbox; - } - - - public void setSandbox(Boolean sandbox) { - this.sandbox = sandbox; - } - - public AchievementBaseV2 subscribedApplications(List subscribedApplications) { this.subscribedApplications = subscribedApplications; @@ -466,29 +435,6 @@ public void setSubscribedApplications(List subscribedApplications) { } - public AchievementBaseV2 timezone(String timezone) { - - this.timezone = timezone; - return this; - } - - /** - * A string containing an IANA timezone descriptor. - * @return timezone - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Europe/Berlin", value = "A string containing an IANA timezone descriptor.") - - public String getTimezone() { - return timezone; - } - - - public void setTimezone(String timezone) { - this.timezone = timezone; - } - - @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -508,14 +454,12 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.fixedStartDate, achievementBaseV2.fixedStartDate) && Objects.equals(this.endDate, achievementBaseV2.endDate) && Objects.equals(this.allowRollbackAfterCompletion, achievementBaseV2.allowRollbackAfterCompletion) && - Objects.equals(this.sandbox, achievementBaseV2.sandbox) && - Objects.equals(this.subscribedApplications, achievementBaseV2.subscribedApplications) && - Objects.equals(this.timezone, achievementBaseV2.timezone); + Objects.equals(this.subscribedApplications, achievementBaseV2.subscribedApplications); } @Override public int hashCode() { - return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, sandbox, subscribedApplications, timezone); + return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, subscribedApplications); } @@ -533,9 +477,7 @@ public String toString() { sb.append(" fixedStartDate: ").append(toIndentedString(fixedStartDate)).append("\n"); sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); - sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" subscribedApplications: ").append(toIndentedString(subscribedApplications)).append("\n"); - sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/AchievementProgressWithDefinition.java b/src/main/java/one/talon/model/AchievementProgressWithDefinition.java index 895fa1dd..5534b666 100644 --- a/src/main/java/one/talon/model/AchievementProgressWithDefinition.java +++ b/src/main/java/one/talon/model/AchievementProgressWithDefinition.java @@ -24,6 +24,9 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CampaignReference; import org.threeten.bp.OffsetDateTime; /** @@ -123,6 +126,14 @@ public StatusEnum read(final JsonReader jsonReader) throws IOException { @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) private Long campaignId; + public static final String SERIALIZED_NAME_CAMPAIGN_IDS = "campaignIds"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_IDS) + private List campaignIds = new ArrayList(); + + public static final String SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS = "referencedByCampaigns"; + @SerializedName(SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS) + private List referencedByCampaigns = new ArrayList(); + public static final String SERIALIZED_NAME_TARGET = "target"; @SerializedName(SERIALIZED_NAME_TARGET) private BigDecimal target; @@ -452,10 +463,11 @@ public AchievementProgressWithDefinition campaignId(Long campaignId) { } /** - * The ID of the campaign the achievement belongs to. + * This property is **deprecated**. Use `campaignIds` (Integration API) or `referencedByCampaigns` (Management API) instead. This field contains the first campaign ID from the related `campaignIds`, and is omitted when `campaignIds` is empty. * @return campaignId **/ - @ApiModelProperty(example = "3", required = true, value = "The ID of the campaign the achievement belongs to.") + @javax.annotation.Nullable + @ApiModelProperty(example = "3", value = "This property is **deprecated**. Use `campaignIds` (Integration API) or `referencedByCampaigns` (Management API) instead. This field contains the first campaign ID from the related `campaignIds`, and is omitted when `campaignIds` is empty.") public Long getCampaignId() { return campaignId; @@ -467,6 +479,60 @@ public void setCampaignId(Long campaignId) { } + public AchievementProgressWithDefinition campaignIds(List campaignIds) { + + this.campaignIds = campaignIds; + return this; + } + + public AchievementProgressWithDefinition addCampaignIdsItem(Long campaignIdsItem) { + this.campaignIds.add(campaignIdsItem); + return this; + } + + /** + * The IDs of the campaigns that reference this achievement, in ascending order. + * @return campaignIds + **/ + @ApiModelProperty(example = "[1, 14, 27]", required = true, value = "The IDs of the campaigns that reference this achievement, in ascending order.") + + public List getCampaignIds() { + return campaignIds; + } + + + public void setCampaignIds(List campaignIds) { + this.campaignIds = campaignIds; + } + + + public AchievementProgressWithDefinition referencedByCampaigns(List referencedByCampaigns) { + + this.referencedByCampaigns = referencedByCampaigns; + return this; + } + + public AchievementProgressWithDefinition addReferencedByCampaignsItem(CampaignReference referencedByCampaignsItem) { + this.referencedByCampaigns.add(referencedByCampaignsItem); + return this; + } + + /** + * The campaigns that reference this achievement, in ascending order of their `id`. + * @return referencedByCampaigns + **/ + @ApiModelProperty(required = true, value = "The campaigns that reference this achievement, in ascending order of their `id`.") + + public List getReferencedByCampaigns() { + return referencedByCampaigns; + } + + + public void setReferencedByCampaigns(List referencedByCampaigns) { + this.referencedByCampaigns = referencedByCampaigns; + } + + public AchievementProgressWithDefinition target(BigDecimal target) { this.target = target; @@ -622,6 +688,8 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.title, achievementProgressWithDefinition.title) && Objects.equals(this.description, achievementProgressWithDefinition.description) && Objects.equals(this.campaignId, achievementProgressWithDefinition.campaignId) && + Objects.equals(this.campaignIds, achievementProgressWithDefinition.campaignIds) && + Objects.equals(this.referencedByCampaigns, achievementProgressWithDefinition.referencedByCampaigns) && Objects.equals(this.target, achievementProgressWithDefinition.target) && Objects.equals(this.achievementRecurrencePolicy, achievementProgressWithDefinition.achievementRecurrencePolicy) && Objects.equals(this.achievementActivationPolicy, achievementProgressWithDefinition.achievementActivationPolicy) && @@ -632,7 +700,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(status, progress, startDate, completionDate, endDate, achievementId, name, title, description, campaignId, target, achievementRecurrencePolicy, achievementActivationPolicy, achievementFixedStartDate, achievementEndDate, achievementAllowRollbackAfterCompletion); + return Objects.hash(status, progress, startDate, completionDate, endDate, achievementId, name, title, description, campaignId, campaignIds, referencedByCampaigns, target, achievementRecurrencePolicy, achievementActivationPolicy, achievementFixedStartDate, achievementEndDate, achievementAllowRollbackAfterCompletion); } @@ -650,6 +718,8 @@ public String toString() { sb.append(" title: ").append(toIndentedString(title)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" campaignIds: ").append(toIndentedString(campaignIds)).append("\n"); + sb.append(" referencedByCampaigns: ").append(toIndentedString(referencedByCampaigns)).append("\n"); sb.append(" target: ").append(toIndentedString(target)).append("\n"); sb.append(" achievementRecurrencePolicy: ").append(toIndentedString(achievementRecurrencePolicy)).append("\n"); sb.append(" achievementActivationPolicy: ").append(toIndentedString(achievementActivationPolicy)).append("\n"); diff --git a/src/main/java/one/talon/model/AchievementReference.java b/src/main/java/one/talon/model/AchievementReference.java index 49d17d5c..cd13842a 100644 --- a/src/main/java/one/talon/model/AchievementReference.java +++ b/src/main/java/one/talon/model/AchievementReference.java @@ -45,6 +45,63 @@ public class AchievementReference { @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) private Long campaignId; + public static final String SERIALIZED_NAME_CAMPAIGN_NAME = "campaignName"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_NAME) + private String campaignName; + + /** + * The state of the campaign that references this achievement. + */ + @JsonAdapter(CampaignStateEnum.Adapter.class) + public enum CampaignStateEnum { + ENABLED("enabled"), + + DISABLED("disabled"), + + ARCHIVED("archived"); + + private String value; + + CampaignStateEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static CampaignStateEnum fromValue(String value) { + for (CampaignStateEnum b : CampaignStateEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final CampaignStateEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public CampaignStateEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return CampaignStateEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_CAMPAIGN_STATE = "campaignState"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_STATE) + private CampaignStateEnum campaignState; + public AchievementReference achievementId(Long achievementId) { @@ -134,6 +191,50 @@ public void setCampaignId(Long campaignId) { } + public AchievementReference campaignName(String campaignName) { + + this.campaignName = campaignName; + return this; + } + + /** + * The name of the campaign that references this achievement. + * @return campaignName + **/ + @ApiModelProperty(example = "Summer promotions", required = true, value = "The name of the campaign that references this achievement.") + + public String getCampaignName() { + return campaignName; + } + + + public void setCampaignName(String campaignName) { + this.campaignName = campaignName; + } + + + public AchievementReference campaignState(CampaignStateEnum campaignState) { + + this.campaignState = campaignState; + return this; + } + + /** + * The state of the campaign that references this achievement. + * @return campaignState + **/ + @ApiModelProperty(example = "enabled", required = true, value = "The state of the campaign that references this achievement.") + + public CampaignStateEnum getCampaignState() { + return campaignState; + } + + + public void setCampaignState(CampaignStateEnum campaignState) { + this.campaignState = campaignState; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -146,12 +247,14 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.achievementId, achievementReference.achievementId) && Objects.equals(this.applicationId, achievementReference.applicationId) && Objects.equals(this.applicationName, achievementReference.applicationName) && - Objects.equals(this.campaignId, achievementReference.campaignId); + Objects.equals(this.campaignId, achievementReference.campaignId) && + Objects.equals(this.campaignName, achievementReference.campaignName) && + Objects.equals(this.campaignState, achievementReference.campaignState); } @Override public int hashCode() { - return Objects.hash(achievementId, applicationId, applicationName, campaignId); + return Objects.hash(achievementId, applicationId, applicationName, campaignId, campaignName, campaignState); } @@ -163,6 +266,8 @@ public String toString() { sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); sb.append(" applicationName: ").append(toIndentedString(applicationName)).append("\n"); sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" campaignName: ").append(toIndentedString(campaignName)).append("\n"); + sb.append(" campaignState: ").append(toIndentedString(campaignState)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/AchievementStatusEntry.java b/src/main/java/one/talon/model/AchievementStatusEntry.java index 021b2349..f244152a 100644 --- a/src/main/java/one/talon/model/AchievementStatusEntry.java +++ b/src/main/java/one/talon/model/AchievementStatusEntry.java @@ -24,6 +24,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.AchievementProgress; import one.talon.model.TimePoint; import org.threeten.bp.OffsetDateTime; @@ -185,6 +187,10 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) private Long campaignId; + public static final String SERIALIZED_NAME_CAMPAIGN_IDS = "campaignIds"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_IDS) + private List campaignIds = null; + /** * The status of the achievement. */ @@ -541,11 +547,11 @@ public AchievementStatusEntry campaignId(Long campaignId) { } /** - * The ID of the campaign the achievement belongs to. + * This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. * @return campaignId **/ @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "The ID of the campaign the achievement belongs to.") + @ApiModelProperty(example = "1", value = "This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty.") public Long getCampaignId() { return campaignId; @@ -557,6 +563,37 @@ public void setCampaignId(Long campaignId) { } + public AchievementStatusEntry campaignIds(List campaignIds) { + + this.campaignIds = campaignIds; + return this; + } + + public AchievementStatusEntry addCampaignIdsItem(Long campaignIdsItem) { + if (this.campaignIds == null) { + this.campaignIds = new ArrayList(); + } + this.campaignIds.add(campaignIdsItem); + return this; + } + + /** + * The IDs of the campaigns that reference this achievement, in ascending order. + * @return campaignIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[1, 14, 27]", value = "The IDs of the campaigns that reference this achievement, in ascending order.") + + public List getCampaignIds() { + return campaignIds; + } + + + public void setCampaignIds(List campaignIds) { + this.campaignIds = campaignIds; + } + + public AchievementStatusEntry status(StatusEnum status) { this.status = status; @@ -626,13 +663,14 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.endDate, achievementStatusEntry.endDate) && Objects.equals(this.allowRollbackAfterCompletion, achievementStatusEntry.allowRollbackAfterCompletion) && Objects.equals(this.campaignId, achievementStatusEntry.campaignId) && + Objects.equals(this.campaignIds, achievementStatusEntry.campaignIds) && Objects.equals(this.status, achievementStatusEntry.status) && Objects.equals(this.currentProgress, achievementStatusEntry.currentProgress); } @Override public int hashCode() { - return Objects.hash(id, created, name, title, description, target, period, periodEndOverride, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, campaignId, status, currentProgress); + return Objects.hash(id, created, name, title, description, target, period, periodEndOverride, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, campaignId, campaignIds, status, currentProgress); } @@ -654,6 +692,7 @@ public String toString() { sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" campaignIds: ").append(toIndentedString(campaignIds)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" currentProgress: ").append(toIndentedString(currentProgress)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/AchievementV2.java b/src/main/java/one/talon/model/AchievementV2.java index 9de66267..949b114d 100644 --- a/src/main/java/one/talon/model/AchievementV2.java +++ b/src/main/java/one/talon/model/AchievementV2.java @@ -26,6 +26,8 @@ import java.math.BigDecimal; import java.util.ArrayList; import java.util.List; +import one.talon.model.CampaignReference; +import one.talon.model.TimePoint; import org.threeten.bp.OffsetDateTime; /** @@ -177,18 +179,10 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION) private Boolean allowRollbackAfterCompletion; - public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; - @SerializedName(SERIALIZED_NAME_SANDBOX) - private Boolean sandbox; - public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS = "subscribedApplications"; @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS) private List subscribedApplications = new ArrayList(); - public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; - @SerializedName(SERIALIZED_NAME_TIMEZONE) - private String timezone; - public static final String SERIALIZED_NAME_USER_ID = "userId"; @SerializedName(SERIALIZED_NAME_USER_ID) private Long userId; @@ -197,22 +191,24 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_CREATED_BY) private String createdBy; + public static final String SERIALIZED_NAME_PERIOD_END_OVERRIDE = "periodEndOverride"; + @SerializedName(SERIALIZED_NAME_PERIOD_END_OVERRIDE) + private TimePoint periodEndOverride; + public static final String SERIALIZED_NAME_HAS_PROGRESS = "hasProgress"; @SerializedName(SERIALIZED_NAME_HAS_PROGRESS) private Boolean hasProgress; /** - * The status of the achievement. + * The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. */ @JsonAdapter(StatusEnum.Adapter.class) public enum StatusEnum { - INPROGRESS("inprogress"), - - EXPIRED("expired"), + ACTIVE("active"), - NOT_STARTED("not_started"), + SCHEDULED("scheduled"), - COMPLETED("completed"); + EXPIRED("expired"); private String value; @@ -256,6 +252,22 @@ public StatusEnum read(final JsonReader jsonReader) throws IOException { @SerializedName(SERIALIZED_NAME_STATUS) private StatusEnum status; + public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; + @SerializedName(SERIALIZED_NAME_SANDBOX) + private Boolean sandbox; + + public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; + @SerializedName(SERIALIZED_NAME_TIMEZONE) + private String timezone; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS = "referencedByCampaigns"; + @SerializedName(SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS) + private List referencedByCampaigns = new ArrayList(); + public AchievementV2 id(Long id) { @@ -525,28 +537,6 @@ public void setAllowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion } - public AchievementV2 sandbox(Boolean sandbox) { - - this.sandbox = sandbox; - return this; - } - - /** - * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. - * @return sandbox - **/ - @ApiModelProperty(example = "true", required = true, value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") - - public Boolean getSandbox() { - return sandbox; - } - - - public void setSandbox(Boolean sandbox) { - this.sandbox = sandbox; - } - - public AchievementV2 subscribedApplications(List subscribedApplications) { this.subscribedApplications = subscribedApplications; @@ -574,28 +564,6 @@ public void setSubscribedApplications(List subscribedApplications) { } - public AchievementV2 timezone(String timezone) { - - this.timezone = timezone; - return this; - } - - /** - * A string containing an IANA timezone descriptor. - * @return timezone - **/ - @ApiModelProperty(example = "Europe/Berlin", required = true, value = "A string containing an IANA timezone descriptor.") - - public String getTimezone() { - return timezone; - } - - - public void setTimezone(String timezone) { - this.timezone = timezone; - } - - public AchievementV2 userId(Long userId) { this.userId = userId; @@ -641,6 +609,29 @@ public void setCreatedBy(String createdBy) { } + public AchievementV2 periodEndOverride(TimePoint periodEndOverride) { + + this.periodEndOverride = periodEndOverride; + return this; + } + + /** + * Get periodEndOverride + * @return periodEndOverride + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public TimePoint getPeriodEndOverride() { + return periodEndOverride; + } + + + public void setPeriodEndOverride(TimePoint periodEndOverride) { + this.periodEndOverride = periodEndOverride; + } + + public AchievementV2 hasProgress(Boolean hasProgress) { this.hasProgress = hasProgress; @@ -671,11 +662,11 @@ public AchievementV2 status(StatusEnum status) { } /** - * The status of the achievement. + * The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. * @return status **/ @javax.annotation.Nullable - @ApiModelProperty(example = "inprogress", value = "The status of the achievement.") + @ApiModelProperty(example = "active", value = "The status of the achievement. - `active`: The achievement is available to customers. - `scheduled`: The achievement has a `fixedStartDate` set in the future. - `expired`: The achievement's `endDate` is in the past. ") public StatusEnum getStatus() { return status; @@ -687,6 +678,100 @@ public void setStatus(StatusEnum status) { } + public AchievementV2 sandbox(Boolean sandbox) { + + this.sandbox = sandbox; + return this; + } + + /** + * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. + * @return sandbox + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") + + public Boolean getSandbox() { + return sandbox; + } + + + public void setSandbox(Boolean sandbox) { + this.sandbox = sandbox; + } + + + public AchievementV2 timezone(String timezone) { + + this.timezone = timezone; + return this; + } + + /** + * A string containing an IANA timezone descriptor. + * @return timezone + **/ + @ApiModelProperty(example = "Europe/Berlin", required = true, value = "A string containing an IANA timezone descriptor.") + + public String getTimezone() { + return timezone; + } + + + public void setTimezone(String timezone) { + this.timezone = timezone; + } + + + public AchievementV2 campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. + * @return campaignId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "3", value = "This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public AchievementV2 referencedByCampaigns(List referencedByCampaigns) { + + this.referencedByCampaigns = referencedByCampaigns; + return this; + } + + public AchievementV2 addReferencedByCampaignsItem(CampaignReference referencedByCampaignsItem) { + this.referencedByCampaigns.add(referencedByCampaignsItem); + return this; + } + + /** + * The campaigns that reference this achievement. They are sorted in ascending order by their id. + * @return referencedByCampaigns + **/ + @ApiModelProperty(required = true, value = "The campaigns that reference this achievement. They are sorted in ascending order by their id.") + + public List getReferencedByCampaigns() { + return referencedByCampaigns; + } + + + public void setReferencedByCampaigns(List referencedByCampaigns) { + this.referencedByCampaigns = referencedByCampaigns; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -708,18 +793,21 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.fixedStartDate, achievementV2.fixedStartDate) && Objects.equals(this.endDate, achievementV2.endDate) && Objects.equals(this.allowRollbackAfterCompletion, achievementV2.allowRollbackAfterCompletion) && - Objects.equals(this.sandbox, achievementV2.sandbox) && Objects.equals(this.subscribedApplications, achievementV2.subscribedApplications) && - Objects.equals(this.timezone, achievementV2.timezone) && Objects.equals(this.userId, achievementV2.userId) && Objects.equals(this.createdBy, achievementV2.createdBy) && + Objects.equals(this.periodEndOverride, achievementV2.periodEndOverride) && Objects.equals(this.hasProgress, achievementV2.hasProgress) && - Objects.equals(this.status, achievementV2.status); + Objects.equals(this.status, achievementV2.status) && + Objects.equals(this.sandbox, achievementV2.sandbox) && + Objects.equals(this.timezone, achievementV2.timezone) && + Objects.equals(this.campaignId, achievementV2.campaignId) && + Objects.equals(this.referencedByCampaigns, achievementV2.referencedByCampaigns); } @Override public int hashCode() { - return Objects.hash(id, created, name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, sandbox, subscribedApplications, timezone, userId, createdBy, hasProgress, status); + return Objects.hash(id, created, name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, subscribedApplications, userId, createdBy, periodEndOverride, hasProgress, status, sandbox, timezone, campaignId, referencedByCampaigns); } @@ -739,13 +827,16 @@ public String toString() { sb.append(" fixedStartDate: ").append(toIndentedString(fixedStartDate)).append("\n"); sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); - sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" subscribedApplications: ").append(toIndentedString(subscribedApplications)).append("\n"); - sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); sb.append(" createdBy: ").append(toIndentedString(createdBy)).append("\n"); + sb.append(" periodEndOverride: ").append(toIndentedString(periodEndOverride)).append("\n"); sb.append(" hasProgress: ").append(toIndentedString(hasProgress)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); + sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" referencedByCampaigns: ").append(toIndentedString(referencedByCampaigns)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/AddFreeItemEffectProps.java b/src/main/java/one/talon/model/AddFreeItemEffectProps.java index 97032691..e27eeac0 100644 --- a/src/main/java/one/talon/model/AddFreeItemEffectProps.java +++ b/src/main/java/one/talon/model/AddFreeItemEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"addFreeItem\" effect. This gets triggered whenever a validated rule contained an \"add free item\" effect. + * This effect indicates that a free item should be added to the shopping cart in the current session. In this example, add the SKU to the shopping cart and set its price to `0`. The effect of a successful referral can mean a free item for someone else, such as the referrer. */ -@ApiModel(description = "The properties specific to the \"addFreeItem\" effect. This gets triggered whenever a validated rule contained an \"add free item\" effect.") +@ApiModel(description = "This effect indicates that a free item should be added to the shopping cart in the current session. In this example, add the SKU to the shopping cart and set its price to `0`. The effect of a successful referral can mean a free item for someone else, such as the referrer.") public class AddFreeItemEffectProps { public static final String SERIALIZED_NAME_SKU = "sku"; @@ -72,10 +72,10 @@ public AddFreeItemEffectProps name(String name) { } /** - * The name / description of the effect + * Description of the effect. * @return name **/ - @ApiModelProperty(required = true, value = "The name / description of the effect") + @ApiModelProperty(required = true, value = "Description of the effect.") public String getName() { return name; diff --git a/src/main/java/one/talon/model/AddLoyaltyPointsEffectProps.java b/src/main/java/one/talon/model/AddLoyaltyPointsEffectProps.java index 5eb69551..8c725d9a 100644 --- a/src/main/java/one/talon/model/AddLoyaltyPointsEffectProps.java +++ b/src/main/java/one/talon/model/AddLoyaltyPointsEffectProps.java @@ -27,9 +27,9 @@ import org.threeten.bp.OffsetDateTime; /** - * The properties specific to the \"addLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained an \"add loyalty\" effect. These points are automatically stored and managed inside Talon.One. + * This effect indicates that a defined amount of loyalty points was successfully added to the customer's profile or to a loyalty card. If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which item to add the loyalty points for. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. See the example below for more information. If your list of cart items is a [bundle definition](https://docs.talon.one/docs/product/rules/create-and-manage-bundles), use the `bundleIndex` and `bundleName` properties to identify the bundle containing the items for which loyalty points are added. If you have set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card on which these points are added. The points only persist when the session is closed. */ -@ApiModel(description = "The properties specific to the \"addLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained an \"add loyalty\" effect. These points are automatically stored and managed inside Talon.One. ") +@ApiModel(description = "This effect indicates that a defined amount of loyalty points was successfully added to the customer's profile or to a loyalty card. If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which item to add the loyalty points for. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. See the example below for more information. If your list of cart items is a [bundle definition](https://docs.talon.one/docs/product/rules/create-and-manage-bundles), use the `bundleIndex` and `bundleName` properties to identify the bundle containing the items for which loyalty points are added. If you have set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card on which these points are added. The points only persist when the session is closed.") public class AddLoyaltyPointsEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -104,10 +104,10 @@ public AddLoyaltyPointsEffectProps name(String name) { } /** - * The name / description of this loyalty point addition. + * The reason of this loyalty point addition. * @return name **/ - @ApiModelProperty(required = true, value = "The name / description of this loyalty point addition.") + @ApiModelProperty(required = true, value = "The reason of this loyalty point addition.") public String getName() { return name; @@ -192,11 +192,11 @@ public AddLoyaltyPointsEffectProps desiredValue(BigDecimal desiredValue) { } /** - * The original amount of loyalty points to be awarded. + * (Partial rewards enabled only) The amount of loyalty points to be awarded without considering budget limitations. * @return desiredValue **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The original amount of loyalty points to be awarded.") + @ApiModelProperty(value = "(Partial rewards enabled only) The amount of loyalty points to be awarded without considering budget limitations.") public BigDecimal getDesiredValue() { return desiredValue; @@ -237,11 +237,11 @@ public AddLoyaltyPointsEffectProps startDate(OffsetDateTime startDate) { } /** - * Date after which points will be valid. + * The date after which the added points will be valid. * @return startDate **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Date after which points will be valid.") + @ApiModelProperty(value = "The date after which the added points will be valid.") public OffsetDateTime getStartDate() { return startDate; @@ -260,11 +260,11 @@ public AddLoyaltyPointsEffectProps expiryDate(OffsetDateTime expiryDate) { } /** - * Date after which points will expire. + * The date after which the added points will expire. * @return expiryDate **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Date after which points will expire.") + @ApiModelProperty(value = "The date after which the added points will expire.") public OffsetDateTime getExpiryDate() { return expiryDate; @@ -283,10 +283,10 @@ public AddLoyaltyPointsEffectProps transactionUUID(String transactionUUID) { } /** - * The identifier of this addition in the loyalty ledger. + * The identifier of this loyalty point transaction. * @return transactionUUID **/ - @ApiModelProperty(required = true, value = "The identifier of this addition in the loyalty ledger.") + @ApiModelProperty(required = true, value = "The identifier of this loyalty point transaction.") public String getTransactionUUID() { return transactionUUID; @@ -305,11 +305,11 @@ public AddLoyaltyPointsEffectProps cartItemPosition(BigDecimal cartItemPosition) } /** - * The index of the item in the cart items list on which the loyal points addition should be applied. + * (_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were added. * @return cartItemPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The index of the item in the cart items list on which the loyal points addition should be applied.") + @ApiModelProperty(value = "(_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were added.") public BigDecimal getCartItemPosition() { return cartItemPosition; @@ -328,11 +328,11 @@ public AddLoyaltyPointsEffectProps cartItemSubPosition(BigDecimal cartItemSubPos } /** - * For cart items with `quantity` > 1, the sub position indicates to which item the loyalty points addition is applied. + * (_Add points per cart item_ ) The index of the item unit in its line item. * @return cartItemSubPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "For cart items with `quantity` > 1, the sub position indicates to which item the loyalty points addition is applied. ") + @ApiModelProperty(value = "(_Add points per cart item_ ) The index of the item unit in its line item.") public BigDecimal getCartItemSubPosition() { return cartItemSubPosition; @@ -374,11 +374,11 @@ public AddLoyaltyPointsEffectProps bundleIndex(Long bundleIndex) { } /** - * The position of the bundle in a list of item bundles created from the same bundle definition. + * _(With bundles only)_ The position of the specific bundle in the list of bundles created from the same bundle definition. * @return bundleIndex **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The position of the bundle in a list of item bundles created from the same bundle definition.") + @ApiModelProperty(value = "_(With bundles only)_ The position of the specific bundle in the list of bundles created from the same bundle definition.") public Long getBundleIndex() { return bundleIndex; @@ -397,11 +397,11 @@ public AddLoyaltyPointsEffectProps bundleName(String bundleName) { } /** - * The name of the bundle definition. + * _(With bundles only)_ The name of the bundle definition. * @return bundleName **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the bundle definition.") + @ApiModelProperty(value = "_(With bundles only)_ The name of the bundle definition.") public String getBundleName() { return bundleName; @@ -420,11 +420,11 @@ public AddLoyaltyPointsEffectProps awaitsActivation(Boolean awaitsActivation) { } /** - * If `true`, the loyalty points remain pending until a specific action is complete. The `startDate` parameter automatically sets to `on_action`. + * Indicates whether the points have an action-based start date. This property is returned only for point transactions with an action-based start date. * @return awaitsActivation **/ @javax.annotation.Nullable - @ApiModelProperty(value = "If `true`, the loyalty points remain pending until a specific action is complete. The `startDate` parameter automatically sets to `on_action`. ") + @ApiModelProperty(value = "Indicates whether the points have an action-based start date. This property is returned only for point transactions with an action-based start date.") public Boolean getAwaitsActivation() { return awaitsActivation; @@ -443,11 +443,11 @@ public AddLoyaltyPointsEffectProps validityDuration(String validityDuration) { } /** - * The duration for which the points remain active, calculated relative to the activation date. **Note**: This value is returned only if `awaitsActivation` is `true` and `expiryDate` is not set. + * The duration for which the points remain active, calculated relative to their start date. * @return validityDuration **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The duration for which the points remain active, calculated relative to the activation date. **Note**: This value is returned only if `awaitsActivation` is `true` and `expiryDate` is not set. ") + @ApiModelProperty(value = "The duration for which the points remain active, calculated relative to their start date.") public String getValidityDuration() { return validityDuration; diff --git a/src/main/java/one/talon/model/AddLoyaltyPointsSupport.java b/src/main/java/one/talon/model/AddLoyaltyPointsSupport.java new file mode 100644 index 00000000..dbf9fec2 --- /dev/null +++ b/src/main/java/one/talon/model/AddLoyaltyPointsSupport.java @@ -0,0 +1,363 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.threeten.bp.OffsetDateTime; + +/** + * Points to add via the support portal. + */ +@ApiModel(description = "Points to add via the support portal.") + +public class AddLoyaltyPointsSupport { + public static final String SERIALIZED_NAME_POINTS = "points"; + @SerializedName(SERIALIZED_NAME_POINTS) + private BigDecimal points; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_VALIDITY_DURATION = "validityDuration"; + @SerializedName(SERIALIZED_NAME_VALIDITY_DURATION) + private String validityDuration; + + public static final String SERIALIZED_NAME_VALID_UNTIL = "validUntil"; + @SerializedName(SERIALIZED_NAME_VALID_UNTIL) + private OffsetDateTime validUntil; + + public static final String SERIALIZED_NAME_PENDING_DURATION = "pendingDuration"; + @SerializedName(SERIALIZED_NAME_PENDING_DURATION) + private String pendingDuration; + + public static final String SERIALIZED_NAME_PENDING_UNTIL = "pendingUntil"; + @SerializedName(SERIALIZED_NAME_PENDING_UNTIL) + private OffsetDateTime pendingUntil; + + public static final String SERIALIZED_NAME_SUBLEDGER_ID = "subledgerId"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER_ID) + private String subledgerId; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_SUPPORT_REQUEST_ID = "supportRequestId"; + @SerializedName(SERIALIZED_NAME_SUPPORT_REQUEST_ID) + private Long supportRequestId; + + public static final String SERIALIZED_NAME_PROCESSING_NOTE = "processingNote"; + @SerializedName(SERIALIZED_NAME_PROCESSING_NOTE) + private String processingNote; + + + public AddLoyaltyPointsSupport points(BigDecimal points) { + + this.points = points; + return this; + } + + /** + * Amount of loyalty points. + * maximum: 999999999999.99 + * @return points + **/ + @ApiModelProperty(example = "300.0", required = true, value = "Amount of loyalty points.") + + public BigDecimal getPoints() { + return points; + } + + + public void setPoints(BigDecimal points) { + this.points = points; + } + + + public AddLoyaltyPointsSupport name(String name) { + + this.name = name; + return this; + } + + /** + * Name / reason for the point addition. + * @return name + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Compensation", value = "Name / reason for the point addition.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AddLoyaltyPointsSupport validityDuration(String validityDuration) { + + this.validityDuration = validityDuration; + return this; + } + + /** + * The time format is either: - `unlimited` or, - an **integer** followed by one letter indicating the time unit. Examples: `unlimited`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `validUntil` should be omitted. + * @return validityDuration + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "5D", value = "The time format is either: - `unlimited` or, - an **integer** followed by one letter indicating the time unit. Examples: `unlimited`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. If passed, `validUntil` should be omitted. ") + + public String getValidityDuration() { + return validityDuration; + } + + + public void setValidityDuration(String validityDuration) { + this.validityDuration = validityDuration; + } + + + public AddLoyaltyPointsSupport validUntil(OffsetDateTime validUntil) { + + this.validUntil = validUntil; + return this; + } + + /** + * Date and time when points should expire. The value should be provided in RFC 3339 format. If passed, `validityDuration` should be omitted. + * @return validUntil + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-07-20T22:00Z", value = "Date and time when points should expire. The value should be provided in RFC 3339 format. If passed, `validityDuration` should be omitted. ") + + public OffsetDateTime getValidUntil() { + return validUntil; + } + + + public void setValidUntil(OffsetDateTime validUntil) { + this.validUntil = validUntil; + } + + + public AddLoyaltyPointsSupport pendingDuration(String pendingDuration) { + + this.pendingDuration = pendingDuration; + return this; + } + + /** + * The amount of time before the points are considered valid. The time format is either: - `immediate` or, - `on_action` or, - an **integer** followed by one letter indicating the time unit. Examples: `immediate`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`, `on_action`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. + * @return pendingDuration + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "12h", value = "The amount of time before the points are considered valid. The time format is either: - `immediate` or, - `on_action` or, - an **integer** followed by one letter indicating the time unit. Examples: `immediate`, `30s`, `40m`, `1h`, `5D`, `7W`, `10M`, `15Y`, `on_action`. Available units: - `s`: seconds - `m`: minutes - `h`: hours - `D`: days - `W`: weeks - `M`: months - `Y`: years You can round certain units up or down: - `_D` for rounding down days only. Signifies the start of the day. - `_U` for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. ") + + public String getPendingDuration() { + return pendingDuration; + } + + + public void setPendingDuration(String pendingDuration) { + this.pendingDuration = pendingDuration; + } + + + public AddLoyaltyPointsSupport pendingUntil(OffsetDateTime pendingUntil) { + + this.pendingUntil = pendingUntil; + return this; + } + + /** + * Date and time after the points are considered valid. The value should be provided in RFC 3339 format. If passed, `pendingDuration` should be omitted. + * @return pendingUntil + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-07-20T22:00Z", value = "Date and time after the points are considered valid. The value should be provided in RFC 3339 format. If passed, `pendingDuration` should be omitted. ") + + public OffsetDateTime getPendingUntil() { + return pendingUntil; + } + + + public void setPendingUntil(OffsetDateTime pendingUntil) { + this.pendingUntil = pendingUntil; + } + + + public AddLoyaltyPointsSupport subledgerId(String subledgerId) { + + this.subledgerId = subledgerId; + return this; + } + + /** + * ID of the subledger the points are added to. If there is no existing subledger with this ID, the subledger is created automatically. + * @return subledgerId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "sub-123", value = "ID of the subledger the points are added to. If there is no existing subledger with this ID, the subledger is created automatically.") + + public String getSubledgerId() { + return subledgerId; + } + + + public void setSubledgerId(String subledgerId) { + this.subledgerId = subledgerId; + } + + + public AddLoyaltyPointsSupport applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * ID of the Application that is connected to the loyalty program. It is displayed in your Talon.One deployment URL. + * @return applicationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "322", value = "ID of the Application that is connected to the loyalty program. It is displayed in your Talon.One deployment URL.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public AddLoyaltyPointsSupport supportRequestId(Long supportRequestId) { + + this.supportRequestId = supportRequestId; + return this; + } + + /** + * ID of the support request to approve. When provided by an admin, the points are added on behalf of the support user who created the request. + * @return supportRequestId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "ID of the support request to approve. When provided by an admin, the points are added on behalf of the support user who created the request.") + + public Long getSupportRequestId() { + return supportRequestId; + } + + + public void setSupportRequestId(Long supportRequestId) { + this.supportRequestId = supportRequestId; + } + + + public AddLoyaltyPointsSupport processingNote(String processingNote) { + + this.processingNote = processingNote; + return this; + } + + /** + * Note from the admin approving the support request. Stored as the processing note on the support request record. This is only used when a supportRequestId is passed. + * @return processingNote + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Approved after manual review.", value = "Note from the admin approving the support request. Stored as the processing note on the support request record. This is only used when a supportRequestId is passed.") + + public String getProcessingNote() { + return processingNote; + } + + + public void setProcessingNote(String processingNote) { + this.processingNote = processingNote; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AddLoyaltyPointsSupport addLoyaltyPointsSupport = (AddLoyaltyPointsSupport) o; + return Objects.equals(this.points, addLoyaltyPointsSupport.points) && + Objects.equals(this.name, addLoyaltyPointsSupport.name) && + Objects.equals(this.validityDuration, addLoyaltyPointsSupport.validityDuration) && + Objects.equals(this.validUntil, addLoyaltyPointsSupport.validUntil) && + Objects.equals(this.pendingDuration, addLoyaltyPointsSupport.pendingDuration) && + Objects.equals(this.pendingUntil, addLoyaltyPointsSupport.pendingUntil) && + Objects.equals(this.subledgerId, addLoyaltyPointsSupport.subledgerId) && + Objects.equals(this.applicationId, addLoyaltyPointsSupport.applicationId) && + Objects.equals(this.supportRequestId, addLoyaltyPointsSupport.supportRequestId) && + Objects.equals(this.processingNote, addLoyaltyPointsSupport.processingNote); + } + + @Override + public int hashCode() { + return Objects.hash(points, name, validityDuration, validUntil, pendingDuration, pendingUntil, subledgerId, applicationId, supportRequestId, processingNote); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AddLoyaltyPointsSupport {\n"); + sb.append(" points: ").append(toIndentedString(points)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" validityDuration: ").append(toIndentedString(validityDuration)).append("\n"); + sb.append(" validUntil: ").append(toIndentedString(validUntil)).append("\n"); + sb.append(" pendingDuration: ").append(toIndentedString(pendingDuration)).append("\n"); + sb.append(" pendingUntil: ").append(toIndentedString(pendingUntil)).append("\n"); + sb.append(" subledgerId: ").append(toIndentedString(subledgerId)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" supportRequestId: ").append(toIndentedString(supportRequestId)).append("\n"); + sb.append(" processingNote: ").append(toIndentedString(processingNote)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AddToAudienceEffectProps.java b/src/main/java/one/talon/model/AddToAudienceEffectProps.java index d31c6b50..b9c17596 100644 --- a/src/main/java/one/talon/model/AddToAudienceEffectProps.java +++ b/src/main/java/one/talon/model/AddToAudienceEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"addToAudience\" effect. This gets triggered whenever a validated rule contains an \"addToAudience\" effect. + * This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Add customer to an audience** selected is validated. It indicates that a customer was added to an audience and is returned when a customer session is opened, updated, or closed. */ -@ApiModel(description = "The properties specific to the \"addToAudience\" effect. This gets triggered whenever a validated rule contains an \"addToAudience\" effect.") +@ApiModel(description = "This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Add customer to an audience** selected is validated. It indicates that a customer was added to an audience and is returned when a customer session is opened, updated, or closed.") public class AddToAudienceEffectProps { public static final String SERIALIZED_NAME_AUDIENCE_ID = "audienceId"; diff --git a/src/main/java/one/talon/model/AdditionalCampaignProperties.java b/src/main/java/one/talon/model/AdditionalCampaignProperties.java index f00dd708..8e96b776 100644 --- a/src/main/java/one/talon/model/AdditionalCampaignProperties.java +++ b/src/main/java/one/talon/model/AdditionalCampaignProperties.java @@ -600,7 +600,7 @@ public AdditionalCampaignProperties updated(OffsetDateTime updated) { * @return updated **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. ") + @ApiModelProperty(example = "2022-10-27T15:00Z", value = "Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. ") public OffsetDateTime getUpdated() { return updated; diff --git a/src/main/java/one/talon/model/AdditionalCostReference.java b/src/main/java/one/talon/model/AdditionalCostReference.java new file mode 100644 index 00000000..3dcc531b --- /dev/null +++ b/src/main/java/one/talon/model/AdditionalCostReference.java @@ -0,0 +1,156 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Identifies an additional cost referenced from a rule. + */ +@ApiModel(description = "Identifies an additional cost referenced from a rule.") + +public class AdditionalCostReference { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + + public AdditionalCostReference id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal identifier of the additional cost. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The internal identifier of the additional cost.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public AdditionalCostReference name(String name) { + + this.name = name; + return this; + } + + /** + * The additional cost name as used in API requests. + * @return name + **/ + @ApiModelProperty(example = "shipping", required = true, value = "The additional cost name as used in API requests.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AdditionalCostReference title(String title) { + + this.title = title; + return this; + } + + /** + * The human-readable title of the additional cost. + * @return title + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Shipping", value = "The human-readable title of the additional cost.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AdditionalCostReference additionalCostReference = (AdditionalCostReference) o; + return Objects.equals(this.id, additionalCostReference.id) && + Objects.equals(this.name, additionalCostReference.name) && + Objects.equals(this.title, additionalCostReference.title); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AdditionalCostReference {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Application.java b/src/main/java/one/talon/model/Application.java index 298b12b0..4155c7b1 100644 --- a/src/main/java/one/talon/model/Application.java +++ b/src/main/java/one/talon/model/Application.java @@ -26,6 +26,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; import one.talon.model.LoyaltyProgram; import org.threeten.bp.OffsetDateTime; @@ -266,6 +267,10 @@ public DefaultDiscountAdditionalCostPerItemScopeEnum read(final JsonReader jsonR @SerializedName(SERIALIZED_NAME_ENABLE_CAMPAIGN_STATE_MANAGEMENT) private Boolean enableCampaignStateManagement; + public static final String SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS = "bestPriorPriceSettings"; + @SerializedName(SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS) + private BestPriorPriceSettings bestPriorPriceSettings; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAMS = "loyaltyPrograms"; @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAMS) private List loyaltyPrograms = new ArrayList(); @@ -755,6 +760,29 @@ public void setEnableCampaignStateManagement(Boolean enableCampaignStateManageme } + public Application bestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + + this.bestPriorPriceSettings = bestPriorPriceSettings; + return this; + } + + /** + * Get bestPriorPriceSettings + * @return bestPriorPriceSettings + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public BestPriorPriceSettings getBestPriorPriceSettings() { + return bestPriorPriceSettings; + } + + + public void setBestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + this.bestPriorPriceSettings = bestPriorPriceSettings; + } + + public Application loyaltyPrograms(List loyaltyPrograms) { this.loyaltyPrograms = loyaltyPrograms; @@ -812,12 +840,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.defaultEvaluationGroupId, application.defaultEvaluationGroupId) && Objects.equals(this.defaultCartItemFilterId, application.defaultCartItemFilterId) && Objects.equals(this.enableCampaignStateManagement, application.enableCampaignStateManagement) && + Objects.equals(this.bestPriorPriceSettings, application.bestPriorPriceSettings) && Objects.equals(this.loyaltyPrograms, application.loyaltyPrograms); } @Override public int hashCode() { - return Objects.hash(id, created, modified, accountId, name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, defaultEvaluationGroupId, defaultCartItemFilterId, enableCampaignStateManagement, loyaltyPrograms); + return Objects.hash(id, created, modified, accountId, name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, defaultEvaluationGroupId, defaultCartItemFilterId, enableCampaignStateManagement, bestPriorPriceSettings, loyaltyPrograms); } @@ -846,6 +875,7 @@ public String toString() { sb.append(" defaultEvaluationGroupId: ").append(toIndentedString(defaultEvaluationGroupId)).append("\n"); sb.append(" defaultCartItemFilterId: ").append(toIndentedString(defaultCartItemFilterId)).append("\n"); sb.append(" enableCampaignStateManagement: ").append(toIndentedString(enableCampaignStateManagement)).append("\n"); + sb.append(" bestPriorPriceSettings: ").append(toIndentedString(bestPriorPriceSettings)).append("\n"); sb.append(" loyaltyPrograms: ").append(toIndentedString(loyaltyPrograms)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/ApplicationCIFExpression.java b/src/main/java/one/talon/model/ApplicationCIFExpression.java index 5d823994..2a43ae9a 100644 --- a/src/main/java/one/talon/model/ApplicationCIFExpression.java +++ b/src/main/java/one/talon/model/ApplicationCIFExpression.java @@ -166,7 +166,7 @@ public ApplicationCIFExpression addExpressionItem(Object expressionItem) { * @return expression **/ @javax.annotation.Nullable - @ApiModelProperty(example = "{expr=[filter, [., Session, CartItems], [[Item], [catch, false, [=, [., Item, Category], Kitchen]]]]}", value = "Arbitrary additional JSON data associated with the Application cart item filter.") + @ApiModelProperty(example = "{expr=[filter, [., Session, CartItems], [[Item], [catch, false, [contains, [., Item, Category], Kitchen]]]]}", value = "Arbitrary additional JSON data associated with the Application cart item filter.") public List getExpression() { return expression; diff --git a/src/main/java/one/talon/model/ApplicationEvent.java b/src/main/java/one/talon/model/ApplicationEvent.java index c860a349..84cc9c62 100644 --- a/src/main/java/one/talon/model/ApplicationEvent.java +++ b/src/main/java/one/talon/model/ApplicationEvent.java @@ -58,6 +58,10 @@ public class ApplicationEvent { @SerializedName(SERIALIZED_NAME_STORE_INTEGRATION_ID) private String storeIntegrationId; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + public static final String SERIALIZED_NAME_SESSION_ID = "sessionId"; @SerializedName(SERIALIZED_NAME_SESSION_ID) private Long sessionId; @@ -214,6 +218,29 @@ public void setStoreIntegrationId(String storeIntegrationId) { } + public ApplicationEvent integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + public ApplicationEvent sessionId(Long sessionId) { this.sessionId = sessionId; @@ -244,10 +271,10 @@ public ApplicationEvent type(String type) { } /** - * A string representing the event. Must not be a reserved event name. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(required = true, value = "A string representing the event. Must not be a reserved event name.") + @ApiModelProperty(required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; @@ -354,6 +381,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.profileId, applicationEvent.profileId) && Objects.equals(this.storeId, applicationEvent.storeId) && Objects.equals(this.storeIntegrationId, applicationEvent.storeIntegrationId) && + Objects.equals(this.integrationId, applicationEvent.integrationId) && Objects.equals(this.sessionId, applicationEvent.sessionId) && Objects.equals(this.type, applicationEvent.type) && Objects.equals(this.attributes, applicationEvent.attributes) && @@ -363,7 +391,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(id, created, applicationId, profileId, storeId, storeIntegrationId, sessionId, type, attributes, effects, ruleFailureReasons); + return Objects.hash(id, created, applicationId, profileId, storeId, storeIntegrationId, integrationId, sessionId, type, attributes, effects, ruleFailureReasons); } @@ -377,6 +405,7 @@ public String toString() { sb.append(" profileId: ").append(toIndentedString(profileId)).append("\n"); sb.append(" storeId: ").append(toIndentedString(storeId)).append("\n"); sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" sessionId: ").append(toIndentedString(sessionId)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); diff --git a/src/main/java/one/talon/model/ApplicationMembership.java b/src/main/java/one/talon/model/ApplicationMembership.java new file mode 100644 index 00000000..7a9bf7f6 --- /dev/null +++ b/src/main/java/one/talon/model/ApplicationMembership.java @@ -0,0 +1,126 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * ApplicationMembership + */ + +public class ApplicationMembership { + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_APPLICATION_NAME = "applicationName"; + @SerializedName(SERIALIZED_NAME_APPLICATION_NAME) + private String applicationName; + + + public ApplicationMembership applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application the customer belongs to. + * @return applicationId + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the Application the customer belongs to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public ApplicationMembership applicationName(String applicationName) { + + this.applicationName = applicationName; + return this; + } + + /** + * The name of the Application the customer belongs to. + * @return applicationName + **/ + @ApiModelProperty(example = "My Application", required = true, value = "The name of the Application the customer belongs to.") + + public String getApplicationName() { + return applicationName; + } + + + public void setApplicationName(String applicationName) { + this.applicationName = applicationName; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ApplicationMembership applicationMembership = (ApplicationMembership) o; + return Objects.equals(this.applicationId, applicationMembership.applicationId) && + Objects.equals(this.applicationName, applicationMembership.applicationName); + } + + @Override + public int hashCode() { + return Objects.hash(applicationId, applicationName); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ApplicationMembership {\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" applicationName: ").append(toIndentedString(applicationName)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ApplicationReferee.java b/src/main/java/one/talon/model/ApplicationReferee.java index 9c923d9b..f25b1d58 100644 --- a/src/main/java/one/talon/model/ApplicationReferee.java +++ b/src/main/java/one/talon/model/ApplicationReferee.java @@ -38,6 +38,10 @@ public class ApplicationReferee { @SerializedName(SERIALIZED_NAME_SESSION_ID) private String sessionId; + public static final String SERIALIZED_NAME_ADVANCED_EVENT_INTEGRATION_ID = "advancedEventIntegrationId"; + @SerializedName(SERIALIZED_NAME_ADVANCED_EVENT_INTEGRATION_ID) + private String advancedEventIntegrationId; + public static final String SERIALIZED_NAME_ADVOCATE_INTEGRATION_ID = "advocateIntegrationId"; @SerializedName(SERIALIZED_NAME_ADVOCATE_INTEGRATION_ID) private String advocateIntegrationId; @@ -99,6 +103,29 @@ public void setSessionId(String sessionId) { } + public ApplicationReferee advancedEventIntegrationId(String advancedEventIntegrationId) { + + this.advancedEventIntegrationId = advancedEventIntegrationId; + return this; + } + + /** + * The unique ID of the advanced event in which the customer redeemed the referral. Omitted when the referral was redeemed through a customer session rather than an advanced event. + * @return advancedEventIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "advanced_event_1234", value = "The unique ID of the advanced event in which the customer redeemed the referral. Omitted when the referral was redeemed through a customer session rather than an advanced event.") + + public String getAdvancedEventIntegrationId() { + return advancedEventIntegrationId; + } + + + public void setAdvancedEventIntegrationId(String advancedEventIntegrationId) { + this.advancedEventIntegrationId = advancedEventIntegrationId; + } + + public ApplicationReferee advocateIntegrationId(String advocateIntegrationId) { this.advocateIntegrationId = advocateIntegrationId; @@ -198,6 +225,7 @@ public boolean equals(java.lang.Object o) { ApplicationReferee applicationReferee = (ApplicationReferee) o; return Objects.equals(this.applicationId, applicationReferee.applicationId) && Objects.equals(this.sessionId, applicationReferee.sessionId) && + Objects.equals(this.advancedEventIntegrationId, applicationReferee.advancedEventIntegrationId) && Objects.equals(this.advocateIntegrationId, applicationReferee.advocateIntegrationId) && Objects.equals(this.friendIntegrationId, applicationReferee.friendIntegrationId) && Objects.equals(this.code, applicationReferee.code) && @@ -206,7 +234,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(applicationId, sessionId, advocateIntegrationId, friendIntegrationId, code, created); + return Objects.hash(applicationId, sessionId, advancedEventIntegrationId, advocateIntegrationId, friendIntegrationId, code, created); } @@ -216,6 +244,7 @@ public String toString() { sb.append("class ApplicationReferee {\n"); sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); sb.append(" sessionId: ").append(toIndentedString(sessionId)).append("\n"); + sb.append(" advancedEventIntegrationId: ").append(toIndentedString(advancedEventIntegrationId)).append("\n"); sb.append(" advocateIntegrationId: ").append(toIndentedString(advocateIntegrationId)).append("\n"); sb.append(" friendIntegrationId: ").append(toIndentedString(friendIntegrationId)).append("\n"); sb.append(" code: ").append(toIndentedString(code)).append("\n"); diff --git a/src/main/java/one/talon/model/ApplicationSession.java b/src/main/java/one/talon/model/ApplicationSession.java index 05695f4e..196a263f 100644 --- a/src/main/java/one/talon/model/ApplicationSession.java +++ b/src/main/java/one/talon/model/ApplicationSession.java @@ -73,7 +73,7 @@ public class ApplicationSession { private String referral; /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). */ @JsonAdapter(StateEnum.Adapter.class) public enum StateEnum { @@ -356,10 +356,10 @@ public ApplicationSession state(StateEnum state) { } /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). * @return state **/ - @ApiModelProperty(example = "closed", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") + @ApiModelProperty(example = "closed", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") public StateEnum getState() { return state; diff --git a/src/main/java/one/talon/model/Audience.java b/src/main/java/one/talon/model/Audience.java index 8da12ac5..8602168a 100644 --- a/src/main/java/one/talon/model/Audience.java +++ b/src/main/java/one/talon/model/Audience.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; /** @@ -54,6 +56,10 @@ public class Audience { @SerializedName(SERIALIZED_NAME_DESCRIPTION) private String description; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public static final String SERIALIZED_NAME_INTEGRATION = "integration"; @SerializedName(SERIALIZED_NAME_INTEGRATION) private String integration; @@ -205,6 +211,37 @@ public void setDescription(String description) { } + public Audience subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public Audience addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + public Audience integration(String integration) { this.integration = integration; @@ -312,6 +349,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.name, audience.name) && Objects.equals(this.sandbox, audience.sandbox) && Objects.equals(this.description, audience.description) && + Objects.equals(this.subscribedApplicationsIds, audience.subscribedApplicationsIds) && Objects.equals(this.integration, audience.integration) && Objects.equals(this.integrationId, audience.integrationId) && Objects.equals(this.createdIn3rdParty, audience.createdIn3rdParty) && @@ -320,7 +358,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(accountId, id, created, name, sandbox, description, integration, integrationId, createdIn3rdParty, lastUpdate); + return Objects.hash(accountId, id, created, name, sandbox, description, subscribedApplicationsIds, integration, integrationId, createdIn3rdParty, lastUpdate); } @@ -334,6 +372,7 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append(" integration: ").append(toIndentedString(integration)).append("\n"); sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" createdIn3rdParty: ").append(toIndentedString(createdIn3rdParty)).append("\n"); diff --git a/src/main/java/one/talon/model/AwardDiscountAdditionalCostTarget.java b/src/main/java/one/talon/model/AwardDiscountAdditionalCostTarget.java new file mode 100644 index 00000000..faca5375 --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountAdditionalCostTarget.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AdditionalCostReference; + +/** + * Applies the discount to an additional cost. The `target` field determines which subset of cart items the additional cost contribution is applied to. + */ +@ApiModel(description = "Applies the discount to an additional cost. The `target` field determines which subset of cart items the additional cost contribution is applied to.") + +public class AwardDiscountAdditionalCostTarget { + /** + * A target discriminator of type `additionalCost`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + ADDITIONALCOST("additionalCost"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_ADDITIONAL_COST = "additionalCost"; + @SerializedName(SERIALIZED_NAME_ADDITIONAL_COST) + private AdditionalCostReference additionalCost; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private Object target; + + + public AwardDiscountAdditionalCostTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `additionalCost`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `additionalCost`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountAdditionalCostTarget additionalCost(AdditionalCostReference additionalCost) { + + this.additionalCost = additionalCost; + return this; + } + + /** + * Get additionalCost + * @return additionalCost + **/ + @ApiModelProperty(required = true, value = "") + + public AdditionalCostReference getAdditionalCost() { + return additionalCost; + } + + + public void setAdditionalCost(AdditionalCostReference additionalCost) { + this.additionalCost = additionalCost; + } + + + public AwardDiscountAdditionalCostTarget target(Object target) { + + this.target = target; + return this; + } + + /** + * A subset of cart items whose additional cost the discount applies to. Cannot be another `additionalCost` target. + * @return target + **/ + @ApiModelProperty(required = true, value = "A subset of cart items whose additional cost the discount applies to. Cannot be another `additionalCost` target.") + + public Object getTarget() { + return target; + } + + + public void setTarget(Object target) { + this.target = target; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountAdditionalCostTarget awardDiscountAdditionalCostTarget = (AwardDiscountAdditionalCostTarget) o; + return Objects.equals(this.type, awardDiscountAdditionalCostTarget.type) && + Objects.equals(this.additionalCost, awardDiscountAdditionalCostTarget.additionalCost) && + Objects.equals(this.target, awardDiscountAdditionalCostTarget.target); + } + + @Override + public int hashCode() { + return Objects.hash(type, additionalCost, target); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountAdditionalCostTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" additionalCost: ").append(toIndentedString(additionalCost)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountAllItemsTarget.java b/src/main/java/one/talon/model/AwardDiscountAllItemsTarget.java new file mode 100644 index 00000000..daa7c8cd --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountAllItemsTarget.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Applies the discount across all cart items. + */ +@ApiModel(description = "Applies the discount across all cart items.") + +public class AwardDiscountAllItemsTarget { + /** + * A target discriminator of type `allItems`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + ALLITEMS("allItems"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PRORATED = "prorated"; + @SerializedName(SERIALIZED_NAME_PRORATED) + private Boolean prorated; + + + public AwardDiscountAllItemsTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `allItems`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `allItems`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountAllItemsTarget prorated(Boolean prorated) { + + this.prorated = prorated; + return this; + } + + /** + * Whether to distribute the discount proportionally across the targeted items. + * @return prorated + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "Whether to distribute the discount proportionally across the targeted items.") + + public Boolean getProrated() { + return prorated; + } + + + public void setProrated(Boolean prorated) { + this.prorated = prorated; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountAllItemsTarget awardDiscountAllItemsTarget = (AwardDiscountAllItemsTarget) o; + return Objects.equals(this.type, awardDiscountAllItemsTarget.type) && + Objects.equals(this.prorated, awardDiscountAllItemsTarget.prorated); + } + + @Override + public int hashCode() { + return Objects.hash(type, prorated); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountAllItemsTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" prorated: ").append(toIndentedString(prorated)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountBlock.java b/src/main/java/one/talon/model/AwardDiscountBlock.java new file mode 100644 index 00000000..41d42d5b --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountBlock.java @@ -0,0 +1,253 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that grants a discount when its rule conditions evaluate to `true`. The `target` field determines what the discount applies to (the whole cart, a subset of items, a bundle, an additional cost, etc.); the `value` field is the discount amount. + */ +@ApiModel(description = "A block that grants a discount when its rule conditions evaluate to `true`. The `target` field determines what the discount applies to (the whole cart, a subset of items, a bundle, an additional cost, etc.); the `value` field is the discount amount.") + +public class AwardDiscountBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_PARTIAL = "partial"; + @SerializedName(SERIALIZED_NAME_PARTIAL) + private Boolean partial; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private Object target; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public AwardDiscountBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public AwardDiscountBlock name(String name) { + + this.name = name; + return this; + } + + /** + * The human-readable label attached to the discount. + * @return name + **/ + @ApiModelProperty(example = "10% Off", required = true, value = "The human-readable label attached to the discount.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AwardDiscountBlock value(Object value) { + + this.value = value; + return this; + } + + /** + * Discount amount. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return value + **/ + @ApiModelProperty(required = true, value = "Discount amount. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public AwardDiscountBlock partial(Boolean partial) { + + this.partial = partial; + return this; + } + + /** + * Whether to apply a partial discount when the requested value exceeds the configured budget. + * @return partial + **/ + @ApiModelProperty(example = "false", required = true, value = "Whether to apply a partial discount when the requested value exceeds the configured budget.") + + public Boolean getPartial() { + return partial; + } + + + public void setPartial(Boolean partial) { + this.partial = partial; + } + + + public AwardDiscountBlock target(Object target) { + + this.target = target; + return this; + } + + /** + * Identifies the scope a discount applies to. The `type` field selects the concrete target variant. + * @return target + **/ + @ApiModelProperty(required = true, value = "Identifies the scope a discount applies to. The `type` field selects the concrete target variant.") + + public Object getTarget() { + return target; + } + + + public void setTarget(Object target) { + this.target = target; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountBlock awardDiscountBlock = (AwardDiscountBlock) o; + return Objects.equals(this.id, awardDiscountBlock.id) && + Objects.equals(this.type, awardDiscountBlock.type) && + Objects.equals(this.tags, awardDiscountBlock.tags) && + Objects.equals(this.name, awardDiscountBlock.name) && + Objects.equals(this.value, awardDiscountBlock.value) && + Objects.equals(this.partial, awardDiscountBlock.partial) && + Objects.equals(this.target, awardDiscountBlock.target); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, name, value, partial, target); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" partial: ").append(toIndentedString(partial)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountBundleItemByAttribute.java b/src/main/java/one/talon/model/AwardDiscountBundleItemByAttribute.java new file mode 100644 index 00000000..67bc9aaa --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountBundleItemByAttribute.java @@ -0,0 +1,247 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Identifies a bundle slot by ranking items by a per-item attribute expression and picking the highest- or lowest-ranked one. + */ +@ApiModel(description = "Identifies a bundle slot by ranking items by a per-item attribute expression and picking the highest- or lowest-ranked one.") + +public class AwardDiscountBundleItemByAttribute { + /** + * A bundle-item selector of type `byAttribute`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + BYATTRIBUTE("byAttribute"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTE) + private String attribute; + + /** + * Ranking direction. `highest` picks the item with the largest attribute value, `lowest` the smallest. + */ + @JsonAdapter(DirectionEnum.Adapter.class) + public enum DirectionEnum { + HIGHEST("highest"), + + LOWEST("lowest"); + + private String value; + + DirectionEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static DirectionEnum fromValue(String value) { + for (DirectionEnum b : DirectionEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final DirectionEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public DirectionEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return DirectionEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_DIRECTION = "direction"; + @SerializedName(SERIALIZED_NAME_DIRECTION) + private DirectionEnum direction; + + + public AwardDiscountBundleItemByAttribute type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A bundle-item selector of type `byAttribute`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A bundle-item selector of type `byAttribute`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountBundleItemByAttribute attribute(String attribute) { + + this.attribute = attribute; + return this; + } + + /** + * A per-item attribute expression used to rank bundle items. + * @return attribute + **/ + @ApiModelProperty(example = "{{$Item.Price}}", required = true, value = "A per-item attribute expression used to rank bundle items.") + + public String getAttribute() { + return attribute; + } + + + public void setAttribute(String attribute) { + this.attribute = attribute; + } + + + public AwardDiscountBundleItemByAttribute direction(DirectionEnum direction) { + + this.direction = direction; + return this; + } + + /** + * Ranking direction. `highest` picks the item with the largest attribute value, `lowest` the smallest. + * @return direction + **/ + @ApiModelProperty(example = "highest", required = true, value = "Ranking direction. `highest` picks the item with the largest attribute value, `lowest` the smallest.") + + public DirectionEnum getDirection() { + return direction; + } + + + public void setDirection(DirectionEnum direction) { + this.direction = direction; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountBundleItemByAttribute awardDiscountBundleItemByAttribute = (AwardDiscountBundleItemByAttribute) o; + return Objects.equals(this.type, awardDiscountBundleItemByAttribute.type) && + Objects.equals(this.attribute, awardDiscountBundleItemByAttribute.attribute) && + Objects.equals(this.direction, awardDiscountBundleItemByAttribute.direction); + } + + @Override + public int hashCode() { + return Objects.hash(type, attribute, direction); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountBundleItemByAttribute {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); + sb.append(" direction: ").append(toIndentedString(direction)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountBundleItemByIndex.java b/src/main/java/one/talon/model/AwardDiscountBundleItemByIndex.java new file mode 100644 index 00000000..b90f1339 --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountBundleItemByIndex.java @@ -0,0 +1,172 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Identifies a bundle slot by its zero-based index within the bundle. + */ +@ApiModel(description = "Identifies a bundle slot by its zero-based index within the bundle.") + +public class AwardDiscountBundleItemByIndex { + /** + * A bundle-item selector of type `byIndex`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + BYINDEX("byIndex"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Long value; + + + public AwardDiscountBundleItemByIndex type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A bundle-item selector of type `byIndex`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A bundle-item selector of type `byIndex`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountBundleItemByIndex value(Long value) { + + this.value = value; + return this; + } + + /** + * The zero-based index of the slot within the bundle. + * @return value + **/ + @ApiModelProperty(example = "0", required = true, value = "The zero-based index of the slot within the bundle.") + + public Long getValue() { + return value; + } + + + public void setValue(Long value) { + this.value = value; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountBundleItemByIndex awardDiscountBundleItemByIndex = (AwardDiscountBundleItemByIndex) o; + return Objects.equals(this.type, awardDiscountBundleItemByIndex.type) && + Objects.equals(this.value, awardDiscountBundleItemByIndex.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountBundleItemByIndex {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountBundleTarget.java b/src/main/java/one/talon/model/AwardDiscountBundleTarget.java new file mode 100644 index 00000000..cd41a45e --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountBundleTarget.java @@ -0,0 +1,230 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Applies the discount to items belonging to a named bundle. + */ +@ApiModel(description = "Applies the discount to items belonging to a named bundle.") + +public class AwardDiscountBundleTarget { + /** + * A target discriminator of type `bundle`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + BUNDLE("bundle"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_ITEM = "item"; + @SerializedName(SERIALIZED_NAME_ITEM) + private Object item; + + public static final String SERIALIZED_NAME_PRORATED = "prorated"; + @SerializedName(SERIALIZED_NAME_PRORATED) + private Boolean prorated; + + + public AwardDiscountBundleTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `bundle`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `bundle`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountBundleTarget name(String name) { + + this.name = name; + return this; + } + + /** + * Name of the bundle binding the discount targets. + * @return name + **/ + @ApiModelProperty(example = "BogoBundle", required = true, value = "Name of the bundle binding the discount targets.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AwardDiscountBundleTarget item(Object item) { + + this.item = item; + return this; + } + + /** + * Selects which slot inside a bundle a discount applies to. The `type` field picks the selection mode. + * @return item + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Selects which slot inside a bundle a discount applies to. The `type` field picks the selection mode.") + + public Object getItem() { + return item; + } + + + public void setItem(Object item) { + this.item = item; + } + + + public AwardDiscountBundleTarget prorated(Boolean prorated) { + + this.prorated = prorated; + return this; + } + + /** + * Whether to distribute the discount proportionally across the bundle's items. + * @return prorated + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Whether to distribute the discount proportionally across the bundle's items.") + + public Boolean getProrated() { + return prorated; + } + + + public void setProrated(Boolean prorated) { + this.prorated = prorated; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountBundleTarget awardDiscountBundleTarget = (AwardDiscountBundleTarget) o; + return Objects.equals(this.type, awardDiscountBundleTarget.type) && + Objects.equals(this.name, awardDiscountBundleTarget.name) && + Objects.equals(this.item, awardDiscountBundleTarget.item) && + Objects.equals(this.prorated, awardDiscountBundleTarget.prorated); + } + + @Override + public int hashCode() { + return Objects.hash(type, name, item, prorated); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountBundleTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" item: ").append(toIndentedString(item)).append("\n"); + sb.append(" prorated: ").append(toIndentedString(prorated)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountCartTarget.java b/src/main/java/one/talon/model/AwardDiscountCartTarget.java new file mode 100644 index 00000000..0ca0b19f --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountCartTarget.java @@ -0,0 +1,144 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Applies the discount to the entire cart as a single unit. + */ +@ApiModel(description = "Applies the discount to the entire cart as a single unit.") + +public class AwardDiscountCartTarget { + /** + * A target discriminator of type `cart`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + CART("cart"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + + public AwardDiscountCartTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `cart`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `cart`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountCartTarget awardDiscountCartTarget = (AwardDiscountCartTarget) o; + return Objects.equals(this.type, awardDiscountCartTarget.type); + } + + @Override + public int hashCode() { + return Objects.hash(type); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountCartTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountGlobalFilterTarget.java b/src/main/java/one/talon/model/AwardDiscountGlobalFilterTarget.java new file mode 100644 index 00000000..020b3532 --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountGlobalFilterTarget.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Applies the discount to items matched by a named Application-level cart-item filter. + */ +@ApiModel(description = "Applies the discount to items matched by a named Application-level cart-item filter.") + +public class AwardDiscountGlobalFilterTarget { + /** + * A target discriminator of type `globalFilter`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + GLOBALFILTER("globalFilter"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_PRORATED = "prorated"; + @SerializedName(SERIALIZED_NAME_PRORATED) + private Boolean prorated; + + + public AwardDiscountGlobalFilterTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `globalFilter`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `globalFilter`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountGlobalFilterTarget name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the Application-level cart-item filter the discount targets. + * @return name + **/ + @ApiModelProperty(example = "PremiumItems", required = true, value = "The name of the Application-level cart-item filter the discount targets.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AwardDiscountGlobalFilterTarget prorated(Boolean prorated) { + + this.prorated = prorated; + return this; + } + + /** + * Whether to distribute the discount proportionally across the matched items. + * @return prorated + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Whether to distribute the discount proportionally across the matched items.") + + public Boolean getProrated() { + return prorated; + } + + + public void setProrated(Boolean prorated) { + this.prorated = prorated; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountGlobalFilterTarget awardDiscountGlobalFilterTarget = (AwardDiscountGlobalFilterTarget) o; + return Objects.equals(this.type, awardDiscountGlobalFilterTarget.type) && + Objects.equals(this.name, awardDiscountGlobalFilterTarget.name) && + Objects.equals(this.prorated, awardDiscountGlobalFilterTarget.prorated); + } + + @Override + public int hashCode() { + return Objects.hash(type, name, prorated); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountGlobalFilterTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" prorated: ").append(toIndentedString(prorated)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardDiscountSelectorTarget.java b/src/main/java/one/talon/model/AwardDiscountSelectorTarget.java new file mode 100644 index 00000000..7f4c94f8 --- /dev/null +++ b/src/main/java/one/talon/model/AwardDiscountSelectorTarget.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Applies the discount to items matched by a named selector binding. + */ +@ApiModel(description = "Applies the discount to items matched by a named selector binding.") + +public class AwardDiscountSelectorTarget { + /** + * A target discriminator of type `selector`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + SELECTOR("selector"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_PRORATED = "prorated"; + @SerializedName(SERIALIZED_NAME_PRORATED) + private Boolean prorated; + + + public AwardDiscountSelectorTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A target discriminator of type `selector`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A target discriminator of type `selector`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public AwardDiscountSelectorTarget name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the selector binding the discount targets. + * @return name + **/ + @ApiModelProperty(example = "ElectronicsItems", required = true, value = "The name of the selector binding the discount targets.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AwardDiscountSelectorTarget prorated(Boolean prorated) { + + this.prorated = prorated; + return this; + } + + /** + * Whether to distribute the discount proportionally across the selected items. + * @return prorated + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Whether to distribute the discount proportionally across the selected items.") + + public Boolean getProrated() { + return prorated; + } + + + public void setProrated(Boolean prorated) { + this.prorated = prorated; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardDiscountSelectorTarget awardDiscountSelectorTarget = (AwardDiscountSelectorTarget) o; + return Objects.equals(this.type, awardDiscountSelectorTarget.type) && + Objects.equals(this.name, awardDiscountSelectorTarget.name) && + Objects.equals(this.prorated, awardDiscountSelectorTarget.prorated); + } + + @Override + public int hashCode() { + return Objects.hash(type, name, prorated); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardDiscountSelectorTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" prorated: ").append(toIndentedString(prorated)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardGiveawayBlock.java b/src/main/java/one/talon/model/AwardGiveawayBlock.java new file mode 100644 index 00000000..22f9ccb9 --- /dev/null +++ b/src/main/java/one/talon/model/AwardGiveawayBlock.java @@ -0,0 +1,321 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.GiveawayPoolReference; + +/** + * A block that awards a giveaway item from a configured giveaway pool to the specified customer profile. + */ +@ApiModel(description = "A block that awards a giveaway item from a configured giveaway pool to the specified customer profile.") + +public class AwardGiveawayBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_GIVEAWAY_POOL = "giveawayPool"; + @SerializedName(SERIALIZED_NAME_GIVEAWAY_POOL) + private GiveawayPoolReference giveawayPool; + + /** + * The customer profile to award the giveaway to. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + */ + @JsonAdapter(ProfileEnum.Adapter.class) + public enum ProfileEnum { + CURRENT("Current"), + + ADVOCATE("Advocate"); + + private String value; + + ProfileEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ProfileEnum fromValue(String value) { + for (ProfileEnum b : ProfileEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ProfileEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ProfileEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ProfileEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_PROFILE = "profile"; + @SerializedName(SERIALIZED_NAME_PROFILE) + private ProfileEnum profile; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public AwardGiveawayBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public AwardGiveawayBlock giveawayPool(GiveawayPoolReference giveawayPool) { + + this.giveawayPool = giveawayPool; + return this; + } + + /** + * Get giveawayPool + * @return giveawayPool + **/ + @ApiModelProperty(required = true, value = "") + + public GiveawayPoolReference getGiveawayPool() { + return giveawayPool; + } + + + public void setGiveawayPool(GiveawayPoolReference giveawayPool) { + this.giveawayPool = giveawayPool; + } + + + public AwardGiveawayBlock profile(ProfileEnum profile) { + + this.profile = profile; + return this; + } + + /** + * The customer profile to award the giveaway to. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + * @return profile + **/ + @ApiModelProperty(example = "Current", required = true, value = "The customer profile to award the giveaway to. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program.") + + public ProfileEnum getProfile() { + return profile; + } + + + public void setProfile(ProfileEnum profile) { + this.profile = profile; + } + + + public AwardGiveawayBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public AwardGiveawayBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + public AwardGiveawayBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public AwardGiveawayBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardGiveawayBlock awardGiveawayBlock = (AwardGiveawayBlock) o; + return Objects.equals(this.id, awardGiveawayBlock.id) && + Objects.equals(this.type, awardGiveawayBlock.type) && + Objects.equals(this.tags, awardGiveawayBlock.tags) && + Objects.equals(this.giveawayPool, awardGiveawayBlock.giveawayPool) && + Objects.equals(this.profile, awardGiveawayBlock.profile) && + Objects.equals(this.onFailure, awardGiveawayBlock.onFailure) && + Objects.equals(this.onError, awardGiveawayBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, giveawayPool, profile, onFailure, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardGiveawayBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" giveawayPool: ").append(toIndentedString(giveawayPool)).append("\n"); + sb.append(" profile: ").append(toIndentedString(profile)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AwardGiveawayEffectProps.java b/src/main/java/one/talon/model/AwardGiveawayEffectProps.java index 0b0f3765..538f0616 100644 --- a/src/main/java/one/talon/model/AwardGiveawayEffectProps.java +++ b/src/main/java/one/talon/model/AwardGiveawayEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"awardGiveaway\" effect. This effect contains information on the giveaway item, and which profile it was awarded to. + * This effect indicates the awarded giveaway item and to which profile the item was awarded. Learn more about [giveaways](https://docs.talon.one/docs/product/giveaways/overview). */ -@ApiModel(description = "The properties specific to the \"awardGiveaway\" effect. This effect contains information on the giveaway item, and which profile it was awarded to.") +@ApiModel(description = "This effect indicates the awarded giveaway item and to which profile the item was awarded. Learn more about [giveaways](https://docs.talon.one/docs/product/giveaways/overview).") public class AwardGiveawayEffectProps { public static final String SERIALIZED_NAME_POOL_ID = "poolId"; @@ -58,10 +58,10 @@ public AwardGiveawayEffectProps poolId(Long poolId) { } /** - * The ID of the giveaways pool the code was taken from. + * The internal ID of the giveaway pool. * @return poolId **/ - @ApiModelProperty(example = "2", required = true, value = "The ID of the giveaways pool the code was taken from.") + @ApiModelProperty(example = "2", required = true, value = "The internal ID of the giveaway pool.") public Long getPoolId() { return poolId; @@ -80,10 +80,10 @@ public AwardGiveawayEffectProps poolName(String poolName) { } /** - * The name of the giveaways pool the code was taken from. + * The name of the giveaway pool. * @return poolName **/ - @ApiModelProperty(example = "My pool", required = true, value = "The name of the giveaways pool the code was taken from.") + @ApiModelProperty(example = "My pool", required = true, value = "The name of the giveaway pool.") public String getPoolName() { return poolName; @@ -102,10 +102,10 @@ public AwardGiveawayEffectProps recipientIntegrationId(String recipientIntegrati } /** - * The integration ID of the profile that was awarded the giveaway. + * The integration ID of the customer that receives the giveaway. * @return recipientIntegrationId **/ - @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The integration ID of the profile that was awarded the giveaway.") + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The integration ID of the customer that receives the giveaway.") public String getRecipientIntegrationId() { return recipientIntegrationId; @@ -124,10 +124,10 @@ public AwardGiveawayEffectProps giveawayId(Long giveawayId) { } /** - * The internal ID for the giveaway that was awarded. + * The internal ID of the giveaway. * @return giveawayId **/ - @ApiModelProperty(example = "5", required = true, value = "The internal ID for the giveaway that was awarded.") + @ApiModelProperty(example = "5", required = true, value = "The internal ID of the giveaway.") public Long getGiveawayId() { return giveawayId; @@ -146,10 +146,10 @@ public AwardGiveawayEffectProps code(String code) { } /** - * The giveaway code that was awarded. + * The giveaway code to be rewarded. * @return code **/ - @ApiModelProperty(example = "57638t-67439hty", required = true, value = "The giveaway code that was awarded.") + @ApiModelProperty(example = "57638t-67439hty", required = true, value = "The giveaway code to be rewarded.") public String getCode() { return code; diff --git a/src/main/java/one/talon/model/AwardItemBlock.java b/src/main/java/one/talon/model/AwardItemBlock.java new file mode 100644 index 00000000..b99bef2d --- /dev/null +++ b/src/main/java/one/talon/model/AwardItemBlock.java @@ -0,0 +1,330 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * A block that awards a free cart item to the customer. The item is identified by SKU and name and has a configurable quantity. + */ +@ApiModel(description = "A block that awards a free cart item to the customer. The item is identified by SKU and name and has a configurable quantity.") + +public class AwardItemBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_SKU = "sku"; + @SerializedName(SERIALIZED_NAME_SKU) + private String sku; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_QUANTITY = "quantity"; + @SerializedName(SERIALIZED_NAME_QUANTITY) + private String quantity; + + public static final String SERIALIZED_NAME_PARTIAL = "partial"; + @SerializedName(SERIALIZED_NAME_PARTIAL) + private Boolean partial; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public AwardItemBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public AwardItemBlock sku(String sku) { + + this.sku = sku; + return this; + } + + /** + * The stock keeping unit of the item to award. + * @return sku + **/ + @ApiModelProperty(example = "SKU1241028", required = true, value = "The stock keeping unit of the item to award.") + + public String getSku() { + return sku; + } + + + public void setSku(String sku) { + this.sku = sku; + } + + + public AwardItemBlock name(String name) { + + this.name = name; + return this; + } + + /** + * The display name of the item to award. + * @return name + **/ + @ApiModelProperty(example = "Free Tote Bag", required = true, value = "The display name of the item to award.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public AwardItemBlock quantity(String quantity) { + + this.quantity = quantity; + return this; + } + + /** + * The number of items to award. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities. + * @return quantity + **/ + @ApiModelProperty(example = "1", required = true, value = "The number of items to award. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities.") + + public String getQuantity() { + return quantity; + } + + + public void setQuantity(String quantity) { + this.quantity = quantity; + } + + + public AwardItemBlock partial(Boolean partial) { + + this.partial = partial; + return this; + } + + /** + * When set to `true`, applies a partial item reward if the remaining budget is insufficient to award the full reward. + * @return partial + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "When set to `true`, applies a partial item reward if the remaining budget is insufficient to award the full reward.") + + public Boolean getPartial() { + return partial; + } + + + public void setPartial(Boolean partial) { + this.partial = partial; + } + + + public AwardItemBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public AwardItemBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + public AwardItemBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public AwardItemBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AwardItemBlock awardItemBlock = (AwardItemBlock) o; + return Objects.equals(this.id, awardItemBlock.id) && + Objects.equals(this.type, awardItemBlock.type) && + Objects.equals(this.tags, awardItemBlock.tags) && + Objects.equals(this.sku, awardItemBlock.sku) && + Objects.equals(this.name, awardItemBlock.name) && + Objects.equals(this.quantity, awardItemBlock.quantity) && + Objects.equals(this.partial, awardItemBlock.partial) && + Objects.equals(this.onFailure, awardItemBlock.onFailure) && + Objects.equals(this.onError, awardItemBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, sku, name, quantity, partial, onFailure, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AwardItemBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" sku: ").append(toIndentedString(sku)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" quantity: ").append(toIndentedString(quantity)).append("\n"); + sb.append(" partial: ").append(toIndentedString(partial)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/BaseBlock.java b/src/main/java/one/talon/model/BaseBlock.java new file mode 100644 index 00000000..1e7332f1 --- /dev/null +++ b/src/main/java/one/talon/model/BaseBlock.java @@ -0,0 +1,141 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * Common properties shared by all block types. + */ +@ApiModel(description = "Common properties shared by all block types.") + +public class BaseBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public BaseBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + BaseBlock baseBlock = (BaseBlock) o; + return Objects.equals(this.id, baseBlock.id) && + Objects.equals(this.type, baseBlock.type) && + Objects.equals(this.tags, baseBlock.tags); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class BaseBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/BaseCampaign.java b/src/main/java/one/talon/model/BaseCampaign.java index f3635230..193dc8b5 100644 --- a/src/main/java/one/talon/model/BaseCampaign.java +++ b/src/main/java/one/talon/model/BaseCampaign.java @@ -134,7 +134,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/BestPriorPrice.java b/src/main/java/one/talon/model/BestPriorPrice.java index 1db09975..f1292d3c 100644 --- a/src/main/java/one/talon/model/BestPriorPrice.java +++ b/src/main/java/one/talon/model/BestPriorPrice.java @@ -24,6 +24,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.BestPriorPriceMetadata; import org.threeten.bp.OffsetDateTime; @@ -44,9 +46,9 @@ public class BestPriorPrice { @SerializedName(SERIALIZED_NAME_OBSERVED_AT) private OffsetDateTime observedAt; - public static final String SERIALIZED_NAME_CONTEXT_ID = "contextId"; - @SerializedName(SERIALIZED_NAME_CONTEXT_ID) - private String contextId; + public static final String SERIALIZED_NAME_CONTEXT_IDS = "contextIds"; + @SerializedName(SERIALIZED_NAME_CONTEXT_IDS) + private List contextIds = new ArrayList(); public static final String SERIALIZED_NAME_PRICE = "price"; @SerializedName(SERIALIZED_NAME_PRICE) @@ -93,7 +95,7 @@ public BestPriorPrice sku(String sku) { * sku * @return sku **/ - @ApiModelProperty(example = "NVR-GN-GV-UUP", required = true, value = "sku") + @ApiModelProperty(example = "SKU7345278", required = true, value = "sku") public String getSku() { return sku; @@ -115,7 +117,7 @@ public BestPriorPrice observedAt(OffsetDateTime observedAt) { * The date and time when the price was observed. * @return observedAt **/ - @ApiModelProperty(example = "2020-11-10T23:00Z", required = true, value = "The date and time when the price was observed.") + @ApiModelProperty(example = "2025-11-10T23:00Z", required = true, value = "The date and time when the price was observed.") public OffsetDateTime getObservedAt() { return observedAt; @@ -127,25 +129,30 @@ public void setObservedAt(OffsetDateTime observedAt) { } - public BestPriorPrice contextId(String contextId) { + public BestPriorPrice contextIds(List contextIds) { - this.contextId = contextId; + this.contextIds = contextIds; + return this; + } + + public BestPriorPrice addContextIdsItem(String contextIdsItem) { + this.contextIds.add(contextIdsItem); return this; } /** - * The context ID of the context active at the time of observation. - * @return contextId + * The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. + * @return contextIds **/ - @ApiModelProperty(example = "Summer Sale 2025", required = true, value = "The context ID of the context active at the time of observation. ") + @ApiModelProperty(example = "[SpringSale, SummerSale2025]", required = true, value = "The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. ") - public String getContextId() { - return contextId; + public List getContextIds() { + return contextIds; } - public void setContextId(String contextId) { - this.contextId = contextId; + public void setContextIds(List contextIds) { + this.contextIds = contextIds; } @@ -227,7 +234,7 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.id, bestPriorPrice.id) && Objects.equals(this.sku, bestPriorPrice.sku) && Objects.equals(this.observedAt, bestPriorPrice.observedAt) && - Objects.equals(this.contextId, bestPriorPrice.contextId) && + Objects.equals(this.contextIds, bestPriorPrice.contextIds) && Objects.equals(this.price, bestPriorPrice.price) && Objects.equals(this.metadata, bestPriorPrice.metadata) && Objects.equals(this.target, bestPriorPrice.target); @@ -235,7 +242,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(id, sku, observedAt, contextId, price, metadata, target); + return Objects.hash(id, sku, observedAt, contextIds, price, metadata, target); } @@ -246,7 +253,7 @@ public String toString() { sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" sku: ").append(toIndentedString(sku)).append("\n"); sb.append(" observedAt: ").append(toIndentedString(observedAt)).append("\n"); - sb.append(" contextId: ").append(toIndentedString(contextId)).append("\n"); + sb.append(" contextIds: ").append(toIndentedString(contextIds)).append("\n"); sb.append(" price: ").append(toIndentedString(price)).append("\n"); sb.append(" metadata: ").append(toIndentedString(metadata)).append("\n"); sb.append(" target: ").append(toIndentedString(target)).append("\n"); diff --git a/src/main/java/one/talon/model/BestPriorPriceRequest.java b/src/main/java/one/talon/model/BestPriorPriceRequest.java index 2d14395e..e4fc5f46 100644 --- a/src/main/java/one/talon/model/BestPriorPriceRequest.java +++ b/src/main/java/one/talon/model/BestPriorPriceRequest.java @@ -118,7 +118,7 @@ public BestPriorPriceRequest addSkusItem(String skusItem) { * List of product SKUs to check when determining the best prior price. * @return skus **/ - @ApiModelProperty(example = "[comma, period]", required = true, value = "List of product SKUs to check when determining the best prior price.") + @ApiModelProperty(example = "[SKU1241028, SKU7345278]", required = true, value = "List of product SKUs to check when determining the best prior price.") public List getSkus() { return skus; diff --git a/src/main/java/one/talon/model/BestPriorPriceSettings.java b/src/main/java/one/talon/model/BestPriorPriceSettings.java new file mode 100644 index 00000000..e3df5493 --- /dev/null +++ b/src/main/java/one/talon/model/BestPriorPriceSettings.java @@ -0,0 +1,100 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The best prior price settings for this Application. + */ +@ApiModel(description = "The best prior price settings for this Application.") + +public class BestPriorPriceSettings { + public static final String SERIALIZED_NAME_ENABLE_BEST_PRIOR_PRICE = "enableBestPriorPrice"; + @SerializedName(SERIALIZED_NAME_ENABLE_BEST_PRIOR_PRICE) + private Boolean enableBestPriorPrice; + + + public BestPriorPriceSettings enableBestPriorPrice(Boolean enableBestPriorPrice) { + + this.enableBestPriorPrice = enableBestPriorPrice; + return this; + } + + /** + * When set to `true`, the best prior price feature is enabled in this Application and its [price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory) is recorded. + * @return enableBestPriorPrice + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When set to `true`, the best prior price feature is enabled in this Application and its [price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory) is recorded.") + + public Boolean getEnableBestPriorPrice() { + return enableBestPriorPrice; + } + + + public void setEnableBestPriorPrice(Boolean enableBestPriorPrice) { + this.enableBestPriorPrice = enableBestPriorPrice; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + BestPriorPriceSettings bestPriorPriceSettings = (BestPriorPriceSettings) o; + return Objects.equals(this.enableBestPriorPrice, bestPriorPriceSettings.enableBestPriorPrice); + } + + @Override + public int hashCode() { + return Objects.hash(enableBestPriorPrice); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class BestPriorPriceSettings {\n"); + sb.append(" enableBestPriorPrice: ").append(toIndentedString(enableBestPriorPrice)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/BetweenCheckAttributeBlock.java b/src/main/java/one/talon/model/BetweenCheckAttributeBlock.java new file mode 100644 index 00000000..d25f6c96 --- /dev/null +++ b/src/main/java/one/talon/model/BetweenCheckAttributeBlock.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for the `between` operator, which requires both a minimum and maximum value. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for the `between` operator, which requires both a minimum and maximum value.") + +public class BetweenCheckAttributeBlock { + /** + * The range comparison operator. Must be `between`. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + BETWEEN("between"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_MIN = "min"; + @SerializedName(SERIALIZED_NAME_MIN) + private Object min; + + public static final String SERIALIZED_NAME_MAX = "max"; + @SerializedName(SERIALIZED_NAME_MAX) + private Object max; + + + public BetweenCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The range comparison operator. Must be `between`. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The range comparison operator. Must be `between`.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public BetweenCheckAttributeBlock min(Object min) { + + this.min = min; + return this; + } + + /** + * The minimum value allowed for the `between` operator. + * @return min + **/ + @ApiModelProperty(example = "10", required = true, value = "The minimum value allowed for the `between` operator.") + + public Object getMin() { + return min; + } + + + public void setMin(Object min) { + this.min = min; + } + + + public BetweenCheckAttributeBlock max(Object max) { + + this.max = max; + return this; + } + + /** + * The maximum value allowed for the `between` operator. + * @return max + **/ + @ApiModelProperty(example = "100", required = true, value = "The maximum value allowed for the `between` operator.") + + public Object getMax() { + return max; + } + + + public void setMax(Object max) { + this.max = max; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + BetweenCheckAttributeBlock betweenCheckAttributeBlock = (BetweenCheckAttributeBlock) o; + return Objects.equals(this.operator, betweenCheckAttributeBlock.operator) && + Objects.equals(this.min, betweenCheckAttributeBlock.min) && + Objects.equals(this.max, betweenCheckAttributeBlock.max); + } + + @Override + public int hashCode() { + return Objects.hash(operator, min, max); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class BetweenCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" min: ").append(toIndentedString(min)).append("\n"); + sb.append(" max: ").append(toIndentedString(max)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Binding.java b/src/main/java/one/talon/model/Binding.java index 77c99439..661a1bf6 100644 --- a/src/main/java/one/talon/model/Binding.java +++ b/src/main/java/one/talon/model/Binding.java @@ -75,7 +75,7 @@ public Binding name(String name) { * A descriptive name for the value to be bound. * @return name **/ - @ApiModelProperty(example = "my property", required = true, value = "A descriptive name for the value to be bound.") + @ApiModelProperty(example = "Discount percentage", required = true, value = "A descriptive name for the value to be bound.") public String getName() { return name; @@ -122,10 +122,10 @@ public Binding addExpressionItem(Object expressionItem) { } /** - * A Talang expression that will be evaluated and its result attached to the name of the binding. + * A Talang expression that is evaluated, and its result is bound to the name of the binding. The first element must be one of the functions or operators supported by Talang, followed by its arguments. The arguments can be strings, numbers, or nested expressions. For example: - `[\"list\", \"10014\", \"10015\"]` calls the `list` function to build a list of strings. - `[\"+\", 2, 0]` uses the `+` operator to add two numbers. * @return expression **/ - @ApiModelProperty(example = "[string1, string2]", required = true, value = "A Talang expression that will be evaluated and its result attached to the name of the binding.") + @ApiModelProperty(example = "[identity, 10]", required = true, value = "A Talang expression that is evaluated, and its result is bound to the name of the binding. The first element must be one of the functions or operators supported by Talang, followed by its arguments. The arguments can be strings, numbers, or nested expressions. For example: - `[\"list\", \"10014\", \"10015\"]` calls the `list` function to build a list of strings. - `[\"+\", 2, 0]` uses the `+` operator to add two numbers. ") public List getExpression() { return expression; @@ -144,11 +144,11 @@ public Binding valueType(String valueType) { } /** - * Can be one of the following: - `string` - `number` - `boolean` + * The data type of the value. One of the following: - `string` - `number` - `boolean` * @return valueType **/ @javax.annotation.Nullable - @ApiModelProperty(example = "string", value = "Can be one of the following: - `string` - `number` - `boolean` ") + @ApiModelProperty(example = "number", value = "The data type of the value. One of the following: - `string` - `number` - `boolean` ") public String getValueType() { return valueType; @@ -213,11 +213,11 @@ public Binding attributeId(Long attributeId) { } /** - * Id of the attribute attached to the placeholder. + * Identifier of the attribute attached to the placeholder. * @return attributeId **/ @javax.annotation.Nullable - @ApiModelProperty(example = "100", value = "Id of the attribute attached to the placeholder.") + @ApiModelProperty(example = "100", value = "Identifier of the attribute attached to the placeholder.") public Long getAttributeId() { return attributeId; @@ -236,11 +236,11 @@ public Binding description(String description) { } /** - * Describes the placeholder field and value in the template. This description can be used when creating campaigns from this template. + * Description of the placeholder field and its value in the template. This text can be shown when creating campaigns from this template. * @return description **/ @javax.annotation.Nullable - @ApiModelProperty(example = "This is a template parameter of type `number`.", value = "Describes the placeholder field and value in the template. This description can be used when creating campaigns from this template.") + @ApiModelProperty(example = "The percentage discount applied to the cart total.", value = "Description of the placeholder field and its value in the template. This text can be shown when creating campaigns from this template.") public String getDescription() { return description; diff --git a/src/main/java/one/talon/model/Bundle.java b/src/main/java/one/talon/model/Bundle.java new file mode 100644 index 00000000..4a645e03 --- /dev/null +++ b/src/main/java/one/talon/model/Bundle.java @@ -0,0 +1,305 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A named bundle definition consisting of selector sources with matching constraints. Replaces `bundle` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. + */ +@ApiModel(description = "A named bundle definition consisting of selector sources with matching constraints. Replaces `bundle` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets.") + +public class Bundle { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + /** + * A binding of type `bundle`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + BUNDLE("bundle"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_SOURCES = "sources"; + @SerializedName(SERIALIZED_NAME_SOURCES) + private List sources = new ArrayList(); + + public static final String SERIALIZED_NAME_COUNTS = "counts"; + @SerializedName(SERIALIZED_NAME_COUNTS) + private List counts = new ArrayList(); + + public static final String SERIALIZED_NAME_MATCHERS = "matchers"; + @SerializedName(SERIALIZED_NAME_MATCHERS) + private List matchers = null; + + + public Bundle id(String id) { + + this.id = id; + return this; + } + + /** + * An identifier derived from the bundle content. + * @return id + **/ + @ApiModelProperty(example = "1b671a64-40d5-491e-99b0-da01ff1f3341", required = true, value = "An identifier derived from the bundle content.") + + public String getId() { + return id; + } + + + public void setId(String id) { + this.id = id; + } + + + public Bundle name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the bundle. + * @return name + **/ + @ApiModelProperty(example = "meal_deal", required = true, value = "The name of the bundle.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public Bundle type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A binding of type `bundle`. + * @return type + **/ + @ApiModelProperty(example = "bundle", required = true, value = "A binding of type `bundle`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public Bundle sources(List sources) { + + this.sources = sources; + return this; + } + + public Bundle addSourcesItem(String sourcesItem) { + this.sources.add(sourcesItem); + return this; + } + + /** + * The selector sources of bundle items. Each source is expressed as a `{{$selectorName}}` reference. + * @return sources + **/ + @ApiModelProperty(example = "[{{$mains}}, {{$drinks}}]", required = true, value = "The selector sources of bundle items. Each source is expressed as a `{{$selectorName}}` reference.") + + public List getSources() { + return sources; + } + + + public void setSources(List sources) { + this.sources = sources; + } + + + public Bundle counts(List counts) { + + this.counts = counts; + return this; + } + + public Bundle addCountsItem(Long countsItem) { + this.counts.add(countsItem); + return this; + } + + /** + * The number of items to retrieve from each corresponding source in `sources`. + * @return counts + **/ + @ApiModelProperty(example = "[1, 2]", required = true, value = "The number of items to retrieve from each corresponding source in `sources`.") + + public List getCounts() { + return counts; + } + + + public void setCounts(List counts) { + this.counts = counts; + } + + + public Bundle matchers(List matchers) { + + this.matchers = matchers; + return this; + } + + public Bundle addMatchersItem(String matchersItem) { + if (this.matchers == null) { + this.matchers = new ArrayList(); + } + this.matchers.add(matchersItem); + return this; + } + + /** + * Attribute names that the bundled items must share. + * @return matchers + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[color]", value = "Attribute names that the bundled items must share.") + + public List getMatchers() { + return matchers; + } + + + public void setMatchers(List matchers) { + this.matchers = matchers; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Bundle bundle = (Bundle) o; + return Objects.equals(this.id, bundle.id) && + Objects.equals(this.name, bundle.name) && + Objects.equals(this.type, bundle.type) && + Objects.equals(this.sources, bundle.sources) && + Objects.equals(this.counts, bundle.counts) && + Objects.equals(this.matchers, bundle.matchers); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, type, sources, counts, matchers); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Bundle {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" sources: ").append(toIndentedString(sources)).append("\n"); + sb.append(" counts: ").append(toIndentedString(counts)).append("\n"); + sb.append(" matchers: ").append(toIndentedString(matchers)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Campaign.java b/src/main/java/one/talon/model/Campaign.java index 365b6c0d..be641ee8 100644 --- a/src/main/java/one/talon/model/Campaign.java +++ b/src/main/java/one/talon/model/Campaign.java @@ -152,7 +152,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; @@ -1414,7 +1416,7 @@ public Campaign updated(OffsetDateTime updated) { * @return updated **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. ") + @ApiModelProperty(example = "2022-10-27T15:00Z", value = "Timestamp of the most recent update to the campaign's property. Updates to external entities used in this campaign are **not** registered by this property, such as collection or coupon updates. ") public OffsetDateTime getUpdated() { return updated; diff --git a/src/main/java/one/talon/model/CampaignEligibility.java b/src/main/java/one/talon/model/CampaignEligibility.java new file mode 100644 index 00000000..18def8c0 --- /dev/null +++ b/src/main/java/one/talon/model/CampaignEligibility.java @@ -0,0 +1,568 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CampaignEligibilityDetails; +import one.talon.model.CampaignEligibilityExperiment; +import one.talon.model.RuleMetadataEligibility; +import org.threeten.bp.OffsetDateTime; + +/** + * A list of campaigns and their evaluation status for the current customer session. For experiment campaigns, the experiment and variant assigned to the customer profile are returned through the `experiment` field. Customer profiles with no variant assignment are not included. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. + */ +@ApiModel(description = "A list of campaigns and their evaluation status for the current customer session. For experiment campaigns, the experiment and variant assigned to the customer profile are returned through the `experiment` field. Customer profiles with no variant assignment are not included. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. ") + +public class CampaignEligibility { + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_START_TIME = "startTime"; + @SerializedName(SERIALIZED_NAME_START_TIME) + private OffsetDateTime startTime; + + public static final String SERIALIZED_NAME_END_TIME = "endTime"; + @SerializedName(SERIALIZED_NAME_END_TIME) + private OffsetDateTime endTime; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + /** + * The state of the campaign. + */ + @JsonAdapter(StateEnum.Adapter.class) + public enum StateEnum { + ENABLED("enabled"); + + private String value; + + StateEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StateEnum fromValue(String value) { + for (StateEnum b : StateEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StateEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StateEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StateEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATE = "state"; + @SerializedName(SERIALIZED_NAME_STATE) + private StateEnum state = StateEnum.ENABLED; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = new ArrayList(); + + /** + * Gets or Sets features + */ + @JsonAdapter(FeaturesEnum.Adapter.class) + public enum FeaturesEnum { + COUPONS("coupons"), + + REFERRALS("referrals"), + + LOYALTY("loyalty"), + + GIVEAWAYS("giveaways"), + + STRIKETHROUGH("strikethrough"), + + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); + + private String value; + + FeaturesEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static FeaturesEnum fromValue(String value) { + for (FeaturesEnum b : FeaturesEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final FeaturesEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public FeaturesEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return FeaturesEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_FEATURES = "features"; + @SerializedName(SERIALIZED_NAME_FEATURES) + private List features = new ArrayList(); + + public static final String SERIALIZED_NAME_ELIGIBILITY = "eligibility"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY) + private List eligibility = new ArrayList(); + + public static final String SERIALIZED_NAME_RULES = "rules"; + @SerializedName(SERIALIZED_NAME_RULES) + private List rules = new ArrayList(); + + public static final String SERIALIZED_NAME_EXPERIMENT = "experiment"; + @SerializedName(SERIALIZED_NAME_EXPERIMENT) + private CampaignEligibilityExperiment experiment; + + + public CampaignEligibility applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application that owns this entity. + * @return applicationId + **/ + @ApiModelProperty(example = "322", required = true, value = "The ID of the Application that owns this entity.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public CampaignEligibility id(Long id) { + + this.id = id; + return this; + } + + /** + * Unique ID of Campaign. + * @return id + **/ + @ApiModelProperty(example = "4", required = true, value = "Unique ID of Campaign.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CampaignEligibility name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the campaign. + * @return name + **/ + @ApiModelProperty(example = "Summer promotions", required = true, value = "The name of the campaign.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CampaignEligibility description(String description) { + + this.description = description; + return this; + } + + /** + * A detailed description of the campaign. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Campaign for all summer 2021 promotions", value = "A detailed description of the campaign.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public CampaignEligibility startTime(OffsetDateTime startTime) { + + this.startTime = startTime; + return this; + } + + /** + * Timestamp when the campaign will become active. + * @return startTime + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-07-20T22:00Z", value = "Timestamp when the campaign will become active.") + + public OffsetDateTime getStartTime() { + return startTime; + } + + + public void setStartTime(OffsetDateTime startTime) { + this.startTime = startTime; + } + + + public CampaignEligibility endTime(OffsetDateTime endTime) { + + this.endTime = endTime; + return this; + } + + /** + * Timestamp when the campaign will become inactive. + * @return endTime + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00Z", value = "Timestamp when the campaign will become inactive.") + + public OffsetDateTime getEndTime() { + return endTime; + } + + + public void setEndTime(OffsetDateTime endTime) { + this.endTime = endTime; + } + + + public CampaignEligibility attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Arbitrary properties associated with this campaign. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Arbitrary properties associated with this campaign.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public CampaignEligibility state(StateEnum state) { + + this.state = state; + return this; + } + + /** + * The state of the campaign. + * @return state + **/ + @ApiModelProperty(example = "enabled", required = true, value = "The state of the campaign. ") + + public StateEnum getState() { + return state; + } + + + public void setState(StateEnum state) { + this.state = state; + } + + + public CampaignEligibility tags(List tags) { + + this.tags = tags; + return this; + } + + public CampaignEligibility addTagsItem(String tagsItem) { + this.tags.add(tagsItem); + return this; + } + + /** + * A list of tags for the campaign. + * @return tags + **/ + @ApiModelProperty(example = "[summer]", required = true, value = "A list of tags for the campaign.") + + public List getTags() { + return tags; + } + + + public void setTags(List tags) { + this.tags = tags; + } + + + public CampaignEligibility features(List features) { + + this.features = features; + return this; + } + + public CampaignEligibility addFeaturesItem(FeaturesEnum featuresItem) { + this.features.add(featuresItem); + return this; + } + + /** + * The features enabled in this campaign. + * @return features + **/ + @ApiModelProperty(example = "[coupons, referrals]", required = true, value = "The features enabled in this campaign.") + + public List getFeatures() { + return features; + } + + + public void setFeatures(List features) { + this.features = features; + } + + + public CampaignEligibility eligibility(List eligibility) { + + this.eligibility = eligibility; + return this; + } + + public CampaignEligibility addEligibilityItem(CampaignEligibilityDetails eligibilityItem) { + this.eligibility.add(eligibilityItem); + return this; + } + + /** + * The customer's eligibility for each campaign in the current customer session. + * @return eligibility + **/ + @ApiModelProperty(required = true, value = "The customer's eligibility for each campaign in the current customer session.") + + public List getEligibility() { + return eligibility; + } + + + public void setEligibility(List eligibility) { + this.eligibility = eligibility; + } + + + public CampaignEligibility rules(List rules) { + + this.rules = rules; + return this; + } + + public CampaignEligibility addRulesItem(RuleMetadataEligibility rulesItem) { + this.rules.add(rulesItem); + return this; + } + + /** + * A list of rules containing customer-facing details of the rewards defined in the campaign. + * @return rules + **/ + @ApiModelProperty(required = true, value = "A list of rules containing customer-facing details of the rewards defined in the campaign.") + + public List getRules() { + return rules; + } + + + public void setRules(List rules) { + this.rules = rules; + } + + + public CampaignEligibility experiment(CampaignEligibilityExperiment experiment) { + + this.experiment = experiment; + return this; + } + + /** + * Get experiment + * @return experiment + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public CampaignEligibilityExperiment getExperiment() { + return experiment; + } + + + public void setExperiment(CampaignEligibilityExperiment experiment) { + this.experiment = experiment; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignEligibility campaignEligibility = (CampaignEligibility) o; + return Objects.equals(this.applicationId, campaignEligibility.applicationId) && + Objects.equals(this.id, campaignEligibility.id) && + Objects.equals(this.name, campaignEligibility.name) && + Objects.equals(this.description, campaignEligibility.description) && + Objects.equals(this.startTime, campaignEligibility.startTime) && + Objects.equals(this.endTime, campaignEligibility.endTime) && + Objects.equals(this.attributes, campaignEligibility.attributes) && + Objects.equals(this.state, campaignEligibility.state) && + Objects.equals(this.tags, campaignEligibility.tags) && + Objects.equals(this.features, campaignEligibility.features) && + Objects.equals(this.eligibility, campaignEligibility.eligibility) && + Objects.equals(this.rules, campaignEligibility.rules) && + Objects.equals(this.experiment, campaignEligibility.experiment); + } + + @Override + public int hashCode() { + return Objects.hash(applicationId, id, name, description, startTime, endTime, attributes, state, tags, features, eligibility, rules, experiment); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignEligibility {\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); + sb.append(" endTime: ").append(toIndentedString(endTime)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" state: ").append(toIndentedString(state)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" features: ").append(toIndentedString(features)).append("\n"); + sb.append(" eligibility: ").append(toIndentedString(eligibility)).append("\n"); + sb.append(" rules: ").append(toIndentedString(rules)).append("\n"); + sb.append(" experiment: ").append(toIndentedString(experiment)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignEligibilityDetails.java b/src/main/java/one/talon/model/CampaignEligibilityDetails.java new file mode 100644 index 00000000..53bdcc90 --- /dev/null +++ b/src/main/java/one/talon/model/CampaignEligibilityDetails.java @@ -0,0 +1,157 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.CampaignEligibilityFailureDetails; + +/** + * CampaignEligibilityDetails + */ + +public class CampaignEligibilityDetails { + public static final String SERIALIZED_NAME_PASSED = "passed"; + @SerializedName(SERIALIZED_NAME_PASSED) + private Boolean passed; + + public static final String SERIALIZED_NAME_COUPON_CODE = "couponCode"; + @SerializedName(SERIALIZED_NAME_COUPON_CODE) + private String couponCode; + + public static final String SERIALIZED_NAME_DETAILS = "details"; + @SerializedName(SERIALIZED_NAME_DETAILS) + private CampaignEligibilityFailureDetails details; + + + public CampaignEligibilityDetails passed(Boolean passed) { + + this.passed = passed; + return this; + } + + /** + * Indicates whether the customer was eligible for the campaign in the current session. + * @return passed + **/ + @ApiModelProperty(required = true, value = "Indicates whether the customer was eligible for the campaign in the current session.") + + public Boolean getPassed() { + return passed; + } + + + public void setPassed(Boolean passed) { + this.passed = passed; + } + + + public CampaignEligibilityDetails couponCode(String couponCode) { + + this.couponCode = couponCode; + return this; + } + + /** + * The coupon code used to check a customer's eligibility for the campaign in the current session, if applicable. + * @return couponCode + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The coupon code used to check a customer's eligibility for the campaign in the current session, if applicable.") + + public String getCouponCode() { + return couponCode; + } + + + public void setCouponCode(String couponCode) { + this.couponCode = couponCode; + } + + + public CampaignEligibilityDetails details(CampaignEligibilityFailureDetails details) { + + this.details = details; + return this; + } + + /** + * Get details + * @return details + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public CampaignEligibilityFailureDetails getDetails() { + return details; + } + + + public void setDetails(CampaignEligibilityFailureDetails details) { + this.details = details; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignEligibilityDetails campaignEligibilityDetails = (CampaignEligibilityDetails) o; + return Objects.equals(this.passed, campaignEligibilityDetails.passed) && + Objects.equals(this.couponCode, campaignEligibilityDetails.couponCode) && + Objects.equals(this.details, campaignEligibilityDetails.details); + } + + @Override + public int hashCode() { + return Objects.hash(passed, couponCode, details); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignEligibilityDetails {\n"); + sb.append(" passed: ").append(toIndentedString(passed)).append("\n"); + sb.append(" couponCode: ").append(toIndentedString(couponCode)).append("\n"); + sb.append(" details: ").append(toIndentedString(details)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignEligibilityExperiment.java b/src/main/java/one/talon/model/CampaignEligibilityExperiment.java new file mode 100644 index 00000000..97fc17a0 --- /dev/null +++ b/src/main/java/one/talon/model/CampaignEligibilityExperiment.java @@ -0,0 +1,127 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The identifiers for the [experiment](https://docs.talon.one/management-api#tag/Experiments) and the variant assigned to the customer profile. Only returned when the customer profile has been assigned to a variant in an experiment campaign. + */ +@ApiModel(description = "The identifiers for the [experiment](https://docs.talon.one/management-api#tag/Experiments) and the variant assigned to the customer profile. Only returned when the customer profile has been assigned to a variant in an experiment campaign. ") + +public class CampaignEligibilityExperiment { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_VARIANT_ID = "variantId"; + @SerializedName(SERIALIZED_NAME_VARIANT_ID) + private Long variantId; + + + public CampaignEligibilityExperiment id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the experiment. + * @return id + **/ + @ApiModelProperty(required = true, value = "The ID of the experiment.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CampaignEligibilityExperiment variantId(Long variantId) { + + this.variantId = variantId; + return this; + } + + /** + * The ID of the variant assigned to the customer profile. + * @return variantId + **/ + @ApiModelProperty(required = true, value = "The ID of the variant assigned to the customer profile.") + + public Long getVariantId() { + return variantId; + } + + + public void setVariantId(Long variantId) { + this.variantId = variantId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignEligibilityExperiment campaignEligibilityExperiment = (CampaignEligibilityExperiment) o; + return Objects.equals(this.id, campaignEligibilityExperiment.id) && + Objects.equals(this.variantId, campaignEligibilityExperiment.variantId); + } + + @Override + public int hashCode() { + return Objects.hash(id, variantId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignEligibilityExperiment {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" variantId: ").append(toIndentedString(variantId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignEligibilityFailureDetails.java b/src/main/java/one/talon/model/CampaignEligibilityFailureDetails.java new file mode 100644 index 00000000..bef451d3 --- /dev/null +++ b/src/main/java/one/talon/model/CampaignEligibilityFailureDetails.java @@ -0,0 +1,148 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The details about why the customer was not eligible for the campaign in the current session. + */ +@ApiModel(description = "The details about why the customer was not eligible for the campaign in the current session.") + +public class CampaignEligibilityFailureDetails { + /** + * A code identifying why the customer was not eligible for the campaign. + */ + @JsonAdapter(FailureCodeEnum.Adapter.class) + public enum FailureCodeEnum { + ALL_RULES_FAILED("ALL_RULES_FAILED"), + + SKIPPED("SKIPPED"), + + AUDIENCE_NOT_MATCHED("AUDIENCE_NOT_MATCHED"); + + private String value; + + FailureCodeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static FailureCodeEnum fromValue(String value) { + for (FailureCodeEnum b : FailureCodeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final FailureCodeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public FailureCodeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return FailureCodeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_FAILURE_CODE = "failureCode"; + @SerializedName(SERIALIZED_NAME_FAILURE_CODE) + private FailureCodeEnum failureCode; + + + public CampaignEligibilityFailureDetails failureCode(FailureCodeEnum failureCode) { + + this.failureCode = failureCode; + return this; + } + + /** + * A code identifying why the customer was not eligible for the campaign. + * @return failureCode + **/ + @ApiModelProperty(required = true, value = "A code identifying why the customer was not eligible for the campaign.") + + public FailureCodeEnum getFailureCode() { + return failureCode; + } + + + public void setFailureCode(FailureCodeEnum failureCode) { + this.failureCode = failureCode; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignEligibilityFailureDetails campaignEligibilityFailureDetails = (CampaignEligibilityFailureDetails) o; + return Objects.equals(this.failureCode, campaignEligibilityFailureDetails.failureCode); + } + + @Override + public int hashCode() { + return Objects.hash(failureCode); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignEligibilityFailureDetails {\n"); + sb.append(" failureCode: ").append(toIndentedString(failureCode)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignLoyaltyProgram.java b/src/main/java/one/talon/model/CampaignLoyaltyProgram.java new file mode 100644 index 00000000..5dc7889d --- /dev/null +++ b/src/main/java/one/talon/model/CampaignLoyaltyProgram.java @@ -0,0 +1,190 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A loyalty program referenced in a campaign. + */ +@ApiModel(description = "A loyalty program referenced in a campaign.") + +public class CampaignLoyaltyProgram { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TIERS = "tiers"; + @SerializedName(SERIALIZED_NAME_TIERS) + private List tiers = new ArrayList(); + + public static final String SERIALIZED_NAME_CARD_BASED = "cardBased"; + @SerializedName(SERIALIZED_NAME_CARD_BASED) + private Boolean cardBased; + + + public CampaignLoyaltyProgram id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the loyalty program. + * @return id + **/ + @ApiModelProperty(example = "5", required = true, value = "The ID of the loyalty program.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CampaignLoyaltyProgram name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the loyalty program. + * @return name + **/ + @ApiModelProperty(example = "My program", required = true, value = "The name of the loyalty program.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CampaignLoyaltyProgram tiers(List tiers) { + + this.tiers = tiers; + return this; + } + + public CampaignLoyaltyProgram addTiersItem(String tiersItem) { + this.tiers.add(tiersItem); + return this; + } + + /** + * The names of the tiers in the loyalty program. + * @return tiers + **/ + @ApiModelProperty(example = "[Silver, Gold, Platinum]", required = true, value = "The names of the tiers in the loyalty program.") + + public List getTiers() { + return tiers; + } + + + public void setTiers(List tiers) { + this.tiers = tiers; + } + + + public CampaignLoyaltyProgram cardBased(Boolean cardBased) { + + this.cardBased = cardBased; + return this; + } + + /** + * Whether the loyalty program is card-based. + * @return cardBased + **/ + @ApiModelProperty(example = "false", required = true, value = "Whether the loyalty program is card-based.") + + public Boolean getCardBased() { + return cardBased; + } + + + public void setCardBased(Boolean cardBased) { + this.cardBased = cardBased; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignLoyaltyProgram campaignLoyaltyProgram = (CampaignLoyaltyProgram) o; + return Objects.equals(this.id, campaignLoyaltyProgram.id) && + Objects.equals(this.name, campaignLoyaltyProgram.name) && + Objects.equals(this.tiers, campaignLoyaltyProgram.tiers) && + Objects.equals(this.cardBased, campaignLoyaltyProgram.cardBased); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, tiers, cardBased); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignLoyaltyProgram {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" tiers: ").append(toIndentedString(tiers)).append("\n"); + sb.append(" cardBased: ").append(toIndentedString(cardBased)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignReference.java b/src/main/java/one/talon/model/CampaignReference.java new file mode 100644 index 00000000..433c4e6f --- /dev/null +++ b/src/main/java/one/talon/model/CampaignReference.java @@ -0,0 +1,126 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * CampaignReference + */ + +public class CampaignReference { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + + public CampaignReference id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the campaign that references this achievement. + * @return id + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the campaign that references this achievement.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CampaignReference applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application the campaign belongs to. + * @return applicationId + **/ + @ApiModelProperty(example = "2", required = true, value = "The ID of the Application the campaign belongs to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CampaignReference campaignReference = (CampaignReference) o; + return Objects.equals(this.id, campaignReference.id) && + Objects.equals(this.applicationId, campaignReference.applicationId); + } + + @Override + public int hashCode() { + return Objects.hash(id, applicationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CampaignReference {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignTemplate.java b/src/main/java/one/talon/model/CampaignTemplate.java index 034973d2..34a7e952 100644 --- a/src/main/java/one/talon/model/CampaignTemplate.java +++ b/src/main/java/one/talon/model/CampaignTemplate.java @@ -153,7 +153,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/CardLedgerTransactionLogEntryIntegrationAPI.java b/src/main/java/one/talon/model/CardLedgerTransactionLogEntryIntegrationAPI.java index 81ca82f8..08fa522f 100644 --- a/src/main/java/one/talon/model/CardLedgerTransactionLogEntryIntegrationAPI.java +++ b/src/main/java/one/talon/model/CardLedgerTransactionLogEntryIntegrationAPI.java @@ -458,11 +458,11 @@ public CardLedgerTransactionLogEntryIntegrationAPI validityDuration(String valid } /** - * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. + * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. * @return validityDuration **/ @javax.annotation.Nullable - @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") + @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") public String getValidityDuration() { return validityDuration; diff --git a/src/main/java/one/talon/model/CartItemFilterTemplate.java b/src/main/java/one/talon/model/CartItemFilterTemplate.java index 8a6c5dd1..830aace0 100644 --- a/src/main/java/one/talon/model/CartItemFilterTemplate.java +++ b/src/main/java/one/talon/model/CartItemFilterTemplate.java @@ -78,7 +78,7 @@ public CartItemFilterTemplate addExpressionItem(Object expressionItem) { * The Talang expression for the cart item filter. * @return expression **/ - @ApiModelProperty(example = "[filter, [., Session, CartItems], [[Item], [catch, false, [=, [., Item, Category], Kitchen]]]]", required = true, value = "The Talang expression for the cart item filter.") + @ApiModelProperty(example = "[filter, [., Session, CartItems], [[Item], [catch, false, [contains, [., Item, Category], Kitchen]]]]", required = true, value = "The Talang expression for the cart item filter.") public List getExpression() { return expression; diff --git a/src/main/java/one/talon/model/CatalogAction.java b/src/main/java/one/talon/model/CatalogAction.java index 39bb0e8c..23a338bf 100644 --- a/src/main/java/one/talon/model/CatalogAction.java +++ b/src/main/java/one/talon/model/CatalogAction.java @@ -25,9 +25,10 @@ import java.io.IOException; /** - * Definition of all the properties that are needed for a single catalog sync action. + * Definition of all the properties that are needed for a single catalog sync action. The `type` field selects the concrete action variant. */ -@ApiModel(description = "Definition of all the properties that are needed for a single catalog sync action.") +@ApiModel(description = "Definition of all the properties that are needed for a single catalog sync action. The `type` field selects the concrete action variant.") + public class CatalogAction { /** @@ -87,12 +88,14 @@ public TypeEnum read(final JsonReader jsonReader) throws IOException { public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) - private TypeEnum type; + protected TypeEnum type; public static final String SERIALIZED_NAME_PAYLOAD = "payload"; @SerializedName(SERIALIZED_NAME_PAYLOAD) private Object payload; + public CatalogAction() { + } public CatalogAction type(TypeEnum type) { @@ -104,7 +107,8 @@ public CatalogAction type(TypeEnum type) { * The type of sync action. * @return type **/ - @ApiModelProperty(example = "ADD", required = true, value = "The type of sync action.") + @javax.annotation.Nullable + @ApiModelProperty(example = "ADD", value = "The type of sync action.") public TypeEnum getType() { return type; @@ -126,7 +130,8 @@ public CatalogAction payload(Object payload) { * Get payload * @return payload **/ - @ApiModelProperty(required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "") public Object getPayload() { return payload; diff --git a/src/main/java/one/talon/model/CatalogActionAdd.java b/src/main/java/one/talon/model/CatalogActionAdd.java new file mode 100644 index 00000000..ac238936 --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionAdd.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AddItemCatalogAction; + +/** + * Adds an item to the catalog. + */ +@ApiModel(description = "Adds an item to the catalog.") + +public class CatalogActionAdd { + /** + * A catalog sync action discriminator of type `ADD`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + ADD("ADD"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private AddItemCatalogAction payload; + + + public CatalogActionAdd type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `ADD`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `ADD`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionAdd payload(AddItemCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public AddItemCatalogAction getPayload() { + return payload; + } + + + public void setPayload(AddItemCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionAdd catalogActionAdd = (CatalogActionAdd) o; + return Objects.equals(this.type, catalogActionAdd.type) && + Objects.equals(this.payload, catalogActionAdd.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionAdd {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CatalogActionAddPriceAdjustment.java b/src/main/java/one/talon/model/CatalogActionAddPriceAdjustment.java new file mode 100644 index 00000000..6f2cfdcb --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionAddPriceAdjustment.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AddPriceAdjustmentCatalogAction; + +/** + * Adds price adjustments to an item of the catalog. + */ +@ApiModel(description = "Adds price adjustments to an item of the catalog.") + +public class CatalogActionAddPriceAdjustment { + /** + * A catalog sync action discriminator of type `ADD_PRICE_ADJUSTMENT`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + ADD_PRICE_ADJUSTMENT("ADD_PRICE_ADJUSTMENT"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private AddPriceAdjustmentCatalogAction payload; + + + public CatalogActionAddPriceAdjustment type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `ADD_PRICE_ADJUSTMENT`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `ADD_PRICE_ADJUSTMENT`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionAddPriceAdjustment payload(AddPriceAdjustmentCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public AddPriceAdjustmentCatalogAction getPayload() { + return payload; + } + + + public void setPayload(AddPriceAdjustmentCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionAddPriceAdjustment catalogActionAddPriceAdjustment = (CatalogActionAddPriceAdjustment) o; + return Objects.equals(this.type, catalogActionAddPriceAdjustment.type) && + Objects.equals(this.payload, catalogActionAddPriceAdjustment.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionAddPriceAdjustment {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CatalogActionPatch.java b/src/main/java/one/talon/model/CatalogActionPatch.java new file mode 100644 index 00000000..d3cb0724 --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionPatch.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.PatchItemCatalogAction; + +/** + * Updates an item in the catalog. + */ +@ApiModel(description = "Updates an item in the catalog.") + +public class CatalogActionPatch { + /** + * A catalog sync action discriminator of type `PATCH`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + PATCH("PATCH"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private PatchItemCatalogAction payload; + + + public CatalogActionPatch type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `PATCH`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `PATCH`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionPatch payload(PatchItemCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public PatchItemCatalogAction getPayload() { + return payload; + } + + + public void setPayload(PatchItemCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionPatch catalogActionPatch = (CatalogActionPatch) o; + return Objects.equals(this.type, catalogActionPatch.type) && + Objects.equals(this.payload, catalogActionPatch.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionPatch {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CatalogActionPatchMany.java b/src/main/java/one/talon/model/CatalogActionPatchMany.java new file mode 100644 index 00000000..c8a294b4 --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionPatchMany.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.PatchManyItemsCatalogAction; + +/** + * Updates the items of the catalog that match the given filters. + */ +@ApiModel(description = "Updates the items of the catalog that match the given filters.") + +public class CatalogActionPatchMany { + /** + * A catalog sync action discriminator of type `PATCH_MANY`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + PATCH_MANY("PATCH_MANY"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private PatchManyItemsCatalogAction payload; + + + public CatalogActionPatchMany type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `PATCH_MANY`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `PATCH_MANY`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionPatchMany payload(PatchManyItemsCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public PatchManyItemsCatalogAction getPayload() { + return payload; + } + + + public void setPayload(PatchManyItemsCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionPatchMany catalogActionPatchMany = (CatalogActionPatchMany) o; + return Objects.equals(this.type, catalogActionPatchMany.type) && + Objects.equals(this.payload, catalogActionPatchMany.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionPatchMany {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CatalogActionRemove.java b/src/main/java/one/talon/model/CatalogActionRemove.java new file mode 100644 index 00000000..65abb6f2 --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionRemove.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RemoveItemCatalogAction; + +/** + * Removes an item from the catalog. + */ +@ApiModel(description = "Removes an item from the catalog.") + +public class CatalogActionRemove { + /** + * A catalog sync action discriminator of type `REMOVE`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + REMOVE("REMOVE"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private RemoveItemCatalogAction payload; + + + public CatalogActionRemove type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `REMOVE`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `REMOVE`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionRemove payload(RemoveItemCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public RemoveItemCatalogAction getPayload() { + return payload; + } + + + public void setPayload(RemoveItemCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionRemove catalogActionRemove = (CatalogActionRemove) o; + return Objects.equals(this.type, catalogActionRemove.type) && + Objects.equals(this.payload, catalogActionRemove.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionRemove {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CatalogActionRemoveMany.java b/src/main/java/one/talon/model/CatalogActionRemoveMany.java new file mode 100644 index 00000000..f890b193 --- /dev/null +++ b/src/main/java/one/talon/model/CatalogActionRemoveMany.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RemoveManyItemsCatalogAction; + +/** + * Removes the items of the catalog that match the given filters. + */ +@ApiModel(description = "Removes the items of the catalog that match the given filters.") + +public class CatalogActionRemoveMany { + /** + * A catalog sync action discriminator of type `REMOVE_MANY`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + REMOVE_MANY("REMOVE_MANY"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private RemoveManyItemsCatalogAction payload; + + + public CatalogActionRemoveMany type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A catalog sync action discriminator of type `REMOVE_MANY`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A catalog sync action discriminator of type `REMOVE_MANY`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public CatalogActionRemoveMany payload(RemoveManyItemsCatalogAction payload) { + + this.payload = payload; + return this; + } + + /** + * Get payload + * @return payload + **/ + @ApiModelProperty(required = true, value = "") + + public RemoveManyItemsCatalogAction getPayload() { + return payload; + } + + + public void setPayload(RemoveManyItemsCatalogAction payload) { + this.payload = payload; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CatalogActionRemoveMany catalogActionRemoveMany = (CatalogActionRemoveMany) o; + return Objects.equals(this.type, catalogActionRemoveMany.type) && + Objects.equals(this.payload, catalogActionRemoveMany.payload); + } + + @Override + public int hashCode() { + return Objects.hash(type, payload); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CatalogActionRemoveMany {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ChangeLoyaltyTierLevelEffectProps.java b/src/main/java/one/talon/model/ChangeLoyaltyTierLevelEffectProps.java index 71b2eb73..8b0f2bfe 100644 --- a/src/main/java/one/talon/model/ChangeLoyaltyTierLevelEffectProps.java +++ b/src/main/java/one/talon/model/ChangeLoyaltyTierLevelEffectProps.java @@ -26,9 +26,9 @@ import org.threeten.bp.OffsetDateTime; /** - * The properties specific to the \"changeLoyaltyTierLevel\" effect. This is triggered whenever the user's loyalty tier is upgraded due to a validated rule that contained an \"addLoyaltyPoints\" effect. + * This effect indicates that a customer's loyalty tier has been upgraded. This effect is generated only when the [Add loyalty points](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points) and the [Add loyalty points per cart item](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points-per-cart-item) effects are triggered for a particular customer, and, as a result, the customer's loyalty tier is upgraded. */ -@ApiModel(description = "The properties specific to the \"changeLoyaltyTierLevel\" effect. This is triggered whenever the user's loyalty tier is upgraded due to a validated rule that contained an \"addLoyaltyPoints\" effect. ") +@ApiModel(description = "This effect indicates that a customer's loyalty tier has been upgraded. This effect is generated only when the [Add loyalty points](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points) and the [Add loyalty points per cart item](https://docs.talon.one/docs/product/rules/effects/use-effects#add-loyalty-points-per-cart-item) effects are triggered for a particular customer, and, as a result, the customer's loyalty tier is upgraded.") public class ChangeLoyaltyTierLevelEffectProps { public static final String SERIALIZED_NAME_RULE_TITLE = "ruleTitle"; @@ -85,10 +85,10 @@ public ChangeLoyaltyTierLevelEffectProps programId(Long programId) { } /** - * The ID of the loyalty program where these points were added. + * The ID of the loyalty program where the points were added. * @return programId **/ - @ApiModelProperty(required = true, value = "The ID of the loyalty program where these points were added.") + @ApiModelProperty(required = true, value = "The ID of the loyalty program where the points were added.") public Long getProgramId() { return programId; @@ -107,10 +107,10 @@ public ChangeLoyaltyTierLevelEffectProps subLedgerId(String subLedgerId) { } /** - * The ID of the subledger within the loyalty program where these points were added. + * The ID of the subledger within the loyalty program where the points were added. * @return subLedgerId **/ - @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program where these points were added.") + @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program where the points were added.") public String getSubLedgerId() { return subLedgerId; diff --git a/src/main/java/one/talon/model/CheckAchievementBlock.java b/src/main/java/one/talon/model/CheckAchievementBlock.java new file mode 100644 index 00000000..44d9e5fd --- /dev/null +++ b/src/main/java/one/talon/model/CheckAchievementBlock.java @@ -0,0 +1,292 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckAchievementBlockAchievement; + +/** + * A block that checks the current customer's completion or progress status in an achievement. + */ +@ApiModel(description = "A block that checks the current customer's completion or progress status in an achievement.") + +public class CheckAchievementBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The comparison operator applied to the achievement. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + JUSTCOMPLETED("justCompleted"), + + STARTED("started"), + + NOT_STARTED_("not(started)"), + + INPROGRESS("inProgress"), + + NOT_INPROGRESS_("not(inProgress)"), + + COMPLETED("completed"), + + NOT_COMPLETED_("not(completed)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_ACHIEVEMENT = "achievement"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENT) + private CheckAchievementBlockAchievement achievement; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckAchievementBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckAchievementBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The comparison operator applied to the achievement. + * @return operator + **/ + @ApiModelProperty(example = "justCompleted", required = true, value = "The comparison operator applied to the achievement.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckAchievementBlock achievement(CheckAchievementBlockAchievement achievement) { + + this.achievement = achievement; + return this; + } + + /** + * Get achievement + * @return achievement + **/ + @ApiModelProperty(required = true, value = "") + + public CheckAchievementBlockAchievement getAchievement() { + return achievement; + } + + + public void setAchievement(CheckAchievementBlockAchievement achievement) { + this.achievement = achievement; + } + + + public CheckAchievementBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckAchievementBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAchievementBlock checkAchievementBlock = (CheckAchievementBlock) o; + return Objects.equals(this.id, checkAchievementBlock.id) && + Objects.equals(this.type, checkAchievementBlock.type) && + Objects.equals(this.tags, checkAchievementBlock.tags) && + Objects.equals(this.operator, checkAchievementBlock.operator) && + Objects.equals(this.achievement, checkAchievementBlock.achievement) && + Objects.equals(this.onFailure, checkAchievementBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, achievement, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAchievementBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" achievement: ").append(toIndentedString(achievement)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckAchievementBlockAchievement.java b/src/main/java/one/talon/model/CheckAchievementBlockAchievement.java new file mode 100644 index 00000000..a54a261e --- /dev/null +++ b/src/main/java/one/talon/model/CheckAchievementBlockAchievement.java @@ -0,0 +1,184 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * The achievement to check for. + */ +@ApiModel(description = "The achievement to check for.") + +public class CheckAchievementBlockAchievement { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private BigDecimal target; + + + public CheckAchievementBlockAchievement id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the achievement. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the achievement.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CheckAchievementBlockAchievement title(String title) { + + this.title = title; + return this; + } + + /** + * The display name for the achievement in the Campaign Manager. + * @return title + **/ + @ApiModelProperty(example = "50% off on 50th purchase.", required = true, value = "The display name for the achievement in the Campaign Manager.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public CheckAchievementBlockAchievement name(String name) { + + this.name = name; + return this; + } + + /** + * The internal name of the achievement used in API requests. + * @return name + **/ + @ApiModelProperty(example = "Order50Discount", required = true, value = "The internal name of the achievement used in API requests.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CheckAchievementBlockAchievement target(BigDecimal target) { + + this.target = target; + return this; + } + + /** + * The required number of actions or the transactional milestone to complete the achievement. + * @return target + **/ + @ApiModelProperty(example = "50.0", required = true, value = "The required number of actions or the transactional milestone to complete the achievement.") + + public BigDecimal getTarget() { + return target; + } + + + public void setTarget(BigDecimal target) { + this.target = target; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAchievementBlockAchievement checkAchievementBlockAchievement = (CheckAchievementBlockAchievement) o; + return Objects.equals(this.id, checkAchievementBlockAchievement.id) && + Objects.equals(this.title, checkAchievementBlockAchievement.title) && + Objects.equals(this.name, checkAchievementBlockAchievement.name) && + Objects.equals(this.target, checkAchievementBlockAchievement.target); + } + + @Override + public int hashCode() { + return Objects.hash(id, title, name, target); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAchievementBlockAchievement {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckAttributeBlock.java b/src/main/java/one/talon/model/CheckAttributeBlock.java new file mode 100644 index 00000000..91b53c77 --- /dev/null +++ b/src/main/java/one/talon/model/CheckAttributeBlock.java @@ -0,0 +1,681 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields. + */ +@ApiModel(description = "Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields.") + + +public class CheckAttributeBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + /** + * A block discriminator of type `checkAttribute`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + CHECKATTRIBUTE("checkAttribute"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The comparison operator applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + EQUALS("equals"), + + NOT_EQUALS_("not(equals)"), + + LESSTHAN("lessThan"), + + LESSTHANOREQUAL("lessThanOrEqual"), + + GREATERTHAN("greaterThan"), + + GREATERTHANOREQUAL("greaterThanOrEqual"), + + BETWEEN("between"), + + CONTAINS("contains"), + + NOT_CONTAINS_("not(contains)"), + + MATCHESREGEXP("matchesRegexp"), + + STARTSWITH("startsWith"), + + ENDSWITH("endsWith"), + + ONEOF("oneOf"), + + NOT_ONEOF_("not(oneOf)"), + + INCOLLECTION("inCollection"), + + NOT_INCOLLECTION_("not(inCollection)"), + + EMPTY("empty"), + + NOT_EMPTY_("not(empty)"), + + EXISTS("exists"), + + NOT_EXISTS_("not(exists)"), + + ISTRUE("isTrue"), + + ISFALSE("isFalse"), + + CONTAINSATLEAST("containsAtLeast"), + + CONTAINSEXACTLY("containsExactly"), + + CONTAINSONEOF("containsOneOf"), + + CONTAINSNONEOF("containsNoneOf"), + + CONTAINSALLOF("containsAllOf"), + + AFTER("after"), + + BEFORE("before"), + + WITHIN("within"), + + NOT_WITHIN_("not(within)"), + + IN("in"), + + NOT_IN_("not(in)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + protected OperatorEnum operator; + + public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTE) + private Object attribute; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_MIN = "min"; + @SerializedName(SERIALIZED_NAME_MIN) + private Object min; + + public static final String SERIALIZED_NAME_MAX = "max"; + @SerializedName(SERIALIZED_NAME_MAX) + private Object max; + + public static final String SERIALIZED_NAME_START = "start"; + @SerializedName(SERIALIZED_NAME_START) + private Object start; + + public static final String SERIALIZED_NAME_END = "end"; + @SerializedName(SERIALIZED_NAME_END) + private Object end; + + public static final String SERIALIZED_NAME_START_INCLUSIVE = "startInclusive"; + @SerializedName(SERIALIZED_NAME_START_INCLUSIVE) + private Boolean startInclusive; + + public static final String SERIALIZED_NAME_END_INCLUSIVE = "endInclusive"; + @SerializedName(SERIALIZED_NAME_END_INCLUSIVE) + private Boolean endInclusive; + + public static final String SERIALIZED_NAME_TIMEZONE_INSENSITIVE = "timezoneInsensitive"; + @SerializedName(SERIALIZED_NAME_TIMEZONE_INSENSITIVE) + private Boolean timezoneInsensitive; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private Object values; + + public static final String SERIALIZED_NAME_COUNT = "count"; + @SerializedName(SERIALIZED_NAME_COUNT) + private Object count; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + public CheckAttributeBlock() { + } + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckAttributeBlock type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A block discriminator of type `checkAttribute`. + * @return type + **/ + @ApiModelProperty(example = "checkAttribute", required = true, value = "A block discriminator of type `checkAttribute`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The comparison operator applied to the attribute. + * @return operator + **/ + @ApiModelProperty(example = "greaterThan", required = true, value = "The comparison operator applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckAttributeBlock attribute(Object attribute) { + + this.attribute = attribute; + return this; + } + + /** + * The attribute path identifier (e.g. \"$Session.Total\"). + * @return attribute + **/ + @ApiModelProperty(example = "$Session.Total", required = true, value = "The attribute path identifier (e.g. \"$Session.Total\").") + + public Object getAttribute() { + return attribute; + } + + + public void setAttribute(Object attribute) { + this.attribute = attribute; + } + + + public CheckAttributeBlock value(Object value) { + + this.value = value; + return this; + } + + /** + * The comparison value for scalar operators. + * @return value + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "The comparison value for scalar operators.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public CheckAttributeBlock min(Object min) { + + this.min = min; + return this; + } + + /** + * The minimum value allowed for the `between` operator. + * @return min + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "10", value = "The minimum value allowed for the `between` operator.") + + public Object getMin() { + return min; + } + + + public void setMin(Object min) { + this.min = min; + } + + + public CheckAttributeBlock max(Object max) { + + this.max = max; + return this; + } + + /** + * The maximum value allowed for the `between` operator. + * @return max + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "The maximum value allowed for the `between` operator.") + + public Object getMax() { + return max; + } + + + public void setMax(Object max) { + this.max = max; + } + + + public CheckAttributeBlock start(Object start) { + + this.start = start; + return this; + } + + /** + * The start value for the `within` operator. + * @return start + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00:00Z", value = "The start value for the `within` operator.") + + public Object getStart() { + return start; + } + + + public void setStart(Object start) { + this.start = start; + } + + + public CheckAttributeBlock end(Object end) { + + this.end = end; + return this; + } + + /** + * The end value for the `within` operator. + * @return end + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00:00Z", value = "The end value for the `within` operator.") + + public Object getEnd() { + return end; + } + + + public void setEnd(Object end) { + this.end = end; + } + + + public CheckAttributeBlock startInclusive(Boolean startInclusive) { + + this.startInclusive = startInclusive; + return this; + } + + /** + * When `true`, the `start` value is included in the range for the `within` operator. + * @return startInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `start` value is included in the range for the `within` operator.") + + public Boolean getStartInclusive() { + return startInclusive; + } + + + public void setStartInclusive(Boolean startInclusive) { + this.startInclusive = startInclusive; + } + + + public CheckAttributeBlock endInclusive(Boolean endInclusive) { + + this.endInclusive = endInclusive; + return this; + } + + /** + * When `true`, the `end` value is included in the range for the `within` operator. + * @return endInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `end` value is included in the range for the `within` operator.") + + public Boolean getEndInclusive() { + return endInclusive; + } + + + public void setEndInclusive(Boolean endInclusive) { + this.endInclusive = endInclusive; + } + + + public CheckAttributeBlock timezoneInsensitive(Boolean timezoneInsensitive) { + + this.timezoneInsensitive = timezoneInsensitive; + return this; + } + + /** + * Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. + * @return timezoneInsensitive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account.") + + public Boolean getTimezoneInsensitive() { + return timezoneInsensitive; + } + + + public void setTimezoneInsensitive(Boolean timezoneInsensitive) { + this.timezoneInsensitive = timezoneInsensitive; + } + + + public CheckAttributeBlock values(Object values) { + + this.values = values; + return this; + } + + /** + * The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute. + * @return values + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "", value = "The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute.") + + public Object getValues() { + return values; + } + + + public void setValues(Object values) { + this.values = values; + } + + + public CheckAttributeBlock count(Object count) { + + this.count = count; + return this; + } + + /** + * The count threshold for `containsAtLeast` and `containsExactly` operators. + * @return count + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2", value = "The count threshold for `containsAtLeast` and `containsExactly` operators.") + + public Object getCount() { + return count; + } + + + public void setCount(Object count) { + this.count = count; + } + + + public CheckAttributeBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckAttributeBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAttributeBlock checkAttributeBlock = (CheckAttributeBlock) o; + return Objects.equals(this.id, checkAttributeBlock.id) && + Objects.equals(this.type, checkAttributeBlock.type) && + Objects.equals(this.tags, checkAttributeBlock.tags) && + Objects.equals(this.operator, checkAttributeBlock.operator) && + Objects.equals(this.attribute, checkAttributeBlock.attribute) && + Objects.equals(this.value, checkAttributeBlock.value) && + Objects.equals(this.min, checkAttributeBlock.min) && + Objects.equals(this.max, checkAttributeBlock.max) && + Objects.equals(this.start, checkAttributeBlock.start) && + Objects.equals(this.end, checkAttributeBlock.end) && + Objects.equals(this.startInclusive, checkAttributeBlock.startInclusive) && + Objects.equals(this.endInclusive, checkAttributeBlock.endInclusive) && + Objects.equals(this.timezoneInsensitive, checkAttributeBlock.timezoneInsensitive) && + Objects.equals(this.values, checkAttributeBlock.values) && + Objects.equals(this.count, checkAttributeBlock.count) && + Objects.equals(this.onFailure, checkAttributeBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, attribute, value, min, max, start, end, startInclusive, endInclusive, timezoneInsensitive, values, count, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAttributeBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" min: ").append(toIndentedString(min)).append("\n"); + sb.append(" max: ").append(toIndentedString(max)).append("\n"); + sb.append(" start: ").append(toIndentedString(start)).append("\n"); + sb.append(" end: ").append(toIndentedString(end)).append("\n"); + sb.append(" startInclusive: ").append(toIndentedString(startInclusive)).append("\n"); + sb.append(" endInclusive: ").append(toIndentedString(endInclusive)).append("\n"); + sb.append(" timezoneInsensitive: ").append(toIndentedString(timezoneInsensitive)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append(" count: ").append(toIndentedString(count)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckAttributeBlockBase.java b/src/main/java/one/talon/model/CheckAttributeBlockBase.java new file mode 100644 index 00000000..44d62e0d --- /dev/null +++ b/src/main/java/one/talon/model/CheckAttributeBlockBase.java @@ -0,0 +1,633 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields. + */ +@ApiModel(description = "Shared shape for attribute-comparison blocks: a single attribute evaluated by a named operator. The operator determines which additional fields are required: - `scalar` requires `value`. - `between` requires `min` and `max` values. - `list` requires `values`. - `list-with-count` requires `values` and `count`. - `unary` requires no extra fields.") + +public class CheckAttributeBlockBase { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The comparison operator applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + EQUALS("equals"), + + NOT_EQUALS_("not(equals)"), + + LESSTHAN("lessThan"), + + LESSTHANOREQUAL("lessThanOrEqual"), + + GREATERTHAN("greaterThan"), + + GREATERTHANOREQUAL("greaterThanOrEqual"), + + BETWEEN("between"), + + CONTAINS("contains"), + + NOT_CONTAINS_("not(contains)"), + + MATCHESREGEXP("matchesRegexp"), + + STARTSWITH("startsWith"), + + ENDSWITH("endsWith"), + + ONEOF("oneOf"), + + NOT_ONEOF_("not(oneOf)"), + + INCOLLECTION("inCollection"), + + NOT_INCOLLECTION_("not(inCollection)"), + + EMPTY("empty"), + + NOT_EMPTY_("not(empty)"), + + EXISTS("exists"), + + NOT_EXISTS_("not(exists)"), + + ISTRUE("isTrue"), + + ISFALSE("isFalse"), + + CONTAINSATLEAST("containsAtLeast"), + + CONTAINSEXACTLY("containsExactly"), + + CONTAINSONEOF("containsOneOf"), + + CONTAINSNONEOF("containsNoneOf"), + + CONTAINSALLOF("containsAllOf"), + + AFTER("after"), + + BEFORE("before"), + + WITHIN("within"), + + NOT_WITHIN_("not(within)"), + + IN("in"), + + NOT_IN_("not(in)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTE) + private Object attribute; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_MIN = "min"; + @SerializedName(SERIALIZED_NAME_MIN) + private Object min; + + public static final String SERIALIZED_NAME_MAX = "max"; + @SerializedName(SERIALIZED_NAME_MAX) + private Object max; + + public static final String SERIALIZED_NAME_START = "start"; + @SerializedName(SERIALIZED_NAME_START) + private Object start; + + public static final String SERIALIZED_NAME_END = "end"; + @SerializedName(SERIALIZED_NAME_END) + private Object end; + + public static final String SERIALIZED_NAME_START_INCLUSIVE = "startInclusive"; + @SerializedName(SERIALIZED_NAME_START_INCLUSIVE) + private Boolean startInclusive; + + public static final String SERIALIZED_NAME_END_INCLUSIVE = "endInclusive"; + @SerializedName(SERIALIZED_NAME_END_INCLUSIVE) + private Boolean endInclusive; + + public static final String SERIALIZED_NAME_TIMEZONE_INSENSITIVE = "timezoneInsensitive"; + @SerializedName(SERIALIZED_NAME_TIMEZONE_INSENSITIVE) + private Boolean timezoneInsensitive; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private Object values; + + public static final String SERIALIZED_NAME_COUNT = "count"; + @SerializedName(SERIALIZED_NAME_COUNT) + private Object count; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckAttributeBlockBase type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckAttributeBlockBase operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The comparison operator applied to the attribute. + * @return operator + **/ + @ApiModelProperty(example = "greaterThan", required = true, value = "The comparison operator applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckAttributeBlockBase attribute(Object attribute) { + + this.attribute = attribute; + return this; + } + + /** + * The attribute path identifier (e.g. \"$Session.Total\"). + * @return attribute + **/ + @ApiModelProperty(example = "$Session.Total", required = true, value = "The attribute path identifier (e.g. \"$Session.Total\").") + + public Object getAttribute() { + return attribute; + } + + + public void setAttribute(Object attribute) { + this.attribute = attribute; + } + + + public CheckAttributeBlockBase value(Object value) { + + this.value = value; + return this; + } + + /** + * The comparison value for scalar operators. + * @return value + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "The comparison value for scalar operators.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public CheckAttributeBlockBase min(Object min) { + + this.min = min; + return this; + } + + /** + * The minimum value allowed for the `between` operator. + * @return min + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "10", value = "The minimum value allowed for the `between` operator.") + + public Object getMin() { + return min; + } + + + public void setMin(Object min) { + this.min = min; + } + + + public CheckAttributeBlockBase max(Object max) { + + this.max = max; + return this; + } + + /** + * The maximum value allowed for the `between` operator. + * @return max + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "The maximum value allowed for the `between` operator.") + + public Object getMax() { + return max; + } + + + public void setMax(Object max) { + this.max = max; + } + + + public CheckAttributeBlockBase start(Object start) { + + this.start = start; + return this; + } + + /** + * The start value for the `within` operator. + * @return start + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00:00Z", value = "The start value for the `within` operator.") + + public Object getStart() { + return start; + } + + + public void setStart(Object start) { + this.start = start; + } + + + public CheckAttributeBlockBase end(Object end) { + + this.end = end; + return this; + } + + /** + * The end value for the `within` operator. + * @return end + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00:00Z", value = "The end value for the `within` operator.") + + public Object getEnd() { + return end; + } + + + public void setEnd(Object end) { + this.end = end; + } + + + public CheckAttributeBlockBase startInclusive(Boolean startInclusive) { + + this.startInclusive = startInclusive; + return this; + } + + /** + * When `true`, the `start` value is included in the range for the `within` operator. + * @return startInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `start` value is included in the range for the `within` operator.") + + public Boolean getStartInclusive() { + return startInclusive; + } + + + public void setStartInclusive(Boolean startInclusive) { + this.startInclusive = startInclusive; + } + + + public CheckAttributeBlockBase endInclusive(Boolean endInclusive) { + + this.endInclusive = endInclusive; + return this; + } + + /** + * When `true`, the `end` value is included in the range for the `within` operator. + * @return endInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `end` value is included in the range for the `within` operator.") + + public Boolean getEndInclusive() { + return endInclusive; + } + + + public void setEndInclusive(Boolean endInclusive) { + this.endInclusive = endInclusive; + } + + + public CheckAttributeBlockBase timezoneInsensitive(Boolean timezoneInsensitive) { + + this.timezoneInsensitive = timezoneInsensitive; + return this; + } + + /** + * Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. + * @return timezoneInsensitive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account.") + + public Boolean getTimezoneInsensitive() { + return timezoneInsensitive; + } + + + public void setTimezoneInsensitive(Boolean timezoneInsensitive) { + this.timezoneInsensitive = timezoneInsensitive; + } + + + public CheckAttributeBlockBase values(Object values) { + + this.values = values; + return this; + } + + /** + * The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute. + * @return values + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "", value = "The set of values to match against for list operators. For location operators (`in`, `not(in)`), an array of objects with a `geometry` (see `GeoJSONGeometry`) and an optional `name`, or a string reference to a list attribute.") + + public Object getValues() { + return values; + } + + + public void setValues(Object values) { + this.values = values; + } + + + public CheckAttributeBlockBase count(Object count) { + + this.count = count; + return this; + } + + /** + * The count threshold for `containsAtLeast` and `containsExactly` operators. + * @return count + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2", value = "The count threshold for `containsAtLeast` and `containsExactly` operators.") + + public Object getCount() { + return count; + } + + + public void setCount(Object count) { + this.count = count; + } + + + public CheckAttributeBlockBase onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckAttributeBlockBase addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAttributeBlockBase checkAttributeBlockBase = (CheckAttributeBlockBase) o; + return Objects.equals(this.id, checkAttributeBlockBase.id) && + Objects.equals(this.type, checkAttributeBlockBase.type) && + Objects.equals(this.tags, checkAttributeBlockBase.tags) && + Objects.equals(this.operator, checkAttributeBlockBase.operator) && + Objects.equals(this.attribute, checkAttributeBlockBase.attribute) && + Objects.equals(this.value, checkAttributeBlockBase.value) && + Objects.equals(this.min, checkAttributeBlockBase.min) && + Objects.equals(this.max, checkAttributeBlockBase.max) && + Objects.equals(this.start, checkAttributeBlockBase.start) && + Objects.equals(this.end, checkAttributeBlockBase.end) && + Objects.equals(this.startInclusive, checkAttributeBlockBase.startInclusive) && + Objects.equals(this.endInclusive, checkAttributeBlockBase.endInclusive) && + Objects.equals(this.timezoneInsensitive, checkAttributeBlockBase.timezoneInsensitive) && + Objects.equals(this.values, checkAttributeBlockBase.values) && + Objects.equals(this.count, checkAttributeBlockBase.count) && + Objects.equals(this.onFailure, checkAttributeBlockBase.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, attribute, value, min, max, start, end, startInclusive, endInclusive, timezoneInsensitive, values, count, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAttributeBlockBase {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" min: ").append(toIndentedString(min)).append("\n"); + sb.append(" max: ").append(toIndentedString(max)).append("\n"); + sb.append(" start: ").append(toIndentedString(start)).append("\n"); + sb.append(" end: ").append(toIndentedString(end)).append("\n"); + sb.append(" startInclusive: ").append(toIndentedString(startInclusive)).append("\n"); + sb.append(" endInclusive: ").append(toIndentedString(endInclusive)).append("\n"); + sb.append(" timezoneInsensitive: ").append(toIndentedString(timezoneInsensitive)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append(" count: ").append(toIndentedString(count)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckAudienceBlock.java b/src/main/java/one/talon/model/CheckAudienceBlock.java new file mode 100644 index 00000000..99429007 --- /dev/null +++ b/src/main/java/one/talon/model/CheckAudienceBlock.java @@ -0,0 +1,361 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckAudienceBlockAudience; + +/** + * A block that checks whether a given customer profile is a member of an audience. + */ +@ApiModel(description = "A block that checks whether a given customer profile is a member of an audience.") + +public class CheckAudienceBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * An indicator of how the block compares its elements. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + MEMBER("member"), + + NOT_MEMBER_("not(member)"), + + JUSTJOINED("justJoined"), + + JUSTLEFT("justLeft"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + /** + * The customer profile to check against the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + */ + @JsonAdapter(ProfileEnum.Adapter.class) + public enum ProfileEnum { + CURRENT("Current"), + + ADVOCATE("Advocate"); + + private String value; + + ProfileEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ProfileEnum fromValue(String value) { + for (ProfileEnum b : ProfileEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ProfileEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ProfileEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ProfileEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_PROFILE = "profile"; + @SerializedName(SERIALIZED_NAME_PROFILE) + private ProfileEnum profile; + + public static final String SERIALIZED_NAME_AUDIENCE = "audience"; + @SerializedName(SERIALIZED_NAME_AUDIENCE) + private CheckAudienceBlockAudience audience; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckAudienceBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckAudienceBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * An indicator of how the block compares its elements. + * @return operator + **/ + @ApiModelProperty(example = "member", required = true, value = "An indicator of how the block compares its elements.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckAudienceBlock profile(ProfileEnum profile) { + + this.profile = profile; + return this; + } + + /** + * The customer profile to check against the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + * @return profile + **/ + @ApiModelProperty(example = "Current", required = true, value = "The customer profile to check against the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program.") + + public ProfileEnum getProfile() { + return profile; + } + + + public void setProfile(ProfileEnum profile) { + this.profile = profile; + } + + + public CheckAudienceBlock audience(CheckAudienceBlockAudience audience) { + + this.audience = audience; + return this; + } + + /** + * Get audience + * @return audience + **/ + @ApiModelProperty(required = true, value = "") + + public CheckAudienceBlockAudience getAudience() { + return audience; + } + + + public void setAudience(CheckAudienceBlockAudience audience) { + this.audience = audience; + } + + + public CheckAudienceBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckAudienceBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAudienceBlock checkAudienceBlock = (CheckAudienceBlock) o; + return Objects.equals(this.id, checkAudienceBlock.id) && + Objects.equals(this.type, checkAudienceBlock.type) && + Objects.equals(this.tags, checkAudienceBlock.tags) && + Objects.equals(this.operator, checkAudienceBlock.operator) && + Objects.equals(this.profile, checkAudienceBlock.profile) && + Objects.equals(this.audience, checkAudienceBlock.audience) && + Objects.equals(this.onFailure, checkAudienceBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, profile, audience, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAudienceBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" profile: ").append(toIndentedString(profile)).append("\n"); + sb.append(" audience: ").append(toIndentedString(audience)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckAudienceBlockAudience.java b/src/main/java/one/talon/model/CheckAudienceBlockAudience.java new file mode 100644 index 00000000..58bafe12 --- /dev/null +++ b/src/main/java/one/talon/model/CheckAudienceBlockAudience.java @@ -0,0 +1,185 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The audience to check the profile against. + */ +@ApiModel(description = "The audience to check the profile against.") + +public class CheckAudienceBlockAudience { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_INTEGRATION = "integration"; + @SerializedName(SERIALIZED_NAME_INTEGRATION) + private String integration; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + + public CheckAudienceBlockAudience id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the audience. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the audience.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CheckAudienceBlockAudience name(String name) { + + this.name = name; + return this; + } + + /** + * The display name of the audience. + * @return name + **/ + @ApiModelProperty(example = "Travel audience", required = true, value = "The display name of the audience.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CheckAudienceBlockAudience integration(String integration) { + + this.integration = integration; + return this; + } + + /** + * The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. + * @return integration + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "mparticle", value = "The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. ") + + public String getIntegration() { + return integration; + } + + + public void setIntegration(String integration) { + this.integration = integration; + } + + + public CheckAudienceBlockAudience integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. + * @return integrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "382370BKDB946", value = "The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckAudienceBlockAudience checkAudienceBlockAudience = (CheckAudienceBlockAudience) o; + return Objects.equals(this.id, checkAudienceBlockAudience.id) && + Objects.equals(this.name, checkAudienceBlockAudience.name) && + Objects.equals(this.integration, checkAudienceBlockAudience.integration) && + Objects.equals(this.integrationId, checkAudienceBlockAudience.integrationId); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, integration, integrationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckAudienceBlockAudience {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" integration: ").append(toIndentedString(integration)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckBudgetBlock.java b/src/main/java/one/talon/model/CheckBudgetBlock.java new file mode 100644 index 00000000..49d40c9b --- /dev/null +++ b/src/main/java/one/talon/model/CheckBudgetBlock.java @@ -0,0 +1,382 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that verifies if a specific budget has sufficient limit available, and whether this limit meets or exceeds a specific value. + */ +@ApiModel(description = "A block that verifies if a specific budget has sufficient limit available, and whether this limit meets or exceeds a specific value.") + +public class CheckBudgetBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The comparison operator applied to the limit. `available` checks if there is budget available for a given limitable action; `enoughFor` checks if the available budget meets or exceeds a specific value limit. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + AVAILABLE("available"), + + ENOUGHFOR("enoughFor"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + /** + * The limitable action to check. + */ + @JsonAdapter(ActionEnum.Adapter.class) + public enum ActionEnum { + REDEEMCOUPON("redeemCoupon"), + + REDEEMREFERRAL("redeemReferral"), + + SETDISCOUNT("setDiscount"), + + CREATECOUPON("createCoupon"), + + CREATEREFERRAL("createReferral"), + + SETDISCOUNTEFFECT("setDiscountEffect"), + + CREATELOYALTYPOINTS("createLoyaltyPoints"), + + CREATELOYALTYPOINTSEFFECT("createLoyaltyPointsEffect"), + + REDEEMLOYALTYPOINTS("redeemLoyaltyPoints"), + + REDEEMLOYALTYPOINTSEFFECT("redeemLoyaltyPointsEffect"), + + AWARDGIVEAWAY("awardGiveaway"), + + ADDFREEITEMEFFECT("addFreeItemEffect"), + + CUSTOMEFFECT("customEffect"), + + CALLAPI("callApi"); + + private String value; + + ActionEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActionEnum fromValue(String value) { + for (ActionEnum b : ActionEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActionEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActionEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActionEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTION = "action"; + @SerializedName(SERIALIZED_NAME_ACTION) + private ActionEnum action; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private BigDecimal value; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckBudgetBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckBudgetBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The comparison operator applied to the limit. `available` checks if there is budget available for a given limitable action; `enoughFor` checks if the available budget meets or exceeds a specific value limit. + * @return operator + **/ + @ApiModelProperty(example = "available", required = true, value = "The comparison operator applied to the limit. `available` checks if there is budget available for a given limitable action; `enoughFor` checks if the available budget meets or exceeds a specific value limit.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckBudgetBlock action(ActionEnum action) { + + this.action = action; + return this; + } + + /** + * The limitable action to check. + * @return action + **/ + @ApiModelProperty(example = "setDiscount", required = true, value = "The limitable action to check.") + + public ActionEnum getAction() { + return action; + } + + + public void setAction(ActionEnum action) { + this.action = action; + } + + + public CheckBudgetBlock value(BigDecimal value) { + + this.value = value; + return this; + } + + /** + * The value to check against when using the `enoughFor` operator. + * @return value + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "5.0", value = "The value to check against when using the `enoughFor` operator.") + + public BigDecimal getValue() { + return value; + } + + + public void setValue(BigDecimal value) { + this.value = value; + } + + + public CheckBudgetBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckBudgetBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckBudgetBlock checkBudgetBlock = (CheckBudgetBlock) o; + return Objects.equals(this.id, checkBudgetBlock.id) && + Objects.equals(this.type, checkBudgetBlock.type) && + Objects.equals(this.tags, checkBudgetBlock.tags) && + Objects.equals(this.operator, checkBudgetBlock.operator) && + Objects.equals(this.action, checkBudgetBlock.action) && + Objects.equals(this.value, checkBudgetBlock.value) && + Objects.equals(this.onFailure, checkBudgetBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, action, value, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckBudgetBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" action: ").append(toIndentedString(action)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckCouponBlock.java b/src/main/java/one/talon/model/CheckCouponBlock.java new file mode 100644 index 00000000..d8b4d590 --- /dev/null +++ b/src/main/java/one/talon/model/CheckCouponBlock.java @@ -0,0 +1,206 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that validates the coupon code value and date. + */ +@ApiModel(description = "A block that validates the coupon code value and date.") + +public class CheckCouponBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_REDEEM = "redeem"; + @SerializedName(SERIALIZED_NAME_REDEEM) + private Boolean redeem; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckCouponBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckCouponBlock redeem(Boolean redeem) { + + this.redeem = redeem; + return this; + } + + /** + * When `true`, the coupon code is redeemed. + * @return redeem + **/ + @ApiModelProperty(example = "true", required = true, value = "When `true`, the coupon code is redeemed.") + + public Boolean getRedeem() { + return redeem; + } + + + public void setRedeem(Boolean redeem) { + this.redeem = redeem; + } + + + public CheckCouponBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckCouponBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckCouponBlock checkCouponBlock = (CheckCouponBlock) o; + return Objects.equals(this.id, checkCouponBlock.id) && + Objects.equals(this.type, checkCouponBlock.type) && + Objects.equals(this.tags, checkCouponBlock.tags) && + Objects.equals(this.redeem, checkCouponBlock.redeem) && + Objects.equals(this.onFailure, checkCouponBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, redeem, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckCouponBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" redeem: ").append(toIndentedString(redeem)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckEventBlock.java b/src/main/java/one/talon/model/CheckEventBlock.java new file mode 100644 index 00000000..47a1ee8a --- /dev/null +++ b/src/main/java/one/talon/model/CheckEventBlock.java @@ -0,0 +1,243 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that validates the event type. + */ +@ApiModel(description = "A block that validates the event type.") + +public class CheckEventBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_EVENT_TYPE = "eventType"; + @SerializedName(SERIALIZED_NAME_EVENT_TYPE) + private String eventType; + + public static final String SERIALIZED_NAME_MATCHERS = "matchers"; + @SerializedName(SERIALIZED_NAME_MATCHERS) + private List matchers = null; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckEventBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckEventBlock eventType(String eventType) { + + this.eventType = eventType; + return this; + } + + /** + * The event type to check against. + * @return eventType + **/ + @ApiModelProperty(example = "profileCreated", required = true, value = "The event type to check against.") + + public String getEventType() { + return eventType; + } + + + public void setEventType(String eventType) { + this.eventType = eventType; + } + + + public CheckEventBlock matchers(List matchers) { + + this.matchers = matchers; + return this; + } + + public CheckEventBlock addMatchersItem(Object matchersItem) { + if (this.matchers == null) { + this.matchers = new ArrayList(); + } + this.matchers.add(matchersItem); + return this; + } + + /** + * Get matchers + * @return matchers + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public List getMatchers() { + return matchers; + } + + + public void setMatchers(List matchers) { + this.matchers = matchers; + } + + + public CheckEventBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckEventBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckEventBlock checkEventBlock = (CheckEventBlock) o; + return Objects.equals(this.id, checkEventBlock.id) && + Objects.equals(this.type, checkEventBlock.type) && + Objects.equals(this.tags, checkEventBlock.tags) && + Objects.equals(this.eventType, checkEventBlock.eventType) && + Objects.equals(this.matchers, checkEventBlock.matchers) && + Objects.equals(this.onFailure, checkEventBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, eventType, matchers, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckEventBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" eventType: ").append(toIndentedString(eventType)).append("\n"); + sb.append(" matchers: ").append(toIndentedString(matchers)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckLoyaltyBalanceBlock.java b/src/main/java/one/talon/model/CheckLoyaltyBalanceBlock.java new file mode 100644 index 00000000..13e92f98 --- /dev/null +++ b/src/main/java/one/talon/model/CheckLoyaltyBalanceBlock.java @@ -0,0 +1,426 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckLoyaltyBalanceBlockProgram; + +/** + * A block that checks a specific loyalty program's ledger or subledger balance against a numeric value. + */ +@ApiModel(description = "A block that checks a specific loyalty program's ledger or subledger balance against a numeric value.") + +public class CheckLoyaltyBalanceBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * An indicator of how the block compares the balance to the value. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + EQUALS("equals"), + + NOT_EQUALS_("not(equals)"), + + LESSTHAN("lessThan"), + + LESSTHANOREQUAL("lessThanOrEqual"), + + GREATERTHAN("greaterThan"), + + GREATERTHANOREQUAL("greaterThanOrEqual"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_PROGRAM = "program"; + @SerializedName(SERIALIZED_NAME_PROGRAM) + private CheckLoyaltyBalanceBlockProgram program; + + public static final String SERIALIZED_NAME_SUBLEDGER = "subledger"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER) + private String subledger; + + /** + * The type of balance to check: - `current` is the sum of currently active points - `pending` is the sum of pending points. - `negative` is the sum of negative points. - `tentativeCurrent` is the tentative points balance within the current open customer session. + */ + @JsonAdapter(BalanceEnum.Adapter.class) + public enum BalanceEnum { + CURRENT("current"), + + PENDING("pending"), + + NEGATIVE("negative"), + + TENTATIVECURRENT("tentativeCurrent"); + + private String value; + + BalanceEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static BalanceEnum fromValue(String value) { + for (BalanceEnum b : BalanceEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final BalanceEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public BalanceEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return BalanceEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_BALANCE = "balance"; + @SerializedName(SERIALIZED_NAME_BALANCE) + private BalanceEnum balance; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private BigDecimal value; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckLoyaltyBalanceBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckLoyaltyBalanceBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * An indicator of how the block compares the balance to the value. + * @return operator + **/ + @ApiModelProperty(example = "greaterThanOrEqual", required = true, value = "An indicator of how the block compares the balance to the value.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckLoyaltyBalanceBlock program(CheckLoyaltyBalanceBlockProgram program) { + + this.program = program; + return this; + } + + /** + * Get program + * @return program + **/ + @ApiModelProperty(required = true, value = "") + + public CheckLoyaltyBalanceBlockProgram getProgram() { + return program; + } + + + public void setProgram(CheckLoyaltyBalanceBlockProgram program) { + this.program = program; + } + + + public CheckLoyaltyBalanceBlock subledger(String subledger) { + + this.subledger = subledger; + return this; + } + + /** + * The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger. + * @return subledger + **/ + @ApiModelProperty(example = "", required = true, value = "The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger.") + + public String getSubledger() { + return subledger; + } + + + public void setSubledger(String subledger) { + this.subledger = subledger; + } + + + public CheckLoyaltyBalanceBlock balance(BalanceEnum balance) { + + this.balance = balance; + return this; + } + + /** + * The type of balance to check: - `current` is the sum of currently active points - `pending` is the sum of pending points. - `negative` is the sum of negative points. - `tentativeCurrent` is the tentative points balance within the current open customer session. + * @return balance + **/ + @ApiModelProperty(example = "current", required = true, value = "The type of balance to check: - `current` is the sum of currently active points - `pending` is the sum of pending points. - `negative` is the sum of negative points. - `tentativeCurrent` is the tentative points balance within the current open customer session.") + + public BalanceEnum getBalance() { + return balance; + } + + + public void setBalance(BalanceEnum balance) { + this.balance = balance; + } + + + public CheckLoyaltyBalanceBlock value(BigDecimal value) { + + this.value = value; + return this; + } + + /** + * The numeric value to compare the balance against. + * @return value + **/ + @ApiModelProperty(example = "500.0", required = true, value = "The numeric value to compare the balance against.") + + public BigDecimal getValue() { + return value; + } + + + public void setValue(BigDecimal value) { + this.value = value; + } + + + public CheckLoyaltyBalanceBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckLoyaltyBalanceBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckLoyaltyBalanceBlock checkLoyaltyBalanceBlock = (CheckLoyaltyBalanceBlock) o; + return Objects.equals(this.id, checkLoyaltyBalanceBlock.id) && + Objects.equals(this.type, checkLoyaltyBalanceBlock.type) && + Objects.equals(this.tags, checkLoyaltyBalanceBlock.tags) && + Objects.equals(this.operator, checkLoyaltyBalanceBlock.operator) && + Objects.equals(this.program, checkLoyaltyBalanceBlock.program) && + Objects.equals(this.subledger, checkLoyaltyBalanceBlock.subledger) && + Objects.equals(this.balance, checkLoyaltyBalanceBlock.balance) && + Objects.equals(this.value, checkLoyaltyBalanceBlock.value) && + Objects.equals(this.onFailure, checkLoyaltyBalanceBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, program, subledger, balance, value, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckLoyaltyBalanceBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" program: ").append(toIndentedString(program)).append("\n"); + sb.append(" subledger: ").append(toIndentedString(subledger)).append("\n"); + sb.append(" balance: ").append(toIndentedString(balance)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckLoyaltyBalanceBlockProgram.java b/src/main/java/one/talon/model/CheckLoyaltyBalanceBlockProgram.java new file mode 100644 index 00000000..82268576 --- /dev/null +++ b/src/main/java/one/talon/model/CheckLoyaltyBalanceBlockProgram.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The loyalty program whose ledger balance is checked. + */ +@ApiModel(description = "The loyalty program whose ledger balance is checked.") + +public class CheckLoyaltyBalanceBlockProgram { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + + public CheckLoyaltyBalanceBlockProgram id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the loyalty program. + * @return id + **/ + @ApiModelProperty(example = "10", required = true, value = "The ID of the loyalty program.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CheckLoyaltyBalanceBlockProgram name(String name) { + + this.name = name; + return this; + } + + /** + * The internal name of the loyalty program. + * @return name + **/ + @ApiModelProperty(example = "MainProgram", required = true, value = "The internal name of the loyalty program.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CheckLoyaltyBalanceBlockProgram title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the loyalty program. + * @return title + **/ + @ApiModelProperty(example = "Main Loyalty Program", required = true, value = "The display name of the loyalty program.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckLoyaltyBalanceBlockProgram checkLoyaltyBalanceBlockProgram = (CheckLoyaltyBalanceBlockProgram) o; + return Objects.equals(this.id, checkLoyaltyBalanceBlockProgram.id) && + Objects.equals(this.name, checkLoyaltyBalanceBlockProgram.name) && + Objects.equals(this.title, checkLoyaltyBalanceBlockProgram.title); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckLoyaltyBalanceBlockProgram {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckLoyaltyCardBlock.java b/src/main/java/one/talon/model/CheckLoyaltyCardBlock.java new file mode 100644 index 00000000..a045bfd5 --- /dev/null +++ b/src/main/java/one/talon/model/CheckLoyaltyCardBlock.java @@ -0,0 +1,253 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that verifies whether a loyalty card is linked to the user's profile. + */ +@ApiModel(description = "A block that verifies whether a loyalty card is linked to the user's profile.") + +public class CheckLoyaltyCardBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * An indicator of how the block compares its elements. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + LINKED("linked"), + + NOT_LINKED_("not(linked)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckLoyaltyCardBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckLoyaltyCardBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * An indicator of how the block compares its elements. + * @return operator + **/ + @ApiModelProperty(required = true, value = "An indicator of how the block compares its elements.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckLoyaltyCardBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckLoyaltyCardBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckLoyaltyCardBlock checkLoyaltyCardBlock = (CheckLoyaltyCardBlock) o; + return Objects.equals(this.id, checkLoyaltyCardBlock.id) && + Objects.equals(this.type, checkLoyaltyCardBlock.type) && + Objects.equals(this.tags, checkLoyaltyCardBlock.tags) && + Objects.equals(this.operator, checkLoyaltyCardBlock.operator) && + Objects.equals(this.onFailure, checkLoyaltyCardBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckLoyaltyCardBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckReferralBlock.java b/src/main/java/one/talon/model/CheckReferralBlock.java new file mode 100644 index 00000000..70e118e6 --- /dev/null +++ b/src/main/java/one/talon/model/CheckReferralBlock.java @@ -0,0 +1,206 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that validates the referral code value and date. + */ +@ApiModel(description = "A block that validates the referral code value and date.") + +public class CheckReferralBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_REDEEM = "redeem"; + @SerializedName(SERIALIZED_NAME_REDEEM) + private Boolean redeem; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckReferralBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckReferralBlock redeem(Boolean redeem) { + + this.redeem = redeem; + return this; + } + + /** + * When `true`, the referral code is redeemed. + * @return redeem + **/ + @ApiModelProperty(example = "true", required = true, value = "When `true`, the referral code is redeemed.") + + public Boolean getRedeem() { + return redeem; + } + + + public void setRedeem(Boolean redeem) { + this.redeem = redeem; + } + + + public CheckReferralBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckReferralBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckReferralBlock checkReferralBlock = (CheckReferralBlock) o; + return Objects.equals(this.id, checkReferralBlock.id) && + Objects.equals(this.type, checkReferralBlock.type) && + Objects.equals(this.tags, checkReferralBlock.tags) && + Objects.equals(this.redeem, checkReferralBlock.redeem) && + Objects.equals(this.onFailure, checkReferralBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, redeem, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckReferralBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" redeem: ").append(toIndentedString(redeem)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckTierBlock.java b/src/main/java/one/talon/model/CheckTierBlock.java new file mode 100644 index 00000000..a6d3a39a --- /dev/null +++ b/src/main/java/one/talon/model/CheckTierBlock.java @@ -0,0 +1,310 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckTierBlockTier; + +/** + * A block that checks whether a user profile is a member of a specific tier within a loyalty program. + */ +@ApiModel(description = "A block that checks whether a user profile is a member of a specific tier within a loyalty program.") + +public class CheckTierBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * An indicator of how the block compares its elements. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + MEMBER("member"), + + NOT_MEMBER_("not(member)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_SUBLEDGER = "subledger"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER) + private String subledger; + + public static final String SERIALIZED_NAME_TIER = "tier"; + @SerializedName(SERIALIZED_NAME_TIER) + private CheckTierBlockTier tier; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CheckTierBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CheckTierBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * An indicator of how the block compares its elements. + * @return operator + **/ + @ApiModelProperty(example = "member", required = true, value = "An indicator of how the block compares its elements.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public CheckTierBlock subledger(String subledger) { + + this.subledger = subledger; + return this; + } + + /** + * The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger. + * @return subledger + **/ + @ApiModelProperty(example = "", required = true, value = "The name of the subledger to check the balance of. Can be empty if this block checks the loyalty program's main ledger balance instead of a subledger.") + + public String getSubledger() { + return subledger; + } + + + public void setSubledger(String subledger) { + this.subledger = subledger; + } + + + public CheckTierBlock tier(CheckTierBlockTier tier) { + + this.tier = tier; + return this; + } + + /** + * Get tier + * @return tier + **/ + @ApiModelProperty(required = true, value = "") + + public CheckTierBlockTier getTier() { + return tier; + } + + + public void setTier(CheckTierBlockTier tier) { + this.tier = tier; + } + + + public CheckTierBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public CheckTierBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckTierBlock checkTierBlock = (CheckTierBlock) o; + return Objects.equals(this.id, checkTierBlock.id) && + Objects.equals(this.type, checkTierBlock.type) && + Objects.equals(this.tags, checkTierBlock.tags) && + Objects.equals(this.operator, checkTierBlock.operator) && + Objects.equals(this.subledger, checkTierBlock.subledger) && + Objects.equals(this.tier, checkTierBlock.tier) && + Objects.equals(this.onFailure, checkTierBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, subledger, tier, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckTierBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" subledger: ").append(toIndentedString(subledger)).append("\n"); + sb.append(" tier: ").append(toIndentedString(tier)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CheckTierBlockTier.java b/src/main/java/one/talon/model/CheckTierBlockTier.java new file mode 100644 index 00000000..2bbe0fe3 --- /dev/null +++ b/src/main/java/one/talon/model/CheckTierBlockTier.java @@ -0,0 +1,184 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * CheckTierBlockTier + */ + +public class CheckTierBlockTier { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_MIN_POINTS = "minPoints"; + @SerializedName(SERIALIZED_NAME_MIN_POINTS) + private BigDecimal minPoints; + + public static final String SERIALIZED_NAME_UPPER_LIMIT = "upperLimit"; + @SerializedName(SERIALIZED_NAME_UPPER_LIMIT) + private BigDecimal upperLimit; + + + public CheckTierBlockTier id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the tier. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the tier.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CheckTierBlockTier name(String name) { + + this.name = name; + return this; + } + + /** + * The display name of the tier. + * @return name + **/ + @ApiModelProperty(example = "Bronze", required = true, value = "The display name of the tier.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CheckTierBlockTier minPoints(BigDecimal minPoints) { + + this.minPoints = minPoints; + return this; + } + + /** + * The minimum amount of points required to enter the tier. + * @return minPoints + **/ + @ApiModelProperty(example = "150.0", required = true, value = "The minimum amount of points required to enter the tier.") + + public BigDecimal getMinPoints() { + return minPoints; + } + + + public void setMinPoints(BigDecimal minPoints) { + this.minPoints = minPoints; + } + + + public CheckTierBlockTier upperLimit(BigDecimal upperLimit) { + + this.upperLimit = upperLimit; + return this; + } + + /** + * Get upperLimit + * @return upperLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public BigDecimal getUpperLimit() { + return upperLimit; + } + + + public void setUpperLimit(BigDecimal upperLimit) { + this.upperLimit = upperLimit; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CheckTierBlockTier checkTierBlockTier = (CheckTierBlockTier) o; + return Objects.equals(this.id, checkTierBlockTier.id) && + Objects.equals(this.name, checkTierBlockTier.name) && + Objects.equals(this.minPoints, checkTierBlockTier.minPoints) && + Objects.equals(this.upperLimit, checkTierBlockTier.upperLimit); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, minPoints, upperLimit); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CheckTierBlockTier {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" minPoints: ").append(toIndentedString(minPoints)).append("\n"); + sb.append(" upperLimit: ").append(toIndentedString(upperLimit)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ConfirmRisksRequest.java b/src/main/java/one/talon/model/ConfirmRisksRequest.java new file mode 100644 index 00000000..b832f8c0 --- /dev/null +++ b/src/main/java/one/talon/model/ConfirmRisksRequest.java @@ -0,0 +1,133 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * ConfirmRisksRequest + */ + +public class ConfirmRisksRequest { + public static final String SERIALIZED_NAME_RISK_IDS = "riskIds"; + @SerializedName(SERIALIZED_NAME_RISK_IDS) + private List riskIds = new ArrayList(); + + public static final String SERIALIZED_NAME_COMMENT = "comment"; + @SerializedName(SERIALIZED_NAME_COMMENT) + private String comment; + + + public ConfirmRisksRequest riskIds(List riskIds) { + + this.riskIds = riskIds; + return this; + } + + public ConfirmRisksRequest addRiskIdsItem(Long riskIdsItem) { + this.riskIds.add(riskIdsItem); + return this; + } + + /** + * The IDs of the risks to confirm. + * @return riskIds + **/ + @ApiModelProperty(example = "[1, 2, 3]", required = true, value = "The IDs of the risks to confirm.") + + public List getRiskIds() { + return riskIds; + } + + + public void setRiskIds(List riskIds) { + this.riskIds = riskIds; + } + + + public ConfirmRisksRequest comment(String comment) { + + this.comment = comment; + return this; + } + + /** + * Free-text description of how the risk was resolved. + * @return comment + **/ + @ApiModelProperty(example = "Investigated with the customer and fixed the loyalty rule.", required = true, value = "Free-text description of how the risk was resolved.") + + public String getComment() { + return comment; + } + + + public void setComment(String comment) { + this.comment = comment; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ConfirmRisksRequest confirmRisksRequest = (ConfirmRisksRequest) o; + return Objects.equals(this.riskIds, confirmRisksRequest.riskIds) && + Objects.equals(this.comment, confirmRisksRequest.comment); + } + + @Override + public int hashCode() { + return Objects.hash(riskIds, comment); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ConfirmRisksRequest {\n"); + sb.append(" riskIds: ").append(toIndentedString(riskIds)).append("\n"); + sb.append(" comment: ").append(toIndentedString(comment)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CouponCreatedEffectProps.java b/src/main/java/one/talon/model/CouponCreatedEffectProps.java index d18a55c8..d1da08df 100644 --- a/src/main/java/one/talon/model/CouponCreatedEffectProps.java +++ b/src/main/java/one/talon/model/CouponCreatedEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"couponCreated\" effect. This gets triggered whenever a validated rule contained a \"create coupon\" effect, and a coupon was created for a customer. See \"createdCoupons\" on the response for all details of this coupon. + * This effect indicates that a coupon was created. For referrals and retention marketing, a common use case is to generate a coupon that can only be redeemed by one specific customer. Handle this effect by notifying the recipient about their new coupon code. */ -@ApiModel(description = "The properties specific to the \"couponCreated\" effect. This gets triggered whenever a validated rule contained a \"create coupon\" effect, and a coupon was created for a customer. See \"createdCoupons\" on the response for all details of this coupon.") +@ApiModel(description = "This effect indicates that a coupon was created. For referrals and retention marketing, a common use case is to generate a coupon that can only be redeemed by one specific customer. Handle this effect by notifying the recipient about their new coupon code.") public class CouponCreatedEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; diff --git a/src/main/java/one/talon/model/CouponEligibilityInfo.java b/src/main/java/one/talon/model/CouponEligibilityInfo.java new file mode 100644 index 00000000..0e7a5fd4 --- /dev/null +++ b/src/main/java/one/talon/model/CouponEligibilityInfo.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * CouponEligibilityInfo + */ + +public class CouponEligibilityInfo { + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_CAMPAIGN_NAME = "campaignName"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_NAME) + private String campaignName; + + public static final String SERIALIZED_NAME_FAILURE_REASON = "failureReason"; + @SerializedName(SERIALIZED_NAME_FAILURE_REASON) + private String failureReason; + + + public CouponEligibilityInfo campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * The ID of the campaign that owns the coupon. + * @return campaignId + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the campaign that owns the coupon.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public CouponEligibilityInfo campaignName(String campaignName) { + + this.campaignName = campaignName; + return this; + } + + /** + * The name of the campaign that owns the coupon. + * @return campaignName + **/ + @ApiModelProperty(example = "Summer Sale 2026", required = true, value = "The name of the campaign that owns the coupon.") + + public String getCampaignName() { + return campaignName; + } + + + public void setCampaignName(String campaignName) { + this.campaignName = campaignName; + } + + + public CouponEligibilityInfo failureReason(String failureReason) { + + this.failureReason = failureReason; + return this; + } + + /** + * The reason the coupon is not eligible, if applicable. + * @return failureReason + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Coupon has expired", value = "The reason the coupon is not eligible, if applicable.") + + public String getFailureReason() { + return failureReason; + } + + + public void setFailureReason(String failureReason) { + this.failureReason = failureReason; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CouponEligibilityInfo couponEligibilityInfo = (CouponEligibilityInfo) o; + return Objects.equals(this.campaignId, couponEligibilityInfo.campaignId) && + Objects.equals(this.campaignName, couponEligibilityInfo.campaignName) && + Objects.equals(this.failureReason, couponEligibilityInfo.failureReason); + } + + @Override + public int hashCode() { + return Objects.hash(campaignId, campaignName, failureReason); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CouponEligibilityInfo {\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" campaignName: ").append(toIndentedString(campaignName)).append("\n"); + sb.append(" failureReason: ").append(toIndentedString(failureReason)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CreateAchievementV2.java b/src/main/java/one/talon/model/CreateAchievementV2.java index 06be65aa..2719eb25 100644 --- a/src/main/java/one/talon/model/CreateAchievementV2.java +++ b/src/main/java/one/talon/model/CreateAchievementV2.java @@ -169,14 +169,14 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION) private Boolean allowRollbackAfterCompletion; - public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; - @SerializedName(SERIALIZED_NAME_SANDBOX) - private Boolean sandbox; - public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS = "subscribedApplications"; @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS) private List subscribedApplications = null; + public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; + @SerializedName(SERIALIZED_NAME_SANDBOX) + private Boolean sandbox; + public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; @SerializedName(SERIALIZED_NAME_TIMEZONE) private String timezone; @@ -408,28 +408,6 @@ public void setAllowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion } - public CreateAchievementV2 sandbox(Boolean sandbox) { - - this.sandbox = sandbox; - return this; - } - - /** - * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. - * @return sandbox - **/ - @ApiModelProperty(example = "true", required = true, value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") - - public Boolean getSandbox() { - return sandbox; - } - - - public void setSandbox(Boolean sandbox) { - this.sandbox = sandbox; - } - - public CreateAchievementV2 subscribedApplications(List subscribedApplications) { this.subscribedApplications = subscribedApplications; @@ -461,6 +439,28 @@ public void setSubscribedApplications(List subscribedApplications) { } + public CreateAchievementV2 sandbox(Boolean sandbox) { + + this.sandbox = sandbox; + return this; + } + + /** + * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. + * @return sandbox + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") + + public Boolean getSandbox() { + return sandbox; + } + + + public void setSandbox(Boolean sandbox) { + this.sandbox = sandbox; + } + + public CreateAchievementV2 timezone(String timezone) { this.timezone = timezone; @@ -502,14 +502,14 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.fixedStartDate, createAchievementV2.fixedStartDate) && Objects.equals(this.endDate, createAchievementV2.endDate) && Objects.equals(this.allowRollbackAfterCompletion, createAchievementV2.allowRollbackAfterCompletion) && - Objects.equals(this.sandbox, createAchievementV2.sandbox) && Objects.equals(this.subscribedApplications, createAchievementV2.subscribedApplications) && + Objects.equals(this.sandbox, createAchievementV2.sandbox) && Objects.equals(this.timezone, createAchievementV2.timezone); } @Override public int hashCode() { - return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, sandbox, subscribedApplications, timezone); + return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, subscribedApplications, sandbox, timezone); } @@ -527,8 +527,8 @@ public String toString() { sb.append(" fixedStartDate: ").append(toIndentedString(fixedStartDate)).append("\n"); sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); - sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" subscribedApplications: ").append(toIndentedString(subscribedApplications)).append("\n"); + sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/CreateCouponBlock.java b/src/main/java/one/talon/model/CreateCouponBlock.java new file mode 100644 index 00000000..d50dfc4e --- /dev/null +++ b/src/main/java/one/talon/model/CreateCouponBlock.java @@ -0,0 +1,428 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that creates a coupon code. + */ +@ApiModel(description = "A block that creates a coupon code.") + +public class CreateCouponBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Object campaignId; + + public static final String SERIALIZED_NAME_RECIPIENT_ID = "recipientId"; + @SerializedName(SERIALIZED_NAME_RECIPIENT_ID) + private String recipientId; + + public static final String SERIALIZED_NAME_STORE_IN_SESSION = "storeInSession"; + @SerializedName(SERIALIZED_NAME_STORE_IN_SESSION) + private Boolean storeInSession; + + public static final String SERIALIZED_NAME_USAGE_LIMIT = "usageLimit"; + @SerializedName(SERIALIZED_NAME_USAGE_LIMIT) + private Object usageLimit; + + public static final String SERIALIZED_NAME_DISCOUNT_LIMIT = "discountLimit"; + @SerializedName(SERIALIZED_NAME_DISCOUNT_LIMIT) + private Object discountLimit; + + public static final String SERIALIZED_NAME_START_DATE = "startDate"; + @SerializedName(SERIALIZED_NAME_START_DATE) + private Object startDate; + + public static final String SERIALIZED_NAME_EXPIRY_DATE = "expiryDate"; + @SerializedName(SERIALIZED_NAME_EXPIRY_DATE) + private Object expiryDate; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + public static final String SERIALIZED_NAME_VALID_CHARACTERS = "validCharacters"; + @SerializedName(SERIALIZED_NAME_VALID_CHARACTERS) + private String validCharacters; + + public static final String SERIALIZED_NAME_PATTERN = "pattern"; + @SerializedName(SERIALIZED_NAME_PATTERN) + private String pattern; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CreateCouponBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CreateCouponBlock campaignId(Object campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * The ID of the campaign in which the coupon code is created. + * @return campaignId + **/ + @ApiModelProperty(required = true, value = "The ID of the campaign in which the coupon code is created.") + + public Object getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Object campaignId) { + this.campaignId = campaignId; + } + + + public CreateCouponBlock recipientId(String recipientId) { + + this.recipientId = recipientId; + return this; + } + + /** + * The integration ID of the customer that is allowed to redeem this coupon. + * @return recipientId + **/ + @ApiModelProperty(example = "{{$Profile.IntegrationId}}", required = true, value = "The integration ID of the customer that is allowed to redeem this coupon.") + + public String getRecipientId() { + return recipientId; + } + + + public void setRecipientId(String recipientId) { + this.recipientId = recipientId; + } + + + public CreateCouponBlock storeInSession(Boolean storeInSession) { + + this.storeInSession = storeInSession; + return this; + } + + /** + * When `true`, the coupon is stored in the session. + * @return storeInSession + **/ + @ApiModelProperty(example = "true", required = true, value = "When `true`, the coupon is stored in the session.") + + public Boolean getStoreInSession() { + return storeInSession; + } + + + public void setStoreInSession(Boolean storeInSession) { + this.storeInSession = storeInSession; + } + + + public CreateCouponBlock usageLimit(Object usageLimit) { + + this.usageLimit = usageLimit; + return this; + } + + /** + * The number of times the coupon code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return usageLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The number of times the coupon code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. ") + + public Object getUsageLimit() { + return usageLimit; + } + + + public void setUsageLimit(Object usageLimit) { + this.usageLimit = usageLimit; + } + + + public CreateCouponBlock discountLimit(Object discountLimit) { + + this.discountLimit = discountLimit; + return this; + } + + /** + * The total discount value that the code can give. Typically used to represent a gift card value. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return discountLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The total discount value that the code can give. Typically used to represent a gift card value. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. ") + + public Object getDiscountLimit() { + return discountLimit; + } + + + public void setDiscountLimit(Object discountLimit) { + this.discountLimit = discountLimit; + } + + + public CreateCouponBlock startDate(Object startDate) { + + this.startDate = startDate; + return this; + } + + /** + * Timestamp at which point the coupon becomes valid. + * @return startDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2024-12-24T14:15:22Z", value = "Timestamp at which point the coupon becomes valid.") + + public Object getStartDate() { + return startDate; + } + + + public void setStartDate(Object startDate) { + this.startDate = startDate; + } + + + public CreateCouponBlock expiryDate(Object expiryDate) { + + this.expiryDate = expiryDate; + return this; + } + + /** + * Expiration date of the coupon. Coupon never expires if this is omitted. + * @return expiryDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2024-12-24T14:15:22Z", value = "Expiration date of the coupon. Coupon never expires if this is omitted.") + + public Object getExpiryDate() { + return expiryDate; + } + + + public void setExpiryDate(Object expiryDate) { + this.expiryDate = expiryDate; + } + + + public CreateCouponBlock attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Custom attributes associated with this coupon code. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Custom attributes associated with this coupon code.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public CreateCouponBlock validCharacters(String validCharacters) { + + this.validCharacters = validCharacters; + return this; + } + + /** + * Characters used to generate the random parts of a code. + * @return validCharacters + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "ABC", value = "Characters used to generate the random parts of a code.") + + public String getValidCharacters() { + return validCharacters; + } + + + public void setValidCharacters(String validCharacters) { + this.validCharacters = validCharacters; + } + + + public CreateCouponBlock pattern(String pattern) { + + this.pattern = pattern; + return this; + } + + /** + * The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + * @return pattern + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "SUMMER-####-####", value = "The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. ") + + public String getPattern() { + return pattern; + } + + + public void setPattern(String pattern) { + this.pattern = pattern; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateCouponBlock createCouponBlock = (CreateCouponBlock) o; + return Objects.equals(this.id, createCouponBlock.id) && + Objects.equals(this.type, createCouponBlock.type) && + Objects.equals(this.tags, createCouponBlock.tags) && + Objects.equals(this.campaignId, createCouponBlock.campaignId) && + Objects.equals(this.recipientId, createCouponBlock.recipientId) && + Objects.equals(this.storeInSession, createCouponBlock.storeInSession) && + Objects.equals(this.usageLimit, createCouponBlock.usageLimit) && + Objects.equals(this.discountLimit, createCouponBlock.discountLimit) && + Objects.equals(this.startDate, createCouponBlock.startDate) && + Objects.equals(this.expiryDate, createCouponBlock.expiryDate) && + Objects.equals(this.attributes, createCouponBlock.attributes) && + Objects.equals(this.validCharacters, createCouponBlock.validCharacters) && + Objects.equals(this.pattern, createCouponBlock.pattern); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, campaignId, recipientId, storeInSession, usageLimit, discountLimit, startDate, expiryDate, attributes, validCharacters, pattern); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateCouponBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" recipientId: ").append(toIndentedString(recipientId)).append("\n"); + sb.append(" storeInSession: ").append(toIndentedString(storeInSession)).append("\n"); + sb.append(" usageLimit: ").append(toIndentedString(usageLimit)).append("\n"); + sb.append(" discountLimit: ").append(toIndentedString(discountLimit)).append("\n"); + sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); + sb.append(" expiryDate: ").append(toIndentedString(expiryDate)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" validCharacters: ").append(toIndentedString(validCharacters)).append("\n"); + sb.append(" pattern: ").append(toIndentedString(pattern)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CreateReferralBlock.java b/src/main/java/one/talon/model/CreateReferralBlock.java new file mode 100644 index 00000000..bba93b15 --- /dev/null +++ b/src/main/java/one/talon/model/CreateReferralBlock.java @@ -0,0 +1,399 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that creates a referral code. + */ +@ApiModel(description = "A block that creates a referral code.") + +public class CreateReferralBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Object campaignId; + + public static final String SERIALIZED_NAME_FRIEND_ID = "friendId"; + @SerializedName(SERIALIZED_NAME_FRIEND_ID) + private String friendId; + + public static final String SERIALIZED_NAME_STORE_IN_SESSION = "storeInSession"; + @SerializedName(SERIALIZED_NAME_STORE_IN_SESSION) + private Boolean storeInSession; + + public static final String SERIALIZED_NAME_USAGE_LIMIT = "usageLimit"; + @SerializedName(SERIALIZED_NAME_USAGE_LIMIT) + private Object usageLimit; + + public static final String SERIALIZED_NAME_START_DATE = "startDate"; + @SerializedName(SERIALIZED_NAME_START_DATE) + private Object startDate; + + public static final String SERIALIZED_NAME_EXPIRY_DATE = "expiryDate"; + @SerializedName(SERIALIZED_NAME_EXPIRY_DATE) + private Object expiryDate; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + public static final String SERIALIZED_NAME_VALID_CHARACTERS = "validCharacters"; + @SerializedName(SERIALIZED_NAME_VALID_CHARACTERS) + private String validCharacters; + + public static final String SERIALIZED_NAME_PATTERN = "pattern"; + @SerializedName(SERIALIZED_NAME_PATTERN) + private String pattern; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public CreateReferralBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public CreateReferralBlock campaignId(Object campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * The ID of the campaign in which the referral code is created. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return campaignId + **/ + @ApiModelProperty(required = true, value = "The ID of the campaign in which the referral code is created. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time.") + + public Object getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Object campaignId) { + this.campaignId = campaignId; + } + + + public CreateReferralBlock friendId(String friendId) { + + this.friendId = friendId; + return this; + } + + /** + * An optional integration ID of the friend's profile. + * @return friendId + **/ + @ApiModelProperty(example = "{{$Profile.IntegrationId}}", required = true, value = "An optional integration ID of the friend's profile.") + + public String getFriendId() { + return friendId; + } + + + public void setFriendId(String friendId) { + this.friendId = friendId; + } + + + public CreateReferralBlock storeInSession(Boolean storeInSession) { + + this.storeInSession = storeInSession; + return this; + } + + /** + * When `true`, the referral code is stored in the session. + * @return storeInSession + **/ + @ApiModelProperty(example = "true", required = true, value = "When `true`, the referral code is stored in the session.") + + public Boolean getStoreInSession() { + return storeInSession; + } + + + public void setStoreInSession(Boolean storeInSession) { + this.storeInSession = storeInSession; + } + + + public CreateReferralBlock usageLimit(Object usageLimit) { + + this.usageLimit = usageLimit; + return this; + } + + /** + * The number of times the referral code code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return usageLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The number of times the referral code code can be redeemed. `0` means unlimited redemptions, but any campaign usage limits still apply. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. ") + + public Object getUsageLimit() { + return usageLimit; + } + + + public void setUsageLimit(Object usageLimit) { + this.usageLimit = usageLimit; + } + + + public CreateReferralBlock startDate(Object startDate) { + + this.startDate = startDate; + return this; + } + + /** + * Timestamp at which point the referral code becomes valid. + * @return startDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2024-12-24T14:15:22Z", value = "Timestamp at which point the referral code becomes valid.") + + public Object getStartDate() { + return startDate; + } + + + public void setStartDate(Object startDate) { + this.startDate = startDate; + } + + + public CreateReferralBlock expiryDate(Object expiryDate) { + + this.expiryDate = expiryDate; + return this; + } + + /** + * Expiration date of the referral code. Referral code never expires if this is omitted. + * @return expiryDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2024-12-24T14:15:22Z", value = "Expiration date of the referral code. Referral code never expires if this is omitted.") + + public Object getExpiryDate() { + return expiryDate; + } + + + public void setExpiryDate(Object expiryDate) { + this.expiryDate = expiryDate; + } + + + public CreateReferralBlock attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Custom attributes associated with this referral code. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Custom attributes associated with this referral code.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public CreateReferralBlock validCharacters(String validCharacters) { + + this.validCharacters = validCharacters; + return this; + } + + /** + * Characters used to generate the random parts of a code. + * @return validCharacters + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "ABC", value = "Characters used to generate the random parts of a code.") + + public String getValidCharacters() { + return validCharacters; + } + + + public void setValidCharacters(String validCharacters) { + this.validCharacters = validCharacters; + } + + + public CreateReferralBlock pattern(String pattern) { + + this.pattern = pattern; + return this; + } + + /** + * The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + * @return pattern + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "SUMMER-####-####", value = "The pattern used to generate codes, such as coupon codes, referral codes, and loyalty cards. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. ") + + public String getPattern() { + return pattern; + } + + + public void setPattern(String pattern) { + this.pattern = pattern; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateReferralBlock createReferralBlock = (CreateReferralBlock) o; + return Objects.equals(this.id, createReferralBlock.id) && + Objects.equals(this.type, createReferralBlock.type) && + Objects.equals(this.tags, createReferralBlock.tags) && + Objects.equals(this.campaignId, createReferralBlock.campaignId) && + Objects.equals(this.friendId, createReferralBlock.friendId) && + Objects.equals(this.storeInSession, createReferralBlock.storeInSession) && + Objects.equals(this.usageLimit, createReferralBlock.usageLimit) && + Objects.equals(this.startDate, createReferralBlock.startDate) && + Objects.equals(this.expiryDate, createReferralBlock.expiryDate) && + Objects.equals(this.attributes, createReferralBlock.attributes) && + Objects.equals(this.validCharacters, createReferralBlock.validCharacters) && + Objects.equals(this.pattern, createReferralBlock.pattern); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, campaignId, friendId, storeInSession, usageLimit, startDate, expiryDate, attributes, validCharacters, pattern); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateReferralBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" friendId: ").append(toIndentedString(friendId)).append("\n"); + sb.append(" storeInSession: ").append(toIndentedString(storeInSession)).append("\n"); + sb.append(" usageLimit: ").append(toIndentedString(usageLimit)).append("\n"); + sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); + sb.append(" expiryDate: ").append(toIndentedString(expiryDate)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" validCharacters: ").append(toIndentedString(validCharacters)).append("\n"); + sb.append(" pattern: ").append(toIndentedString(pattern)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CustomEffectProps.java b/src/main/java/one/talon/model/CustomEffectProps.java index 2352e230..97240961 100644 --- a/src/main/java/one/talon/model/CustomEffectProps.java +++ b/src/main/java/one/talon/model/CustomEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * Effect containing custom payload. + * If you want to return data as an effect but no effect matches your use case, you can [create a custom effect](https://docs.talon.one/docs/dev/tutorials/create-custom-effects). Custom effects can be used as both rule effects and failure effects. The structure of a custom effect depends on your specifications but is always named `customEffect`. */ -@ApiModel(description = "Effect containing custom payload.") +@ApiModel(description = "If you want to return data as an effect but no effect matches your use case, you can [create a custom effect](https://docs.talon.one/docs/dev/tutorials/create-custom-effects). Custom effects can be used as both rule effects and failure effects. The structure of a custom effect depends on your specifications but is always named `customEffect`.") public class CustomEffectProps { public static final String SERIALIZED_NAME_EFFECT_ID = "effectId"; diff --git a/src/main/java/one/talon/model/CustomerAchievement.java b/src/main/java/one/talon/model/CustomerAchievement.java new file mode 100644 index 00000000..c9943ab4 --- /dev/null +++ b/src/main/java/one/talon/model/CustomerAchievement.java @@ -0,0 +1,579 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.AchievementProgress; +import one.talon.model.CampaignReference; +import org.threeten.bp.OffsetDateTime; + +/** + * A customer's progress in an achievement, together with the achievement definition. + */ +@ApiModel(description = "A customer's progress in an achievement, together with the achievement definition.") + +public class CustomerAchievement { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private BigDecimal target; + + /** + * 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. + */ + @JsonAdapter(RecurrencePolicyEnum.Adapter.class) + public enum RecurrencePolicyEnum { + NO_RECURRENCE("no_recurrence"), + + ON_EXPIRATION("on_expiration"), + + ON_COMPLETION("on_completion"); + + private String value; + + RecurrencePolicyEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RecurrencePolicyEnum fromValue(String value) { + for (RecurrencePolicyEnum b : RecurrencePolicyEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RecurrencePolicyEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RecurrencePolicyEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RecurrencePolicyEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_RECURRENCE_POLICY = "recurrencePolicy"; + @SerializedName(SERIALIZED_NAME_RECURRENCE_POLICY) + private RecurrencePolicyEnum recurrencePolicy; + + /** + * 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. + */ + @JsonAdapter(ActivationPolicyEnum.Adapter.class) + public enum ActivationPolicyEnum { + USER_ACTION("user_action"), + + FIXED_SCHEDULE("fixed_schedule"); + + private String value; + + ActivationPolicyEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivationPolicyEnum fromValue(String value) { + for (ActivationPolicyEnum b : ActivationPolicyEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivationPolicyEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivationPolicyEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVATION_POLICY = "activationPolicy"; + @SerializedName(SERIALIZED_NAME_ACTIVATION_POLICY) + private ActivationPolicyEnum activationPolicy; + + public static final String SERIALIZED_NAME_FIXED_START_DATE = "fixedStartDate"; + @SerializedName(SERIALIZED_NAME_FIXED_START_DATE) + private OffsetDateTime fixedStartDate; + + public static final String SERIALIZED_NAME_END_DATE = "endDate"; + @SerializedName(SERIALIZED_NAME_END_DATE) + private OffsetDateTime endDate; + + public static final String SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION = "allowRollbackAfterCompletion"; + @SerializedName(SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION) + private Boolean allowRollbackAfterCompletion; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_CAMPAIGN_IDS = "campaignIds"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_IDS) + private List campaignIds = new ArrayList(); + + public static final String SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS = "referencedByCampaigns"; + @SerializedName(SERIALIZED_NAME_REFERENCED_BY_CAMPAIGNS) + private List referencedByCampaigns = new ArrayList(); + + public static final String SERIALIZED_NAME_CURRENT_PROGRESS = "currentProgress"; + @SerializedName(SERIALIZED_NAME_CURRENT_PROGRESS) + private AchievementProgress currentProgress; + + + public CustomerAchievement id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of the achievement. + * @return id + **/ + @ApiModelProperty(example = "3", required = true, value = "The internal ID of the achievement.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CustomerAchievement name(String name) { + + this.name = name; + return this; + } + + /** + * The internal name of the achievement used in API requests. + * @return name + **/ + @ApiModelProperty(example = "FreeCoffee10Orders", required = true, value = "The internal name of the achievement used in API requests. ") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public CustomerAchievement title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the achievement in the Campaign Manager. + * @return title + **/ + @ApiModelProperty(example = "50% off on 50th purchase.", required = true, value = "The display name of the achievement in the Campaign Manager.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public CustomerAchievement description(String description) { + + this.description = description; + return this; + } + + /** + * The description of the achievement in the Campaign Manager. + * @return description + **/ + @ApiModelProperty(example = "50% off for every 50th purchase in a year.", required = true, value = "The description of the achievement in the Campaign Manager.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public CustomerAchievement target(BigDecimal target) { + + this.target = target; + return this; + } + + /** + * The required number of actions or the transactional milestone to complete the achievement. + * @return target + **/ + @ApiModelProperty(example = "10.0", required = true, value = "The required number of actions or the transactional milestone to complete the achievement.") + + public BigDecimal getTarget() { + return target; + } + + + public void setTarget(BigDecimal target) { + this.target = target; + } + + + public CustomerAchievement recurrencePolicy(RecurrencePolicyEnum recurrencePolicy) { + + this.recurrencePolicy = recurrencePolicy; + return this; + } + + /** + * 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. + * @return recurrencePolicy + **/ + @ApiModelProperty(example = "no_recurrence", required = true, value = "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. ") + + public RecurrencePolicyEnum getRecurrencePolicy() { + return recurrencePolicy; + } + + + public void setRecurrencePolicy(RecurrencePolicyEnum recurrencePolicy) { + this.recurrencePolicy = recurrencePolicy; + } + + + public CustomerAchievement activationPolicy(ActivationPolicyEnum activationPolicy) { + + this.activationPolicy = activationPolicy; + return this; + } + + /** + * 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. + * @return activationPolicy + **/ + @ApiModelProperty(example = "fixed_schedule", required = true, value = "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. ") + + public ActivationPolicyEnum getActivationPolicy() { + return activationPolicy; + } + + + public void setActivationPolicy(ActivationPolicyEnum activationPolicy) { + this.activationPolicy = activationPolicy; + } + + + public CustomerAchievement fixedStartDate(OffsetDateTime fixedStartDate) { + + this.fixedStartDate = fixedStartDate; + return this; + } + + /** + * The achievement's start date when `activationPolicy` is equal to `fixed_schedule`. **Note:** It is an RFC3339 timestamp string. + * @return fixedStartDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievement's start date when `activationPolicy` is equal to `fixed_schedule`. **Note:** It is an RFC3339 timestamp string. ") + + public OffsetDateTime getFixedStartDate() { + return fixedStartDate; + } + + + public void setFixedStartDate(OffsetDateTime fixedStartDate) { + this.fixedStartDate = fixedStartDate; + } + + + public CustomerAchievement endDate(OffsetDateTime endDate) { + + this.endDate = endDate; + return this; + } + + /** + * The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It is an RFC3339 timestamp string. + * @return endDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It is an RFC3339 timestamp string. ") + + public OffsetDateTime getEndDate() { + return endDate; + } + + + public void setEndDate(OffsetDateTime endDate) { + this.endDate = endDate; + } + + + public CustomerAchievement allowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion) { + + this.allowRollbackAfterCompletion = allowRollbackAfterCompletion; + return this; + } + + /** + * When `true`, customer progress can be rolled back in completed achievements. + * @return allowRollbackAfterCompletion + **/ + @ApiModelProperty(example = "false", required = true, value = "When `true`, customer progress can be rolled back in completed achievements.") + + public Boolean getAllowRollbackAfterCompletion() { + return allowRollbackAfterCompletion; + } + + + public void setAllowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion) { + this.allowRollbackAfterCompletion = allowRollbackAfterCompletion; + } + + + public CustomerAchievement campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty. + * @return campaignId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "3", value = "This property is **deprecated**. Use `referencedByCampaigns` instead. This field contains the first campaign ID from the related `referencedByCampaigns`, and is omitted when `referencedByCampaigns` is empty.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public CustomerAchievement campaignIds(List campaignIds) { + + this.campaignIds = campaignIds; + return this; + } + + public CustomerAchievement addCampaignIdsItem(Long campaignIdsItem) { + this.campaignIds.add(campaignIdsItem); + return this; + } + + /** + * The IDs of the campaigns that reference this achievement, in ascending order. + * @return campaignIds + **/ + @ApiModelProperty(example = "[1, 14, 27]", required = true, value = "The IDs of the campaigns that reference this achievement, in ascending order.") + + public List getCampaignIds() { + return campaignIds; + } + + + public void setCampaignIds(List campaignIds) { + this.campaignIds = campaignIds; + } + + + public CustomerAchievement referencedByCampaigns(List referencedByCampaigns) { + + this.referencedByCampaigns = referencedByCampaigns; + return this; + } + + public CustomerAchievement addReferencedByCampaignsItem(CampaignReference referencedByCampaignsItem) { + this.referencedByCampaigns.add(referencedByCampaignsItem); + return this; + } + + /** + * The campaigns that reference this achievement. They are sorted in ascending order by their `id`. + * @return referencedByCampaigns + **/ + @ApiModelProperty(required = true, value = "The campaigns that reference this achievement. They are sorted in ascending order by their `id`.") + + public List getReferencedByCampaigns() { + return referencedByCampaigns; + } + + + public void setReferencedByCampaigns(List referencedByCampaigns) { + this.referencedByCampaigns = referencedByCampaigns; + } + + + public CustomerAchievement currentProgress(AchievementProgress currentProgress) { + + this.currentProgress = currentProgress; + return this; + } + + /** + * Get currentProgress + * @return currentProgress + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public AchievementProgress getCurrentProgress() { + return currentProgress; + } + + + public void setCurrentProgress(AchievementProgress currentProgress) { + this.currentProgress = currentProgress; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CustomerAchievement customerAchievement = (CustomerAchievement) o; + return Objects.equals(this.id, customerAchievement.id) && + Objects.equals(this.name, customerAchievement.name) && + Objects.equals(this.title, customerAchievement.title) && + Objects.equals(this.description, customerAchievement.description) && + Objects.equals(this.target, customerAchievement.target) && + Objects.equals(this.recurrencePolicy, customerAchievement.recurrencePolicy) && + Objects.equals(this.activationPolicy, customerAchievement.activationPolicy) && + Objects.equals(this.fixedStartDate, customerAchievement.fixedStartDate) && + Objects.equals(this.endDate, customerAchievement.endDate) && + Objects.equals(this.allowRollbackAfterCompletion, customerAchievement.allowRollbackAfterCompletion) && + Objects.equals(this.campaignId, customerAchievement.campaignId) && + Objects.equals(this.campaignIds, customerAchievement.campaignIds) && + Objects.equals(this.referencedByCampaigns, customerAchievement.referencedByCampaigns) && + Objects.equals(this.currentProgress, customerAchievement.currentProgress); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title, description, target, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, campaignId, campaignIds, referencedByCampaigns, currentProgress); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CustomerAchievement {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append(" recurrencePolicy: ").append(toIndentedString(recurrencePolicy)).append("\n"); + sb.append(" activationPolicy: ").append(toIndentedString(activationPolicy)).append("\n"); + sb.append(" fixedStartDate: ").append(toIndentedString(fixedStartDate)).append("\n"); + sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); + sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" campaignIds: ").append(toIndentedString(campaignIds)).append("\n"); + sb.append(" referencedByCampaigns: ").append(toIndentedString(referencedByCampaigns)).append("\n"); + sb.append(" currentProgress: ").append(toIndentedString(currentProgress)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CustomerInventory.java b/src/main/java/one/talon/model/CustomerInventory.java index f52e2296..3623e58a 100644 --- a/src/main/java/one/talon/model/CustomerInventory.java +++ b/src/main/java/one/talon/model/CustomerInventory.java @@ -31,6 +31,7 @@ import one.talon.model.InventoryCoupon; import one.talon.model.InventoryReferral; import one.talon.model.Loyalty; +import one.talon.model.RewardWithUnlocks; /** * CustomerInventory @@ -61,6 +62,10 @@ public class CustomerInventory { @SerializedName(SERIALIZED_NAME_ACHIEVEMENTS) private List achievements = null; + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public CustomerInventory profile(CustomerProfile profile) { @@ -232,6 +237,37 @@ public void setAchievements(List achievements } + public CustomerInventory rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public CustomerInventory addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The customer rewards that are `unlocked` and not yet `used`. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The customer rewards that are `unlocked` and not yet `used`.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -246,12 +282,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.referrals, customerInventory.referrals) && Objects.equals(this.coupons, customerInventory.coupons) && Objects.equals(this.giveaways, customerInventory.giveaways) && - Objects.equals(this.achievements, customerInventory.achievements); + Objects.equals(this.achievements, customerInventory.achievements) && + Objects.equals(this.rewards, customerInventory.rewards); } @Override public int hashCode() { - return Objects.hash(profile, loyalty, referrals, coupons, giveaways, achievements); + return Objects.hash(profile, loyalty, referrals, coupons, giveaways, achievements, rewards); } @@ -265,6 +302,7 @@ public String toString() { sb.append(" coupons: ").append(toIndentedString(coupons)).append("\n"); sb.append(" giveaways: ").append(toIndentedString(giveaways)).append("\n"); sb.append(" achievements: ").append(toIndentedString(achievements)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/CustomerProfileIntegrationRequestV2.java b/src/main/java/one/talon/model/CustomerProfileIntegrationRequestV2.java index 6f9f10a9..e8c54be5 100644 --- a/src/main/java/one/talon/model/CustomerProfileIntegrationRequestV2.java +++ b/src/main/java/one/talon/model/CustomerProfileIntegrationRequestV2.java @@ -56,7 +56,13 @@ public enum ResponseContentEnum { AWARDEDGIVEAWAYS("awardedGiveaways"), - RULEFAILUREREASONS("ruleFailureReasons"); + RULEFAILUREREASONS("ruleFailureReasons"), + + CAMPAIGNELIGIBILITY("campaignEligibility"), + + ACHIEVEMENTS("achievements"), + + UNLOCKEDREWARDS("unlockedRewards"); private String value; diff --git a/src/main/java/one/talon/model/CustomerProfileIntegrationResponseV2.java b/src/main/java/one/talon/model/CustomerProfileIntegrationResponseV2.java index 5230188a..a50a5721 100644 --- a/src/main/java/one/talon/model/CustomerProfileIntegrationResponseV2.java +++ b/src/main/java/one/talon/model/CustomerProfileIntegrationResponseV2.java @@ -26,6 +26,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; import one.talon.model.CustomerProfile; import one.talon.model.Effect; @@ -33,6 +34,7 @@ import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; /** @@ -61,10 +63,18 @@ public class CustomerProfileIntegrationResponseV2 { @SerializedName(SERIALIZED_NAME_RULE_FAILURE_REASONS) private List ruleFailureReasons = null; + public static final String SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY = "campaignEligibility"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY) + private List campaignEligibility = null; + public static final String SERIALIZED_NAME_AWARDED_GIVEAWAYS = "awardedGiveaways"; @SerializedName(SERIALIZED_NAME_AWARDED_GIVEAWAYS) private List awardedGiveaways = null; + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; @SerializedName(SERIALIZED_NAME_EFFECTS) private List effects = new ArrayList(); @@ -209,6 +219,37 @@ public void setRuleFailureReasons(List ruleFailureReasons) { } + public CustomerProfileIntegrationResponseV2 campaignEligibility(List campaignEligibility) { + + this.campaignEligibility = campaignEligibility; + return this; + } + + public CustomerProfileIntegrationResponseV2 addCampaignEligibilityItem(CampaignEligibility campaignEligibilityItem) { + if (this.campaignEligibility == null) { + this.campaignEligibility = new ArrayList(); + } + this.campaignEligibility.add(campaignEligibilityItem); + return this; + } + + /** + * Get campaignEligibility + * @return campaignEligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public List getCampaignEligibility() { + return campaignEligibility; + } + + + public void setCampaignEligibility(List campaignEligibility) { + this.campaignEligibility = campaignEligibility; + } + + public CustomerProfileIntegrationResponseV2 awardedGiveaways(List awardedGiveaways) { this.awardedGiveaways = awardedGiveaways; @@ -240,6 +281,37 @@ public void setAwardedGiveaways(List awardedGiveaways) { } + public CustomerProfileIntegrationResponseV2 rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public CustomerProfileIntegrationResponseV2 addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The rewards for the customer profile. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The rewards for the customer profile.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + public CustomerProfileIntegrationResponseV2 effects(List effects) { this.effects = effects; @@ -335,7 +407,9 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.loyalty, customerProfileIntegrationResponseV2.loyalty) && Objects.equals(this.triggeredCampaigns, customerProfileIntegrationResponseV2.triggeredCampaigns) && Objects.equals(this.ruleFailureReasons, customerProfileIntegrationResponseV2.ruleFailureReasons) && + Objects.equals(this.campaignEligibility, customerProfileIntegrationResponseV2.campaignEligibility) && Objects.equals(this.awardedGiveaways, customerProfileIntegrationResponseV2.awardedGiveaways) && + Objects.equals(this.rewards, customerProfileIntegrationResponseV2.rewards) && Objects.equals(this.effects, customerProfileIntegrationResponseV2.effects) && Objects.equals(this.createdCoupons, customerProfileIntegrationResponseV2.createdCoupons) && Objects.equals(this.createdReferrals, customerProfileIntegrationResponseV2.createdReferrals); @@ -343,7 +417,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(customerProfile, event, loyalty, triggeredCampaigns, ruleFailureReasons, awardedGiveaways, effects, createdCoupons, createdReferrals); + return Objects.hash(customerProfile, event, loyalty, triggeredCampaigns, ruleFailureReasons, campaignEligibility, awardedGiveaways, rewards, effects, createdCoupons, createdReferrals); } @@ -356,7 +430,9 @@ public String toString() { sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); sb.append(" triggeredCampaigns: ").append(toIndentedString(triggeredCampaigns)).append("\n"); sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); + sb.append(" campaignEligibility: ").append(toIndentedString(campaignEligibility)).append("\n"); sb.append(" awardedGiveaways: ").append(toIndentedString(awardedGiveaways)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" createdCoupons: ").append(toIndentedString(createdCoupons)).append("\n"); sb.append(" createdReferrals: ").append(toIndentedString(createdReferrals)).append("\n"); diff --git a/src/main/java/one/talon/model/CustomerProfileReward.java b/src/main/java/one/talon/model/CustomerProfileReward.java new file mode 100644 index 00000000..f145577a --- /dev/null +++ b/src/main/java/one/talon/model/CustomerProfileReward.java @@ -0,0 +1,519 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RuleMetadata; +import org.threeten.bp.OffsetDateTime; + +/** + * A reward instance held by a customer profile. + */ +@ApiModel(description = "A reward instance held by a customer profile.") + +public class CustomerProfileReward { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + + public static final String SERIALIZED_NAME_REWARD_INTEGRATION_ID = "rewardIntegrationId"; + @SerializedName(SERIALIZED_NAME_REWARD_INTEGRATION_ID) + private String rewardIntegrationId; + + public static final String SERIALIZED_NAME_REWARD_NAME = "rewardName"; + @SerializedName(SERIALIZED_NAME_REWARD_NAME) + private String rewardName; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private RuleMetadata rule; + + /** + * The status of the customer reward: - `unlocked`: The reward is available for use. - `used`: The reward has been used. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + UNLOCKED("unlocked"), + + USED("used"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + public static final String SERIALIZED_NAME_UNLOCKED_AT = "unlockedAt"; + @SerializedName(SERIALIZED_NAME_UNLOCKED_AT) + private OffsetDateTime unlockedAt; + + public static final String SERIALIZED_NAME_UNLOCKED_BY_PROFILE_INTEGRATION_ID = "unlockedByProfileIntegrationId"; + @SerializedName(SERIALIZED_NAME_UNLOCKED_BY_PROFILE_INTEGRATION_ID) + private String unlockedByProfileIntegrationId; + + public static final String SERIALIZED_NAME_USED_AT = "usedAt"; + @SerializedName(SERIALIZED_NAME_USED_AT) + private OffsetDateTime usedAt; + + public static final String SERIALIZED_NAME_USED_BY_PROFILE_INTEGRATION_ID = "usedByProfileIntegrationId"; + @SerializedName(SERIALIZED_NAME_USED_BY_PROFILE_INTEGRATION_ID) + private String usedByProfileIntegrationId; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_LOYALTY_CARD_IDENTIFIER = "loyaltyCardIdentifier"; + @SerializedName(SERIALIZED_NAME_LOYALTY_CARD_IDENTIFIER) + private String loyaltyCardIdentifier; + + + public CustomerProfileReward id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the customer reward instance. A customer profile can have multiple instances of the same reward. + * @return id + **/ + @ApiModelProperty(example = "6", required = true, value = "The ID of the customer reward instance. A customer profile can have multiple instances of the same reward.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public CustomerProfileReward integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID of the customer reward instance. + * @return integrationId + **/ + @ApiModelProperty(example = "reward-unlock-123", required = true, value = "The integration ID of the customer reward instance.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public CustomerProfileReward rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward this instance belongs to. + * @return rewardId + **/ + @ApiModelProperty(example = "12", required = true, value = "The ID of the reward this instance belongs to.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + + public CustomerProfileReward rewardIntegrationId(String rewardIntegrationId) { + + this.rewardIntegrationId = rewardIntegrationId; + return this; + } + + /** + * The integration ID of the reward this instance belongs to. + * @return rewardIntegrationId + **/ + @ApiModelProperty(example = "free-coffee", required = true, value = "The integration ID of the reward this instance belongs to.") + + public String getRewardIntegrationId() { + return rewardIntegrationId; + } + + + public void setRewardIntegrationId(String rewardIntegrationId) { + this.rewardIntegrationId = rewardIntegrationId; + } + + + public CustomerProfileReward rewardName(String rewardName) { + + this.rewardName = rewardName; + return this; + } + + /** + * The name of the reward. + * @return rewardName + **/ + @ApiModelProperty(example = "Free coffee", required = true, value = "The name of the reward.") + + public String getRewardName() { + return rewardName; + } + + + public void setRewardName(String rewardName) { + this.rewardName = rewardName; + } + + + public CustomerProfileReward description(String description) { + + this.description = description; + return this; + } + + /** + * The customer-facing description of the reward. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "One free coffee of any size", value = "The customer-facing description of the reward.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public CustomerProfileReward rule(RuleMetadata rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public RuleMetadata getRule() { + return rule; + } + + + public void setRule(RuleMetadata rule) { + this.rule = rule; + } + + + public CustomerProfileReward status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The status of the customer reward: - `unlocked`: The reward is available for use. - `used`: The reward has been used. + * @return status + **/ + @ApiModelProperty(example = "unlocked", required = true, value = "The status of the customer reward: - `unlocked`: The reward is available for use. - `used`: The reward has been used. ") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + public CustomerProfileReward unlockedAt(OffsetDateTime unlockedAt) { + + this.unlockedAt = unlockedAt; + return this; + } + + /** + * The date and time when the reward was unlocked. + * @return unlockedAt + **/ + @ApiModelProperty(example = "2026-07-01T09:00Z", required = true, value = "The date and time when the reward was unlocked.") + + public OffsetDateTime getUnlockedAt() { + return unlockedAt; + } + + + public void setUnlockedAt(OffsetDateTime unlockedAt) { + this.unlockedAt = unlockedAt; + } + + + public CustomerProfileReward unlockedByProfileIntegrationId(String unlockedByProfileIntegrationId) { + + this.unlockedByProfileIntegrationId = unlockedByProfileIntegrationId; + return this; + } + + /** + * The integration ID of the customer profile that unlocked the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. + * @return unlockedByProfileIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "customer2839", value = "The integration ID of the customer profile that unlocked the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. ") + + public String getUnlockedByProfileIntegrationId() { + return unlockedByProfileIntegrationId; + } + + + public void setUnlockedByProfileIntegrationId(String unlockedByProfileIntegrationId) { + this.unlockedByProfileIntegrationId = unlockedByProfileIntegrationId; + } + + + public CustomerProfileReward usedAt(OffsetDateTime usedAt) { + + this.usedAt = usedAt; + return this; + } + + /** + * The date and time when the reward was used. + * @return usedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2026-07-02T10:30Z", value = "The date and time when the reward was used.") + + public OffsetDateTime getUsedAt() { + return usedAt; + } + + + public void setUsedAt(OffsetDateTime usedAt) { + this.usedAt = usedAt; + } + + + public CustomerProfileReward usedByProfileIntegrationId(String usedByProfileIntegrationId) { + + this.usedByProfileIntegrationId = usedByProfileIntegrationId; + return this; + } + + /** + * The integration ID of the customer profile that used the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. Only returned when the reward has been used. + * @return usedByProfileIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "customer2840", value = "The integration ID of the customer profile that used the reward. For rewards unlocked with a loyalty card, this can be any customer profile linked to that loyalty card. Only returned when the reward has been used. ") + + public String getUsedByProfileIntegrationId() { + return usedByProfileIntegrationId; + } + + + public void setUsedByProfileIntegrationId(String usedByProfileIntegrationId) { + this.usedByProfileIntegrationId = usedByProfileIntegrationId; + } + + + public CustomerProfileReward loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * The ID of the loyalty program that the loyalty card belongs to. Only returned for rewards unlocked with a loyalty card. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "9", value = "The ID of the loyalty program that the loyalty card belongs to. Only returned for rewards unlocked with a loyalty card.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public CustomerProfileReward loyaltyCardIdentifier(String loyaltyCardIdentifier) { + + this.loyaltyCardIdentifier = loyaltyCardIdentifier; + return this; + } + + /** + * The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + * @return loyaltyCardIdentifier + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "summer-loyalty-card-0543", value = "The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. ") + + public String getLoyaltyCardIdentifier() { + return loyaltyCardIdentifier; + } + + + public void setLoyaltyCardIdentifier(String loyaltyCardIdentifier) { + this.loyaltyCardIdentifier = loyaltyCardIdentifier; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CustomerProfileReward customerProfileReward = (CustomerProfileReward) o; + return Objects.equals(this.id, customerProfileReward.id) && + Objects.equals(this.integrationId, customerProfileReward.integrationId) && + Objects.equals(this.rewardId, customerProfileReward.rewardId) && + Objects.equals(this.rewardIntegrationId, customerProfileReward.rewardIntegrationId) && + Objects.equals(this.rewardName, customerProfileReward.rewardName) && + Objects.equals(this.description, customerProfileReward.description) && + Objects.equals(this.rule, customerProfileReward.rule) && + Objects.equals(this.status, customerProfileReward.status) && + Objects.equals(this.unlockedAt, customerProfileReward.unlockedAt) && + Objects.equals(this.unlockedByProfileIntegrationId, customerProfileReward.unlockedByProfileIntegrationId) && + Objects.equals(this.usedAt, customerProfileReward.usedAt) && + Objects.equals(this.usedByProfileIntegrationId, customerProfileReward.usedByProfileIntegrationId) && + Objects.equals(this.loyaltyProgramId, customerProfileReward.loyaltyProgramId) && + Objects.equals(this.loyaltyCardIdentifier, customerProfileReward.loyaltyCardIdentifier); + } + + @Override + public int hashCode() { + return Objects.hash(id, integrationId, rewardId, rewardIntegrationId, rewardName, description, rule, status, unlockedAt, unlockedByProfileIntegrationId, usedAt, usedByProfileIntegrationId, loyaltyProgramId, loyaltyCardIdentifier); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CustomerProfileReward {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); + sb.append(" rewardIntegrationId: ").append(toIndentedString(rewardIntegrationId)).append("\n"); + sb.append(" rewardName: ").append(toIndentedString(rewardName)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" unlockedAt: ").append(toIndentedString(unlockedAt)).append("\n"); + sb.append(" unlockedByProfileIntegrationId: ").append(toIndentedString(unlockedByProfileIntegrationId)).append("\n"); + sb.append(" usedAt: ").append(toIndentedString(usedAt)).append("\n"); + sb.append(" usedByProfileIntegrationId: ").append(toIndentedString(usedByProfileIntegrationId)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" loyaltyCardIdentifier: ").append(toIndentedString(loyaltyCardIdentifier)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CustomerReward.java b/src/main/java/one/talon/model/CustomerReward.java new file mode 100644 index 00000000..fa209f60 --- /dev/null +++ b/src/main/java/one/talon/model/CustomerReward.java @@ -0,0 +1,213 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; + +/** + * A reward unlocked by a customer profile. + */ +@ApiModel(description = "A reward unlocked by a customer profile.") + +public class CustomerReward { + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_ID = "profileIntegrationId"; + @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_ID) + private String profileIntegrationId; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_UNLOCKED_AT = "unlockedAt"; + @SerializedName(SERIALIZED_NAME_UNLOCKED_AT) + private OffsetDateTime unlockedAt; + + public static final String SERIALIZED_NAME_USED_AT = "usedAt"; + @SerializedName(SERIALIZED_NAME_USED_AT) + private OffsetDateTime usedAt; + + + public CustomerReward applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application in which the reward was unlocked. + * @return applicationId + **/ + @ApiModelProperty(example = "3", required = true, value = "The ID of the Application in which the reward was unlocked.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public CustomerReward profileIntegrationId(String profileIntegrationId) { + + this.profileIntegrationId = profileIntegrationId; + return this; + } + + /** + * The integration ID of the customer profile that unlocked this reward. + * @return profileIntegrationId + **/ + @ApiModelProperty(example = "customer1", required = true, value = "The integration ID of the customer profile that unlocked this reward.") + + public String getProfileIntegrationId() { + return profileIntegrationId; + } + + + public void setProfileIntegrationId(String profileIntegrationId) { + this.profileIntegrationId = profileIntegrationId; + } + + + public CustomerReward integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID assigned to this reward unlock. + * @return integrationId + **/ + @ApiModelProperty(example = "reward-unlock-123", required = true, value = "The integration ID assigned to this reward unlock.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public CustomerReward unlockedAt(OffsetDateTime unlockedAt) { + + this.unlockedAt = unlockedAt; + return this; + } + + /** + * The date and time when the reward was unlocked. + * @return unlockedAt + **/ + @ApiModelProperty(example = "2024-01-01T00:00Z", required = true, value = "The date and time when the reward was unlocked.") + + public OffsetDateTime getUnlockedAt() { + return unlockedAt; + } + + + public void setUnlockedAt(OffsetDateTime unlockedAt) { + this.unlockedAt = unlockedAt; + } + + + public CustomerReward usedAt(OffsetDateTime usedAt) { + + this.usedAt = usedAt; + return this; + } + + /** + * The date and time when the reward was used. + * @return usedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2024-01-02T00:00Z", value = "The date and time when the reward was used.") + + public OffsetDateTime getUsedAt() { + return usedAt; + } + + + public void setUsedAt(OffsetDateTime usedAt) { + this.usedAt = usedAt; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CustomerReward customerReward = (CustomerReward) o; + return Objects.equals(this.applicationId, customerReward.applicationId) && + Objects.equals(this.profileIntegrationId, customerReward.profileIntegrationId) && + Objects.equals(this.integrationId, customerReward.integrationId) && + Objects.equals(this.unlockedAt, customerReward.unlockedAt) && + Objects.equals(this.usedAt, customerReward.usedAt); + } + + @Override + public int hashCode() { + return Objects.hash(applicationId, profileIntegrationId, integrationId, unlockedAt, usedAt); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CustomerReward {\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" profileIntegrationId: ").append(toIndentedString(profileIntegrationId)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" unlockedAt: ").append(toIndentedString(unlockedAt)).append("\n"); + sb.append(" usedAt: ").append(toIndentedString(usedAt)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CustomerSession.java b/src/main/java/one/talon/model/CustomerSession.java index e1890521..c1610652 100644 --- a/src/main/java/one/talon/model/CustomerSession.java +++ b/src/main/java/one/talon/model/CustomerSession.java @@ -61,7 +61,7 @@ public class CustomerSession { private String referral; /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). */ @JsonAdapter(StateEnum.Adapter.class) public enum StateEnum { @@ -287,10 +287,10 @@ public CustomerSession state(StateEnum state) { } /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). * @return state **/ - @ApiModelProperty(example = "open", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") + @ApiModelProperty(example = "open", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") public StateEnum getState() { return state; diff --git a/src/main/java/one/talon/model/CustomerSessionV2.java b/src/main/java/one/talon/model/CustomerSessionV2.java index d059cbf2..3d76e1d8 100644 --- a/src/main/java/one/talon/model/CustomerSessionV2.java +++ b/src/main/java/one/talon/model/CustomerSessionV2.java @@ -79,8 +79,12 @@ public class CustomerSessionV2 { @SerializedName(SERIALIZED_NAME_LOYALTY_CARDS) private List loyaltyCards = null; + public static final String SERIALIZED_NAME_REWARD_INTEGRATION_IDS = "rewardIntegrationIds"; + @SerializedName(SERIALIZED_NAME_REWARD_INTEGRATION_IDS) + private List rewardIntegrationIds = null; + /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). */ @JsonAdapter(StateEnum.Adapter.class) public enum StateEnum { @@ -174,6 +178,10 @@ public StateEnum read(final JsonReader jsonReader) throws IOException { @SerializedName(SERIALIZED_NAME_ADDITIONAL_COST_TOTAL) private BigDecimal additionalCostTotal; + public static final String SERIALIZED_NAME_CART_ITEM_ADDITIONAL_COST_TOTAL = "cartItemAdditionalCostTotal"; + @SerializedName(SERIALIZED_NAME_CART_ITEM_ADDITIONAL_COST_TOTAL) + private BigDecimal cartItemAdditionalCostTotal; + public static final String SERIALIZED_NAME_UPDATED = "updated"; @SerializedName(SERIALIZED_NAME_UPDATED) private OffsetDateTime updated; @@ -428,6 +436,37 @@ public void setLoyaltyCards(List loyaltyCards) { } + public CustomerSessionV2 rewardIntegrationIds(List rewardIntegrationIds) { + + this.rewardIntegrationIds = rewardIntegrationIds; + return this; + } + + public CustomerSessionV2 addRewardIntegrationIdsItem(String rewardIntegrationIdsItem) { + if (this.rewardIntegrationIds == null) { + this.rewardIntegrationIds = new ArrayList(); + } + this.rewardIntegrationIds.add(rewardIntegrationIdsItem); + return this; + } + + /** + * The integration IDs of the unlocked rewards that can be used in this session. + * @return rewardIntegrationIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90]", value = "The integration IDs of the unlocked rewards that can be used in this session. ") + + public List getRewardIntegrationIds() { + return rewardIntegrationIds; + } + + + public void setRewardIntegrationIds(List rewardIntegrationIds) { + this.rewardIntegrationIds = rewardIntegrationIds; + } + + public CustomerSessionV2 state(StateEnum state) { this.state = state; @@ -435,10 +474,10 @@ public CustomerSessionV2 state(StateEnum state) { } /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). * @return state **/ - @ApiModelProperty(example = "open", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") + @ApiModelProperty(example = "open", required = true, value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") public StateEnum getState() { return state; @@ -646,7 +685,7 @@ public CustomerSessionV2 total(BigDecimal total) { * The total value of cart items and additional costs in the session, before any discounts are applied. * @return total **/ - @ApiModelProperty(example = "119.99", required = true, value = "The total value of cart items and additional costs in the session, before any discounts are applied.") + @ApiModelProperty(example = "134.99", required = true, value = "The total value of cart items and additional costs in the session, before any discounts are applied.") public BigDecimal getTotal() { return total; @@ -702,6 +741,19 @@ public void setAdditionalCostTotal(BigDecimal additionalCostTotal) { } + /** + * The total value of additional costs applied to individual items, before any discounts are applied. + * @return cartItemAdditionalCostTotal + **/ + @ApiModelProperty(example = "15.0", required = true, value = "The total value of additional costs applied to individual items, before any discounts are applied.") + + public BigDecimal getCartItemAdditionalCostTotal() { + return cartItemAdditionalCostTotal; + } + + + + public CustomerSessionV2 updated(OffsetDateTime updated) { this.updated = updated; @@ -743,6 +795,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.couponCodes, customerSessionV2.couponCodes) && Objects.equals(this.referralCode, customerSessionV2.referralCode) && Objects.equals(this.loyaltyCards, customerSessionV2.loyaltyCards) && + Objects.equals(this.rewardIntegrationIds, customerSessionV2.rewardIntegrationIds) && Objects.equals(this.state, customerSessionV2.state) && Objects.equals(this.cartItems, customerSessionV2.cartItems) && Objects.equals(this.experimentVariantAllocations, customerSessionV2.experimentVariantAllocations) && @@ -754,12 +807,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.total, customerSessionV2.total) && Objects.equals(this.cartItemTotal, customerSessionV2.cartItemTotal) && Objects.equals(this.additionalCostTotal, customerSessionV2.additionalCostTotal) && + Objects.equals(this.cartItemAdditionalCostTotal, customerSessionV2.cartItemAdditionalCostTotal) && Objects.equals(this.updated, customerSessionV2.updated); } @Override public int hashCode() { - return Objects.hash(id, created, integrationId, applicationId, profileId, storeIntegrationId, evaluableCampaignIds, couponCodes, referralCode, loyaltyCards, state, cartItems, experimentVariantAllocations, additionalCosts, identifiers, attributes, firstSession, updateCount, total, cartItemTotal, additionalCostTotal, updated); + return Objects.hash(id, created, integrationId, applicationId, profileId, storeIntegrationId, evaluableCampaignIds, couponCodes, referralCode, loyaltyCards, rewardIntegrationIds, state, cartItems, experimentVariantAllocations, additionalCosts, identifiers, attributes, firstSession, updateCount, total, cartItemTotal, additionalCostTotal, cartItemAdditionalCostTotal, updated); } @@ -777,6 +831,7 @@ public String toString() { sb.append(" couponCodes: ").append(toIndentedString(couponCodes)).append("\n"); sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); sb.append(" loyaltyCards: ").append(toIndentedString(loyaltyCards)).append("\n"); + sb.append(" rewardIntegrationIds: ").append(toIndentedString(rewardIntegrationIds)).append("\n"); sb.append(" state: ").append(toIndentedString(state)).append("\n"); sb.append(" cartItems: ").append(toIndentedString(cartItems)).append("\n"); sb.append(" experimentVariantAllocations: ").append(toIndentedString(experimentVariantAllocations)).append("\n"); @@ -788,6 +843,7 @@ public String toString() { sb.append(" total: ").append(toIndentedString(total)).append("\n"); sb.append(" cartItemTotal: ").append(toIndentedString(cartItemTotal)).append("\n"); sb.append(" additionalCostTotal: ").append(toIndentedString(additionalCostTotal)).append("\n"); + sb.append(" cartItemAdditionalCostTotal: ").append(toIndentedString(cartItemAdditionalCostTotal)).append("\n"); sb.append(" updated: ").append(toIndentedString(updated)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/DeductLoyaltyPointsEffectProps.java b/src/main/java/one/talon/model/DeductLoyaltyPointsEffectProps.java index 36bbf4b6..a710c502 100644 --- a/src/main/java/one/talon/model/DeductLoyaltyPointsEffectProps.java +++ b/src/main/java/one/talon/model/DeductLoyaltyPointsEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"deductLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained a condition to only trigger when the given number of loyalty points could be deduced. These points are automatically stored and managed inside Talon.One. + * This effect is triggered when a customer redeems loyalty points. The points are deducted from their active point balance. If the loyalty program is card-based, use the `cardIdentifier` property to identify the loyalty card from which these points are deducted. The Rule Engine deducts points in this order: - Points with the earliest expiry date are deducted first, regardless of when they were added. - Points with an unlimited expiry date are deducted last. - For points with an unlimited expiry date, the points awarded first are deducted first. The points only persist when the session is closed. */ -@ApiModel(description = "The properties specific to the \"deductLoyaltyPoints\" effect. This gets triggered whenever a validated rule contained a condition to only trigger when the given number of loyalty points could be deduced. These points are automatically stored and managed inside Talon.One.") +@ApiModel(description = "This effect is triggered when a customer redeems loyalty points. The points are deducted from their active point balance. If the loyalty program is card-based, use the `cardIdentifier` property to identify the loyalty card from which these points are deducted. The Rule Engine deducts points in this order: - Points with the earliest expiry date are deducted first, regardless of when they were added. - Points with an unlimited expiry date are deducted last. - For points with an unlimited expiry date, the points awarded first are deducted first. The points only persist when the session is closed.") public class DeductLoyaltyPointsEffectProps { public static final String SERIALIZED_NAME_RULE_TITLE = "ruleTitle"; @@ -89,10 +89,10 @@ public DeductLoyaltyPointsEffectProps programId(Long programId) { } /** - * The ID of the loyalty program where these points were added. + * The ID of the loyalty program from which these points were deducted. * @return programId **/ - @ApiModelProperty(required = true, value = "The ID of the loyalty program where these points were added.") + @ApiModelProperty(required = true, value = "The ID of the loyalty program from which these points were deducted.") public Long getProgramId() { return programId; @@ -111,10 +111,10 @@ public DeductLoyaltyPointsEffectProps subLedgerId(String subLedgerId) { } /** - * The ID of the subledger within the loyalty program where these points were added. + * The ID of the subledger within the loyalty program from which these points were deducted. * @return subLedgerId **/ - @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program where these points were added.") + @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program from which these points were deducted.") public String getSubLedgerId() { return subLedgerId; @@ -155,10 +155,10 @@ public DeductLoyaltyPointsEffectProps transactionUUID(String transactionUUID) { } /** - * The identifier of this deduction in the loyalty ledger. + * The identifier of this loyalty point transaction. * @return transactionUUID **/ - @ApiModelProperty(required = true, value = "The identifier of this deduction in the loyalty ledger.") + @ApiModelProperty(required = true, value = "The identifier of this loyalty point transaction.") public String getTransactionUUID() { return transactionUUID; @@ -177,10 +177,10 @@ public DeductLoyaltyPointsEffectProps name(String name) { } /** - * The name property gets one of the following two values. It can be the loyalty program name or it can represent a reason for the respective deduction of loyalty points. The latter is an optional value defined in a deduction rule. + * The reason of this loyalty points deduction. * @return name **/ - @ApiModelProperty(required = true, value = "The name property gets one of the following two values. It can be the loyalty program name or it can represent a reason for the respective deduction of loyalty points. The latter is an optional value defined in a deduction rule. ") + @ApiModelProperty(required = true, value = "The reason of this loyalty points deduction.") public String getName() { return name; diff --git a/src/main/java/one/talon/model/DigitalPass.java b/src/main/java/one/talon/model/DigitalPass.java new file mode 100644 index 00000000..9ac8d3ee --- /dev/null +++ b/src/main/java/one/talon/model/DigitalPass.java @@ -0,0 +1,228 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.net.URI; + +/** + * DigitalPass + */ + +public class DigitalPass { + public static final String SERIALIZED_NAME_PASS_ID = "passId"; + @SerializedName(SERIALIZED_NAME_PASS_ID) + private String passId; + + public static final String SERIALIZED_NAME_PASS_TEMPLATE_ID = "passTemplateId"; + @SerializedName(SERIALIZED_NAME_PASS_TEMPLATE_ID) + private String passTemplateId; + + /** + * The status of the digital pass. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + CREATED("created"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + public static final String SERIALIZED_NAME_PASS_URL = "passUrl"; + @SerializedName(SERIALIZED_NAME_PASS_URL) + private URI passUrl; + + + public DigitalPass passId(String passId) { + + this.passId = passId; + return this; + } + + /** + * The ID of the generated digital pass. + * @return passId + **/ + @ApiModelProperty(example = "pass_9c3f1a2b", required = true, value = "The ID of the generated digital pass.") + + public String getPassId() { + return passId; + } + + + public void setPassId(String passId) { + this.passId = passId; + } + + + public DigitalPass passTemplateId(String passTemplateId) { + + this.passTemplateId = passTemplateId; + return this; + } + + /** + * The ID of the digital pass template used to generate the pass. + * @return passTemplateId + **/ + @ApiModelProperty(example = "tmpl_summer_loyalty", required = true, value = "The ID of the digital pass template used to generate the pass.") + + public String getPassTemplateId() { + return passTemplateId; + } + + + public void setPassTemplateId(String passTemplateId) { + this.passTemplateId = passTemplateId; + } + + + public DigitalPass status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The status of the digital pass. + * @return status + **/ + @ApiModelProperty(example = "created", required = true, value = "The status of the digital pass.") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + public DigitalPass passUrl(URI passUrl) { + + this.passUrl = passUrl; + return this; + } + + /** + * The URL you can use to let the customer add the digital pass to their wallet. + * @return passUrl + **/ + @ApiModelProperty(example = "https://wallet.example.com/passes/pass_9c3f1a2b", required = true, value = "The URL you can use to let the customer add the digital pass to their wallet.") + + public URI getPassUrl() { + return passUrl; + } + + + public void setPassUrl(URI passUrl) { + this.passUrl = passUrl; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + DigitalPass digitalPass = (DigitalPass) o; + return Objects.equals(this.passId, digitalPass.passId) && + Objects.equals(this.passTemplateId, digitalPass.passTemplateId) && + Objects.equals(this.status, digitalPass.status) && + Objects.equals(this.passUrl, digitalPass.passUrl); + } + + @Override + public int hashCode() { + return Objects.hash(passId, passTemplateId, status, passUrl); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class DigitalPass {\n"); + sb.append(" passId: ").append(toIndentedString(passId)).append("\n"); + sb.append(" passTemplateId: ").append(toIndentedString(passTemplateId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" passUrl: ").append(toIndentedString(passUrl)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/DiscardRisksRequest.java b/src/main/java/one/talon/model/DiscardRisksRequest.java new file mode 100644 index 00000000..5b5f9c4e --- /dev/null +++ b/src/main/java/one/talon/model/DiscardRisksRequest.java @@ -0,0 +1,209 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * DiscardRisksRequest + */ + +public class DiscardRisksRequest { + public static final String SERIALIZED_NAME_RISK_IDS = "riskIds"; + @SerializedName(SERIALIZED_NAME_RISK_IDS) + private List riskIds = new ArrayList(); + + /** + * The reason the risks are being discarded. + */ + @JsonAdapter(ReasonEnum.Adapter.class) + public enum ReasonEnum { + EXPECTED_BEHAVIOR("expected_behavior"), + + OTHER("other"); + + private String value; + + ReasonEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ReasonEnum fromValue(String value) { + for (ReasonEnum b : ReasonEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ReasonEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ReasonEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ReasonEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_REASON = "reason"; + @SerializedName(SERIALIZED_NAME_REASON) + private ReasonEnum reason; + + public static final String SERIALIZED_NAME_COMMENT = "comment"; + @SerializedName(SERIALIZED_NAME_COMMENT) + private String comment; + + + public DiscardRisksRequest riskIds(List riskIds) { + + this.riskIds = riskIds; + return this; + } + + public DiscardRisksRequest addRiskIdsItem(Long riskIdsItem) { + this.riskIds.add(riskIdsItem); + return this; + } + + /** + * The IDs of the risks to discard. + * @return riskIds + **/ + @ApiModelProperty(example = "[1, 2, 3]", required = true, value = "The IDs of the risks to discard.") + + public List getRiskIds() { + return riskIds; + } + + + public void setRiskIds(List riskIds) { + this.riskIds = riskIds; + } + + + public DiscardRisksRequest reason(ReasonEnum reason) { + + this.reason = reason; + return this; + } + + /** + * The reason the risks are being discarded. + * @return reason + **/ + @ApiModelProperty(example = "expected_behavior", required = true, value = "The reason the risks are being discarded.") + + public ReasonEnum getReason() { + return reason; + } + + + public void setReason(ReasonEnum reason) { + this.reason = reason; + } + + + public DiscardRisksRequest comment(String comment) { + + this.comment = comment; + return this; + } + + /** + * Free-text description of why the risks are being discarded. Required when `reason` is `other`, optional for `expected_behavior`. + * @return comment + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Duplicate of a risk already being handled.", value = "Free-text description of why the risks are being discarded. Required when `reason` is `other`, optional for `expected_behavior`. ") + + public String getComment() { + return comment; + } + + + public void setComment(String comment) { + this.comment = comment; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + DiscardRisksRequest discardRisksRequest = (DiscardRisksRequest) o; + return Objects.equals(this.riskIds, discardRisksRequest.riskIds) && + Objects.equals(this.reason, discardRisksRequest.reason) && + Objects.equals(this.comment, discardRisksRequest.comment); + } + + @Override + public int hashCode() { + return Objects.hash(riskIds, reason, comment); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class DiscardRisksRequest {\n"); + sb.append(" riskIds: ").append(toIndentedString(riskIds)).append("\n"); + sb.append(" reason: ").append(toIndentedString(reason)).append("\n"); + sb.append(" comment: ").append(toIndentedString(comment)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Effect.java b/src/main/java/one/talon/model/Effect.java index 0dfd18ec..b3cfc533 100644 --- a/src/main/java/one/talon/model/Effect.java +++ b/src/main/java/one/talon/model/Effect.java @@ -96,6 +96,10 @@ public class Effect { @SerializedName(SERIALIZED_NAME_ADJUSTMENT_REFERENCE_ID) private UUID adjustmentReferenceId; + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + public static final String SERIALIZED_NAME_PROPS = "props"; @SerializedName(SERIALIZED_NAME_PROPS) private Object props; @@ -464,6 +468,29 @@ public void setAdjustmentReferenceId(UUID adjustmentReferenceId) { } + public Effect rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward that was being evaluated when this effect was triggered. + * @return rewardId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The ID of the reward that was being evaluated when this effect was triggered.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + public Effect props(Object props) { this.props = props; @@ -511,12 +538,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.selectedPriceType, effect.selectedPriceType) && Objects.equals(this.selectedPrice, effect.selectedPrice) && Objects.equals(this.adjustmentReferenceId, effect.adjustmentReferenceId) && + Objects.equals(this.rewardId, effect.rewardId) && Objects.equals(this.props, effect.props); } @Override public int hashCode() { - return Objects.hash(experimentId, campaignId, rulesetId, ruleIndex, ruleName, effectType, triggeredByCoupon, triggeredForCatalogItem, conditionIndex, evaluationGroupID, evaluationGroupMode, campaignRevisionId, campaignRevisionVersionId, selectedPriceType, selectedPrice, adjustmentReferenceId, props); + return Objects.hash(experimentId, campaignId, rulesetId, ruleIndex, ruleName, effectType, triggeredByCoupon, triggeredForCatalogItem, conditionIndex, evaluationGroupID, evaluationGroupMode, campaignRevisionId, campaignRevisionVersionId, selectedPriceType, selectedPrice, adjustmentReferenceId, rewardId, props); } @@ -540,6 +568,7 @@ public String toString() { sb.append(" selectedPriceType: ").append(toIndentedString(selectedPriceType)).append("\n"); sb.append(" selectedPrice: ").append(toIndentedString(selectedPrice)).append("\n"); sb.append(" adjustmentReferenceId: ").append(toIndentedString(adjustmentReferenceId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); sb.append(" props: ").append(toIndentedString(props)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/EffectEntity.java b/src/main/java/one/talon/model/EffectEntity.java index 0d070342..7044ea6b 100644 --- a/src/main/java/one/talon/model/EffectEntity.java +++ b/src/main/java/one/talon/model/EffectEntity.java @@ -96,6 +96,10 @@ public class EffectEntity { @SerializedName(SERIALIZED_NAME_ADJUSTMENT_REFERENCE_ID) private UUID adjustmentReferenceId; + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + public EffectEntity experimentId(Long experimentId) { @@ -460,6 +464,29 @@ public void setAdjustmentReferenceId(UUID adjustmentReferenceId) { } + public EffectEntity rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward that was being evaluated when this effect was triggered. + * @return rewardId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The ID of the reward that was being evaluated when this effect was triggered.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -484,12 +511,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.campaignRevisionVersionId, effectEntity.campaignRevisionVersionId) && Objects.equals(this.selectedPriceType, effectEntity.selectedPriceType) && Objects.equals(this.selectedPrice, effectEntity.selectedPrice) && - Objects.equals(this.adjustmentReferenceId, effectEntity.adjustmentReferenceId); + Objects.equals(this.adjustmentReferenceId, effectEntity.adjustmentReferenceId) && + Objects.equals(this.rewardId, effectEntity.rewardId); } @Override public int hashCode() { - return Objects.hash(experimentId, campaignId, rulesetId, ruleIndex, ruleName, effectType, triggeredByCoupon, triggeredForCatalogItem, conditionIndex, evaluationGroupID, evaluationGroupMode, campaignRevisionId, campaignRevisionVersionId, selectedPriceType, selectedPrice, adjustmentReferenceId); + return Objects.hash(experimentId, campaignId, rulesetId, ruleIndex, ruleName, effectType, triggeredByCoupon, triggeredForCatalogItem, conditionIndex, evaluationGroupID, evaluationGroupMode, campaignRevisionId, campaignRevisionVersionId, selectedPriceType, selectedPrice, adjustmentReferenceId, rewardId); } @@ -513,6 +541,7 @@ public String toString() { sb.append(" selectedPriceType: ").append(toIndentedString(selectedPriceType)).append("\n"); sb.append(" selectedPrice: ").append(toIndentedString(selectedPrice)).append("\n"); sb.append(" adjustmentReferenceId: ").append(toIndentedString(adjustmentReferenceId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/ErrorEffectProps.java b/src/main/java/one/talon/model/ErrorEffectProps.java index 7302de32..7a92caaa 100644 --- a/src/main/java/one/talon/model/ErrorEffectProps.java +++ b/src/main/java/one/talon/model/ErrorEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * Whenever an error occurred during evaluation, we return an error effect. This should never happen for rules created in the rule builder. + * This effect is triggered whenever an error occurs during rule evaluation. This effect only provides information about what the error is. */ -@ApiModel(description = "Whenever an error occurred during evaluation, we return an error effect. This should never happen for rules created in the rule builder.") +@ApiModel(description = "This effect is triggered whenever an error occurs during rule evaluation. This effect only provides information about what the error is.") public class ErrorEffectProps { public static final String SERIALIZED_NAME_MESSAGE = "message"; diff --git a/src/main/java/one/talon/model/Event.java b/src/main/java/one/talon/model/Event.java index fb267d1c..d89392ec 100644 --- a/src/main/java/one/talon/model/Event.java +++ b/src/main/java/one/talon/model/Event.java @@ -62,6 +62,10 @@ public class Event { @SerializedName(SERIALIZED_NAME_ATTRIBUTES) private Object attributes; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + public static final String SERIALIZED_NAME_SESSION_ID = "sessionId"; @SerializedName(SERIALIZED_NAME_SESSION_ID) private String sessionId; @@ -198,10 +202,10 @@ public Event type(String type) { } /** - * A string representing the event. Must not be a reserved event name. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event. Must not be a reserved event name.") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; @@ -235,6 +239,29 @@ public void setAttributes(Object attributes) { } + public Event integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + public Event sessionId(String sessionId) { this.sessionId = sessionId; @@ -355,6 +382,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.storeIntegrationId, event.storeIntegrationId) && Objects.equals(this.type, event.type) && Objects.equals(this.attributes, event.attributes) && + Objects.equals(this.integrationId, event.integrationId) && Objects.equals(this.sessionId, event.sessionId) && Objects.equals(this.effects, event.effects) && Objects.equals(this.ledgerEntries, event.ledgerEntries) && @@ -363,7 +391,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(id, created, applicationId, profileId, storeIntegrationId, type, attributes, sessionId, effects, ledgerEntries, meta); + return Objects.hash(id, created, applicationId, profileId, storeIntegrationId, type, attributes, integrationId, sessionId, effects, ledgerEntries, meta); } @@ -378,6 +406,7 @@ public String toString() { sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" sessionId: ").append(toIndentedString(sessionId)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" ledgerEntries: ").append(toIndentedString(ledgerEntries)).append("\n"); diff --git a/src/main/java/one/talon/model/EventAttributesEntity.java b/src/main/java/one/talon/model/EventAttributesEntity.java index 0b686f03..1ab69869 100644 --- a/src/main/java/one/talon/model/EventAttributesEntity.java +++ b/src/main/java/one/talon/model/EventAttributesEntity.java @@ -45,10 +45,10 @@ public EventAttributesEntity type(String type) { } /** - * A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. ") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; diff --git a/src/main/java/one/talon/model/EventV2.java b/src/main/java/one/talon/model/EventV2.java index fb5357df..0dd30359 100644 --- a/src/main/java/one/talon/model/EventV2.java +++ b/src/main/java/one/talon/model/EventV2.java @@ -136,10 +136,10 @@ public EventV2 type(String type) { } /** - * A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. ") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; diff --git a/src/main/java/one/talon/model/EventV3.java b/src/main/java/one/talon/model/EventV3.java index d29f82c2..6ae33708 100644 --- a/src/main/java/one/talon/model/EventV3.java +++ b/src/main/java/one/talon/model/EventV3.java @@ -25,12 +25,29 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.threeten.bp.OffsetDateTime; /** * EventV3 */ public class EventV3 { + public static final String SERIALIZED_NAME_CONNECTED_SESSION_ID = "connectedSessionId"; + @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_ID) + private String connectedSessionId; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + public static final String SERIALIZED_NAME_PROFILE_ID = "profileId"; @SerializedName(SERIALIZED_NAME_PROFILE_ID) private String profileId; @@ -39,14 +56,6 @@ public class EventV3 { @SerializedName(SERIALIZED_NAME_STORE_INTEGRATION_ID) private String storeIntegrationId; - public static final String SERIALIZED_NAME_EVALUABLE_CAMPAIGN_IDS = "evaluableCampaignIds"; - @SerializedName(SERIALIZED_NAME_EVALUABLE_CAMPAIGN_IDS) - private List evaluableCampaignIds = null; - - public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; - @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) - private String integrationId; - public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) private String type; @@ -55,110 +64,151 @@ public class EventV3 { @SerializedName(SERIALIZED_NAME_ATTRIBUTES) private Object attributes; - public static final String SERIALIZED_NAME_CONNECTED_SESSION_I_D = "connectedSessionID"; - @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_I_D) - private String connectedSessionID; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; - public static final String SERIALIZED_NAME_PREVIOUS_EVENT_I_D = "previousEventID"; - @SerializedName(SERIALIZED_NAME_PREVIOUS_EVENT_I_D) - private String previousEventID; + public static final String SERIALIZED_NAME_REFERRAL_CODE = "referralCode"; + @SerializedName(SERIALIZED_NAME_REFERRAL_CODE) + private String referralCode; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; + @SerializedName(SERIALIZED_NAME_EFFECTS) + private List effects = new ArrayList(); - public EventV3 profileId(String profileId) { + + public EventV3 connectedSessionId(String connectedSessionId) { - this.profileId = profileId; + this.connectedSessionId = connectedSessionId; return this; } /** - * ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. - * @return profileId + * The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. + * @return connectedSessionId **/ - @ApiModelProperty(example = "URNGV8294NV", required = true, value = "ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. ") + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail.") - public String getProfileId() { - return profileId; + public String getConnectedSessionId() { + return connectedSessionId; } - public void setProfileId(String profileId) { - this.profileId = profileId; + public void setConnectedSessionId(String connectedSessionId) { + this.connectedSessionId = connectedSessionId; } - public EventV3 storeIntegrationId(String storeIntegrationId) { + public EventV3 id(Long id) { - this.storeIntegrationId = storeIntegrationId; + this.id = id; return this; } /** - * The integration ID of the store. You choose this ID when you create a store. - * @return storeIntegrationId + * The internal ID of this entity. + * @return id **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "STORE-001", value = "The integration ID of the store. You choose this ID when you create a store.") + @ApiModelProperty(example = "6", required = true, value = "The internal ID of this entity.") - public String getStoreIntegrationId() { - return storeIntegrationId; + public Long getId() { + return id; } - public void setStoreIntegrationId(String storeIntegrationId) { - this.storeIntegrationId = storeIntegrationId; + public void setId(Long id) { + this.id = id; } - public EventV3 evaluableCampaignIds(List evaluableCampaignIds) { + public EventV3 created(OffsetDateTime created) { - this.evaluableCampaignIds = evaluableCampaignIds; + this.created = created; return this; } - public EventV3 addEvaluableCampaignIdsItem(Long evaluableCampaignIdsItem) { - if (this.evaluableCampaignIds == null) { - this.evaluableCampaignIds = new ArrayList(); - } - this.evaluableCampaignIds.add(evaluableCampaignIdsItem); + /** + * The time this entity was created. + * @return created + **/ + @ApiModelProperty(example = "2020-06-10T09:05:27.993483Z", required = true, value = "The time this entity was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + public void setCreated(OffsetDateTime created) { + this.created = created; + } + + + public EventV3 applicationId(Long applicationId) { + + this.applicationId = applicationId; return this; } /** - * When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. - * @return evaluableCampaignIds + * The ID of the Application that owns this entity. + * @return applicationId + **/ + @ApiModelProperty(example = "322", required = true, value = "The ID of the Application that owns this entity.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public EventV3 profileId(String profileId) { + + this.profileId = profileId; + return this; + } + + /** + * ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. + * @return profileId **/ @javax.annotation.Nullable - @ApiModelProperty(example = "[10, 12]", value = "When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. ") + @ApiModelProperty(example = "URNGV8294NV", value = "ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. ") - public List getEvaluableCampaignIds() { - return evaluableCampaignIds; + public String getProfileId() { + return profileId; } - public void setEvaluableCampaignIds(List evaluableCampaignIds) { - this.evaluableCampaignIds = evaluableCampaignIds; + public void setProfileId(String profileId) { + this.profileId = profileId; } - public EventV3 integrationId(String integrationId) { + public EventV3 storeIntegrationId(String storeIntegrationId) { - this.integrationId = integrationId; + this.storeIntegrationId = storeIntegrationId; return this; } /** - * The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. - * @return integrationId + * The integration ID of the store. You choose this ID when you create a store. + * @return storeIntegrationId **/ - @ApiModelProperty(example = "175KJPS947296", required = true, value = "The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. ") + @javax.annotation.Nullable + @ApiModelProperty(example = "STORE-001", value = "The integration ID of the store. You choose this ID when you create a store.") - public String getIntegrationId() { - return integrationId; + public String getStoreIntegrationId() { + return storeIntegrationId; } - public void setIntegrationId(String integrationId) { - this.integrationId = integrationId; + public void setStoreIntegrationId(String storeIntegrationId) { + this.storeIntegrationId = storeIntegrationId; } @@ -169,10 +219,10 @@ public EventV3 type(String type) { } /** - * A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. ") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; @@ -191,11 +241,10 @@ public EventV3 attributes(Object attributes) { } /** - * Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). + * Arbitrary additional JSON data associated with the event. * @return attributes **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "{\"myAttribute\":\"myValue\"}", value = "Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute).") + @ApiModelProperty(example = "{\"myAttribute\":\"myValue\"}", required = true, value = "Arbitrary additional JSON data associated with the event.") public Object getAttributes() { return attributes; @@ -207,49 +256,76 @@ public void setAttributes(Object attributes) { } - public EventV3 connectedSessionID(String connectedSessionID) { + public EventV3 integrationId(String integrationId) { - this.connectedSessionID = connectedSessionID; + this.integrationId = integrationId; return this; } /** - * The ID of the session that happened in the past. - * @return connectedSessionID + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId **/ @javax.annotation.Nullable - @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session that happened in the past.") + @ApiModelProperty(example = "175KJPS947296", value = "The unique ID of the event. Only one event with this ID can be registered. ") - public String getConnectedSessionID() { - return connectedSessionID; + public String getIntegrationId() { + return integrationId; } - public void setConnectedSessionID(String connectedSessionID) { - this.connectedSessionID = connectedSessionID; + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; } - public EventV3 previousEventID(String previousEventID) { + public EventV3 referralCode(String referralCode) { - this.previousEventID = previousEventID; + this.referralCode = referralCode; return this; } /** - * The unique identifier of the event that happened in the past. - * @return previousEventID + * The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. + * @return referralCode **/ @javax.annotation.Nullable - @ApiModelProperty(example = "175KJPS947296", value = "The unique identifier of the event that happened in the past.") + @ApiModelProperty(example = "NT2K54D9", value = "The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. ") - public String getPreviousEventID() { - return previousEventID; + public String getReferralCode() { + return referralCode; } - public void setPreviousEventID(String previousEventID) { - this.previousEventID = previousEventID; + public void setReferralCode(String referralCode) { + this.referralCode = referralCode; + } + + + public EventV3 effects(List effects) { + + this.effects = effects; + return this; + } + + public EventV3 addEffectsItem(Object effectsItem) { + this.effects.add(effectsItem); + return this; + } + + /** + * An array of effects generated by the rules of the enabled campaigns of the Application. You decide how to apply them in your system. See the list of [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). + * @return effects + **/ + @ApiModelProperty(required = true, value = "An array of effects generated by the rules of the enabled campaigns of the Application. You decide how to apply them in your system. See the list of [API effects](https://docs.talon.one/docs/dev/integration-api/api-effects). ") + + public List getEffects() { + return effects; + } + + + public void setEffects(List effects) { + this.effects = effects; } @@ -262,19 +338,22 @@ public boolean equals(java.lang.Object o) { return false; } EventV3 eventV3 = (EventV3) o; - return Objects.equals(this.profileId, eventV3.profileId) && + return Objects.equals(this.connectedSessionId, eventV3.connectedSessionId) && + Objects.equals(this.id, eventV3.id) && + Objects.equals(this.created, eventV3.created) && + Objects.equals(this.applicationId, eventV3.applicationId) && + Objects.equals(this.profileId, eventV3.profileId) && Objects.equals(this.storeIntegrationId, eventV3.storeIntegrationId) && - Objects.equals(this.evaluableCampaignIds, eventV3.evaluableCampaignIds) && - Objects.equals(this.integrationId, eventV3.integrationId) && Objects.equals(this.type, eventV3.type) && Objects.equals(this.attributes, eventV3.attributes) && - Objects.equals(this.connectedSessionID, eventV3.connectedSessionID) && - Objects.equals(this.previousEventID, eventV3.previousEventID); + Objects.equals(this.integrationId, eventV3.integrationId) && + Objects.equals(this.referralCode, eventV3.referralCode) && + Objects.equals(this.effects, eventV3.effects); } @Override public int hashCode() { - return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, integrationId, type, attributes, connectedSessionID, previousEventID); + return Objects.hash(connectedSessionId, id, created, applicationId, profileId, storeIntegrationId, type, attributes, integrationId, referralCode, effects); } @@ -282,14 +361,17 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class EventV3 {\n"); + sb.append(" connectedSessionId: ").append(toIndentedString(connectedSessionId)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); sb.append(" profileId: ").append(toIndentedString(profileId)).append("\n"); sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); - sb.append(" evaluableCampaignIds: ").append(toIndentedString(evaluableCampaignIds)).append("\n"); - sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); - sb.append(" connectedSessionID: ").append(toIndentedString(connectedSessionID)).append("\n"); - sb.append(" previousEventID: ").append(toIndentedString(previousEventID)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); + sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/EventV3Connections.java b/src/main/java/one/talon/model/EventV3Connections.java new file mode 100644 index 00000000..4eede501 --- /dev/null +++ b/src/main/java/one/talon/model/EventV3Connections.java @@ -0,0 +1,99 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * EventV3Connections + */ + +public class EventV3Connections { + public static final String SERIALIZED_NAME_CONNECTED_SESSION_ID = "connectedSessionId"; + @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_ID) + private String connectedSessionId; + + + public EventV3Connections connectedSessionId(String connectedSessionId) { + + this.connectedSessionId = connectedSessionId; + return this; + } + + /** + * The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. + * @return connectedSessionId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail.") + + public String getConnectedSessionId() { + return connectedSessionId; + } + + + public void setConnectedSessionId(String connectedSessionId) { + this.connectedSessionId = connectedSessionId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + EventV3Connections eventV3Connections = (EventV3Connections) o; + return Objects.equals(this.connectedSessionId, eventV3Connections.connectedSessionId); + } + + @Override + public int hashCode() { + return Objects.hash(connectedSessionId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class EventV3Connections {\n"); + sb.append(" connectedSessionId: ").append(toIndentedString(connectedSessionId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/EventV3Entity.java b/src/main/java/one/talon/model/EventV3Entity.java new file mode 100644 index 00000000..24fd2280 --- /dev/null +++ b/src/main/java/one/talon/model/EventV3Entity.java @@ -0,0 +1,99 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * EventV3Entity + */ + +public class EventV3Entity { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + + public EventV3Entity integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + EventV3Entity eventV3Entity = (EventV3Entity) o; + return Objects.equals(this.integrationId, eventV3Entity.integrationId); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class EventV3Entity {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/EventV3ReferralEntity.java b/src/main/java/one/talon/model/EventV3ReferralEntity.java new file mode 100644 index 00000000..5a4d00fe --- /dev/null +++ b/src/main/java/one/talon/model/EventV3ReferralEntity.java @@ -0,0 +1,99 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * EventV3ReferralEntity + */ + +public class EventV3ReferralEntity { + public static final String SERIALIZED_NAME_REFERRAL_CODE = "referralCode"; + @SerializedName(SERIALIZED_NAME_REFERRAL_CODE) + private String referralCode; + + + public EventV3ReferralEntity referralCode(String referralCode) { + + this.referralCode = referralCode; + return this; + } + + /** + * The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. + * @return referralCode + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "NT2K54D9", value = "The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. ") + + public String getReferralCode() { + return referralCode; + } + + + public void setReferralCode(String referralCode) { + this.referralCode = referralCode; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + EventV3ReferralEntity eventV3ReferralEntity = (EventV3ReferralEntity) o; + return Objects.equals(this.referralCode, eventV3ReferralEntity.referralCode); + } + + @Override + public int hashCode() { + return Objects.hash(referralCode); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class EventV3ReferralEntity {\n"); + sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/EventV3RequestEntity.java b/src/main/java/one/talon/model/EventV3RequestEntity.java new file mode 100644 index 00000000..b08af10b --- /dev/null +++ b/src/main/java/one/talon/model/EventV3RequestEntity.java @@ -0,0 +1,309 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * EventV3RequestEntity + */ + +public class EventV3RequestEntity { + public static final String SERIALIZED_NAME_PROFILE_ID = "profileId"; + @SerializedName(SERIALIZED_NAME_PROFILE_ID) + private String profileId; + + public static final String SERIALIZED_NAME_STORE_INTEGRATION_ID = "storeIntegrationId"; + @SerializedName(SERIALIZED_NAME_STORE_INTEGRATION_ID) + private String storeIntegrationId; + + public static final String SERIALIZED_NAME_EVALUABLE_CAMPAIGN_IDS = "evaluableCampaignIds"; + @SerializedName(SERIALIZED_NAME_EVALUABLE_CAMPAIGN_IDS) + private List evaluableCampaignIds = null; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_CONNECTED_SESSION_ID = "connectedSessionId"; + @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_ID) + private String connectedSessionId; + + public static final String SERIALIZED_NAME_REFERRAL_CODE = "referralCode"; + @SerializedName(SERIALIZED_NAME_REFERRAL_CODE) + private String referralCode; + + + public EventV3RequestEntity profileId(String profileId) { + + this.profileId = profileId; + return this; + } + + /** + * ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. + * @return profileId + **/ + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "ID of the customer profile set by your integration layer. **Note:** If the customer does not yet have a known `profileId`, we recommend you use a guest `profileId`. ") + + public String getProfileId() { + return profileId; + } + + + public void setProfileId(String profileId) { + this.profileId = profileId; + } + + + public EventV3RequestEntity storeIntegrationId(String storeIntegrationId) { + + this.storeIntegrationId = storeIntegrationId; + return this; + } + + /** + * The integration ID of the store. You choose this ID when you create a store. + * @return storeIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "STORE-001", value = "The integration ID of the store. You choose this ID when you create a store.") + + public String getStoreIntegrationId() { + return storeIntegrationId; + } + + + public void setStoreIntegrationId(String storeIntegrationId) { + this.storeIntegrationId = storeIntegrationId; + } + + + public EventV3RequestEntity evaluableCampaignIds(List evaluableCampaignIds) { + + this.evaluableCampaignIds = evaluableCampaignIds; + return this; + } + + public EventV3RequestEntity addEvaluableCampaignIdsItem(Long evaluableCampaignIdsItem) { + if (this.evaluableCampaignIds == null) { + this.evaluableCampaignIds = new ArrayList(); + } + this.evaluableCampaignIds.add(evaluableCampaignIdsItem); + return this; + } + + /** + * When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. + * @return evaluableCampaignIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[10, 12]", value = "When using the `dry` query parameter, use this property to list the campaign to be evaluated by the Rule Engine. These campaigns will be evaluated, even if they are disabled, allowing you to test specific campaigns before activating them. ") + + public List getEvaluableCampaignIds() { + return evaluableCampaignIds; + } + + + public void setEvaluableCampaignIds(List evaluableCampaignIds) { + this.evaluableCampaignIds = evaluableCampaignIds; + } + + + public EventV3RequestEntity type(String type) { + + this.type = type; + return this; + } + + /** + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. + * @return type + **/ + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + public EventV3RequestEntity attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute). + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "{\"myAttribute\":\"myValue\"}", value = "Arbitrary additional JSON properties associated with the event. They must be created in the Campaign Manager before setting them with this property. See [creating custom attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes#creating-a-custom-attribute).") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public EventV3RequestEntity integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @ApiModelProperty(example = "175KJPS947296", required = true, value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public EventV3RequestEntity connectedSessionId(String connectedSessionId) { + + this.connectedSessionId = connectedSessionId; + return this; + } + + /** + * The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. + * @return connectedSessionId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail.") + + public String getConnectedSessionId() { + return connectedSessionId; + } + + + public void setConnectedSessionId(String connectedSessionId) { + this.connectedSessionId = connectedSessionId; + } + + + public EventV3RequestEntity referralCode(String referralCode) { + + this.referralCode = referralCode; + return this; + } + + /** + * The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. + * @return referralCode + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "NT2K54D9", value = "The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. ") + + public String getReferralCode() { + return referralCode; + } + + + public void setReferralCode(String referralCode) { + this.referralCode = referralCode; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + EventV3RequestEntity eventV3RequestEntity = (EventV3RequestEntity) o; + return Objects.equals(this.profileId, eventV3RequestEntity.profileId) && + Objects.equals(this.storeIntegrationId, eventV3RequestEntity.storeIntegrationId) && + Objects.equals(this.evaluableCampaignIds, eventV3RequestEntity.evaluableCampaignIds) && + Objects.equals(this.type, eventV3RequestEntity.type) && + Objects.equals(this.attributes, eventV3RequestEntity.attributes) && + Objects.equals(this.integrationId, eventV3RequestEntity.integrationId) && + Objects.equals(this.connectedSessionId, eventV3RequestEntity.connectedSessionId) && + Objects.equals(this.referralCode, eventV3RequestEntity.referralCode); + } + + @Override + public int hashCode() { + return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, type, attributes, integrationId, connectedSessionId, referralCode); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class EventV3RequestEntity {\n"); + sb.append(" profileId: ").append(toIndentedString(profileId)).append("\n"); + sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); + sb.append(" evaluableCampaignIds: ").append(toIndentedString(evaluableCampaignIds)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" connectedSessionId: ").append(toIndentedString(connectedSessionId)).append("\n"); + sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ExcludePriceObservationsRequest.java b/src/main/java/one/talon/model/ExcludePriceObservationsRequest.java new file mode 100644 index 00000000..9c87f131 --- /dev/null +++ b/src/main/java/one/talon/model/ExcludePriceObservationsRequest.java @@ -0,0 +1,133 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * ExcludePriceObservationsRequest + */ + +public class ExcludePriceObservationsRequest { + public static final String SERIALIZED_NAME_IDS = "ids"; + @SerializedName(SERIALIZED_NAME_IDS) + private List ids = new ArrayList(); + + public static final String SERIALIZED_NAME_REASON = "reason"; + @SerializedName(SERIALIZED_NAME_REASON) + private String reason; + + + public ExcludePriceObservationsRequest ids(List ids) { + + this.ids = ids; + return this; + } + + public ExcludePriceObservationsRequest addIdsItem(Long idsItem) { + this.ids.add(idsItem); + return this; + } + + /** + * A list of historical price IDs to exclude from best prior price calculation. Must contain between 1 and 1000 IDs. All IDs must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, and must not already be excluded from best prior price calculation. + * @return ids + **/ + @ApiModelProperty(required = true, value = "A list of historical price IDs to exclude from best prior price calculation. Must contain between 1 and 1000 IDs. All IDs must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, and must not already be excluded from best prior price calculation. ") + + public List getIds() { + return ids; + } + + + public void setIds(List ids) { + this.ids = ids; + } + + + public ExcludePriceObservationsRequest reason(String reason) { + + this.reason = reason; + return this; + } + + /** + * The reason for excluding these historical price IDs. Applies to all IDs in the batch. + * @return reason + **/ + @ApiModelProperty(example = "Incorrect contextID value.", required = true, value = "The reason for excluding these historical price IDs. Applies to all IDs in the batch. ") + + public String getReason() { + return reason; + } + + + public void setReason(String reason) { + this.reason = reason; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ExcludePriceObservationsRequest excludePriceObservationsRequest = (ExcludePriceObservationsRequest) o; + return Objects.equals(this.ids, excludePriceObservationsRequest.ids) && + Objects.equals(this.reason, excludePriceObservationsRequest.reason); + } + + @Override + public int hashCode() { + return Objects.hash(ids, reason); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ExcludePriceObservationsRequest {\n"); + sb.append(" ids: ").append(toIndentedString(ids)).append("\n"); + sb.append(" reason: ").append(toIndentedString(reason)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Experiment.java b/src/main/java/one/talon/model/Experiment.java index 6ffa55a3..ceabf90b 100644 --- a/src/main/java/one/talon/model/Experiment.java +++ b/src/main/java/one/talon/model/Experiment.java @@ -115,6 +115,65 @@ public StateEnum read(final JsonReader jsonReader) throws IOException { @SerializedName(SERIALIZED_NAME_VARIANTS) private List variants = null; + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + */ + @JsonAdapter(GoalTypeEnum.Adapter.class) + public enum GoalTypeEnum { + OTHER("other"), + + MAXIMIZE_REVENUE("maximize_revenue"), + + OPTIMIZE_DISCOUNT_EFFICIENCY("optimize_discount_efficiency"), + + MAXIMIZE_ITEMS_SOLD("maximize_items_sold"); + + private String value; + + GoalTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static GoalTypeEnum fromValue(String value) { + for (GoalTypeEnum b : GoalTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final GoalTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public GoalTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return GoalTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_GOAL_TYPE = "goalType"; + @SerializedName(SERIALIZED_NAME_GOAL_TYPE) + private GoalTypeEnum goalType; + + public static final String SERIALIZED_NAME_GOAL_DESCRIPTION = "goalDescription"; + @SerializedName(SERIALIZED_NAME_GOAL_DESCRIPTION) + private String goalDescription; + public static final String SERIALIZED_NAME_DELETEDAT = "deletedat"; @SerializedName(SERIALIZED_NAME_DELETEDAT) private OffsetDateTime deletedat; @@ -308,6 +367,51 @@ public void setVariants(List variants) { } + public Experiment goalType(GoalTypeEnum goalType) { + + this.goalType = goalType; + return this; + } + + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + * @return goalType + **/ + @ApiModelProperty(required = true, value = "The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. ") + + public GoalTypeEnum getGoalType() { + return goalType; + } + + + public void setGoalType(GoalTypeEnum goalType) { + this.goalType = goalType; + } + + + public Experiment goalDescription(String goalDescription) { + + this.goalDescription = goalDescription; + return this; + } + + /** + * A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. + * @return goalDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Offering free shipping will increase average order revenue more than a 10% discount", value = "A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. ") + + public String getGoalDescription() { + return goalDescription; + } + + + public void setGoalDescription(String goalDescription) { + this.goalDescription = goalDescription; + } + + public Experiment deletedat(OffsetDateTime deletedat) { this.deletedat = deletedat; @@ -348,12 +452,14 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.activated, experiment.activated) && Objects.equals(this.state, experiment.state) && Objects.equals(this.variants, experiment.variants) && + Objects.equals(this.goalType, experiment.goalType) && + Objects.equals(this.goalDescription, experiment.goalDescription) && Objects.equals(this.deletedat, experiment.deletedat); } @Override public int hashCode() { - return Objects.hash(id, created, applicationId, isVariantAssignmentExternal, campaign, activated, state, variants, deletedat); + return Objects.hash(id, created, applicationId, isVariantAssignmentExternal, campaign, activated, state, variants, goalType, goalDescription, deletedat); } @@ -369,6 +475,8 @@ public String toString() { sb.append(" activated: ").append(toIndentedString(activated)).append("\n"); sb.append(" state: ").append(toIndentedString(state)).append("\n"); sb.append(" variants: ").append(toIndentedString(variants)).append("\n"); + sb.append(" goalType: ").append(toIndentedString(goalType)).append("\n"); + sb.append(" goalDescription: ").append(toIndentedString(goalDescription)).append("\n"); sb.append(" deletedat: ").append(toIndentedString(deletedat)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/ExperimentConfidenceTimeline.java b/src/main/java/one/talon/model/ExperimentConfidenceTimeline.java new file mode 100644 index 00000000..c2ffd3ec --- /dev/null +++ b/src/main/java/one/talon/model/ExperimentConfidenceTimeline.java @@ -0,0 +1,106 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.ExperimentConfidenceTimelineDataPoint; + +/** + * ExperimentConfidenceTimeline + */ + +public class ExperimentConfidenceTimeline { + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private List data = new ArrayList(); + + + public ExperimentConfidenceTimeline data(List data) { + + this.data = data; + return this; + } + + public ExperimentConfidenceTimeline addDataItem(ExperimentConfidenceTimelineDataPoint dataItem) { + this.data.add(dataItem); + return this; + } + + /** + * Daily cumulative confidence values ordered chronologically from experiment start to end, or to today if the experiment is still running. Empty if the experiment has no data yet. + * @return data + **/ + @ApiModelProperty(required = true, value = "Daily cumulative confidence values ordered chronologically from experiment start to end, or to today if the experiment is still running. Empty if the experiment has no data yet. ") + + public List getData() { + return data; + } + + + public void setData(List data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ExperimentConfidenceTimeline experimentConfidenceTimeline = (ExperimentConfidenceTimeline) o; + return Objects.equals(this.data, experimentConfidenceTimeline.data); + } + + @Override + public int hashCode() { + return Objects.hash(data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ExperimentConfidenceTimeline {\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ExperimentConfidenceTimelineDataPoint.java b/src/main/java/one/talon/model/ExperimentConfidenceTimelineDataPoint.java new file mode 100644 index 00000000..9fd93b38 --- /dev/null +++ b/src/main/java/one/talon/model/ExperimentConfidenceTimelineDataPoint.java @@ -0,0 +1,128 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.ExperimentVariantResultConfidence; +import org.threeten.bp.OffsetDateTime; + +/** + * ExperimentConfidenceTimelineDataPoint + */ + +public class ExperimentConfidenceTimelineDataPoint { + public static final String SERIALIZED_NAME_DATE = "date"; + @SerializedName(SERIALIZED_NAME_DATE) + private OffsetDateTime date; + + public static final String SERIALIZED_NAME_CONFIDENCE = "confidence"; + @SerializedName(SERIALIZED_NAME_CONFIDENCE) + private ExperimentVariantResultConfidence confidence; + + + public ExperimentConfidenceTimelineDataPoint date(OffsetDateTime date) { + + this.date = date; + return this; + } + + /** + * The date-time this data point represents. + * @return date + **/ + @ApiModelProperty(example = "2024-01-15T00:00+07:00", required = true, value = "The date-time this data point represents.") + + public OffsetDateTime getDate() { + return date; + } + + + public void setDate(OffsetDateTime date) { + this.date = date; + } + + + public ExperimentConfidenceTimelineDataPoint confidence(ExperimentVariantResultConfidence confidence) { + + this.confidence = confidence; + return this; + } + + /** + * Get confidence + * @return confidence + **/ + @ApiModelProperty(required = true, value = "") + + public ExperimentVariantResultConfidence getConfidence() { + return confidence; + } + + + public void setConfidence(ExperimentVariantResultConfidence confidence) { + this.confidence = confidence; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ExperimentConfidenceTimelineDataPoint experimentConfidenceTimelineDataPoint = (ExperimentConfidenceTimelineDataPoint) o; + return Objects.equals(this.date, experimentConfidenceTimelineDataPoint.date) && + Objects.equals(this.confidence, experimentConfidenceTimelineDataPoint.confidence); + } + + @Override + public int hashCode() { + return Objects.hash(date, confidence); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ExperimentConfidenceTimelineDataPoint {\n"); + sb.append(" date: ").append(toIndentedString(date)).append("\n"); + sb.append(" confidence: ").append(toIndentedString(confidence)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ExperimentCopyExperiment.java b/src/main/java/one/talon/model/ExperimentCopyExperiment.java index 549ac853..5d2edcd0 100644 --- a/src/main/java/one/talon/model/ExperimentCopyExperiment.java +++ b/src/main/java/one/talon/model/ExperimentCopyExperiment.java @@ -38,6 +38,65 @@ public class ExperimentCopyExperiment { @SerializedName(SERIALIZED_NAME_CAMPAIGN) private ExperimentCampaignCopy campaign; + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the value from the source experiment is used. + */ + @JsonAdapter(GoalTypeEnum.Adapter.class) + public enum GoalTypeEnum { + OTHER("other"), + + MAXIMIZE_REVENUE("maximize_revenue"), + + MAXIMIZE_ITEMS_SOLD("maximize_items_sold"), + + OPTIMIZE_DISCOUNT_EFFICIENCY("optimize_discount_efficiency"); + + private String value; + + GoalTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static GoalTypeEnum fromValue(String value) { + for (GoalTypeEnum b : GoalTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final GoalTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public GoalTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return GoalTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_GOAL_TYPE = "goalType"; + @SerializedName(SERIALIZED_NAME_GOAL_TYPE) + private GoalTypeEnum goalType; + + public static final String SERIALIZED_NAME_GOAL_DESCRIPTION = "goalDescription"; + @SerializedName(SERIALIZED_NAME_GOAL_DESCRIPTION) + private String goalDescription; + public ExperimentCopyExperiment isVariantAssignmentExternal(Boolean isVariantAssignmentExternal) { @@ -83,6 +142,52 @@ public void setCampaign(ExperimentCampaignCopy campaign) { } + public ExperimentCopyExperiment goalType(GoalTypeEnum goalType) { + + this.goalType = goalType; + return this; + } + + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the value from the source experiment is used. + * @return goalType + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the value from the source experiment is used. ") + + public GoalTypeEnum getGoalType() { + return goalType; + } + + + public void setGoalType(GoalTypeEnum goalType) { + this.goalType = goalType; + } + + + public ExperimentCopyExperiment goalDescription(String goalDescription) { + + this.goalDescription = goalDescription; + return this; + } + + /** + * A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the value from the source experiment is used. + * @return goalDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the value from the source experiment is used. ") + + public String getGoalDescription() { + return goalDescription; + } + + + public void setGoalDescription(String goalDescription) { + this.goalDescription = goalDescription; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -93,12 +198,14 @@ public boolean equals(java.lang.Object o) { } ExperimentCopyExperiment experimentCopyExperiment = (ExperimentCopyExperiment) o; return Objects.equals(this.isVariantAssignmentExternal, experimentCopyExperiment.isVariantAssignmentExternal) && - Objects.equals(this.campaign, experimentCopyExperiment.campaign); + Objects.equals(this.campaign, experimentCopyExperiment.campaign) && + Objects.equals(this.goalType, experimentCopyExperiment.goalType) && + Objects.equals(this.goalDescription, experimentCopyExperiment.goalDescription); } @Override public int hashCode() { - return Objects.hash(isVariantAssignmentExternal, campaign); + return Objects.hash(isVariantAssignmentExternal, campaign, goalType, goalDescription); } @@ -108,6 +215,8 @@ public String toString() { sb.append("class ExperimentCopyExperiment {\n"); sb.append(" isVariantAssignmentExternal: ").append(toIndentedString(isVariantAssignmentExternal)).append("\n"); sb.append(" campaign: ").append(toIndentedString(campaign)).append("\n"); + sb.append(" goalType: ").append(toIndentedString(goalType)).append("\n"); + sb.append(" goalDescription: ").append(toIndentedString(goalDescription)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/ExtendLoyaltyPointsExpiryDateEffectProps.java b/src/main/java/one/talon/model/ExtendLoyaltyPointsExpiryDateEffectProps.java index 2edbd7f8..c39f2ae3 100644 --- a/src/main/java/one/talon/model/ExtendLoyaltyPointsExpiryDateEffectProps.java +++ b/src/main/java/one/talon/model/ExtendLoyaltyPointsExpiryDateEffectProps.java @@ -28,9 +28,9 @@ import one.talon.model.LoyaltyLedgerEntryExpiryDateChange; /** - * The properties specific to the \"extendLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"extend expiry date\" effect. The current expiry date gets extended by the time frame given in the effect. + * If loyalty points have an expiry date, this effect extends the expiry of all active and pending point transactions by a selected duration. */ -@ApiModel(description = "The properties specific to the \"extendLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"extend expiry date\" effect. The current expiry date gets extended by the time frame given in the effect. ") +@ApiModel(description = "If loyalty points have an expiry date, this effect extends the expiry of all active and pending point transactions by a selected duration. ") public class ExtendLoyaltyPointsExpiryDateEffectProps { public static final String SERIALIZED_NAME_PROGRAM_ID = "programId"; @@ -79,10 +79,10 @@ public ExtendLoyaltyPointsExpiryDateEffectProps subLedgerId(String subLedgerId) } /** - * API name of the loyalty program subledger that contains these points. added. + * API name of the loyalty program subledger that contains these points. * @return subLedgerId **/ - @ApiModelProperty(required = true, value = "API name of the loyalty program subledger that contains these points. added.") + @ApiModelProperty(required = true, value = "API name of the loyalty program subledger that contains these points.") public String getSubLedgerId() { return subLedgerId; diff --git a/src/main/java/one/talon/model/FeatureFlagUpdate.java b/src/main/java/one/talon/model/FeatureFlagUpdate.java new file mode 100644 index 00000000..3fb60358 --- /dev/null +++ b/src/main/java/one/talon/model/FeatureFlagUpdate.java @@ -0,0 +1,126 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * FeatureFlagUpdate + */ + +public class FeatureFlagUpdate { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private String value; + + + public FeatureFlagUpdate name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the feature flag. + * @return name + **/ + @ApiModelProperty(example = "canCreateCampaignFromTemplate", required = true, value = "The name of the feature flag.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public FeatureFlagUpdate value(String value) { + + this.value = value; + return this; + } + + /** + * The value of the feature flag. + * @return value + **/ + @ApiModelProperty(example = "true", required = true, value = "The value of the feature flag.") + + public String getValue() { + return value; + } + + + public void setValue(String value) { + this.value = value; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FeatureFlagUpdate featureFlagUpdate = (FeatureFlagUpdate) o; + return Objects.equals(this.name, featureFlagUpdate.name) && + Objects.equals(this.value, featureFlagUpdate.value); + } + + @Override + public int hashCode() { + return Objects.hash(name, value); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FeatureFlagUpdate {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/FilterAndMapValuesSelectorStep.java b/src/main/java/one/talon/model/FilterAndMapValuesSelectorStep.java new file mode 100644 index 00000000..620f8ba4 --- /dev/null +++ b/src/main/java/one/talon/model/FilterAndMapValuesSelectorStep.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.SelectorValueMapRef; + +/** + * Keeps items that exist in the value map, and attaches each kept item's mapped value. + */ +@ApiModel(description = "Keeps items that exist in the value map, and attaches each kept item's mapped value.") + +public class FilterAndMapValuesSelectorStep { + /** + * A step discriminator of type `filterAndMapValues`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + FILTERANDMAPVALUES("filterAndMapValues"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_VALUE_MAP = "valueMap"; + @SerializedName(SERIALIZED_NAME_VALUE_MAP) + private SelectorValueMapRef valueMap; + + + public FilterAndMapValuesSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `filterAndMapValues`. + * @return type + **/ + @ApiModelProperty(example = "filterAndMapValues", required = true, value = "A step discriminator of type `filterAndMapValues`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public FilterAndMapValuesSelectorStep valueMap(SelectorValueMapRef valueMap) { + + this.valueMap = valueMap; + return this; + } + + /** + * Get valueMap + * @return valueMap + **/ + @ApiModelProperty(required = true, value = "") + + public SelectorValueMapRef getValueMap() { + return valueMap; + } + + + public void setValueMap(SelectorValueMapRef valueMap) { + this.valueMap = valueMap; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FilterAndMapValuesSelectorStep filterAndMapValuesSelectorStep = (FilterAndMapValuesSelectorStep) o; + return Objects.equals(this.type, filterAndMapValuesSelectorStep.type) && + Objects.equals(this.valueMap, filterAndMapValuesSelectorStep.valueMap); + } + + @Override + public int hashCode() { + return Objects.hash(type, valueMap); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FilterAndMapValuesSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" valueMap: ").append(toIndentedString(valueMap)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/FilterSelectorStep.java b/src/main/java/one/talon/model/FilterSelectorStep.java new file mode 100644 index 00000000..0cecef8f --- /dev/null +++ b/src/main/java/one/talon/model/FilterSelectorStep.java @@ -0,0 +1,172 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Filters only items that match a predicate block. + */ +@ApiModel(description = "Filters only items that match a predicate block.") + +public class FilterSelectorStep { + /** + * A step discriminator of type `filter`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + FILTER("filter"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_PREDICATE = "predicate"; + @SerializedName(SERIALIZED_NAME_PREDICATE) + private Object predicate; + + + public FilterSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `filter`. + * @return type + **/ + @ApiModelProperty(example = "filter", required = true, value = "A step discriminator of type `filter`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public FilterSelectorStep predicate(Object predicate) { + + this.predicate = predicate; + return this; + } + + /** + * Describes a part of the logic of the rule. + * @return predicate + **/ + @ApiModelProperty(required = true, value = "Describes a part of the logic of the rule.") + + public Object getPredicate() { + return predicate; + } + + + public void setPredicate(Object predicate) { + this.predicate = predicate; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FilterSelectorStep filterSelectorStep = (FilterSelectorStep) o; + return Objects.equals(this.type, filterSelectorStep.type) && + Objects.equals(this.predicate, filterSelectorStep.predicate); + } + + @Override + public int hashCode() { + return Objects.hash(type, predicate); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FilterSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" predicate: ").append(toIndentedString(predicate)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GeoJSONGeometryCollection.java b/src/main/java/one/talon/model/GeoJSONGeometryCollection.java new file mode 100644 index 00000000..2b7a9608 --- /dev/null +++ b/src/main/java/one/talon/model/GeoJSONGeometryCollection.java @@ -0,0 +1,179 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A group of different shapes combined into a single location, following the GeoJSON format. + */ +@ApiModel(description = "A group of different shapes combined into a single location, following the GeoJSON format.") + +public class GeoJSONGeometryCollection { + /** + * The geometry type discriminator. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + GEOMETRYCOLLECTION("GeometryCollection"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_GEOMETRIES = "geometries"; + @SerializedName(SERIALIZED_NAME_GEOMETRIES) + private List geometries = new ArrayList(); + + + public GeoJSONGeometryCollection type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The geometry type discriminator. + * @return type + **/ + @ApiModelProperty(required = true, value = "The geometry type discriminator.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public GeoJSONGeometryCollection geometries(List geometries) { + + this.geometries = geometries; + return this; + } + + public GeoJSONGeometryCollection addGeometriesItem(Object geometriesItem) { + this.geometries.add(geometriesItem); + return this; + } + + /** + * The shapes contained in this group. + * @return geometries + **/ + @ApiModelProperty(required = true, value = "The shapes contained in this group.") + + public List getGeometries() { + return geometries; + } + + + public void setGeometries(List geometries) { + this.geometries = geometries; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GeoJSONGeometryCollection geoJSONGeometryCollection = (GeoJSONGeometryCollection) o; + return Objects.equals(this.type, geoJSONGeometryCollection.type) && + Objects.equals(this.geometries, geoJSONGeometryCollection.geometries); + } + + @Override + public int hashCode() { + return Objects.hash(type, geometries); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GeoJSONGeometryCollection {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" geometries: ").append(toIndentedString(geometries)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GeoJSONMultiPolygon.java b/src/main/java/one/talon/model/GeoJSONMultiPolygon.java new file mode 100644 index 00000000..3e94b0f4 --- /dev/null +++ b/src/main/java/one/talon/model/GeoJSONMultiPolygon.java @@ -0,0 +1,180 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; + +/** + * One or more separate shapes grouped together as a single location, following the GeoJSON format. + */ +@ApiModel(description = "One or more separate shapes grouped together as a single location, following the GeoJSON format.") + +public class GeoJSONMultiPolygon { + /** + * The geometry type discriminator. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + MULTIPOLYGON("MultiPolygon"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_COORDINATES = "coordinates"; + @SerializedName(SERIALIZED_NAME_COORDINATES) + private List>>> coordinates = new ArrayList>>>(); + + + public GeoJSONMultiPolygon type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The geometry type discriminator. + * @return type + **/ + @ApiModelProperty(required = true, value = "The geometry type discriminator.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public GeoJSONMultiPolygon coordinates(List>>> coordinates) { + + this.coordinates = coordinates; + return this; + } + + public GeoJSONMultiPolygon addCoordinatesItem(List>> coordinatesItem) { + this.coordinates.add(coordinatesItem); + return this; + } + + /** + * The shapes in this group. Each one follows the same boundary structure as a polygon. + * @return coordinates + **/ + @ApiModelProperty(example = "[[[[13, 52.3], [13.8, 52.3], [13.8, 52.7], [13, 52.7], [13, 52.3]]]]", required = true, value = "The shapes in this group. Each one follows the same boundary structure as a polygon.") + + public List>>> getCoordinates() { + return coordinates; + } + + + public void setCoordinates(List>>> coordinates) { + this.coordinates = coordinates; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GeoJSONMultiPolygon geoJSONMultiPolygon = (GeoJSONMultiPolygon) o; + return Objects.equals(this.type, geoJSONMultiPolygon.type) && + Objects.equals(this.coordinates, geoJSONMultiPolygon.coordinates); + } + + @Override + public int hashCode() { + return Objects.hash(type, coordinates); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GeoJSONMultiPolygon {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" coordinates: ").append(toIndentedString(coordinates)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GeoJSONPoint.java b/src/main/java/one/talon/model/GeoJSONPoint.java new file mode 100644 index 00000000..ae8f4a3e --- /dev/null +++ b/src/main/java/one/talon/model/GeoJSONPoint.java @@ -0,0 +1,180 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; + +/** + * A single point on a map, defined by its longitude and latitude coordinates, following the GeoJSON format. + */ +@ApiModel(description = "A single point on a map, defined by its longitude and latitude coordinates, following the GeoJSON format.") + +public class GeoJSONPoint { + /** + * The geometry type discriminator. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + POINT("Point"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_COORDINATES = "coordinates"; + @SerializedName(SERIALIZED_NAME_COORDINATES) + private List coordinates = new ArrayList(); + + + public GeoJSONPoint type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The geometry type discriminator. + * @return type + **/ + @ApiModelProperty(required = true, value = "The geometry type discriminator.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public GeoJSONPoint coordinates(List coordinates) { + + this.coordinates = coordinates; + return this; + } + + public GeoJSONPoint addCoordinatesItem(BigDecimal coordinatesItem) { + this.coordinates.add(coordinatesItem); + return this; + } + + /** + * The longitude and latitude coordinates of the point, optionally followed by altitude. + * @return coordinates + **/ + @ApiModelProperty(example = "[13.405, 52.52]", required = true, value = "The longitude and latitude coordinates of the point, optionally followed by altitude.") + + public List getCoordinates() { + return coordinates; + } + + + public void setCoordinates(List coordinates) { + this.coordinates = coordinates; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GeoJSONPoint geoJSONPoint = (GeoJSONPoint) o; + return Objects.equals(this.type, geoJSONPoint.type) && + Objects.equals(this.coordinates, geoJSONPoint.coordinates); + } + + @Override + public int hashCode() { + return Objects.hash(type, coordinates); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GeoJSONPoint {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" coordinates: ").append(toIndentedString(coordinates)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GeoJSONPolygon.java b/src/main/java/one/talon/model/GeoJSONPolygon.java new file mode 100644 index 00000000..bed25002 --- /dev/null +++ b/src/main/java/one/talon/model/GeoJSONPolygon.java @@ -0,0 +1,180 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; + +/** + * A shape formed by one or more boundaries, following the GeoJSON format. The first boundary defines the outer edge of the shape; any additional boundaries define holes within the shape. + */ +@ApiModel(description = "A shape formed by one or more boundaries, following the GeoJSON format. The first boundary defines the outer edge of the shape; any additional boundaries define holes within the shape.") + +public class GeoJSONPolygon { + /** + * The geometry type discriminator. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + POLYGON("Polygon"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_COORDINATES = "coordinates"; + @SerializedName(SERIALIZED_NAME_COORDINATES) + private List>> coordinates = new ArrayList>>(); + + + public GeoJSONPolygon type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The geometry type discriminator. + * @return type + **/ + @ApiModelProperty(required = true, value = "The geometry type discriminator.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public GeoJSONPolygon coordinates(List>> coordinates) { + + this.coordinates = coordinates; + return this; + } + + public GeoJSONPolygon addCoordinatesItem(List> coordinatesItem) { + this.coordinates.add(coordinatesItem); + return this; + } + + /** + * The boundaries that make up the shape. Each boundary is a closed loop of longitude and latitude points, where the first and last point are the same. + * @return coordinates + **/ + @ApiModelProperty(example = "[[[13, 52.3], [13.8, 52.3], [13.8, 52.7], [13, 52.7], [13, 52.3]]]", required = true, value = "The boundaries that make up the shape. Each boundary is a closed loop of longitude and latitude points, where the first and last point are the same.") + + public List>> getCoordinates() { + return coordinates; + } + + + public void setCoordinates(List>> coordinates) { + this.coordinates = coordinates; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GeoJSONPolygon geoJSONPolygon = (GeoJSONPolygon) o; + return Objects.equals(this.type, geoJSONPolygon.type) && + Objects.equals(this.coordinates, geoJSONPolygon.coordinates); + } + + @Override + public int hashCode() { + return Objects.hash(type, coordinates); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GeoJSONPolygon {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" coordinates: ").append(toIndentedString(coordinates)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GiveawayPoolReference.java b/src/main/java/one/talon/model/GiveawayPoolReference.java new file mode 100644 index 00000000..85b3d0b1 --- /dev/null +++ b/src/main/java/one/talon/model/GiveawayPoolReference.java @@ -0,0 +1,118 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The giveaway pool from which a giveaway is awarded. + */ +@ApiModel(description = "The giveaway pool from which a giveaway is awarded.") + +public class GiveawayPoolReference { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + + public GiveawayPoolReference id(Long id) { + + this.id = id; + return this; + } + + /** + * The unique identifier of the giveaway pool. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The unique identifier of the giveaway pool.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + /** + * The display name of the giveaway pool. + * @return name + **/ + @ApiModelProperty(example = "Summer Campaign Pool", required = true, value = "The display name of the giveaway pool.") + + public String getName() { + return name; + } + + + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GiveawayPoolReference giveawayPoolReference = (GiveawayPoolReference) o; + return Objects.equals(this.id, giveawayPoolReference.id) && + Objects.equals(this.name, giveawayPoolReference.name); + } + + @Override + public int hashCode() { + return Objects.hash(id, name); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GiveawayPoolReference {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/GroupBlock.java b/src/main/java/one/talon/model/GroupBlock.java new file mode 100644 index 00000000..43d6fca0 --- /dev/null +++ b/src/main/java/one/talon/model/GroupBlock.java @@ -0,0 +1,327 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * A structural combinator block that groups child blocks using a logical operator. Evaluates to true when its operator condition is satisfied across all child blocks. + */ +@ApiModel(description = "A structural combinator block that groups child blocks using a logical operator. Evaluates to true when its operator condition is satisfied across all child blocks.") + +public class GroupBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * Logical operator applied across child blocks. `all` requires every child to pass, `atLeastOne` requires at least one, `none` requires all to fail. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + ALL("all"), + + ATLEASTONE("atLeastOne"), + + NONE("none"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_BLOCKS = "blocks"; + @SerializedName(SERIALIZED_NAME_BLOCKS) + private List blocks = new ArrayList(); + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public GroupBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public GroupBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * Logical operator applied across child blocks. `all` requires every child to pass, `atLeastOne` requires at least one, `none` requires all to fail. + * @return operator + **/ + @ApiModelProperty(required = true, value = "Logical operator applied across child blocks. `all` requires every child to pass, `atLeastOne` requires at least one, `none` requires all to fail.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public GroupBlock blocks(List blocks) { + + this.blocks = blocks; + return this; + } + + public GroupBlock addBlocksItem(Object blocksItem) { + this.blocks.add(blocksItem); + return this; + } + + /** + * Child blocks evaluated according to the operator. + * @return blocks + **/ + @ApiModelProperty(required = true, value = "Child blocks evaluated according to the operator.") + + public List getBlocks() { + return blocks; + } + + + public void setBlocks(List blocks) { + this.blocks = blocks; + } + + + public GroupBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public GroupBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + public GroupBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public GroupBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GroupBlock groupBlock = (GroupBlock) o; + return Objects.equals(this.id, groupBlock.id) && + Objects.equals(this.type, groupBlock.type) && + Objects.equals(this.tags, groupBlock.tags) && + Objects.equals(this.operator, groupBlock.operator) && + Objects.equals(this.blocks, groupBlock.blocks) && + Objects.equals(this.onFailure, groupBlock.onFailure) && + Objects.equals(this.onError, groupBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, blocks, onFailure, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class GroupBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" blocks: ").append(toIndentedString(blocks)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/History.java b/src/main/java/one/talon/model/History.java index 15bea378..6a1b832e 100644 --- a/src/main/java/one/talon/model/History.java +++ b/src/main/java/one/talon/model/History.java @@ -24,6 +24,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.BestPriorPriceMetadata; import org.threeten.bp.OffsetDateTime; @@ -40,9 +42,9 @@ public class History { @SerializedName(SERIALIZED_NAME_OBSERVED_AT) private OffsetDateTime observedAt; - public static final String SERIALIZED_NAME_CONTEXT_ID = "contextId"; - @SerializedName(SERIALIZED_NAME_CONTEXT_ID) - private String contextId; + public static final String SERIALIZED_NAME_CONTEXT_IDS = "contextIds"; + @SerializedName(SERIALIZED_NAME_CONTEXT_IDS) + private List contextIds = new ArrayList(); public static final String SERIALIZED_NAME_PRICE = "price"; @SerializedName(SERIALIZED_NAME_PRICE) @@ -56,6 +58,14 @@ public class History { @SerializedName(SERIALIZED_NAME_TARGET) private Object target; + public static final String SERIALIZED_NAME_EXCLUDED_AT = "excludedAt"; + @SerializedName(SERIALIZED_NAME_EXCLUDED_AT) + private OffsetDateTime excludedAt; + + public static final String SERIALIZED_NAME_EXCLUSION_REASON = "exclusionReason"; + @SerializedName(SERIALIZED_NAME_EXCLUSION_REASON) + private String exclusionReason; + public History id(Long id) { @@ -89,7 +99,7 @@ public History observedAt(OffsetDateTime observedAt) { * The date and time when the price was observed. * @return observedAt **/ - @ApiModelProperty(example = "2020-11-10T23:00Z", required = true, value = "The date and time when the price was observed.") + @ApiModelProperty(example = "2025-11-10T23:00Z", required = true, value = "The date and time when the price was observed.") public OffsetDateTime getObservedAt() { return observedAt; @@ -101,25 +111,30 @@ public void setObservedAt(OffsetDateTime observedAt) { } - public History contextId(String contextId) { + public History contextIds(List contextIds) { - this.contextId = contextId; + this.contextIds = contextIds; + return this; + } + + public History addContextIdsItem(String contextIdsItem) { + this.contextIds.add(contextIdsItem); return this; } /** - * Identifier of the relevant context at the time the price was observed (e.g. summer sale). - * @return contextId + * The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. + * @return contextIds **/ - @ApiModelProperty(example = "Summer Sale 2025", required = true, value = "Identifier of the relevant context at the time the price was observed (e.g. summer sale). ") + @ApiModelProperty(example = "[SpringSale, SummerSale2025]", required = true, value = "The identifiers of the relevant context at the time the price was observed. Includes the context IDs of any price adjustments and of the campaigns that influenced the final price. ") - public String getContextId() { - return contextId; + public List getContextIds() { + return contextIds; } - public void setContextId(String contextId) { - this.contextId = contextId; + public void setContextIds(List contextIds) { + this.contextIds = contextIds; } @@ -189,6 +204,52 @@ public void setTarget(Object target) { } + public History excludedAt(OffsetDateTime excludedAt) { + + this.excludedAt = excludedAt; + return this; + } + + /** + * The date and time when the historical price ID was excluded. + * @return excludedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2025-11-10T23:00Z", value = "The date and time when the historical price ID was excluded.") + + public OffsetDateTime getExcludedAt() { + return excludedAt; + } + + + public void setExcludedAt(OffsetDateTime excludedAt) { + this.excludedAt = excludedAt; + } + + + public History exclusionReason(String exclusionReason) { + + this.exclusionReason = exclusionReason; + return this; + } + + /** + * The reason for excluding this historical price ID. + * @return exclusionReason + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Incorrect contextID value", value = "The reason for excluding this historical price ID.") + + public String getExclusionReason() { + return exclusionReason; + } + + + public void setExclusionReason(String exclusionReason) { + this.exclusionReason = exclusionReason; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -200,15 +261,17 @@ public boolean equals(java.lang.Object o) { History history = (History) o; return Objects.equals(this.id, history.id) && Objects.equals(this.observedAt, history.observedAt) && - Objects.equals(this.contextId, history.contextId) && + Objects.equals(this.contextIds, history.contextIds) && Objects.equals(this.price, history.price) && Objects.equals(this.metadata, history.metadata) && - Objects.equals(this.target, history.target); + Objects.equals(this.target, history.target) && + Objects.equals(this.excludedAt, history.excludedAt) && + Objects.equals(this.exclusionReason, history.exclusionReason); } @Override public int hashCode() { - return Objects.hash(id, observedAt, contextId, price, metadata, target); + return Objects.hash(id, observedAt, contextIds, price, metadata, target, excludedAt, exclusionReason); } @@ -218,10 +281,12 @@ public String toString() { sb.append("class History {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" observedAt: ").append(toIndentedString(observedAt)).append("\n"); - sb.append(" contextId: ").append(toIndentedString(contextId)).append("\n"); + sb.append(" contextIds: ").append(toIndentedString(contextIds)).append("\n"); sb.append(" price: ").append(toIndentedString(price)).append("\n"); sb.append(" metadata: ").append(toIndentedString(metadata)).append("\n"); sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append(" excludedAt: ").append(toIndentedString(excludedAt)).append("\n"); + sb.append(" exclusionReason: ").append(toIndentedString(exclusionReason)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IncreaseAchievementProgressEffectProps.java b/src/main/java/one/talon/model/IncreaseAchievementProgressEffectProps.java index 398b8021..df93e340 100644 --- a/src/main/java/one/talon/model/IncreaseAchievementProgressEffectProps.java +++ b/src/main/java/one/talon/model/IncreaseAchievementProgressEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"increaseAchievementProgress\" effect. This gets triggered whenever a validated rule contained an \"increase customer progress\" effect. + * This effect indicates that the customer's progress in an achievement was updated during the current session. It is triggered when a rule using the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect is successfully validated. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), any customer progress exceeding the target automatically starts a new iteration. This generates a new `progressTrackerId` for each iteration, and there can be multiple progress updates for the same achievement from a single validation of this effect. */ -@ApiModel(description = "The properties specific to the \"increaseAchievementProgress\" effect. This gets triggered whenever a validated rule contained an \"increase customer progress\" effect.") +@ApiModel(description = "This effect indicates that the customer's progress in an achievement was updated during the current session. It is triggered when a rule using the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect is successfully validated. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), any customer progress exceeding the target automatically starts a new iteration. This generates a new `progressTrackerId` for each iteration, and there can be multiple progress updates for the same achievement from a single validation of this effect.") public class IncreaseAchievementProgressEffectProps { public static final String SERIALIZED_NAME_ACHIEVEMENT_ID = "achievementId"; @@ -111,11 +111,11 @@ public IncreaseAchievementProgressEffectProps progressTrackerId(Long progressTra } /** - * The internal ID of the achievement progress tracker. + * The internal ID of the customer progress tracker. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. * @return progressTrackerId **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The internal ID of the achievement progress tracker.") + @ApiModelProperty(value = "The internal ID of the customer progress tracker. For [on-completion achievements](https://docs.talon.one/docs/product/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration.") public Long getProgressTrackerId() { return progressTrackerId; @@ -134,10 +134,10 @@ public IncreaseAchievementProgressEffectProps delta(BigDecimal delta) { } /** - * The value by which the customer's current progress in the achievement is increased. + * The value by which the customer's current progress in the achievement has increased. * @return delta **/ - @ApiModelProperty(required = true, value = "The value by which the customer's current progress in the achievement is increased.") + @ApiModelProperty(required = true, value = "The value by which the customer's current progress in the achievement has increased.") public BigDecimal getDelta() { return delta; diff --git a/src/main/java/one/talon/model/InlineResponse20032.java b/src/main/java/one/talon/model/InlineResponse20032.java index 94cb1d87..41140f38 100644 --- a/src/main/java/one/talon/model/InlineResponse20032.java +++ b/src/main/java/one/talon/model/InlineResponse20032.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationEvent; +import one.talon.model.ApplicationSession; /** * InlineResponse20032 @@ -36,9 +36,13 @@ public class InlineResponse20032 { @SerializedName(SERIALIZED_NAME_HAS_MORE) private Boolean hasMore; + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; + @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) + private Long totalResultSize; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20032 hasMore(Boolean hasMore) { @@ -51,7 +55,8 @@ public InlineResponse20032 hasMore(Boolean hasMore) { * Get hasMore * @return hasMore **/ - @ApiModelProperty(required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "") public Boolean getHasMore() { return hasMore; @@ -63,13 +68,36 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20032 data(List data) { + public InlineResponse20032 totalResultSize(Long totalResultSize) { + + this.totalResultSize = totalResultSize; + return this; + } + + /** + * Get totalResultSize + * @return totalResultSize + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Long getTotalResultSize() { + return totalResultSize; + } + + + public void setTotalResultSize(Long totalResultSize) { + this.totalResultSize = totalResultSize; + } + + + public InlineResponse20032 data(List data) { this.data = data; return this; } - public InlineResponse20032 addDataItem(ApplicationEvent dataItem) { + public InlineResponse20032 addDataItem(ApplicationSession dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +108,12 @@ public InlineResponse20032 addDataItem(ApplicationEvent dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -100,12 +128,13 @@ public boolean equals(java.lang.Object o) { } InlineResponse20032 inlineResponse20032 = (InlineResponse20032) o; return Objects.equals(this.hasMore, inlineResponse20032.hasMore) && + Objects.equals(this.totalResultSize, inlineResponse20032.totalResultSize) && Objects.equals(this.data, inlineResponse20032.data); } @Override public int hashCode() { - return Objects.hash(hasMore, data); + return Objects.hash(hasMore, totalResultSize, data); } @@ -114,6 +143,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20032 {\n"); sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); + sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20033.java b/src/main/java/one/talon/model/InlineResponse20033.java index 2e9d8950..a61f67e7 100644 --- a/src/main/java/one/talon/model/InlineResponse20033.java +++ b/src/main/java/one/talon/model/InlineResponse20033.java @@ -25,50 +25,51 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.ApplicationEvent; /** * InlineResponse20033 */ public class InlineResponse20033 { - public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; - @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) - private Long totalResultSize; + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); - public InlineResponse20033 totalResultSize(Long totalResultSize) { + public InlineResponse20033 hasMore(Boolean hasMore) { - this.totalResultSize = totalResultSize; + this.hasMore = hasMore; return this; } /** - * Get totalResultSize - * @return totalResultSize + * Get hasMore + * @return hasMore **/ - @ApiModelProperty(example = "1", required = true, value = "") + @ApiModelProperty(required = true, value = "") - public Long getTotalResultSize() { - return totalResultSize; + public Boolean getHasMore() { + return hasMore; } - public void setTotalResultSize(Long totalResultSize) { - this.totalResultSize = totalResultSize; + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; } - public InlineResponse20033 data(List data) { + public InlineResponse20033 data(List data) { this.data = data; return this; } - public InlineResponse20033 addDataItem(String dataItem) { + public InlineResponse20033 addDataItem(ApplicationEvent dataItem) { this.data.add(dataItem); return this; } @@ -79,12 +80,12 @@ public InlineResponse20033 addDataItem(String dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -98,13 +99,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20033 inlineResponse20033 = (InlineResponse20033) o; - return Objects.equals(this.totalResultSize, inlineResponse20033.totalResultSize) && + return Objects.equals(this.hasMore, inlineResponse20033.hasMore) && Objects.equals(this.data, inlineResponse20033.data); } @Override public int hashCode() { - return Objects.hash(totalResultSize, data); + return Objects.hash(hasMore, data); } @@ -112,7 +113,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20033 {\n"); - sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20034.java b/src/main/java/one/talon/model/InlineResponse20034.java index 3803c384..e03010ef 100644 --- a/src/main/java/one/talon/model/InlineResponse20034.java +++ b/src/main/java/one/talon/model/InlineResponse20034.java @@ -25,47 +25,19 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Audience; /** * InlineResponse20034 */ public class InlineResponse20034 { - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; - public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); - - - public InlineResponse20034 hasMore(Boolean hasMore) { - - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasMore() { - return hasMore; - } - - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } + private List data = new ArrayList(); public InlineResponse20034 totalResultSize(Long totalResultSize) { @@ -78,8 +50,7 @@ public InlineResponse20034 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") + @ApiModelProperty(example = "1", required = true, value = "") public Long getTotalResultSize() { return totalResultSize; @@ -91,13 +62,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20034 data(List data) { + public InlineResponse20034 data(List data) { this.data = data; return this; } - public InlineResponse20034 addDataItem(Audience dataItem) { + public InlineResponse20034 addDataItem(String dataItem) { this.data.add(dataItem); return this; } @@ -108,12 +79,12 @@ public InlineResponse20034 addDataItem(Audience dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -127,14 +98,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20034 inlineResponse20034 = (InlineResponse20034) o; - return Objects.equals(this.hasMore, inlineResponse20034.hasMore) && - Objects.equals(this.totalResultSize, inlineResponse20034.totalResultSize) && + return Objects.equals(this.totalResultSize, inlineResponse20034.totalResultSize) && Objects.equals(this.data, inlineResponse20034.data); } @Override public int hashCode() { - return Objects.hash(hasMore, totalResultSize, data); + return Objects.hash(totalResultSize, data); } @@ -142,7 +112,6 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20034 {\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/InlineResponse20035.java b/src/main/java/one/talon/model/InlineResponse20035.java index 1031011f..9369fad3 100644 --- a/src/main/java/one/talon/model/InlineResponse20035.java +++ b/src/main/java/one/talon/model/InlineResponse20035.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AudienceAnalytics; +import one.talon.model.Audience; /** * InlineResponse20035 @@ -36,9 +36,13 @@ public class InlineResponse20035 { @SerializedName(SERIALIZED_NAME_HAS_MORE) private Boolean hasMore; + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; + @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) + private Long totalResultSize; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20035 hasMore(Boolean hasMore) { @@ -64,13 +68,36 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20035 data(List data) { + public InlineResponse20035 totalResultSize(Long totalResultSize) { + + this.totalResultSize = totalResultSize; + return this; + } + + /** + * Get totalResultSize + * @return totalResultSize + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "") + + public Long getTotalResultSize() { + return totalResultSize; + } + + + public void setTotalResultSize(Long totalResultSize) { + this.totalResultSize = totalResultSize; + } + + + public InlineResponse20035 data(List data) { this.data = data; return this; } - public InlineResponse20035 addDataItem(AudienceAnalytics dataItem) { + public InlineResponse20035 addDataItem(Audience dataItem) { this.data.add(dataItem); return this; } @@ -81,12 +108,12 @@ public InlineResponse20035 addDataItem(AudienceAnalytics dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -101,12 +128,13 @@ public boolean equals(java.lang.Object o) { } InlineResponse20035 inlineResponse20035 = (InlineResponse20035) o; return Objects.equals(this.hasMore, inlineResponse20035.hasMore) && + Objects.equals(this.totalResultSize, inlineResponse20035.totalResultSize) && Objects.equals(this.data, inlineResponse20035.data); } @Override public int hashCode() { - return Objects.hash(hasMore, data); + return Objects.hash(hasMore, totalResultSize, data); } @@ -115,6 +143,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20035 {\n"); sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); + sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20036.java b/src/main/java/one/talon/model/InlineResponse20036.java index 84606496..334573a8 100644 --- a/src/main/java/one/talon/model/InlineResponse20036.java +++ b/src/main/java/one/talon/model/InlineResponse20036.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CustomerProfile; +import one.talon.model.AudienceAnalytics; /** * InlineResponse20036 @@ -38,7 +38,7 @@ public class InlineResponse20036 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20036 hasMore(Boolean hasMore) { @@ -64,13 +64,13 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20036 data(List data) { + public InlineResponse20036 data(List data) { this.data = data; return this; } - public InlineResponse20036 addDataItem(CustomerProfile dataItem) { + public InlineResponse20036 addDataItem(AudienceAnalytics dataItem) { this.data.add(dataItem); return this; } @@ -81,12 +81,12 @@ public InlineResponse20036 addDataItem(CustomerProfile dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20037.java b/src/main/java/one/talon/model/InlineResponse20037.java index 20ca30c2..e874dd4d 100644 --- a/src/main/java/one/talon/model/InlineResponse20037.java +++ b/src/main/java/one/talon/model/InlineResponse20037.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationReferee; +import one.talon.model.CustomerProfile; /** * InlineResponse20037 @@ -36,13 +36,9 @@ public class InlineResponse20037 { @SerializedName(SERIALIZED_NAME_HAS_MORE) private Boolean hasMore; - public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; - @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) - private Long totalResultSize; - public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20037 hasMore(Boolean hasMore) { @@ -68,36 +64,13 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20037 totalResultSize(Long totalResultSize) { - - this.totalResultSize = totalResultSize; - return this; - } - - /** - * Get totalResultSize - * @return totalResultSize - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") - - public Long getTotalResultSize() { - return totalResultSize; - } - - - public void setTotalResultSize(Long totalResultSize) { - this.totalResultSize = totalResultSize; - } - - - public InlineResponse20037 data(List data) { + public InlineResponse20037 data(List data) { this.data = data; return this; } - public InlineResponse20037 addDataItem(ApplicationReferee dataItem) { + public InlineResponse20037 addDataItem(CustomerProfile dataItem) { this.data.add(dataItem); return this; } @@ -108,12 +81,12 @@ public InlineResponse20037 addDataItem(ApplicationReferee dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -128,13 +101,12 @@ public boolean equals(java.lang.Object o) { } InlineResponse20037 inlineResponse20037 = (InlineResponse20037) o; return Objects.equals(this.hasMore, inlineResponse20037.hasMore) && - Objects.equals(this.totalResultSize, inlineResponse20037.totalResultSize) && Objects.equals(this.data, inlineResponse20037.data); } @Override public int hashCode() { - return Objects.hash(hasMore, totalResultSize, data); + return Objects.hash(hasMore, data); } @@ -143,7 +115,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20037 {\n"); sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); - sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20038.java b/src/main/java/one/talon/model/InlineResponse20038.java index 4c13d60b..151f6279 100644 --- a/src/main/java/one/talon/model/InlineResponse20038.java +++ b/src/main/java/one/talon/model/InlineResponse20038.java @@ -25,20 +25,47 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Attribute; +import one.talon.model.ApplicationReferee; /** * InlineResponse20038 */ public class InlineResponse20038 { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); + + + public InlineResponse20038 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } public InlineResponse20038 totalResultSize(Long totalResultSize) { @@ -51,7 +78,8 @@ public InlineResponse20038 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @ApiModelProperty(example = "1", required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "") public Long getTotalResultSize() { return totalResultSize; @@ -63,13 +91,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20038 data(List data) { + public InlineResponse20038 data(List data) { this.data = data; return this; } - public InlineResponse20038 addDataItem(Attribute dataItem) { + public InlineResponse20038 addDataItem(ApplicationReferee dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +108,12 @@ public InlineResponse20038 addDataItem(Attribute dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -99,13 +127,14 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20038 inlineResponse20038 = (InlineResponse20038) o; - return Objects.equals(this.totalResultSize, inlineResponse20038.totalResultSize) && + return Objects.equals(this.hasMore, inlineResponse20038.hasMore) && + Objects.equals(this.totalResultSize, inlineResponse20038.totalResultSize) && Objects.equals(this.data, inlineResponse20038.data); } @Override public int hashCode() { - return Objects.hash(totalResultSize, data); + return Objects.hash(hasMore, totalResultSize, data); } @@ -113,6 +142,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20038 {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/InlineResponse20039.java b/src/main/java/one/talon/model/InlineResponse20039.java index 26772cf7..af53af94 100644 --- a/src/main/java/one/talon/model/InlineResponse20039.java +++ b/src/main/java/one/talon/model/InlineResponse20039.java @@ -25,47 +25,20 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CatalogItem; +import one.talon.model.Attribute; /** * InlineResponse20039 */ public class InlineResponse20039 { - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; - public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); - - - public InlineResponse20039 hasMore(Boolean hasMore) { - - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasMore() { - return hasMore; - } - - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } + private List data = new ArrayList(); public InlineResponse20039 totalResultSize(Long totalResultSize) { @@ -78,8 +51,7 @@ public InlineResponse20039 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") + @ApiModelProperty(example = "1", required = true, value = "") public Long getTotalResultSize() { return totalResultSize; @@ -91,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20039 data(List data) { + public InlineResponse20039 data(List data) { this.data = data; return this; } - public InlineResponse20039 addDataItem(CatalogItem dataItem) { + public InlineResponse20039 addDataItem(Attribute dataItem) { this.data.add(dataItem); return this; } @@ -108,12 +80,12 @@ public InlineResponse20039 addDataItem(CatalogItem dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -127,14 +99,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20039 inlineResponse20039 = (InlineResponse20039) o; - return Objects.equals(this.hasMore, inlineResponse20039.hasMore) && - Objects.equals(this.totalResultSize, inlineResponse20039.totalResultSize) && + return Objects.equals(this.totalResultSize, inlineResponse20039.totalResultSize) && Objects.equals(this.data, inlineResponse20039.data); } @Override public int hashCode() { - return Objects.hash(hasMore, totalResultSize, data); + return Objects.hash(totalResultSize, data); } @@ -142,7 +113,6 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20039 {\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/InlineResponse20040.java b/src/main/java/one/talon/model/InlineResponse20040.java index 28da0777..7434a740 100644 --- a/src/main/java/one/talon/model/InlineResponse20040.java +++ b/src/main/java/one/talon/model/InlineResponse20040.java @@ -25,20 +25,47 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AccountAdditionalCost; +import one.talon.model.CatalogItem; /** * InlineResponse20040 */ public class InlineResponse20040 { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); + + + public InlineResponse20040 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } public InlineResponse20040 totalResultSize(Long totalResultSize) { @@ -51,7 +78,8 @@ public InlineResponse20040 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @ApiModelProperty(example = "1", required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "") public Long getTotalResultSize() { return totalResultSize; @@ -63,13 +91,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20040 data(List data) { + public InlineResponse20040 data(List data) { this.data = data; return this; } - public InlineResponse20040 addDataItem(AccountAdditionalCost dataItem) { + public InlineResponse20040 addDataItem(CatalogItem dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +108,12 @@ public InlineResponse20040 addDataItem(AccountAdditionalCost dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -99,13 +127,14 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20040 inlineResponse20040 = (InlineResponse20040) o; - return Objects.equals(this.totalResultSize, inlineResponse20040.totalResultSize) && + return Objects.equals(this.hasMore, inlineResponse20040.hasMore) && + Objects.equals(this.totalResultSize, inlineResponse20040.totalResultSize) && Objects.equals(this.data, inlineResponse20040.data); } @Override public int hashCode() { - return Objects.hash(totalResultSize, data); + return Objects.hash(hasMore, totalResultSize, data); } @@ -113,6 +142,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20040 {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/InlineResponse20041.java b/src/main/java/one/talon/model/InlineResponse20041.java index b5fb1b26..80b52fc2 100644 --- a/src/main/java/one/talon/model/InlineResponse20041.java +++ b/src/main/java/one/talon/model/InlineResponse20041.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.WebhookWithOutgoingIntegrationDetails; +import one.talon.model.AccountAdditionalCost; /** * InlineResponse20041 @@ -38,7 +38,7 @@ public class InlineResponse20041 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20041 totalResultSize(Long totalResultSize) { @@ -63,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20041 data(List data) { + public InlineResponse20041 data(List data) { this.data = data; return this; } - public InlineResponse20041 addDataItem(WebhookWithOutgoingIntegrationDetails dataItem) { + public InlineResponse20041 addDataItem(AccountAdditionalCost dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +80,12 @@ public InlineResponse20041 addDataItem(WebhookWithOutgoingIntegrationDetails dat **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20042.java b/src/main/java/one/talon/model/InlineResponse20042.java index 4faa6a0c..e64da09a 100644 --- a/src/main/java/one/talon/model/InlineResponse20042.java +++ b/src/main/java/one/talon/model/InlineResponse20042.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.EventType; +import one.talon.model.WebhookWithOutgoingIntegrationDetails; /** * InlineResponse20042 @@ -38,7 +38,7 @@ public class InlineResponse20042 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20042 totalResultSize(Long totalResultSize) { @@ -63,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20042 data(List data) { + public InlineResponse20042 data(List data) { this.data = data; return this; } - public InlineResponse20042 addDataItem(EventType dataItem) { + public InlineResponse20042 addDataItem(WebhookWithOutgoingIntegrationDetails dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +80,12 @@ public InlineResponse20042 addDataItem(EventType dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20043.java b/src/main/java/one/talon/model/InlineResponse20043.java index fd53978e..2046d3b0 100644 --- a/src/main/java/one/talon/model/InlineResponse20043.java +++ b/src/main/java/one/talon/model/InlineResponse20043.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.User; +import one.talon.model.EventType; /** * InlineResponse20043 @@ -38,7 +38,7 @@ public class InlineResponse20043 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20043 totalResultSize(Long totalResultSize) { @@ -63,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20043 data(List data) { + public InlineResponse20043 data(List data) { this.data = data; return this; } - public InlineResponse20043 addDataItem(User dataItem) { + public InlineResponse20043 addDataItem(EventType dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +80,12 @@ public InlineResponse20043 addDataItem(User dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20044.java b/src/main/java/one/talon/model/InlineResponse20044.java index 5711075b..ca062a47 100644 --- a/src/main/java/one/talon/model/InlineResponse20044.java +++ b/src/main/java/one/talon/model/InlineResponse20044.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Change; +import one.talon.model.User; /** * InlineResponse20044 @@ -36,13 +36,9 @@ public class InlineResponse20044 { @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; - public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20044 totalResultSize(Long totalResultSize) { @@ -55,8 +51,7 @@ public InlineResponse20044 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") + @ApiModelProperty(example = "1", required = true, value = "") public Long getTotalResultSize() { return totalResultSize; @@ -68,36 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20044 hasMore(Boolean hasMore) { - - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasMore() { - return hasMore; - } - - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } - - - public InlineResponse20044 data(List data) { + public InlineResponse20044 data(List data) { this.data = data; return this; } - public InlineResponse20044 addDataItem(Change dataItem) { + public InlineResponse20044 addDataItem(User dataItem) { this.data.add(dataItem); return this; } @@ -108,12 +80,12 @@ public InlineResponse20044 addDataItem(Change dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -128,13 +100,12 @@ public boolean equals(java.lang.Object o) { } InlineResponse20044 inlineResponse20044 = (InlineResponse20044) o; return Objects.equals(this.totalResultSize, inlineResponse20044.totalResultSize) && - Objects.equals(this.hasMore, inlineResponse20044.hasMore) && Objects.equals(this.data, inlineResponse20044.data); } @Override public int hashCode() { - return Objects.hash(totalResultSize, hasMore, data); + return Objects.hash(totalResultSize, data); } @@ -143,7 +114,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20044 {\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20045.java b/src/main/java/one/talon/model/InlineResponse20045.java index ade735a1..6f29b9d6 100644 --- a/src/main/java/one/talon/model/InlineResponse20045.java +++ b/src/main/java/one/talon/model/InlineResponse20045.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Export; +import one.talon.model.Change; /** * InlineResponse20045 @@ -36,9 +36,13 @@ public class InlineResponse20045 { @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20045 totalResultSize(Long totalResultSize) { @@ -51,7 +55,8 @@ public InlineResponse20045 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @ApiModelProperty(example = "1", required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "") public Long getTotalResultSize() { return totalResultSize; @@ -63,13 +68,36 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20045 data(List data) { + public InlineResponse20045 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } + + + public InlineResponse20045 data(List data) { this.data = data; return this; } - public InlineResponse20045 addDataItem(Export dataItem) { + public InlineResponse20045 addDataItem(Change dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +108,12 @@ public InlineResponse20045 addDataItem(Export dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -100,12 +128,13 @@ public boolean equals(java.lang.Object o) { } InlineResponse20045 inlineResponse20045 = (InlineResponse20045) o; return Objects.equals(this.totalResultSize, inlineResponse20045.totalResultSize) && + Objects.equals(this.hasMore, inlineResponse20045.hasMore) && Objects.equals(this.data, inlineResponse20045.data); } @Override public int hashCode() { - return Objects.hash(totalResultSize, data); + return Objects.hash(totalResultSize, hasMore, data); } @@ -114,6 +143,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20045 {\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20046.java b/src/main/java/one/talon/model/InlineResponse20046.java index 317efe19..e57779af 100644 --- a/src/main/java/one/talon/model/InlineResponse20046.java +++ b/src/main/java/one/talon/model/InlineResponse20046.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.RoleV2; +import one.talon.model.Export; /** * InlineResponse20046 @@ -38,7 +38,7 @@ public class InlineResponse20046 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20046 totalResultSize(Long totalResultSize) { @@ -63,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20046 data(List data) { + public InlineResponse20046 data(List data) { this.data = data; return this; } - public InlineResponse20046 addDataItem(RoleV2 dataItem) { + public InlineResponse20046 addDataItem(Export dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +80,12 @@ public InlineResponse20046 addDataItem(RoleV2 dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20047.java b/src/main/java/one/talon/model/InlineResponse20047.java index 8847c406..178c2edc 100644 --- a/src/main/java/one/talon/model/InlineResponse20047.java +++ b/src/main/java/one/talon/model/InlineResponse20047.java @@ -25,47 +25,20 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Store; +import one.talon.model.RoleV2; /** * InlineResponse20047 */ public class InlineResponse20047 { - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; - public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Long totalResultSize; public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); - - - public InlineResponse20047 hasMore(Boolean hasMore) { - - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasMore() { - return hasMore; - } - - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } + private List data = new ArrayList(); public InlineResponse20047 totalResultSize(Long totalResultSize) { @@ -78,8 +51,7 @@ public InlineResponse20047 totalResultSize(Long totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "1", value = "") + @ApiModelProperty(example = "1", required = true, value = "") public Long getTotalResultSize() { return totalResultSize; @@ -91,13 +63,13 @@ public void setTotalResultSize(Long totalResultSize) { } - public InlineResponse20047 data(List data) { + public InlineResponse20047 data(List data) { this.data = data; return this; } - public InlineResponse20047 addDataItem(Store dataItem) { + public InlineResponse20047 addDataItem(RoleV2 dataItem) { this.data.add(dataItem); return this; } @@ -108,12 +80,12 @@ public InlineResponse20047 addDataItem(Store dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -127,14 +99,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20047 inlineResponse20047 = (InlineResponse20047) o; - return Objects.equals(this.hasMore, inlineResponse20047.hasMore) && - Objects.equals(this.totalResultSize, inlineResponse20047.totalResultSize) && + return Objects.equals(this.totalResultSize, inlineResponse20047.totalResultSize) && Objects.equals(this.data, inlineResponse20047.data); } @Override public int hashCode() { - return Objects.hash(hasMore, totalResultSize, data); + return Objects.hash(totalResultSize, data); } @@ -142,7 +113,6 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20047 {\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/InlineResponse20048.java b/src/main/java/one/talon/model/InlineResponse20048.java index 45dbe03e..1ef2db2d 100644 --- a/src/main/java/one/talon/model/InlineResponse20048.java +++ b/src/main/java/one/talon/model/InlineResponse20048.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationCIF; +import one.talon.model.Store; /** * InlineResponse20048 @@ -36,9 +36,13 @@ public class InlineResponse20048 { @SerializedName(SERIALIZED_NAME_HAS_MORE) private Boolean hasMore; + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; + @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) + private Long totalResultSize; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20048 hasMore(Boolean hasMore) { @@ -64,13 +68,36 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20048 data(List data) { + public InlineResponse20048 totalResultSize(Long totalResultSize) { + + this.totalResultSize = totalResultSize; + return this; + } + + /** + * Get totalResultSize + * @return totalResultSize + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "") + + public Long getTotalResultSize() { + return totalResultSize; + } + + + public void setTotalResultSize(Long totalResultSize) { + this.totalResultSize = totalResultSize; + } + + + public InlineResponse20048 data(List data) { this.data = data; return this; } - public InlineResponse20048 addDataItem(ApplicationCIF dataItem) { + public InlineResponse20048 addDataItem(Store dataItem) { this.data.add(dataItem); return this; } @@ -81,12 +108,12 @@ public InlineResponse20048 addDataItem(ApplicationCIF dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -101,12 +128,13 @@ public boolean equals(java.lang.Object o) { } InlineResponse20048 inlineResponse20048 = (InlineResponse20048) o; return Objects.equals(this.hasMore, inlineResponse20048.hasMore) && + Objects.equals(this.totalResultSize, inlineResponse20048.totalResultSize) && Objects.equals(this.data, inlineResponse20048.data); } @Override public int hashCode() { - return Objects.hash(hasMore, data); + return Objects.hash(hasMore, totalResultSize, data); } @@ -115,6 +143,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20048 {\n"); sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); + sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20049.java b/src/main/java/one/talon/model/InlineResponse20049.java index 2ea16667..de332369 100644 --- a/src/main/java/one/talon/model/InlineResponse20049.java +++ b/src/main/java/one/talon/model/InlineResponse20049.java @@ -25,28 +25,52 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ListCampaignStoreBudgets; +import one.talon.model.ApplicationCIF; /** * InlineResponse20049 */ public class InlineResponse20049 { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = null; + private List data = new ArrayList(); - public InlineResponse20049 data(List data) { + public InlineResponse20049 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } + + + public InlineResponse20049 data(List data) { this.data = data; return this; } - public InlineResponse20049 addDataItem(ListCampaignStoreBudgets dataItem) { - if (this.data == null) { - this.data = new ArrayList(); - } + public InlineResponse20049 addDataItem(ApplicationCIF dataItem) { this.data.add(dataItem); return this; } @@ -55,15 +79,14 @@ public InlineResponse20049 addDataItem(ListCampaignStoreBudgets dataItem) { * Get data * @return data **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") + @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -77,12 +100,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20049 inlineResponse20049 = (InlineResponse20049) o; - return Objects.equals(this.data, inlineResponse20049.data); + return Objects.equals(this.hasMore, inlineResponse20049.hasMore) && + Objects.equals(this.data, inlineResponse20049.data); } @Override public int hashCode() { - return Objects.hash(data); + return Objects.hash(hasMore, data); } @@ -90,6 +114,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20049 {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20050.java b/src/main/java/one/talon/model/InlineResponse20050.java index 533ac2d6..ca45704d 100644 --- a/src/main/java/one/talon/model/InlineResponse20050.java +++ b/src/main/java/one/talon/model/InlineResponse20050.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.SummaryCampaignStoreBudget; +import one.talon.model.ListCampaignStoreBudgets; /** * InlineResponse20050 @@ -34,18 +34,18 @@ public class InlineResponse20050 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = null; + private List data = null; - public InlineResponse20050 data(List data) { + public InlineResponse20050 data(List data) { this.data = data; return this; } - public InlineResponse20050 addDataItem(SummaryCampaignStoreBudget dataItem) { + public InlineResponse20050 addDataItem(ListCampaignStoreBudgets dataItem) { if (this.data == null) { - this.data = new ArrayList(); + this.data = new ArrayList(); } this.data.add(dataItem); return this; @@ -58,12 +58,12 @@ public InlineResponse20050 addDataItem(SummaryCampaignStoreBudget dataItem) { @javax.annotation.Nullable @ApiModelProperty(value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20051.java b/src/main/java/one/talon/model/InlineResponse20051.java index 6fc9ea75..bef68dbf 100644 --- a/src/main/java/one/talon/model/InlineResponse20051.java +++ b/src/main/java/one/talon/model/InlineResponse20051.java @@ -25,52 +25,28 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Achievement; +import one.talon.model.SummaryCampaignStoreBudget; /** * InlineResponse20051 */ public class InlineResponse20051 { - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; - public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = null; - public InlineResponse20051 hasMore(Boolean hasMore) { - - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public Boolean getHasMore() { - return hasMore; - } - - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } - - - public InlineResponse20051 data(List data) { + public InlineResponse20051 data(List data) { this.data = data; return this; } - public InlineResponse20051 addDataItem(Achievement dataItem) { + public InlineResponse20051 addDataItem(SummaryCampaignStoreBudget dataItem) { + if (this.data == null) { + this.data = new ArrayList(); + } this.data.add(dataItem); return this; } @@ -79,14 +55,15 @@ public InlineResponse20051 addDataItem(Achievement dataItem) { * Get data * @return data **/ - @ApiModelProperty(required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -100,13 +77,12 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20051 inlineResponse20051 = (InlineResponse20051) o; - return Objects.equals(this.hasMore, inlineResponse20051.hasMore) && - Objects.equals(this.data, inlineResponse20051.data); + return Objects.equals(this.data, inlineResponse20051.data); } @Override public int hashCode() { - return Objects.hash(hasMore, data); + return Objects.hash(data); } @@ -114,7 +90,6 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20051 {\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20052.java b/src/main/java/one/talon/model/InlineResponse20052.java index bcf92c71..d5e15230 100644 --- a/src/main/java/one/talon/model/InlineResponse20052.java +++ b/src/main/java/one/talon/model/InlineResponse20052.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AchievementProgressWithDefinition; +import one.talon.model.Achievement; /** * InlineResponse20052 @@ -38,7 +38,7 @@ public class InlineResponse20052 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public InlineResponse20052 hasMore(Boolean hasMore) { @@ -51,7 +51,8 @@ public InlineResponse20052 hasMore(Boolean hasMore) { * Get hasMore * @return hasMore **/ - @ApiModelProperty(example = "true", required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "") public Boolean getHasMore() { return hasMore; @@ -63,13 +64,13 @@ public void setHasMore(Boolean hasMore) { } - public InlineResponse20052 data(List data) { + public InlineResponse20052 data(List data) { this.data = data; return this; } - public InlineResponse20052 addDataItem(AchievementProgressWithDefinition dataItem) { + public InlineResponse20052 addDataItem(Achievement dataItem) { this.data.add(dataItem); return this; } @@ -80,12 +81,12 @@ public InlineResponse20052 addDataItem(AchievementProgressWithDefinition dataIte **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20053.java b/src/main/java/one/talon/model/InlineResponse20053.java index 6379b94b..7b459b04 100644 --- a/src/main/java/one/talon/model/InlineResponse20053.java +++ b/src/main/java/one/talon/model/InlineResponse20053.java @@ -25,25 +25,52 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CouponFailureSummary; +import one.talon.model.AchievementV2; /** * InlineResponse20053 */ public class InlineResponse20053 { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); + + + public InlineResponse20053 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } - public InlineResponse20053 data(List data) { + public InlineResponse20053 data(List data) { this.data = data; return this; } - public InlineResponse20053 addDataItem(CouponFailureSummary dataItem) { + public InlineResponse20053 addDataItem(AchievementV2 dataItem) { this.data.add(dataItem); return this; } @@ -54,12 +81,12 @@ public InlineResponse20053 addDataItem(CouponFailureSummary dataItem) { **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } @@ -73,12 +100,13 @@ public boolean equals(java.lang.Object o) { return false; } InlineResponse20053 inlineResponse20053 = (InlineResponse20053) o; - return Objects.equals(this.data, inlineResponse20053.data); + return Objects.equals(this.hasMore, inlineResponse20053.hasMore) && + Objects.equals(this.data, inlineResponse20053.data); } @Override public int hashCode() { - return Objects.hash(data); + return Objects.hash(hasMore, data); } @@ -86,6 +114,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InlineResponse20053 {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20054.java b/src/main/java/one/talon/model/InlineResponse20054.java new file mode 100644 index 00000000..10db6c7c --- /dev/null +++ b/src/main/java/one/talon/model/InlineResponse20054.java @@ -0,0 +1,134 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.AchievementProgressWithDefinition; + +/** + * InlineResponse20054 + */ + +public class InlineResponse20054 { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private List data = new ArrayList(); + + + public InlineResponse20054 hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @ApiModelProperty(example = "true", required = true, value = "") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } + + + public InlineResponse20054 data(List data) { + + this.data = data; + return this; + } + + public InlineResponse20054 addDataItem(AchievementProgressWithDefinition dataItem) { + this.data.add(dataItem); + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + + public List getData() { + return data; + } + + + public void setData(List data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + InlineResponse20054 inlineResponse20054 = (InlineResponse20054) o; + return Objects.equals(this.hasMore, inlineResponse20054.hasMore) && + Objects.equals(this.data, inlineResponse20054.data); + } + + @Override + public int hashCode() { + return Objects.hash(hasMore, data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class InlineResponse20054 {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/InlineResponse20055.java b/src/main/java/one/talon/model/InlineResponse20055.java new file mode 100644 index 00000000..947a4e9e --- /dev/null +++ b/src/main/java/one/talon/model/InlineResponse20055.java @@ -0,0 +1,106 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CouponFailureSummary; + +/** + * InlineResponse20055 + */ + +public class InlineResponse20055 { + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private List data = new ArrayList(); + + + public InlineResponse20055 data(List data) { + + this.data = data; + return this; + } + + public InlineResponse20055 addDataItem(CouponFailureSummary dataItem) { + this.data.add(dataItem); + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + + public List getData() { + return data; + } + + + public void setData(List data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + InlineResponse20055 inlineResponse20055 = (InlineResponse20055) o; + return Objects.equals(this.data, inlineResponse20055.data); + } + + @Override + public int hashCode() { + return Objects.hash(data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class InlineResponse20055 {\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/InlineResponse20056.java b/src/main/java/one/talon/model/InlineResponse20056.java new file mode 100644 index 00000000..c0e7f130 --- /dev/null +++ b/src/main/java/one/talon/model/InlineResponse20056.java @@ -0,0 +1,140 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.InlineResponse20056Catalog; +import one.talon.model.LoyaltyBalances; + +/** + * InlineResponse20056 + */ + +public class InlineResponse20056 { + public static final String SERIALIZED_NAME_CATALOG = "catalog"; + @SerializedName(SERIALIZED_NAME_CATALOG) + private InlineResponse20056Catalog catalog; + + public static final String SERIALIZED_NAME_LOYALTY = "loyalty"; + @SerializedName(SERIALIZED_NAME_LOYALTY) + private Map loyalty = null; + + + public InlineResponse20056 catalog(InlineResponse20056Catalog catalog) { + + this.catalog = catalog; + return this; + } + + /** + * Get catalog + * @return catalog + **/ + @ApiModelProperty(required = true, value = "") + + public InlineResponse20056Catalog getCatalog() { + return catalog; + } + + + public void setCatalog(InlineResponse20056Catalog catalog) { + this.catalog = catalog; + } + + + public InlineResponse20056 loyalty(Map loyalty) { + + this.loyalty = loyalty; + return this; + } + + public InlineResponse20056 putLoyaltyItem(String key, LoyaltyBalances loyaltyItem) { + if (this.loyalty == null) { + this.loyalty = new HashMap(); + } + this.loyalty.put(key, loyaltyItem); + return this; + } + + /** + * The customer's loyalty balances for the specified loyalty program. Returned only when `loyaltyProgramId` is provided together with `profileIntegrationId` or `loyaltyCardId`. + * @return loyalty + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The customer's loyalty balances for the specified loyalty program. Returned only when `loyaltyProgramId` is provided together with `profileIntegrationId` or `loyaltyCardId`. ") + + public Map getLoyalty() { + return loyalty; + } + + + public void setLoyalty(Map loyalty) { + this.loyalty = loyalty; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + InlineResponse20056 inlineResponse20056 = (InlineResponse20056) o; + return Objects.equals(this.catalog, inlineResponse20056.catalog) && + Objects.equals(this.loyalty, inlineResponse20056.loyalty); + } + + @Override + public int hashCode() { + return Objects.hash(catalog, loyalty); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class InlineResponse20056 {\n"); + sb.append(" catalog: ").append(toIndentedString(catalog)).append("\n"); + sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/InlineResponse20056Catalog.java b/src/main/java/one/talon/model/InlineResponse20056Catalog.java new file mode 100644 index 00000000..c98871ca --- /dev/null +++ b/src/main/java/one/talon/model/InlineResponse20056Catalog.java @@ -0,0 +1,135 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardCatalogItem; + +/** + * The paginated rewards catalog. + */ +@ApiModel(description = "The paginated rewards catalog.") + +public class InlineResponse20056Catalog { + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; + + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private List data = new ArrayList(); + + + public InlineResponse20056Catalog hasMore(Boolean hasMore) { + + this.hasMore = hasMore; + return this; + } + + /** + * Whether more pages exist after the current one. + * @return hasMore + **/ + @ApiModelProperty(required = true, value = "Whether more pages exist after the current one.") + + public Boolean getHasMore() { + return hasMore; + } + + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } + + + public InlineResponse20056Catalog data(List data) { + + this.data = data; + return this; + } + + public InlineResponse20056Catalog addDataItem(RewardCatalogItem dataItem) { + this.data.add(dataItem); + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + + public List getData() { + return data; + } + + + public void setData(List data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + InlineResponse20056Catalog inlineResponse20056Catalog = (InlineResponse20056Catalog) o; + return Objects.equals(this.hasMore, inlineResponse20056Catalog.hasMore) && + Objects.equals(this.data, inlineResponse20056Catalog.data); + } + + @Override + public int hashCode() { + return Objects.hash(hasMore, data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class InlineResponse20056Catalog {\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/IntegrationCampaign.java b/src/main/java/one/talon/model/IntegrationCampaign.java index 08bc957f..0f3616f5 100644 --- a/src/main/java/one/talon/model/IntegrationCampaign.java +++ b/src/main/java/one/talon/model/IntegrationCampaign.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.RuleMetadata; import org.threeten.bp.OffsetDateTime; /** @@ -32,14 +33,14 @@ */ public class IntegrationCampaign { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private Long id; - public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; @SerializedName(SERIALIZED_NAME_APPLICATION_ID) private Long applicationId; + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) private String name; @@ -128,7 +129,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; @@ -172,48 +175,60 @@ public FeaturesEnum read(final JsonReader jsonReader) throws IOException { @SerializedName(SERIALIZED_NAME_FEATURES) private List features = new ArrayList(); + public static final String SERIALIZED_NAME_RULES = "rules"; + @SerializedName(SERIALIZED_NAME_RULES) + private List rules = new ArrayList(); - public IntegrationCampaign id(Long id) { + public static final String SERIALIZED_NAME_LINKED_STORE_IDS = "linkedStoreIds"; + @SerializedName(SERIALIZED_NAME_LINKED_STORE_IDS) + private List linkedStoreIds = null; + + public static final String SERIALIZED_NAME_LINKED_AUDIENCE_IDS = "linkedAudienceIds"; + @SerializedName(SERIALIZED_NAME_LINKED_AUDIENCE_IDS) + private List linkedAudienceIds = null; + + + public IntegrationCampaign applicationId(Long applicationId) { - this.id = id; + this.applicationId = applicationId; return this; } /** - * Unique ID of Campaign. - * @return id + * The ID of the Application that owns this entity. + * @return applicationId **/ - @ApiModelProperty(example = "4", required = true, value = "Unique ID of Campaign.") + @ApiModelProperty(example = "322", required = true, value = "The ID of the Application that owns this entity.") - public Long getId() { - return id; + public Long getApplicationId() { + return applicationId; } - public void setId(Long id) { - this.id = id; + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; } - public IntegrationCampaign applicationId(Long applicationId) { + public IntegrationCampaign id(Long id) { - this.applicationId = applicationId; + this.id = id; return this; } /** - * The ID of the Application that owns this entity. - * @return applicationId + * Unique ID of Campaign. + * @return id **/ - @ApiModelProperty(example = "322", required = true, value = "The ID of the Application that owns this entity.") + @ApiModelProperty(example = "4", required = true, value = "Unique ID of Campaign.") - public Long getApplicationId() { - return applicationId; + public Long getId() { + return id; } - public void setApplicationId(Long applicationId) { - this.applicationId = applicationId; + public void setId(Long id) { + this.id = id; } @@ -224,10 +239,10 @@ public IntegrationCampaign name(String name) { } /** - * A user-facing name for this campaign. + * The name of the campaign. * @return name **/ - @ApiModelProperty(example = "Summer promotions", required = true, value = "A user-facing name for this campaign.") + @ApiModelProperty(example = "Summer promotions", required = true, value = "The name of the campaign.") public String getName() { return name; @@ -407,6 +422,95 @@ public void setFeatures(List features) { } + public IntegrationCampaign rules(List rules) { + + this.rules = rules; + return this; + } + + public IntegrationCampaign addRulesItem(RuleMetadata rulesItem) { + this.rules.add(rulesItem); + return this; + } + + /** + * A list of rules containing customer-facing details of the rewards defined in the campaign. + * @return rules + **/ + @ApiModelProperty(required = true, value = "A list of rules containing customer-facing details of the rewards defined in the campaign.") + + public List getRules() { + return rules; + } + + + public void setRules(List rules) { + this.rules = rules; + } + + + public IntegrationCampaign linkedStoreIds(List linkedStoreIds) { + + this.linkedStoreIds = linkedStoreIds; + return this; + } + + public IntegrationCampaign addLinkedStoreIdsItem(Long linkedStoreIdsItem) { + if (this.linkedStoreIds == null) { + this.linkedStoreIds = new ArrayList(); + } + this.linkedStoreIds.add(linkedStoreIdsItem); + return this; + } + + /** + * A list of store IDs linked to this campaign. + * @return linkedStoreIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[1, 2]", value = "A list of store IDs linked to this campaign.") + + public List getLinkedStoreIds() { + return linkedStoreIds; + } + + + public void setLinkedStoreIds(List linkedStoreIds) { + this.linkedStoreIds = linkedStoreIds; + } + + + public IntegrationCampaign linkedAudienceIds(List linkedAudienceIds) { + + this.linkedAudienceIds = linkedAudienceIds; + return this; + } + + public IntegrationCampaign addLinkedAudienceIdsItem(Long linkedAudienceIdsItem) { + if (this.linkedAudienceIds == null) { + this.linkedAudienceIds = new ArrayList(); + } + this.linkedAudienceIds.add(linkedAudienceIdsItem); + return this; + } + + /** + * A list of audience IDs linked to this campaign. + * @return linkedAudienceIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 4]", value = "A list of audience IDs linked to this campaign.") + + public List getLinkedAudienceIds() { + return linkedAudienceIds; + } + + + public void setLinkedAudienceIds(List linkedAudienceIds) { + this.linkedAudienceIds = linkedAudienceIds; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -416,8 +520,8 @@ public boolean equals(java.lang.Object o) { return false; } IntegrationCampaign integrationCampaign = (IntegrationCampaign) o; - return Objects.equals(this.id, integrationCampaign.id) && - Objects.equals(this.applicationId, integrationCampaign.applicationId) && + return Objects.equals(this.applicationId, integrationCampaign.applicationId) && + Objects.equals(this.id, integrationCampaign.id) && Objects.equals(this.name, integrationCampaign.name) && Objects.equals(this.description, integrationCampaign.description) && Objects.equals(this.startTime, integrationCampaign.startTime) && @@ -425,12 +529,15 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.attributes, integrationCampaign.attributes) && Objects.equals(this.state, integrationCampaign.state) && Objects.equals(this.tags, integrationCampaign.tags) && - Objects.equals(this.features, integrationCampaign.features); + Objects.equals(this.features, integrationCampaign.features) && + Objects.equals(this.rules, integrationCampaign.rules) && + Objects.equals(this.linkedStoreIds, integrationCampaign.linkedStoreIds) && + Objects.equals(this.linkedAudienceIds, integrationCampaign.linkedAudienceIds); } @Override public int hashCode() { - return Objects.hash(id, applicationId, name, description, startTime, endTime, attributes, state, tags, features); + return Objects.hash(applicationId, id, name, description, startTime, endTime, attributes, state, tags, features, rules, linkedStoreIds, linkedAudienceIds); } @@ -438,8 +545,8 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationCampaign {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); @@ -448,6 +555,9 @@ public String toString() { sb.append(" state: ").append(toIndentedString(state)).append("\n"); sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); sb.append(" features: ").append(toIndentedString(features)).append("\n"); + sb.append(" rules: ").append(toIndentedString(rules)).append("\n"); + sb.append(" linkedStoreIds: ").append(toIndentedString(linkedStoreIds)).append("\n"); + sb.append(" linkedAudienceIds: ").append(toIndentedString(linkedAudienceIds)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IntegrationCampaignBase.java b/src/main/java/one/talon/model/IntegrationCampaignBase.java new file mode 100644 index 00000000..4be95136 --- /dev/null +++ b/src/main/java/one/talon/model/IntegrationCampaignBase.java @@ -0,0 +1,469 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.threeten.bp.OffsetDateTime; + +/** + * IntegrationCampaignBase + */ + +public class IntegrationCampaignBase { + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_START_TIME = "startTime"; + @SerializedName(SERIALIZED_NAME_START_TIME) + private OffsetDateTime startTime; + + public static final String SERIALIZED_NAME_END_TIME = "endTime"; + @SerializedName(SERIALIZED_NAME_END_TIME) + private OffsetDateTime endTime; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + /** + * The state of the campaign. + */ + @JsonAdapter(StateEnum.Adapter.class) + public enum StateEnum { + ENABLED("enabled"); + + private String value; + + StateEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StateEnum fromValue(String value) { + for (StateEnum b : StateEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StateEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StateEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StateEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATE = "state"; + @SerializedName(SERIALIZED_NAME_STATE) + private StateEnum state = StateEnum.ENABLED; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = new ArrayList(); + + /** + * Gets or Sets features + */ + @JsonAdapter(FeaturesEnum.Adapter.class) + public enum FeaturesEnum { + COUPONS("coupons"), + + REFERRALS("referrals"), + + LOYALTY("loyalty"), + + GIVEAWAYS("giveaways"), + + STRIKETHROUGH("strikethrough"), + + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); + + private String value; + + FeaturesEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static FeaturesEnum fromValue(String value) { + for (FeaturesEnum b : FeaturesEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final FeaturesEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public FeaturesEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return FeaturesEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_FEATURES = "features"; + @SerializedName(SERIALIZED_NAME_FEATURES) + private List features = new ArrayList(); + + + public IntegrationCampaignBase applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application that owns this entity. + * @return applicationId + **/ + @ApiModelProperty(example = "322", required = true, value = "The ID of the Application that owns this entity.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public IntegrationCampaignBase id(Long id) { + + this.id = id; + return this; + } + + /** + * Unique ID of Campaign. + * @return id + **/ + @ApiModelProperty(example = "4", required = true, value = "Unique ID of Campaign.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public IntegrationCampaignBase name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the campaign. + * @return name + **/ + @ApiModelProperty(example = "Summer promotions", required = true, value = "The name of the campaign.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public IntegrationCampaignBase description(String description) { + + this.description = description; + return this; + } + + /** + * A detailed description of the campaign. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Campaign for all summer 2021 promotions", value = "A detailed description of the campaign.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public IntegrationCampaignBase startTime(OffsetDateTime startTime) { + + this.startTime = startTime; + return this; + } + + /** + * Timestamp when the campaign will become active. + * @return startTime + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-07-20T22:00Z", value = "Timestamp when the campaign will become active.") + + public OffsetDateTime getStartTime() { + return startTime; + } + + + public void setStartTime(OffsetDateTime startTime) { + this.startTime = startTime; + } + + + public IntegrationCampaignBase endTime(OffsetDateTime endTime) { + + this.endTime = endTime; + return this; + } + + /** + * Timestamp when the campaign will become inactive. + * @return endTime + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-09-22T22:00Z", value = "Timestamp when the campaign will become inactive.") + + public OffsetDateTime getEndTime() { + return endTime; + } + + + public void setEndTime(OffsetDateTime endTime) { + this.endTime = endTime; + } + + + public IntegrationCampaignBase attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Arbitrary properties associated with this campaign. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Arbitrary properties associated with this campaign.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public IntegrationCampaignBase state(StateEnum state) { + + this.state = state; + return this; + } + + /** + * The state of the campaign. + * @return state + **/ + @ApiModelProperty(example = "enabled", required = true, value = "The state of the campaign. ") + + public StateEnum getState() { + return state; + } + + + public void setState(StateEnum state) { + this.state = state; + } + + + public IntegrationCampaignBase tags(List tags) { + + this.tags = tags; + return this; + } + + public IntegrationCampaignBase addTagsItem(String tagsItem) { + this.tags.add(tagsItem); + return this; + } + + /** + * A list of tags for the campaign. + * @return tags + **/ + @ApiModelProperty(example = "[summer]", required = true, value = "A list of tags for the campaign.") + + public List getTags() { + return tags; + } + + + public void setTags(List tags) { + this.tags = tags; + } + + + public IntegrationCampaignBase features(List features) { + + this.features = features; + return this; + } + + public IntegrationCampaignBase addFeaturesItem(FeaturesEnum featuresItem) { + this.features.add(featuresItem); + return this; + } + + /** + * The features enabled in this campaign. + * @return features + **/ + @ApiModelProperty(example = "[coupons, referrals]", required = true, value = "The features enabled in this campaign.") + + public List getFeatures() { + return features; + } + + + public void setFeatures(List features) { + this.features = features; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + IntegrationCampaignBase integrationCampaignBase = (IntegrationCampaignBase) o; + return Objects.equals(this.applicationId, integrationCampaignBase.applicationId) && + Objects.equals(this.id, integrationCampaignBase.id) && + Objects.equals(this.name, integrationCampaignBase.name) && + Objects.equals(this.description, integrationCampaignBase.description) && + Objects.equals(this.startTime, integrationCampaignBase.startTime) && + Objects.equals(this.endTime, integrationCampaignBase.endTime) && + Objects.equals(this.attributes, integrationCampaignBase.attributes) && + Objects.equals(this.state, integrationCampaignBase.state) && + Objects.equals(this.tags, integrationCampaignBase.tags) && + Objects.equals(this.features, integrationCampaignBase.features); + } + + @Override + public int hashCode() { + return Objects.hash(applicationId, id, name, description, startTime, endTime, attributes, state, tags, features); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class IntegrationCampaignBase {\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); + sb.append(" endTime: ").append(toIndentedString(endTime)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" state: ").append(toIndentedString(state)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" features: ").append(toIndentedString(features)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/IntegrationEvent.java b/src/main/java/one/talon/model/IntegrationEvent.java index 826d8346..fd9ad4e1 100644 --- a/src/main/java/one/talon/model/IntegrationEvent.java +++ b/src/main/java/one/talon/model/IntegrationEvent.java @@ -99,10 +99,10 @@ public IntegrationEvent type(String type) { } /** - * A string representing the event. Must not be a reserved event name. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event. Must not be a reserved event name.") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; diff --git a/src/main/java/one/talon/model/IntegrationEventV2Request.java b/src/main/java/one/talon/model/IntegrationEventV2Request.java index 6b020f43..e560c96c 100644 --- a/src/main/java/one/talon/model/IntegrationEventV2Request.java +++ b/src/main/java/one/talon/model/IntegrationEventV2Request.java @@ -66,7 +66,13 @@ public enum ResponseContentEnum { AWARDEDGIVEAWAYS("awardedGiveaways"), - RULEFAILUREREASONS("ruleFailureReasons"); + RULEFAILUREREASONS("ruleFailureReasons"), + + CAMPAIGNELIGIBILITY("campaignEligibility"), + + ACHIEVEMENTS("achievements"), + + UNLOCKEDREWARDS("unlockedRewards"); private String value; @@ -199,10 +205,10 @@ public IntegrationEventV2Request type(String type) { } /** - * A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. ") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; diff --git a/src/main/java/one/talon/model/IntegrationEventV2Response.java b/src/main/java/one/talon/model/IntegrationEventV2Response.java index 58d44351..d9de09b7 100644 --- a/src/main/java/one/talon/model/IntegrationEventV2Response.java +++ b/src/main/java/one/talon/model/IntegrationEventV2Response.java @@ -26,13 +26,16 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.Event; import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; /** @@ -53,6 +56,10 @@ public class IntegrationEventV2Response { @SerializedName(SERIALIZED_NAME_TRIGGERED_CAMPAIGNS) private List triggeredCampaigns = null; + public static final String SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY = "campaignEligibility"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY) + private List campaignEligibility = null; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; @SerializedName(SERIALIZED_NAME_EFFECTS) private List effects = new ArrayList(); @@ -73,6 +80,14 @@ public class IntegrationEventV2Response { @SerializedName(SERIALIZED_NAME_AWARDED_GIVEAWAYS) private List awardedGiveaways = null; + public static final String SERIALIZED_NAME_ACHIEVEMENTS = "achievements"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENTS) + private List achievements = null; + + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public static final String SERIALIZED_NAME_EVENT = "event"; @SerializedName(SERIALIZED_NAME_EVENT) private Event event; @@ -155,6 +170,37 @@ public void setTriggeredCampaigns(List triggeredCampaigns) { } + public IntegrationEventV2Response campaignEligibility(List campaignEligibility) { + + this.campaignEligibility = campaignEligibility; + return this; + } + + public IntegrationEventV2Response addCampaignEligibilityItem(CampaignEligibility campaignEligibilityItem) { + if (this.campaignEligibility == null) { + this.campaignEligibility = new ArrayList(); + } + this.campaignEligibility.add(campaignEligibilityItem); + return this; + } + + /** + * A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. + * @return campaignEligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. ") + + public List getCampaignEligibility() { + return campaignEligibility; + } + + + public void setCampaignEligibility(List campaignEligibility) { + this.campaignEligibility = campaignEligibility; + } + + public IntegrationEventV2Response effects(List effects) { this.effects = effects; @@ -298,6 +344,68 @@ public void setAwardedGiveaways(List awardedGiveaways) { } + public IntegrationEventV2Response achievements(List achievements) { + + this.achievements = achievements; + return this; + } + + public IntegrationEventV2Response addAchievementsItem(CustomerAchievement achievementsItem) { + if (this.achievements == null) { + this.achievements = new ArrayList(); + } + this.achievements.add(achievementsItem); + return this; + } + + /** + * The achievements progress of the customer. + * @return achievements + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievements progress of the customer.") + + public List getAchievements() { + return achievements; + } + + + public void setAchievements(List achievements) { + this.achievements = achievements; + } + + + public IntegrationEventV2Response rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public IntegrationEventV2Response addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The rewards for the customer profile. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The rewards for the customer profile.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + public IntegrationEventV2Response event(Event event) { this.event = event; @@ -333,17 +441,20 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.customerProfile, integrationEventV2Response.customerProfile) && Objects.equals(this.loyalty, integrationEventV2Response.loyalty) && Objects.equals(this.triggeredCampaigns, integrationEventV2Response.triggeredCampaigns) && + Objects.equals(this.campaignEligibility, integrationEventV2Response.campaignEligibility) && Objects.equals(this.effects, integrationEventV2Response.effects) && Objects.equals(this.ruleFailureReasons, integrationEventV2Response.ruleFailureReasons) && Objects.equals(this.createdCoupons, integrationEventV2Response.createdCoupons) && Objects.equals(this.createdReferrals, integrationEventV2Response.createdReferrals) && Objects.equals(this.awardedGiveaways, integrationEventV2Response.awardedGiveaways) && + Objects.equals(this.achievements, integrationEventV2Response.achievements) && + Objects.equals(this.rewards, integrationEventV2Response.rewards) && Objects.equals(this.event, integrationEventV2Response.event); } @Override public int hashCode() { - return Objects.hash(customerProfile, loyalty, triggeredCampaigns, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, event); + return Objects.hash(customerProfile, loyalty, triggeredCampaigns, campaignEligibility, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, achievements, rewards, event); } @@ -354,11 +465,14 @@ public String toString() { sb.append(" customerProfile: ").append(toIndentedString(customerProfile)).append("\n"); sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); sb.append(" triggeredCampaigns: ").append(toIndentedString(triggeredCampaigns)).append("\n"); + sb.append(" campaignEligibility: ").append(toIndentedString(campaignEligibility)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); sb.append(" createdCoupons: ").append(toIndentedString(createdCoupons)).append("\n"); sb.append(" createdReferrals: ").append(toIndentedString(createdReferrals)).append("\n"); sb.append(" awardedGiveaways: ").append(toIndentedString(awardedGiveaways)).append("\n"); + sb.append(" achievements: ").append(toIndentedString(achievements)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append(" event: ").append(toIndentedString(event)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/IntegrationEventV3Request.java b/src/main/java/one/talon/model/IntegrationEventV3Request.java index a0e7c750..9c72110f 100644 --- a/src/main/java/one/talon/model/IntegrationEventV3Request.java +++ b/src/main/java/one/talon/model/IntegrationEventV3Request.java @@ -43,10 +43,6 @@ public class IntegrationEventV3Request { @SerializedName(SERIALIZED_NAME_EVALUABLE_CAMPAIGN_IDS) private List evaluableCampaignIds = null; - public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; - @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) - private String integrationId; - public static final String SERIALIZED_NAME_TYPE = "type"; @SerializedName(SERIALIZED_NAME_TYPE) private String type; @@ -55,13 +51,17 @@ public class IntegrationEventV3Request { @SerializedName(SERIALIZED_NAME_ATTRIBUTES) private Object attributes; - public static final String SERIALIZED_NAME_CONNECTED_SESSION_I_D = "connectedSessionID"; - @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_I_D) - private String connectedSessionID; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_CONNECTED_SESSION_ID = "connectedSessionId"; + @SerializedName(SERIALIZED_NAME_CONNECTED_SESSION_ID) + private String connectedSessionId; - public static final String SERIALIZED_NAME_PREVIOUS_EVENT_I_D = "previousEventID"; - @SerializedName(SERIALIZED_NAME_PREVIOUS_EVENT_I_D) - private String previousEventID; + public static final String SERIALIZED_NAME_REFERRAL_CODE = "referralCode"; + @SerializedName(SERIALIZED_NAME_REFERRAL_CODE) + private String referralCode; public static final String SERIALIZED_NAME_LOYALTY_CARDS = "loyaltyCards"; @SerializedName(SERIALIZED_NAME_LOYALTY_CARDS) @@ -72,17 +72,19 @@ public class IntegrationEventV3Request { */ @JsonAdapter(ResponseContentEnum.Adapter.class) public enum ResponseContentEnum { - CUSTOMERPROFILE("customerProfile"), + ADVANCEDEVENT("advancedEvent"), - TRIGGEREDCAMPAIGNS("triggeredCampaigns"), + AWARDEDGIVEAWAYS("awardedGiveaways"), + + CUSTOMERPROFILE("customerProfile"), LOYALTY("loyalty"), - ADVANCEDEVENT("advancedEvent"), + REFERRAL("referral"), - AWARDEDGIVEAWAYS("awardedGiveaways"), + RULEFAILUREREASONS("ruleFailureReasons"), - RULEFAILUREREASONS("ruleFailureReasons"); + TRIGGEREDCAMPAIGNS("triggeredCampaigns"); private String value; @@ -203,28 +205,6 @@ public void setEvaluableCampaignIds(List evaluableCampaignIds) { } - public IntegrationEventV3Request integrationId(String integrationId) { - - this.integrationId = integrationId; - return this; - } - - /** - * The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. - * @return integrationId - **/ - @ApiModelProperty(example = "175KJPS947296", required = true, value = "The unique ID of the current event. Only one event with this ID could be activated, duplicated events are forbidden. ") - - public String getIntegrationId() { - return integrationId; - } - - - public void setIntegrationId(String integrationId) { - this.integrationId = integrationId; - } - - public IntegrationEventV3Request type(String type) { this.type = type; @@ -232,10 +212,10 @@ public IntegrationEventV3Request type(String type) { } /** - * A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event name. Must not be a reserved event name. You create this value when you [create an attribute](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) of type `event` in the Campaign Manager. ") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; @@ -270,49 +250,71 @@ public void setAttributes(Object attributes) { } - public IntegrationEventV3Request connectedSessionID(String connectedSessionID) { + public IntegrationEventV3Request integrationId(String integrationId) { - this.connectedSessionID = connectedSessionID; + this.integrationId = integrationId; return this; } /** - * The ID of the session that happened in the past. - * @return connectedSessionID + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @ApiModelProperty(example = "175KJPS947296", required = true, value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public IntegrationEventV3Request connectedSessionId(String connectedSessionId) { + + this.connectedSessionId = connectedSessionId; + return this; + } + + /** + * The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail. + * @return connectedSessionId **/ @javax.annotation.Nullable - @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session that happened in the past.") + @ApiModelProperty(example = "175KJPS947296", value = "The ID of the session to reference. The session must be in `closed` state. Otherwise, the API call will fail.") - public String getConnectedSessionID() { - return connectedSessionID; + public String getConnectedSessionId() { + return connectedSessionId; } - public void setConnectedSessionID(String connectedSessionID) { - this.connectedSessionID = connectedSessionID; + public void setConnectedSessionId(String connectedSessionId) { + this.connectedSessionId = connectedSessionId; } - public IntegrationEventV3Request previousEventID(String previousEventID) { + public IntegrationEventV3Request referralCode(String referralCode) { - this.previousEventID = previousEventID; + this.referralCode = referralCode; return this; } /** - * The unique identifier of the event that happened in the past. - * @return previousEventID + * The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. + * @return referralCode **/ @javax.annotation.Nullable - @ApiModelProperty(example = "175KJPS947296", value = "The unique identifier of the event that happened in the past.") + @ApiModelProperty(example = "NT2K54D9", value = "The referral code submitted with the event. The endpoint does not validate the code, and submitting a code does not redeem it. Use the \"Referral code is valid\" condition in the Rule Builder to validate and redeem the code, or \"Referral code is valid (without redemption)\" to validate without redeeming. ") - public String getPreviousEventID() { - return previousEventID; + public String getReferralCode() { + return referralCode; } - public void setPreviousEventID(String previousEventID) { - this.previousEventID = previousEventID; + public void setReferralCode(String referralCode) { + this.referralCode = referralCode; } @@ -390,18 +392,18 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.profileId, integrationEventV3Request.profileId) && Objects.equals(this.storeIntegrationId, integrationEventV3Request.storeIntegrationId) && Objects.equals(this.evaluableCampaignIds, integrationEventV3Request.evaluableCampaignIds) && - Objects.equals(this.integrationId, integrationEventV3Request.integrationId) && Objects.equals(this.type, integrationEventV3Request.type) && Objects.equals(this.attributes, integrationEventV3Request.attributes) && - Objects.equals(this.connectedSessionID, integrationEventV3Request.connectedSessionID) && - Objects.equals(this.previousEventID, integrationEventV3Request.previousEventID) && + Objects.equals(this.integrationId, integrationEventV3Request.integrationId) && + Objects.equals(this.connectedSessionId, integrationEventV3Request.connectedSessionId) && + Objects.equals(this.referralCode, integrationEventV3Request.referralCode) && Objects.equals(this.loyaltyCards, integrationEventV3Request.loyaltyCards) && Objects.equals(this.responseContent, integrationEventV3Request.responseContent); } @Override public int hashCode() { - return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, integrationId, type, attributes, connectedSessionID, previousEventID, loyaltyCards, responseContent); + return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, type, attributes, integrationId, connectedSessionId, referralCode, loyaltyCards, responseContent); } @@ -412,11 +414,11 @@ public String toString() { sb.append(" profileId: ").append(toIndentedString(profileId)).append("\n"); sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); sb.append(" evaluableCampaignIds: ").append(toIndentedString(evaluableCampaignIds)).append("\n"); - sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); - sb.append(" connectedSessionID: ").append(toIndentedString(connectedSessionID)).append("\n"); - sb.append(" previousEventID: ").append(toIndentedString(previousEventID)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" connectedSessionId: ").append(toIndentedString(connectedSessionId)).append("\n"); + sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); sb.append(" loyaltyCards: ").append(toIndentedString(loyaltyCards)).append("\n"); sb.append(" responseContent: ").append(toIndentedString(responseContent)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/IntegrationEventV3Response.java b/src/main/java/one/talon/model/IntegrationEventV3Response.java index 082730d4..87645da4 100644 --- a/src/main/java/one/talon/model/IntegrationEventV3Response.java +++ b/src/main/java/one/talon/model/IntegrationEventV3Response.java @@ -26,13 +26,17 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.EventV3; import one.talon.model.Giveaway; +import one.talon.model.InventoryReferral; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; /** @@ -53,6 +57,10 @@ public class IntegrationEventV3Response { @SerializedName(SERIALIZED_NAME_TRIGGERED_CAMPAIGNS) private List triggeredCampaigns = null; + public static final String SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY = "campaignEligibility"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY) + private List campaignEligibility = null; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; @SerializedName(SERIALIZED_NAME_EFFECTS) private List effects = new ArrayList(); @@ -73,10 +81,22 @@ public class IntegrationEventV3Response { @SerializedName(SERIALIZED_NAME_AWARDED_GIVEAWAYS) private List awardedGiveaways = null; + public static final String SERIALIZED_NAME_ACHIEVEMENTS = "achievements"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENTS) + private List achievements = null; + + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public static final String SERIALIZED_NAME_ADVANCED_EVENT = "advancedEvent"; @SerializedName(SERIALIZED_NAME_ADVANCED_EVENT) private EventV3 advancedEvent; + public static final String SERIALIZED_NAME_REFERRAL = "referral"; + @SerializedName(SERIALIZED_NAME_REFERRAL) + private InventoryReferral referral; + public IntegrationEventV3Response customerProfile(CustomerProfile customerProfile) { @@ -155,6 +175,37 @@ public void setTriggeredCampaigns(List triggeredCampaigns) { } + public IntegrationEventV3Response campaignEligibility(List campaignEligibility) { + + this.campaignEligibility = campaignEligibility; + return this; + } + + public IntegrationEventV3Response addCampaignEligibilityItem(CampaignEligibility campaignEligibilityItem) { + if (this.campaignEligibility == null) { + this.campaignEligibility = new ArrayList(); + } + this.campaignEligibility.add(campaignEligibilityItem); + return this; + } + + /** + * A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. + * @return campaignEligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. ") + + public List getCampaignEligibility() { + return campaignEligibility; + } + + + public void setCampaignEligibility(List campaignEligibility) { + this.campaignEligibility = campaignEligibility; + } + + public IntegrationEventV3Response effects(List effects) { this.effects = effects; @@ -298,6 +349,68 @@ public void setAwardedGiveaways(List awardedGiveaways) { } + public IntegrationEventV3Response achievements(List achievements) { + + this.achievements = achievements; + return this; + } + + public IntegrationEventV3Response addAchievementsItem(CustomerAchievement achievementsItem) { + if (this.achievements == null) { + this.achievements = new ArrayList(); + } + this.achievements.add(achievementsItem); + return this; + } + + /** + * The achievements progress of the customer. + * @return achievements + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievements progress of the customer.") + + public List getAchievements() { + return achievements; + } + + + public void setAchievements(List achievements) { + this.achievements = achievements; + } + + + public IntegrationEventV3Response rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public IntegrationEventV3Response addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The rewards for the customer profile. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The rewards for the customer profile.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + public IntegrationEventV3Response advancedEvent(EventV3 advancedEvent) { this.advancedEvent = advancedEvent; @@ -321,6 +434,29 @@ public void setAdvancedEvent(EventV3 advancedEvent) { } + public IntegrationEventV3Response referral(InventoryReferral referral) { + + this.referral = referral; + return this; + } + + /** + * Get referral + * @return referral + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public InventoryReferral getReferral() { + return referral; + } + + + public void setReferral(InventoryReferral referral) { + this.referral = referral; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -333,17 +469,21 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.customerProfile, integrationEventV3Response.customerProfile) && Objects.equals(this.loyalty, integrationEventV3Response.loyalty) && Objects.equals(this.triggeredCampaigns, integrationEventV3Response.triggeredCampaigns) && + Objects.equals(this.campaignEligibility, integrationEventV3Response.campaignEligibility) && Objects.equals(this.effects, integrationEventV3Response.effects) && Objects.equals(this.ruleFailureReasons, integrationEventV3Response.ruleFailureReasons) && Objects.equals(this.createdCoupons, integrationEventV3Response.createdCoupons) && Objects.equals(this.createdReferrals, integrationEventV3Response.createdReferrals) && Objects.equals(this.awardedGiveaways, integrationEventV3Response.awardedGiveaways) && - Objects.equals(this.advancedEvent, integrationEventV3Response.advancedEvent); + Objects.equals(this.achievements, integrationEventV3Response.achievements) && + Objects.equals(this.rewards, integrationEventV3Response.rewards) && + Objects.equals(this.advancedEvent, integrationEventV3Response.advancedEvent) && + Objects.equals(this.referral, integrationEventV3Response.referral); } @Override public int hashCode() { - return Objects.hash(customerProfile, loyalty, triggeredCampaigns, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, advancedEvent); + return Objects.hash(customerProfile, loyalty, triggeredCampaigns, campaignEligibility, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, achievements, rewards, advancedEvent, referral); } @@ -354,12 +494,16 @@ public String toString() { sb.append(" customerProfile: ").append(toIndentedString(customerProfile)).append("\n"); sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); sb.append(" triggeredCampaigns: ").append(toIndentedString(triggeredCampaigns)).append("\n"); + sb.append(" campaignEligibility: ").append(toIndentedString(campaignEligibility)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); sb.append(" createdCoupons: ").append(toIndentedString(createdCoupons)).append("\n"); sb.append(" createdReferrals: ").append(toIndentedString(createdReferrals)).append("\n"); sb.append(" awardedGiveaways: ").append(toIndentedString(awardedGiveaways)).append("\n"); + sb.append(" achievements: ").append(toIndentedString(achievements)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append(" advancedEvent: ").append(toIndentedString(advancedEvent)).append("\n"); + sb.append(" referral: ").append(toIndentedString(referral)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotifications.java b/src/main/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotifications.java index cb31961a..9c1ea0fd 100644 --- a/src/main/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotifications.java +++ b/src/main/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotifications.java @@ -33,6 +33,10 @@ */ public class IntegrationHubEventPayloadCouponBasedNotifications { + public static final String SERIALIZED_NAME_EVENT_ID = "EventId"; + @SerializedName(SERIALIZED_NAME_EVENT_ID) + private Long eventId; + public static final String SERIALIZED_NAME_ID = "Id"; @SerializedName(SERIALIZED_NAME_ID) private Long id; @@ -118,6 +122,28 @@ public class IntegrationHubEventPayloadCouponBasedNotifications { private String employeeName; + public IntegrationHubEventPayloadCouponBasedNotifications eventId(Long eventId) { + + this.eventId = eventId; + return this; + } + + /** + * The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. + * @return eventId + **/ + @ApiModelProperty(example = "123", required = true, value = "The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed.") + + public Long getEventId() { + return eventId; + } + + + public void setEventId(Long eventId) { + this.eventId = eventId; + } + + public IntegrationHubEventPayloadCouponBasedNotifications id(Long id) { this.id = id; @@ -609,7 +635,8 @@ public boolean equals(java.lang.Object o) { return false; } IntegrationHubEventPayloadCouponBasedNotifications integrationHubEventPayloadCouponBasedNotifications = (IntegrationHubEventPayloadCouponBasedNotifications) o; - return Objects.equals(this.id, integrationHubEventPayloadCouponBasedNotifications.id) && + return Objects.equals(this.eventId, integrationHubEventPayloadCouponBasedNotifications.eventId) && + Objects.equals(this.id, integrationHubEventPayloadCouponBasedNotifications.id) && Objects.equals(this.created, integrationHubEventPayloadCouponBasedNotifications.created) && Objects.equals(this.campaignId, integrationHubEventPayloadCouponBasedNotifications.campaignId) && Objects.equals(this.value, integrationHubEventPayloadCouponBasedNotifications.value) && @@ -634,7 +661,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(id, created, campaignId, value, usageLimit, discountLimit, reservationLimit, startDate, expiryDate, usageCounter, discountCounter, discountRemainder, referralId, recipientIntegrationId, importId, batchId, attributes, limits, publishedAt, sourceOfEvent, employeeName); + return Objects.hash(eventId, id, created, campaignId, value, usageLimit, discountLimit, reservationLimit, startDate, expiryDate, usageCounter, discountCounter, discountRemainder, referralId, recipientIntegrationId, importId, batchId, attributes, limits, publishedAt, sourceOfEvent, employeeName); } @@ -642,6 +669,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubEventPayloadCouponBasedNotifications {\n"); + sb.append(" eventId: ").append(toIndentedString(eventId)).append("\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" created: ").append(toIndentedString(created)).append("\n"); sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.java b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.java index 9ae07998..f38d7eab 100644 --- a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.java +++ b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.java @@ -33,6 +33,10 @@ */ public class IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification { + public static final String SERIALIZED_NAME_EVENT_ID = "EventId"; + @SerializedName(SERIALIZED_NAME_EVENT_ID) + private Long eventId; + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_I_D = "ProfileIntegrationID"; @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_I_D) private String profileIntegrationID; @@ -41,6 +45,10 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificat @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_I_D) private Long loyaltyProgramID; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_NAME = "LoyaltyProgramName"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_NAME) + private String loyaltyProgramName; + public static final String SERIALIZED_NAME_SUBLEDGER_I_D = "SubledgerID"; @SerializedName(SERIALIZED_NAME_SUBLEDGER_I_D) private String subledgerID; @@ -49,6 +57,14 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificat @SerializedName(SERIALIZED_NAME_SOURCE_OF_EVENT) private String sourceOfEvent; + public static final String SERIALIZED_NAME_CURRENT_TIER = "CurrentTier"; + @SerializedName(SERIALIZED_NAME_CURRENT_TIER) + private String currentTier; + + public static final String SERIALIZED_NAME_SESSION_INTEGRATION_I_D = "SessionIntegrationID"; + @SerializedName(SERIALIZED_NAME_SESSION_INTEGRATION_I_D) + private String sessionIntegrationID; + public static final String SERIALIZED_NAME_EMPLOYEE_NAME = "EmployeeName"; @SerializedName(SERIALIZED_NAME_EMPLOYEE_NAME) private String employeeName; @@ -70,6 +86,28 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificat private OffsetDateTime publishedAt; + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification eventId(Long eventId) { + + this.eventId = eventId; + return this; + } + + /** + * The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. + * @return eventId + **/ + @ApiModelProperty(example = "123", required = true, value = "The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed.") + + public Long getEventId() { + return eventId; + } + + + public void setEventId(Long eventId) { + this.eventId = eventId; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification profileIntegrationID(String profileIntegrationID) { this.profileIntegrationID = profileIntegrationID; @@ -114,6 +152,28 @@ public void setLoyaltyProgramID(Long loyaltyProgramID) { } + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification loyaltyProgramName(String loyaltyProgramName) { + + this.loyaltyProgramName = loyaltyProgramName; + return this; + } + + /** + * The name of the loyalty program. + * @return loyaltyProgramName + **/ + @ApiModelProperty(required = true, value = "The name of the loyalty program.") + + public String getLoyaltyProgramName() { + return loyaltyProgramName; + } + + + public void setLoyaltyProgramName(String loyaltyProgramName) { + this.loyaltyProgramName = loyaltyProgramName; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification subledgerID(String subledgerID) { this.subledgerID = subledgerID; @@ -158,6 +218,51 @@ public void setSourceOfEvent(String sourceOfEvent) { } + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification currentTier(String currentTier) { + + this.currentTier = currentTier; + return this; + } + + /** + * The name of the customer's current tier. + * @return currentTier + **/ + @ApiModelProperty(required = true, value = "The name of the customer's current tier.") + + public String getCurrentTier() { + return currentTier; + } + + + public void setCurrentTier(String currentTier) { + this.currentTier = currentTier; + } + + + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification sessionIntegrationID(String sessionIntegrationID) { + + this.sessionIntegrationID = sessionIntegrationID; + return this; + } + + /** + * 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. + * @return sessionIntegrationID + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "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.") + + public String getSessionIntegrationID() { + return sessionIntegrationID; + } + + + public void setSessionIntegrationID(String sessionIntegrationID) { + this.sessionIntegrationID = sessionIntegrationID; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification employeeName(String employeeName) { this.employeeName = employeeName; @@ -288,10 +393,14 @@ public boolean equals(java.lang.Object o) { return false; } IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification = (IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification) o; - return Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.profileIntegrationID) && + return Objects.equals(this.eventId, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.eventId) && + Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.profileIntegrationID) && Objects.equals(this.loyaltyProgramID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.loyaltyProgramID) && + Objects.equals(this.loyaltyProgramName, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.loyaltyProgramName) && Objects.equals(this.subledgerID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.subledgerID) && Objects.equals(this.sourceOfEvent, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.sourceOfEvent) && + Objects.equals(this.currentTier, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.currentTier) && + Objects.equals(this.sessionIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.sessionIntegrationID) && Objects.equals(this.employeeName, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.employeeName) && Objects.equals(this.userID, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.userID) && Objects.equals(this.currentPoints, integrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.currentPoints) && @@ -301,7 +410,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(profileIntegrationID, loyaltyProgramID, subledgerID, sourceOfEvent, employeeName, userID, currentPoints, actions, publishedAt); + return Objects.hash(eventId, profileIntegrationID, loyaltyProgramID, loyaltyProgramName, subledgerID, sourceOfEvent, currentTier, sessionIntegrationID, employeeName, userID, currentPoints, actions, publishedAt); } @@ -309,10 +418,14 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification {\n"); + sb.append(" eventId: ").append(toIndentedString(eventId)).append("\n"); sb.append(" profileIntegrationID: ").append(toIndentedString(profileIntegrationID)).append("\n"); sb.append(" loyaltyProgramID: ").append(toIndentedString(loyaltyProgramID)).append("\n"); + sb.append(" loyaltyProgramName: ").append(toIndentedString(loyaltyProgramName)).append("\n"); sb.append(" subledgerID: ").append(toIndentedString(subledgerID)).append("\n"); sb.append(" sourceOfEvent: ").append(toIndentedString(sourceOfEvent)).append("\n"); + sb.append(" currentTier: ").append(toIndentedString(currentTier)).append("\n"); + sb.append(" sessionIntegrationID: ").append(toIndentedString(sessionIntegrationID)).append("\n"); sb.append(" employeeName: ").append(toIndentedString(employeeName)).append("\n"); sb.append(" userID: ").append(toIndentedString(userID)).append("\n"); sb.append(" currentPoints: ").append(toIndentedString(currentPoints)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.java b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.java index f5ce1bb3..fc75ec6f 100644 --- a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.java +++ b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.java @@ -30,6 +30,10 @@ */ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification { + public static final String SERIALIZED_NAME_EVENT_ID = "EventId"; + @SerializedName(SERIALIZED_NAME_EVENT_ID) + private Long eventId; + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_I_D = "ProfileIntegrationID"; @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_I_D) private String profileIntegrationID; @@ -38,6 +42,10 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificat @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_I_D) private Long loyaltyProgramID; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_NAME = "LoyaltyProgramName"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_NAME) + private String loyaltyProgramName; + public static final String SERIALIZED_NAME_SUBLEDGER_I_D = "SubledgerID"; @SerializedName(SERIALIZED_NAME_SUBLEDGER_I_D) private String subledgerID; @@ -71,6 +79,28 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificat private OffsetDateTime publishedAt; + public IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification eventId(Long eventId) { + + this.eventId = eventId; + return this; + } + + /** + * The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. + * @return eventId + **/ + @ApiModelProperty(example = "123", required = true, value = "The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed.") + + public Long getEventId() { + return eventId; + } + + + public void setEventId(Long eventId) { + this.eventId = eventId; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification profileIntegrationID(String profileIntegrationID) { this.profileIntegrationID = profileIntegrationID; @@ -115,6 +145,28 @@ public void setLoyaltyProgramID(Long loyaltyProgramID) { } + public IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification loyaltyProgramName(String loyaltyProgramName) { + + this.loyaltyProgramName = loyaltyProgramName; + return this; + } + + /** + * The name of the loyalty program. + * @return loyaltyProgramName + **/ + @ApiModelProperty(required = true, value = "The name of the loyalty program.") + + public String getLoyaltyProgramName() { + return loyaltyProgramName; + } + + + public void setLoyaltyProgramName(String loyaltyProgramName) { + this.loyaltyProgramName = loyaltyProgramName; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification subledgerID(String subledgerID) { this.subledgerID = subledgerID; @@ -166,11 +218,11 @@ public IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification cu } /** - * Get currentTier + * The name of the customer's current tier, or null if the customer was downgraded below all tiers. * @return currentTier **/ @javax.annotation.Nullable - @ApiModelProperty(value = "") + @ApiModelProperty(value = "The name of the customer's current tier, or null if the customer was downgraded below all tiers.") public String getCurrentTier() { return currentTier; @@ -304,8 +356,10 @@ public boolean equals(java.lang.Object o) { return false; } IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification = (IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification) o; - return Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.profileIntegrationID) && + return Objects.equals(this.eventId, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.eventId) && + Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.profileIntegrationID) && Objects.equals(this.loyaltyProgramID, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.loyaltyProgramID) && + Objects.equals(this.loyaltyProgramName, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.loyaltyProgramName) && Objects.equals(this.subledgerID, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.subledgerID) && Objects.equals(this.sourceOfEvent, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.sourceOfEvent) && Objects.equals(this.currentTier, integrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification.currentTier) && @@ -318,7 +372,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(profileIntegrationID, loyaltyProgramID, subledgerID, sourceOfEvent, currentTier, currentPoints, oldTier, tierExpirationDate, timestampOfTierChange, publishedAt); + return Objects.hash(eventId, profileIntegrationID, loyaltyProgramID, loyaltyProgramName, subledgerID, sourceOfEvent, currentTier, currentPoints, oldTier, tierExpirationDate, timestampOfTierChange, publishedAt); } @@ -326,8 +380,10 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification {\n"); + sb.append(" eventId: ").append(toIndentedString(eventId)).append("\n"); sb.append(" profileIntegrationID: ").append(toIndentedString(profileIntegrationID)).append("\n"); sb.append(" loyaltyProgramID: ").append(toIndentedString(loyaltyProgramID)).append("\n"); + sb.append(" loyaltyProgramName: ").append(toIndentedString(loyaltyProgramName)).append("\n"); sb.append(" subledgerID: ").append(toIndentedString(subledgerID)).append("\n"); sb.append(" sourceOfEvent: ").append(toIndentedString(sourceOfEvent)).append("\n"); sb.append(" currentTier: ").append(toIndentedString(currentTier)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.java b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.java index 0a42005e..3bb2090c 100644 --- a/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.java +++ b/src/main/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.java @@ -30,6 +30,10 @@ */ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification { + public static final String SERIALIZED_NAME_EVENT_ID = "EventId"; + @SerializedName(SERIALIZED_NAME_EVENT_ID) + private Long eventId; + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_I_D = "ProfileIntegrationID"; @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_I_D) private String profileIntegrationID; @@ -38,6 +42,10 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificatio @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_I_D) private Long loyaltyProgramID; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_NAME = "LoyaltyProgramName"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_NAME) + private String loyaltyProgramName; + public static final String SERIALIZED_NAME_SUBLEDGER_I_D = "SubledgerID"; @SerializedName(SERIALIZED_NAME_SUBLEDGER_I_D) private String subledgerID; @@ -79,6 +87,28 @@ public class IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificatio private OffsetDateTime publishedAt; + public IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification eventId(Long eventId) { + + this.eventId = eventId; + return this; + } + + /** + * The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed. + * @return eventId + **/ + @ApiModelProperty(example = "123", required = true, value = "The ID of the integration hub event. Return this value in the delivery-status callback to mark the event delivered or failed.") + + public Long getEventId() { + return eventId; + } + + + public void setEventId(Long eventId) { + this.eventId = eventId; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification profileIntegrationID(String profileIntegrationID) { this.profileIntegrationID = profileIntegrationID; @@ -123,6 +153,28 @@ public void setLoyaltyProgramID(Long loyaltyProgramID) { } + public IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification loyaltyProgramName(String loyaltyProgramName) { + + this.loyaltyProgramName = loyaltyProgramName; + return this; + } + + /** + * The name of the loyalty program. + * @return loyaltyProgramName + **/ + @ApiModelProperty(required = true, value = "The name of the loyalty program.") + + public String getLoyaltyProgramName() { + return loyaltyProgramName; + } + + + public void setLoyaltyProgramName(String loyaltyProgramName) { + this.loyaltyProgramName = loyaltyProgramName; + } + + public IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification subledgerID(String subledgerID) { this.subledgerID = subledgerID; @@ -174,11 +226,10 @@ public IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification curr } /** - * Get currentTier + * The name of the customer's current tier. * @return currentTier **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") + @ApiModelProperty(required = true, value = "The name of the customer's current tier.") public String getCurrentTier() { return currentTier; @@ -358,8 +409,10 @@ public boolean equals(java.lang.Object o) { return false; } IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification = (IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification) o; - return Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.profileIntegrationID) && + return Objects.equals(this.eventId, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.eventId) && + Objects.equals(this.profileIntegrationID, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.profileIntegrationID) && Objects.equals(this.loyaltyProgramID, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.loyaltyProgramID) && + Objects.equals(this.loyaltyProgramName, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.loyaltyProgramName) && Objects.equals(this.subledgerID, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.subledgerID) && Objects.equals(this.sourceOfEvent, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.sourceOfEvent) && Objects.equals(this.currentTier, integrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification.currentTier) && @@ -374,7 +427,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(profileIntegrationID, loyaltyProgramID, subledgerID, sourceOfEvent, currentTier, currentPoints, oldTier, pointsRequiredToTheNextTier, nextTier, tierExpirationDate, timestampOfTierChange, publishedAt); + return Objects.hash(eventId, profileIntegrationID, loyaltyProgramID, loyaltyProgramName, subledgerID, sourceOfEvent, currentTier, currentPoints, oldTier, pointsRequiredToTheNextTier, nextTier, tierExpirationDate, timestampOfTierChange, publishedAt); } @@ -382,8 +435,10 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification {\n"); + sb.append(" eventId: ").append(toIndentedString(eventId)).append("\n"); sb.append(" profileIntegrationID: ").append(toIndentedString(profileIntegrationID)).append("\n"); sb.append(" loyaltyProgramID: ").append(toIndentedString(loyaltyProgramID)).append("\n"); + sb.append(" loyaltyProgramName: ").append(toIndentedString(loyaltyProgramName)).append("\n"); sb.append(" subledgerID: ").append(toIndentedString(subledgerID)).append("\n"); sb.append(" sourceOfEvent: ").append(toIndentedString(sourceOfEvent)).append("\n"); sb.append(" currentTier: ").append(toIndentedString(currentTier)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationHubEventRecord.java b/src/main/java/one/talon/model/IntegrationHubEventRecord.java index ca450d92..9bf96095 100644 --- a/src/main/java/one/talon/model/IntegrationHubEventRecord.java +++ b/src/main/java/one/talon/model/IntegrationHubEventRecord.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; import org.threeten.bp.OffsetDateTime; /** @@ -30,38 +31,50 @@ */ public class IntegrationHubEventRecord { - public static final String SERIALIZED_NAME_ID = "Id"; + public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) private Long id; - public static final String SERIALIZED_NAME_FLOW_ID = "FlowId"; + public static final String SERIALIZED_NAME_FLOW_ID = "flowId"; @SerializedName(SERIALIZED_NAME_FLOW_ID) private Long flowId; - public static final String SERIALIZED_NAME_EVENT_TYPE = "EventType"; - @SerializedName(SERIALIZED_NAME_EVENT_TYPE) - private String eventType; + public static final String SERIALIZED_NAME_INTEGRATION_NAME = "integrationName"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_NAME) + private String integrationName; + + public static final String SERIALIZED_NAME_INSTANCE_NAME = "instanceName"; + @SerializedName(SERIALIZED_NAME_INSTANCE_NAME) + private String instanceName; - public static final String SERIALIZED_NAME_EVENT_DATA = "EventData"; - @SerializedName(SERIALIZED_NAME_EVENT_DATA) - private Object eventData; + public static final String SERIALIZED_NAME_EVENT_TYPE = "eventType"; + @SerializedName(SERIALIZED_NAME_EVENT_TYPE) + private IntegrationHubEventType eventType; - public static final String SERIALIZED_NAME_PUBLISHED_AT = "PublishedAt"; + public static final String SERIALIZED_NAME_PUBLISHED_AT = "publishedAt"; @SerializedName(SERIALIZED_NAME_PUBLISHED_AT) private OffsetDateTime publishedAt; - public static final String SERIALIZED_NAME_PROCESSED_AT = "ProcessedAt"; + public static final String SERIALIZED_NAME_PROCESSED_AT = "processedAt"; @SerializedName(SERIALIZED_NAME_PROCESSED_AT) private OffsetDateTime processedAt; - public static final String SERIALIZED_NAME_PROCESS_AFTER = "ProcessAfter"; - @SerializedName(SERIALIZED_NAME_PROCESS_AFTER) - private OffsetDateTime processAfter; + public static final String SERIALIZED_NAME_DELIVERED_AT = "deliveredAt"; + @SerializedName(SERIALIZED_NAME_DELIVERED_AT) + private OffsetDateTime deliveredAt; + + public static final String SERIALIZED_NAME_SCHEDULED_TO = "scheduledTo"; + @SerializedName(SERIALIZED_NAME_SCHEDULED_TO) + private OffsetDateTime scheduledTo; - public static final String SERIALIZED_NAME_RETRY = "Retry"; + public static final String SERIALIZED_NAME_RETRY = "retry"; @SerializedName(SERIALIZED_NAME_RETRY) private Long retry; + public static final String SERIALIZED_NAME_PAYLOAD = "payload"; + @SerializedName(SERIALIZED_NAME_PAYLOAD) + private String payload; + public IntegrationHubEventRecord id(Long id) { @@ -70,10 +83,10 @@ public IntegrationHubEventRecord id(Long id) { } /** - * Get id + * ID of the event record. * @return id **/ - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "ID of the event record.") public Long getId() { return id; @@ -92,10 +105,10 @@ public IntegrationHubEventRecord flowId(Long flowId) { } /** - * Get flowId + * ID of the integration hub flow. * @return flowId **/ - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "ID of the integration hub flow.") public Long getFlowId() { return flowId; @@ -107,47 +120,71 @@ public void setFlowId(Long flowId) { } - public IntegrationHubEventRecord eventType(String eventType) { + public IntegrationHubEventRecord integrationName(String integrationName) { - this.eventType = eventType; + this.integrationName = integrationName; return this; } /** - * Get eventType - * @return eventType + * Name of the integration. + * @return integrationName **/ - @ApiModelProperty(required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "Name of the integration.") - public String getEventType() { - return eventType; + public String getIntegrationName() { + return integrationName; } - public void setEventType(String eventType) { - this.eventType = eventType; + public void setIntegrationName(String integrationName) { + this.integrationName = integrationName; + } + + + public IntegrationHubEventRecord instanceName(String instanceName) { + + this.instanceName = instanceName; + return this; + } + + /** + * Name of the integration instance. + * @return instanceName + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Name of the integration instance.") + + public String getInstanceName() { + return instanceName; + } + + + public void setInstanceName(String instanceName) { + this.instanceName = instanceName; } - public IntegrationHubEventRecord eventData(Object eventData) { + public IntegrationHubEventRecord eventType(IntegrationHubEventType eventType) { - this.eventData = eventData; + this.eventType = eventType; return this; } /** - * Get eventData - * @return eventData + * Get eventType + * @return eventType **/ @ApiModelProperty(required = true, value = "") - public Object getEventData() { - return eventData; + public IntegrationHubEventType getEventType() { + return eventType; } - public void setEventData(Object eventData) { - this.eventData = eventData; + public void setEventType(IntegrationHubEventType eventType) { + this.eventType = eventType; } @@ -158,10 +195,10 @@ public IntegrationHubEventRecord publishedAt(OffsetDateTime publishedAt) { } /** - * Get publishedAt + * Timestamp when the event was published. * @return publishedAt **/ - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "Timestamp when the event was published.") public OffsetDateTime getPublishedAt() { return publishedAt; @@ -180,11 +217,11 @@ public IntegrationHubEventRecord processedAt(OffsetDateTime processedAt) { } /** - * Get processedAt + * Timestamp when the event was processed. * @return processedAt **/ @javax.annotation.Nullable - @ApiModelProperty(value = "") + @ApiModelProperty(value = "Timestamp when the event was processed.") public OffsetDateTime getProcessedAt() { return processedAt; @@ -196,25 +233,48 @@ public void setProcessedAt(OffsetDateTime processedAt) { } - public IntegrationHubEventRecord processAfter(OffsetDateTime processAfter) { + public IntegrationHubEventRecord deliveredAt(OffsetDateTime deliveredAt) { - this.processAfter = processAfter; + this.deliveredAt = deliveredAt; return this; } /** - * Get processAfter - * @return processAfter + * Timestamp when the event was delivered. + * @return deliveredAt **/ - @ApiModelProperty(required = true, value = "") + @javax.annotation.Nullable + @ApiModelProperty(value = "Timestamp when the event was delivered.") + + public OffsetDateTime getDeliveredAt() { + return deliveredAt; + } + + + public void setDeliveredAt(OffsetDateTime deliveredAt) { + this.deliveredAt = deliveredAt; + } + - public OffsetDateTime getProcessAfter() { - return processAfter; + public IntegrationHubEventRecord scheduledTo(OffsetDateTime scheduledTo) { + + this.scheduledTo = scheduledTo; + return this; } + /** + * Timestamp after which the event is scheduled to be processed. + * @return scheduledTo + **/ + @ApiModelProperty(required = true, value = "Timestamp after which the event is scheduled to be processed.") - public void setProcessAfter(OffsetDateTime processAfter) { - this.processAfter = processAfter; + public OffsetDateTime getScheduledTo() { + return scheduledTo; + } + + + public void setScheduledTo(OffsetDateTime scheduledTo) { + this.scheduledTo = scheduledTo; } @@ -225,10 +285,10 @@ public IntegrationHubEventRecord retry(Long retry) { } /** - * Get retry + * Number of delivery retries attempted. * @return retry **/ - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "Number of delivery retries attempted.") public Long getRetry() { return retry; @@ -240,6 +300,28 @@ public void setRetry(Long retry) { } + public IntegrationHubEventRecord payload(String payload) { + + this.payload = payload; + return this; + } + + /** + * The event payload as a formatted JSON string. + * @return payload + **/ + @ApiModelProperty(required = true, value = "The event payload as a formatted JSON string.") + + public String getPayload() { + return payload; + } + + + public void setPayload(String payload) { + this.payload = payload; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -251,17 +333,20 @@ public boolean equals(java.lang.Object o) { IntegrationHubEventRecord integrationHubEventRecord = (IntegrationHubEventRecord) o; return Objects.equals(this.id, integrationHubEventRecord.id) && Objects.equals(this.flowId, integrationHubEventRecord.flowId) && + Objects.equals(this.integrationName, integrationHubEventRecord.integrationName) && + Objects.equals(this.instanceName, integrationHubEventRecord.instanceName) && Objects.equals(this.eventType, integrationHubEventRecord.eventType) && - Objects.equals(this.eventData, integrationHubEventRecord.eventData) && Objects.equals(this.publishedAt, integrationHubEventRecord.publishedAt) && Objects.equals(this.processedAt, integrationHubEventRecord.processedAt) && - Objects.equals(this.processAfter, integrationHubEventRecord.processAfter) && - Objects.equals(this.retry, integrationHubEventRecord.retry); + Objects.equals(this.deliveredAt, integrationHubEventRecord.deliveredAt) && + Objects.equals(this.scheduledTo, integrationHubEventRecord.scheduledTo) && + Objects.equals(this.retry, integrationHubEventRecord.retry) && + Objects.equals(this.payload, integrationHubEventRecord.payload); } @Override public int hashCode() { - return Objects.hash(id, flowId, eventType, eventData, publishedAt, processedAt, processAfter, retry); + return Objects.hash(id, flowId, integrationName, instanceName, eventType, publishedAt, processedAt, deliveredAt, scheduledTo, retry, payload); } @@ -271,12 +356,15 @@ public String toString() { sb.append("class IntegrationHubEventRecord {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" flowId: ").append(toIndentedString(flowId)).append("\n"); + sb.append(" integrationName: ").append(toIndentedString(integrationName)).append("\n"); + sb.append(" instanceName: ").append(toIndentedString(instanceName)).append("\n"); sb.append(" eventType: ").append(toIndentedString(eventType)).append("\n"); - sb.append(" eventData: ").append(toIndentedString(eventData)).append("\n"); sb.append(" publishedAt: ").append(toIndentedString(publishedAt)).append("\n"); sb.append(" processedAt: ").append(toIndentedString(processedAt)).append("\n"); - sb.append(" processAfter: ").append(toIndentedString(processAfter)).append("\n"); + sb.append(" deliveredAt: ").append(toIndentedString(deliveredAt)).append("\n"); + sb.append(" scheduledTo: ").append(toIndentedString(scheduledTo)).append("\n"); sb.append(" retry: ").append(toIndentedString(retry)).append("\n"); + sb.append(" payload: ").append(toIndentedString(payload)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IntegrationHubEventStatusUpdate.java b/src/main/java/one/talon/model/IntegrationHubEventStatusUpdate.java new file mode 100644 index 00000000..781905ea --- /dev/null +++ b/src/main/java/one/talon/model/IntegrationHubEventStatusUpdate.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * IntegrationHubEventStatusUpdate + */ + +public class IntegrationHubEventStatusUpdate { + public static final String SERIALIZED_NAME_EVENT_ID = "EventId"; + @SerializedName(SERIALIZED_NAME_EVENT_ID) + private Long eventId; + + /** + * The delivery outcome for the event. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + DELIVERED("delivered"), + + FAILED("failed"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "Status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + + public IntegrationHubEventStatusUpdate eventId(Long eventId) { + + this.eventId = eventId; + return this; + } + + /** + * The ID of the integration hub event. + * @return eventId + **/ + @ApiModelProperty(example = "123", required = true, value = "The ID of the integration hub event.") + + public Long getEventId() { + return eventId; + } + + + public void setEventId(Long eventId) { + this.eventId = eventId; + } + + + public IntegrationHubEventStatusUpdate status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The delivery outcome for the event. + * @return status + **/ + @ApiModelProperty(required = true, value = "The delivery outcome for the event.") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + IntegrationHubEventStatusUpdate integrationHubEventStatusUpdate = (IntegrationHubEventStatusUpdate) o; + return Objects.equals(this.eventId, integrationHubEventStatusUpdate.eventId) && + Objects.equals(this.status, integrationHubEventStatusUpdate.status); + } + + @Override + public int hashCode() { + return Objects.hash(eventId, status); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class IntegrationHubEventStatusUpdate {\n"); + sb.append(" eventId: ").append(toIndentedString(eventId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/IntegrationHubEventType.java b/src/main/java/one/talon/model/IntegrationHubEventType.java new file mode 100644 index 00000000..f86febcc --- /dev/null +++ b/src/main/java/one/talon/model/IntegrationHubEventType.java @@ -0,0 +1,82 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import com.google.gson.annotations.SerializedName; + +import java.io.IOException; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; + +/** + * The type of integration hub event. + */ +@JsonAdapter(IntegrationHubEventType.Adapter.class) +public enum IntegrationHubEventType { + + LOYALTYPOINTSCHANGED("LoyaltyPointsChanged"), + + LOYALTYTIERDOWNGRADE("LoyaltyTierDowngrade"), + + LOYALTYTIERUPGRADE("LoyaltyTierUpgrade"), + + COUPONCREATED("CouponCreated"), + + COUPONUPDATED("CouponUpdated"), + + COUPONDELETED("CouponDeleted"); + + private String value; + + IntegrationHubEventType(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static IntegrationHubEventType fromValue(String value) { + for (IntegrationHubEventType b : IntegrationHubEventType.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final IntegrationHubEventType enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public IntegrationHubEventType read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return IntegrationHubEventType.fromValue(value); + } + } +} + diff --git a/src/main/java/one/talon/model/IntegrationHubFlow.java b/src/main/java/one/talon/model/IntegrationHubFlow.java index 431a7d06..580596fb 100644 --- a/src/main/java/one/talon/model/IntegrationHubFlow.java +++ b/src/main/java/one/talon/model/IntegrationHubFlow.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; /** * IntegrationHubFlow @@ -33,9 +34,13 @@ public class IntegrationHubFlow { @SerializedName(SERIALIZED_NAME_APPLICATION_I_D) private Long applicationID; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_I_D = "LoyaltyProgramID"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_I_D) + private Long loyaltyProgramID; + public static final String SERIALIZED_NAME_EVENT_TYPE = "EventType"; @SerializedName(SERIALIZED_NAME_EVENT_TYPE) - private String eventType; + private IntegrationHubEventType eventType; public static final String SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL = "IntegrationHubFlowUrl"; @SerializedName(SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL) @@ -49,11 +54,11 @@ public IntegrationHubFlow applicationID(Long applicationID) { } /** - * ID of application the flow is registered for. + * ID of the application the flow is registered for. * @return applicationID **/ @javax.annotation.Nullable - @ApiModelProperty(example = "54", value = "ID of application the flow is registered for.") + @ApiModelProperty(example = "54", value = "ID of the application the flow is registered for.") public Long getApplicationID() { return applicationID; @@ -65,24 +70,47 @@ public void setApplicationID(Long applicationID) { } - public IntegrationHubFlow eventType(String eventType) { + public IntegrationHubFlow loyaltyProgramID(Long loyaltyProgramID) { + + this.loyaltyProgramID = loyaltyProgramID; + return this; + } + + /** + * ID of the loyalty program the flow is registered for. + * @return loyaltyProgramID + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "12", value = "ID of the loyalty program the flow is registered for.") + + public Long getLoyaltyProgramID() { + return loyaltyProgramID; + } + + + public void setLoyaltyProgramID(Long loyaltyProgramID) { + this.loyaltyProgramID = loyaltyProgramID; + } + + + public IntegrationHubFlow eventType(IntegrationHubEventType eventType) { this.eventType = eventType; return this; } /** - * The event type we want to register a flow for. + * Get eventType * @return eventType **/ - @ApiModelProperty(required = true, value = "The event type we want to register a flow for.") + @ApiModelProperty(required = true, value = "") - public String getEventType() { + public IntegrationHubEventType getEventType() { return eventType; } - public void setEventType(String eventType) { + public void setEventType(IntegrationHubEventType eventType) { this.eventType = eventType; } @@ -119,13 +147,14 @@ public boolean equals(java.lang.Object o) { } IntegrationHubFlow integrationHubFlow = (IntegrationHubFlow) o; return Objects.equals(this.applicationID, integrationHubFlow.applicationID) && + Objects.equals(this.loyaltyProgramID, integrationHubFlow.loyaltyProgramID) && Objects.equals(this.eventType, integrationHubFlow.eventType) && Objects.equals(this.integrationHubFlowUrl, integrationHubFlow.integrationHubFlowUrl); } @Override public int hashCode() { - return Objects.hash(applicationID, eventType, integrationHubFlowUrl); + return Objects.hash(applicationID, loyaltyProgramID, eventType, integrationHubFlowUrl); } @@ -134,6 +163,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubFlow {\n"); sb.append(" applicationID: ").append(toIndentedString(applicationID)).append("\n"); + sb.append(" loyaltyProgramID: ").append(toIndentedString(loyaltyProgramID)).append("\n"); sb.append(" eventType: ").append(toIndentedString(eventType)).append("\n"); sb.append(" integrationHubFlowUrl: ").append(toIndentedString(integrationHubFlowUrl)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/IntegrationHubFlowConfig.java b/src/main/java/one/talon/model/IntegrationHubFlowConfig.java index 8b4319d0..097d5a4d 100644 --- a/src/main/java/one/talon/model/IntegrationHubFlowConfig.java +++ b/src/main/java/one/talon/model/IntegrationHubFlowConfig.java @@ -45,6 +45,14 @@ public class IntegrationHubFlowConfig { @SerializedName(SERIALIZED_NAME_MAX_RETRIES) private Long maxRetries = 10l; + public static final String SERIALIZED_NAME_INSTANCE_NAME = "InstanceName"; + @SerializedName(SERIALIZED_NAME_INSTANCE_NAME) + private String instanceName; + + public static final String SERIALIZED_NAME_INTEGRATION_NAME = "IntegrationName"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_NAME) + private String integrationName; + public IntegrationHubFlowConfig apiKey(String apiKey) { @@ -141,6 +149,52 @@ public void setMaxRetries(Long maxRetries) { } + public IntegrationHubFlowConfig instanceName(String instanceName) { + + this.instanceName = instanceName; + return this; + } + + /** + * Name of the Prismatic instance that registered this flow. + * @return instanceName + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Name of the Prismatic instance that registered this flow.") + + public String getInstanceName() { + return instanceName; + } + + + public void setInstanceName(String instanceName) { + this.instanceName = instanceName; + } + + + public IntegrationHubFlowConfig integrationName(String integrationName) { + + this.integrationName = integrationName; + return this; + } + + /** + * Name of the Prismatic integration that registered this flow. + * @return integrationName + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Name of the Prismatic integration that registered this flow.") + + public String getIntegrationName() { + return integrationName; + } + + + public void setIntegrationName(String integrationName) { + this.integrationName = integrationName; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -153,12 +207,14 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.apiKey, integrationHubFlowConfig.apiKey) && Objects.equals(this.workerCount, integrationHubFlowConfig.workerCount) && Objects.equals(this.maxEventsPerMessage, integrationHubFlowConfig.maxEventsPerMessage) && - Objects.equals(this.maxRetries, integrationHubFlowConfig.maxRetries); + Objects.equals(this.maxRetries, integrationHubFlowConfig.maxRetries) && + Objects.equals(this.instanceName, integrationHubFlowConfig.instanceName) && + Objects.equals(this.integrationName, integrationHubFlowConfig.integrationName); } @Override public int hashCode() { - return Objects.hash(apiKey, workerCount, maxEventsPerMessage, maxRetries); + return Objects.hash(apiKey, workerCount, maxEventsPerMessage, maxRetries, instanceName, integrationName); } @@ -170,6 +226,8 @@ public String toString() { sb.append(" workerCount: ").append(toIndentedString(workerCount)).append("\n"); sb.append(" maxEventsPerMessage: ").append(toIndentedString(maxEventsPerMessage)).append("\n"); sb.append(" maxRetries: ").append(toIndentedString(maxRetries)).append("\n"); + sb.append(" instanceName: ").append(toIndentedString(instanceName)).append("\n"); + sb.append(" integrationName: ").append(toIndentedString(integrationName)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IntegrationHubFlowResponse.java b/src/main/java/one/talon/model/IntegrationHubFlowResponse.java index ad9cb892..6ff75f63 100644 --- a/src/main/java/one/talon/model/IntegrationHubFlowResponse.java +++ b/src/main/java/one/talon/model/IntegrationHubFlowResponse.java @@ -24,29 +24,46 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import one.talon.model.IntegrationHubFlowConfigResponse; +import org.threeten.bp.OffsetDateTime; /** * IntegrationHubFlowResponse */ public class IntegrationHubFlowResponse { - public static final String SERIALIZED_NAME_ID = "Id"; + public static final String SERIALIZED_NAME_ID = "id"; @SerializedName(SERIALIZED_NAME_ID) private Long id; - public static final String SERIALIZED_NAME_APPLICATION_I_D = "ApplicationID"; - @SerializedName(SERIALIZED_NAME_APPLICATION_I_D) - private Long applicationID; + public static final String SERIALIZED_NAME_INTEGRATION_NAME = "integrationName"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_NAME) + private String integrationName; - public static final String SERIALIZED_NAME_EVENT_TYPE = "EventType"; + public static final String SERIALIZED_NAME_INSTANCE_NAME = "instanceName"; + @SerializedName(SERIALIZED_NAME_INSTANCE_NAME) + private String instanceName; + + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + @SerializedName(SERIALIZED_NAME_CREATED_AT) + private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_DISABLED_UNTIL = "disabledUntil"; + @SerializedName(SERIALIZED_NAME_DISABLED_UNTIL) + private OffsetDateTime disabledUntil; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_EVENT_TYPE = "eventType"; @SerializedName(SERIALIZED_NAME_EVENT_TYPE) private String eventType; - public static final String SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL = "IntegrationHubFlowUrl"; - @SerializedName(SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL) - private String integrationHubFlowUrl; - - public static final String SERIALIZED_NAME_CONFIG = "Config"; + public static final String SERIALIZED_NAME_CONFIG = "config"; @SerializedName(SERIALIZED_NAME_CONFIG) private IntegrationHubFlowConfigResponse config; @@ -73,70 +90,162 @@ public void setId(Long id) { } - public IntegrationHubFlowResponse applicationID(Long applicationID) { + public IntegrationHubFlowResponse integrationName(String integrationName) { - this.applicationID = applicationID; + this.integrationName = integrationName; return this; } /** - * ID of application the flow is registered for. - * @return applicationID + * Name of the integration. + * @return integrationName **/ @javax.annotation.Nullable - @ApiModelProperty(example = "54", value = "ID of application the flow is registered for.") + @ApiModelProperty(value = "Name of the integration.") - public Long getApplicationID() { - return applicationID; + public String getIntegrationName() { + return integrationName; } - public void setApplicationID(Long applicationID) { - this.applicationID = applicationID; + public void setIntegrationName(String integrationName) { + this.integrationName = integrationName; } - public IntegrationHubFlowResponse eventType(String eventType) { + public IntegrationHubFlowResponse instanceName(String instanceName) { - this.eventType = eventType; + this.instanceName = instanceName; return this; } /** - * The event type we want to register a flow for. - * @return eventType + * Name of the integration instance. + * @return instanceName **/ - @ApiModelProperty(required = true, value = "The event type we want to register a flow for.") + @javax.annotation.Nullable + @ApiModelProperty(value = "Name of the integration instance.") - public String getEventType() { - return eventType; + public String getInstanceName() { + return instanceName; } - public void setEventType(String eventType) { - this.eventType = eventType; + public void setInstanceName(String instanceName) { + this.instanceName = instanceName; + } + + + public IntegrationHubFlowResponse createdAt(OffsetDateTime createdAt) { + + this.createdAt = createdAt; + return this; + } + + /** + * Timestamp when the flow was created. + * @return createdAt + **/ + @ApiModelProperty(required = true, value = "Timestamp when the flow was created.") + + public OffsetDateTime getCreatedAt() { + return createdAt; + } + + + public void setCreatedAt(OffsetDateTime createdAt) { + this.createdAt = createdAt; + } + + + public IntegrationHubFlowResponse disabledUntil(OffsetDateTime disabledUntil) { + + this.disabledUntil = disabledUntil; + return this; + } + + /** + * Timestamp until which the flow is disabled. Null when the flow is active. + * @return disabledUntil + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Timestamp until which the flow is disabled. Null when the flow is active.") + + public OffsetDateTime getDisabledUntil() { + return disabledUntil; } - public IntegrationHubFlowResponse integrationHubFlowUrl(String integrationHubFlowUrl) { + public void setDisabledUntil(OffsetDateTime disabledUntil) { + this.disabledUntil = disabledUntil; + } + + + public IntegrationHubFlowResponse applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * ID of the application the flow is registered for. + * @return applicationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "54", value = "ID of the application the flow is registered for.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public IntegrationHubFlowResponse loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * ID of the loyalty program the flow is registered for. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "12", value = "ID of the loyalty program the flow is registered for.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public IntegrationHubFlowResponse eventType(String eventType) { - this.integrationHubFlowUrl = integrationHubFlowUrl; + this.eventType = eventType; return this; } /** - * The URL of the integration hub flow that we want to trigger for the event. - * @return integrationHubFlowUrl + * The event type we want to register a flow for. + * @return eventType **/ - @ApiModelProperty(required = true, value = "The URL of the integration hub flow that we want to trigger for the event.") + @ApiModelProperty(required = true, value = "The event type we want to register a flow for.") - public String getIntegrationHubFlowUrl() { - return integrationHubFlowUrl; + public String getEventType() { + return eventType; } - public void setIntegrationHubFlowUrl(String integrationHubFlowUrl) { - this.integrationHubFlowUrl = integrationHubFlowUrl; + public void setEventType(String eventType) { + this.eventType = eventType; } @@ -172,15 +281,19 @@ public boolean equals(java.lang.Object o) { } IntegrationHubFlowResponse integrationHubFlowResponse = (IntegrationHubFlowResponse) o; return Objects.equals(this.id, integrationHubFlowResponse.id) && - Objects.equals(this.applicationID, integrationHubFlowResponse.applicationID) && + Objects.equals(this.integrationName, integrationHubFlowResponse.integrationName) && + Objects.equals(this.instanceName, integrationHubFlowResponse.instanceName) && + Objects.equals(this.createdAt, integrationHubFlowResponse.createdAt) && + Objects.equals(this.disabledUntil, integrationHubFlowResponse.disabledUntil) && + Objects.equals(this.applicationId, integrationHubFlowResponse.applicationId) && + Objects.equals(this.loyaltyProgramId, integrationHubFlowResponse.loyaltyProgramId) && Objects.equals(this.eventType, integrationHubFlowResponse.eventType) && - Objects.equals(this.integrationHubFlowUrl, integrationHubFlowResponse.integrationHubFlowUrl) && Objects.equals(this.config, integrationHubFlowResponse.config); } @Override public int hashCode() { - return Objects.hash(id, applicationID, eventType, integrationHubFlowUrl, config); + return Objects.hash(id, integrationName, instanceName, createdAt, disabledUntil, applicationId, loyaltyProgramId, eventType, config); } @@ -189,9 +302,13 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubFlowResponse {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" applicationID: ").append(toIndentedString(applicationID)).append("\n"); + sb.append(" integrationName: ").append(toIndentedString(integrationName)).append("\n"); + sb.append(" instanceName: ").append(toIndentedString(instanceName)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" disabledUntil: ").append(toIndentedString(disabledUntil)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); sb.append(" eventType: ").append(toIndentedString(eventType)).append("\n"); - sb.append(" integrationHubFlowUrl: ").append(toIndentedString(integrationHubFlowUrl)).append("\n"); sb.append(" config: ").append(toIndentedString(config)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/IntegrationHubFlowWithConfig.java b/src/main/java/one/talon/model/IntegrationHubFlowWithConfig.java index b4527a81..444ebcad 100644 --- a/src/main/java/one/talon/model/IntegrationHubFlowWithConfig.java +++ b/src/main/java/one/talon/model/IntegrationHubFlowWithConfig.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; import one.talon.model.IntegrationHubFlowConfig; /** @@ -34,9 +35,13 @@ public class IntegrationHubFlowWithConfig { @SerializedName(SERIALIZED_NAME_APPLICATION_I_D) private Long applicationID; + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_I_D = "LoyaltyProgramID"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_I_D) + private Long loyaltyProgramID; + public static final String SERIALIZED_NAME_EVENT_TYPE = "EventType"; @SerializedName(SERIALIZED_NAME_EVENT_TYPE) - private String eventType; + private IntegrationHubEventType eventType; public static final String SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL = "IntegrationHubFlowUrl"; @SerializedName(SERIALIZED_NAME_INTEGRATION_HUB_FLOW_URL) @@ -54,11 +59,11 @@ public IntegrationHubFlowWithConfig applicationID(Long applicationID) { } /** - * ID of application the flow is registered for. + * ID of the application the flow is registered for. * @return applicationID **/ @javax.annotation.Nullable - @ApiModelProperty(example = "54", value = "ID of application the flow is registered for.") + @ApiModelProperty(example = "54", value = "ID of the application the flow is registered for.") public Long getApplicationID() { return applicationID; @@ -70,24 +75,47 @@ public void setApplicationID(Long applicationID) { } - public IntegrationHubFlowWithConfig eventType(String eventType) { + public IntegrationHubFlowWithConfig loyaltyProgramID(Long loyaltyProgramID) { + + this.loyaltyProgramID = loyaltyProgramID; + return this; + } + + /** + * ID of the loyalty program the flow is registered for. + * @return loyaltyProgramID + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "12", value = "ID of the loyalty program the flow is registered for.") + + public Long getLoyaltyProgramID() { + return loyaltyProgramID; + } + + + public void setLoyaltyProgramID(Long loyaltyProgramID) { + this.loyaltyProgramID = loyaltyProgramID; + } + + + public IntegrationHubFlowWithConfig eventType(IntegrationHubEventType eventType) { this.eventType = eventType; return this; } /** - * The event type we want to register a flow for. + * Get eventType * @return eventType **/ - @ApiModelProperty(required = true, value = "The event type we want to register a flow for.") + @ApiModelProperty(required = true, value = "") - public String getEventType() { + public IntegrationHubEventType getEventType() { return eventType; } - public void setEventType(String eventType) { + public void setEventType(IntegrationHubEventType eventType) { this.eventType = eventType; } @@ -146,6 +174,7 @@ public boolean equals(java.lang.Object o) { } IntegrationHubFlowWithConfig integrationHubFlowWithConfig = (IntegrationHubFlowWithConfig) o; return Objects.equals(this.applicationID, integrationHubFlowWithConfig.applicationID) && + Objects.equals(this.loyaltyProgramID, integrationHubFlowWithConfig.loyaltyProgramID) && Objects.equals(this.eventType, integrationHubFlowWithConfig.eventType) && Objects.equals(this.integrationHubFlowUrl, integrationHubFlowWithConfig.integrationHubFlowUrl) && Objects.equals(this.config, integrationHubFlowWithConfig.config); @@ -153,7 +182,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(applicationID, eventType, integrationHubFlowUrl, config); + return Objects.hash(applicationID, loyaltyProgramID, eventType, integrationHubFlowUrl, config); } @@ -162,6 +191,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class IntegrationHubFlowWithConfig {\n"); sb.append(" applicationID: ").append(toIndentedString(applicationID)).append("\n"); + sb.append(" loyaltyProgramID: ").append(toIndentedString(loyaltyProgramID)).append("\n"); sb.append(" eventType: ").append(toIndentedString(eventType)).append("\n"); sb.append(" integrationHubFlowUrl: ").append(toIndentedString(integrationHubFlowUrl)).append("\n"); sb.append(" config: ").append(toIndentedString(config)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationHubInstance.java b/src/main/java/one/talon/model/IntegrationHubInstance.java new file mode 100644 index 00000000..60edc9a6 --- /dev/null +++ b/src/main/java/one/talon/model/IntegrationHubInstance.java @@ -0,0 +1,126 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * IntegrationHubInstance + */ + +public class IntegrationHubInstance { + public static final String SERIALIZED_NAME_INSTANCE_ID = "instanceId"; + @SerializedName(SERIALIZED_NAME_INSTANCE_ID) + private String instanceId; + + public static final String SERIALIZED_NAME_INSTANCE_NAME = "instanceName"; + @SerializedName(SERIALIZED_NAME_INSTANCE_NAME) + private String instanceName; + + + public IntegrationHubInstance instanceId(String instanceId) { + + this.instanceId = instanceId; + return this; + } + + /** + * The ID of the Prismatic integration instance. + * @return instanceId + **/ + @ApiModelProperty(example = "aW5zdGFuY2U6MTIz", required = true, value = "The ID of the Prismatic integration instance.") + + public String getInstanceId() { + return instanceId; + } + + + public void setInstanceId(String instanceId) { + this.instanceId = instanceId; + } + + + public IntegrationHubInstance instanceName(String instanceName) { + + this.instanceName = instanceName; + return this; + } + + /** + * The name of the Prismatic integration instance. + * @return instanceName + **/ + @ApiModelProperty(example = "Create Coupon", required = true, value = "The name of the Prismatic integration instance.") + + public String getInstanceName() { + return instanceName; + } + + + public void setInstanceName(String instanceName) { + this.instanceName = instanceName; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + IntegrationHubInstance integrationHubInstance = (IntegrationHubInstance) o; + return Objects.equals(this.instanceId, integrationHubInstance.instanceId) && + Objects.equals(this.instanceName, integrationHubInstance.instanceName); + } + + @Override + public int hashCode() { + return Objects.hash(instanceId, instanceName); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class IntegrationHubInstance {\n"); + sb.append(" instanceId: ").append(toIndentedString(instanceId)).append("\n"); + sb.append(" instanceName: ").append(toIndentedString(instanceName)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/IntegrationHubPaginatedEventPayload.java b/src/main/java/one/talon/model/IntegrationHubPaginatedEventPayload.java index 6eab1121..67aa405b 100644 --- a/src/main/java/one/talon/model/IntegrationHubPaginatedEventPayload.java +++ b/src/main/java/one/talon/model/IntegrationHubPaginatedEventPayload.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.IntegrationHubEventType; import org.threeten.bp.OffsetDateTime; /** @@ -40,64 +41,9 @@ public class IntegrationHubPaginatedEventPayload { @SerializedName(SERIALIZED_NAME_BATCHED_AT) private OffsetDateTime batchedAt; - /** - * Gets or Sets eventType - */ - @JsonAdapter(EventTypeEnum.Adapter.class) - public enum EventTypeEnum { - LOYALTYPOINTSCHANGED("LoyaltyPointsChanged"), - - LOYALTYTIERDOWNGRADE("LoyaltyTierDowngrade"), - - LOYALTYTIERUPGRADE("LoyaltyTierUpgrade"), - - COUPONCREATED("CouponCreated"), - - COUPONUPDATED("CouponUpdated"), - - COUPONDELETED("CouponDeleted"); - - private String value; - - EventTypeEnum(String value) { - this.value = value; - } - - public String getValue() { - return value; - } - - @Override - public String toString() { - return String.valueOf(value); - } - - public static EventTypeEnum fromValue(String value) { - for (EventTypeEnum b : EventTypeEnum.values()) { - if (b.value.equals(value)) { - return b; - } - } - throw new IllegalArgumentException("Unexpected value '" + value + "'"); - } - - public static class Adapter extends TypeAdapter { - @Override - public void write(final JsonWriter jsonWriter, final EventTypeEnum enumeration) throws IOException { - jsonWriter.value(enumeration.getValue()); - } - - @Override - public EventTypeEnum read(final JsonReader jsonReader) throws IOException { - String value = jsonReader.nextString(); - return EventTypeEnum.fromValue(value); - } - } - } - public static final String SERIALIZED_NAME_EVENT_TYPE = "EventType"; @SerializedName(SERIALIZED_NAME_EVENT_TYPE) - private EventTypeEnum eventType; + private IntegrationHubEventType eventType; public static final String SERIALIZED_NAME_DATA = "Data"; @SerializedName(SERIALIZED_NAME_DATA) @@ -149,7 +95,7 @@ public void setBatchedAt(OffsetDateTime batchedAt) { } - public IntegrationHubPaginatedEventPayload eventType(EventTypeEnum eventType) { + public IntegrationHubPaginatedEventPayload eventType(IntegrationHubEventType eventType) { this.eventType = eventType; return this; @@ -161,12 +107,12 @@ public IntegrationHubPaginatedEventPayload eventType(EventTypeEnum eventType) { **/ @ApiModelProperty(required = true, value = "") - public EventTypeEnum getEventType() { + public IntegrationHubEventType getEventType() { return eventType; } - public void setEventType(EventTypeEnum eventType) { + public void setEventType(IntegrationHubEventType eventType) { this.eventType = eventType; } diff --git a/src/main/java/one/talon/model/IntegrationRequest.java b/src/main/java/one/talon/model/IntegrationRequest.java index c8024bab..5724ea24 100644 --- a/src/main/java/one/talon/model/IntegrationRequest.java +++ b/src/main/java/one/talon/model/IntegrationRequest.java @@ -60,7 +60,13 @@ public enum ResponseContentEnum { RULEFAILUREREASONS("ruleFailureReasons"), - PREVIOUSRETURNS("previousReturns"); + PREVIOUSRETURNS("previousReturns"), + + CAMPAIGNELIGIBILITY("campaignEligibility"), + + ACHIEVEMENTS("achievements"), + + UNLOCKEDREWARDS("unlockedRewards"); private String value; diff --git a/src/main/java/one/talon/model/IntegrationResponse.java b/src/main/java/one/talon/model/IntegrationResponse.java index 8ac79900..3e5d8be8 100644 --- a/src/main/java/one/talon/model/IntegrationResponse.java +++ b/src/main/java/one/talon/model/IntegrationResponse.java @@ -26,12 +26,15 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; /** @@ -52,6 +55,10 @@ public class IntegrationResponse { @SerializedName(SERIALIZED_NAME_TRIGGERED_CAMPAIGNS) private List triggeredCampaigns = null; + public static final String SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY = "campaignEligibility"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY) + private List campaignEligibility = null; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; @SerializedName(SERIALIZED_NAME_EFFECTS) private List effects = new ArrayList(); @@ -72,6 +79,14 @@ public class IntegrationResponse { @SerializedName(SERIALIZED_NAME_AWARDED_GIVEAWAYS) private List awardedGiveaways = null; + public static final String SERIALIZED_NAME_ACHIEVEMENTS = "achievements"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENTS) + private List achievements = null; + + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public IntegrationResponse customerProfile(CustomerProfile customerProfile) { @@ -150,6 +165,37 @@ public void setTriggeredCampaigns(List triggeredCampaigns) { } + public IntegrationResponse campaignEligibility(List campaignEligibility) { + + this.campaignEligibility = campaignEligibility; + return this; + } + + public IntegrationResponse addCampaignEligibilityItem(CampaignEligibility campaignEligibilityItem) { + if (this.campaignEligibility == null) { + this.campaignEligibility = new ArrayList(); + } + this.campaignEligibility.add(campaignEligibilityItem); + return this; + } + + /** + * A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. + * @return campaignEligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. ") + + public List getCampaignEligibility() { + return campaignEligibility; + } + + + public void setCampaignEligibility(List campaignEligibility) { + this.campaignEligibility = campaignEligibility; + } + + public IntegrationResponse effects(List effects) { this.effects = effects; @@ -293,6 +339,68 @@ public void setAwardedGiveaways(List awardedGiveaways) { } + public IntegrationResponse achievements(List achievements) { + + this.achievements = achievements; + return this; + } + + public IntegrationResponse addAchievementsItem(CustomerAchievement achievementsItem) { + if (this.achievements == null) { + this.achievements = new ArrayList(); + } + this.achievements.add(achievementsItem); + return this; + } + + /** + * The achievements progress of the customer. + * @return achievements + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievements progress of the customer.") + + public List getAchievements() { + return achievements; + } + + + public void setAchievements(List achievements) { + this.achievements = achievements; + } + + + public IntegrationResponse rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public IntegrationResponse addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The rewards for the customer profile. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The rewards for the customer profile.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -305,16 +413,19 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.customerProfile, integrationResponse.customerProfile) && Objects.equals(this.loyalty, integrationResponse.loyalty) && Objects.equals(this.triggeredCampaigns, integrationResponse.triggeredCampaigns) && + Objects.equals(this.campaignEligibility, integrationResponse.campaignEligibility) && Objects.equals(this.effects, integrationResponse.effects) && Objects.equals(this.ruleFailureReasons, integrationResponse.ruleFailureReasons) && Objects.equals(this.createdCoupons, integrationResponse.createdCoupons) && Objects.equals(this.createdReferrals, integrationResponse.createdReferrals) && - Objects.equals(this.awardedGiveaways, integrationResponse.awardedGiveaways); + Objects.equals(this.awardedGiveaways, integrationResponse.awardedGiveaways) && + Objects.equals(this.achievements, integrationResponse.achievements) && + Objects.equals(this.rewards, integrationResponse.rewards); } @Override public int hashCode() { - return Objects.hash(customerProfile, loyalty, triggeredCampaigns, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways); + return Objects.hash(customerProfile, loyalty, triggeredCampaigns, campaignEligibility, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, achievements, rewards); } @@ -325,11 +436,14 @@ public String toString() { sb.append(" customerProfile: ").append(toIndentedString(customerProfile)).append("\n"); sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); sb.append(" triggeredCampaigns: ").append(toIndentedString(triggeredCampaigns)).append("\n"); + sb.append(" campaignEligibility: ").append(toIndentedString(campaignEligibility)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); sb.append(" createdCoupons: ").append(toIndentedString(createdCoupons)).append("\n"); sb.append(" createdReferrals: ").append(toIndentedString(createdReferrals)).append("\n"); sb.append(" awardedGiveaways: ").append(toIndentedString(awardedGiveaways)).append("\n"); + sb.append(" achievements: ").append(toIndentedString(achievements)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/IntegrationStateV2.java b/src/main/java/one/talon/model/IntegrationStateV2.java index f0836296..953bcc59 100644 --- a/src/main/java/one/talon/model/IntegrationStateV2.java +++ b/src/main/java/one/talon/model/IntegrationStateV2.java @@ -26,7 +26,9 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.CustomerSessionV2; import one.talon.model.Effect; @@ -38,6 +40,7 @@ import one.talon.model.Loyalty; import one.talon.model.ModelReturn; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; /** @@ -58,6 +61,10 @@ public class IntegrationStateV2 { @SerializedName(SERIALIZED_NAME_TRIGGERED_CAMPAIGNS) private List triggeredCampaigns = null; + public static final String SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY = "campaignEligibility"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ELIGIBILITY) + private List campaignEligibility = null; + public static final String SERIALIZED_NAME_EFFECTS = "effects"; @SerializedName(SERIALIZED_NAME_EFFECTS) private List effects = new ArrayList(); @@ -78,6 +85,14 @@ public class IntegrationStateV2 { @SerializedName(SERIALIZED_NAME_AWARDED_GIVEAWAYS) private List awardedGiveaways = null; + public static final String SERIALIZED_NAME_ACHIEVEMENTS = "achievements"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENTS) + private List achievements = null; + + public static final String SERIALIZED_NAME_REWARDS = "rewards"; + @SerializedName(SERIALIZED_NAME_REWARDS) + private List rewards = null; + public static final String SERIALIZED_NAME_REFERRAL = "referral"; @SerializedName(SERIALIZED_NAME_REFERRAL) private InventoryReferral referral; @@ -184,6 +199,37 @@ public void setTriggeredCampaigns(List triggeredCampaigns) { } + public IntegrationStateV2 campaignEligibility(List campaignEligibility) { + + this.campaignEligibility = campaignEligibility; + return this; + } + + public IntegrationStateV2 addCampaignEligibilityItem(CampaignEligibility campaignEligibilityItem) { + if (this.campaignEligibility == null) { + this.campaignEligibility = new ArrayList(); + } + this.campaignEligibility.add(campaignEligibilityItem); + return this; + } + + /** + * A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. + * @return campaignEligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A list of campaigns and their evaluation status for the current customer session. **Note**: - This response can **only** be included if the `dry` parameter in the query is set to `true`. - Do not include `triggeredCampaigns` or `ruleFailureReasons` in `responseContent` to avoid duplicate results. ") + + public List getCampaignEligibility() { + return campaignEligibility; + } + + + public void setCampaignEligibility(List campaignEligibility) { + this.campaignEligibility = campaignEligibility; + } + + public IntegrationStateV2 effects(List effects) { this.effects = effects; @@ -327,6 +373,68 @@ public void setAwardedGiveaways(List awardedGiveaways) { } + public IntegrationStateV2 achievements(List achievements) { + + this.achievements = achievements; + return this; + } + + public IntegrationStateV2 addAchievementsItem(CustomerAchievement achievementsItem) { + if (this.achievements == null) { + this.achievements = new ArrayList(); + } + this.achievements.add(achievementsItem); + return this; + } + + /** + * The achievements progress of the customer. + * @return achievements + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The achievements progress of the customer.") + + public List getAchievements() { + return achievements; + } + + + public void setAchievements(List achievements) { + this.achievements = achievements; + } + + + public IntegrationStateV2 rewards(List rewards) { + + this.rewards = rewards; + return this; + } + + public IntegrationStateV2 addRewardsItem(RewardWithUnlocks rewardsItem) { + if (this.rewards == null) { + this.rewards = new ArrayList(); + } + this.rewards.add(rewardsItem); + return this; + } + + /** + * The rewards for the customer profile. + * @return rewards + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The rewards for the customer profile.") + + public List getRewards() { + return rewards; + } + + + public void setRewards(List rewards) { + this.rewards = rewards; + } + + public IntegrationStateV2 referral(InventoryReferral referral) { this.referral = referral; @@ -516,11 +624,14 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.customerProfile, integrationStateV2.customerProfile) && Objects.equals(this.loyalty, integrationStateV2.loyalty) && Objects.equals(this.triggeredCampaigns, integrationStateV2.triggeredCampaigns) && + Objects.equals(this.campaignEligibility, integrationStateV2.campaignEligibility) && Objects.equals(this.effects, integrationStateV2.effects) && Objects.equals(this.ruleFailureReasons, integrationStateV2.ruleFailureReasons) && Objects.equals(this.createdCoupons, integrationStateV2.createdCoupons) && Objects.equals(this.createdReferrals, integrationStateV2.createdReferrals) && Objects.equals(this.awardedGiveaways, integrationStateV2.awardedGiveaways) && + Objects.equals(this.achievements, integrationStateV2.achievements) && + Objects.equals(this.rewards, integrationStateV2.rewards) && Objects.equals(this.referral, integrationStateV2.referral) && Objects.equals(this.coupons, integrationStateV2.coupons) && Objects.equals(this.event, integrationStateV2.event) && @@ -532,7 +643,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(customerProfile, loyalty, triggeredCampaigns, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, referral, coupons, event, advancedEvent, customerSession, _return, previousReturns); + return Objects.hash(customerProfile, loyalty, triggeredCampaigns, campaignEligibility, effects, ruleFailureReasons, createdCoupons, createdReferrals, awardedGiveaways, achievements, rewards, referral, coupons, event, advancedEvent, customerSession, _return, previousReturns); } @@ -543,11 +654,14 @@ public String toString() { sb.append(" customerProfile: ").append(toIndentedString(customerProfile)).append("\n"); sb.append(" loyalty: ").append(toIndentedString(loyalty)).append("\n"); sb.append(" triggeredCampaigns: ").append(toIndentedString(triggeredCampaigns)).append("\n"); + sb.append(" campaignEligibility: ").append(toIndentedString(campaignEligibility)).append("\n"); sb.append(" effects: ").append(toIndentedString(effects)).append("\n"); sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); sb.append(" createdCoupons: ").append(toIndentedString(createdCoupons)).append("\n"); sb.append(" createdReferrals: ").append(toIndentedString(createdReferrals)).append("\n"); sb.append(" awardedGiveaways: ").append(toIndentedString(awardedGiveaways)).append("\n"); + sb.append(" achievements: ").append(toIndentedString(achievements)).append("\n"); + sb.append(" rewards: ").append(toIndentedString(rewards)).append("\n"); sb.append(" referral: ").append(toIndentedString(referral)).append("\n"); sb.append(" coupons: ").append(toIndentedString(coupons)).append("\n"); sb.append(" event: ").append(toIndentedString(event)).append("\n"); diff --git a/src/main/java/one/talon/model/IntegrationUnlockRewardRequest.java b/src/main/java/one/talon/model/IntegrationUnlockRewardRequest.java new file mode 100644 index 00000000..811d88b7 --- /dev/null +++ b/src/main/java/one/talon/model/IntegrationUnlockRewardRequest.java @@ -0,0 +1,304 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * The request body for unlocking a reward for a customer profile, optionally using the balance of one of the customer's loyalty cards. + */ +@ApiModel(description = "The request body for unlocking a reward for a customer profile, optionally using the balance of one of the customer's loyalty cards. ") + +public class IntegrationUnlockRewardRequest { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_ID = "profileIntegrationId"; + @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_ID) + private String profileIntegrationId; + + public static final String SERIALIZED_NAME_CARD_IDENTIFIER = "cardIdentifier"; + @SerializedName(SERIALIZED_NAME_CARD_IDENTIFIER) + private String cardIdentifier; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_SUBLEDGER_ID = "subledgerId"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER_ID) + private String subledgerId; + + /** + * Gets or Sets responseContent + */ + @JsonAdapter(ResponseContentEnum.Adapter.class) + public enum ResponseContentEnum { + CUSTOMERPROFILE("customerProfile"), + + EFFECTS("effects"), + + RULEFAILUREREASONS("ruleFailureReasons"), + + LOYALTY("loyalty"); + + private String value; + + ResponseContentEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ResponseContentEnum fromValue(String value) { + for (ResponseContentEnum b : ResponseContentEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ResponseContentEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ResponseContentEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ResponseContentEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_RESPONSE_CONTENT = "responseContent"; + @SerializedName(SERIALIZED_NAME_RESPONSE_CONTENT) + private List responseContent = null; + + + public IntegrationUnlockRewardRequest integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID to assign to the created customer reward unlock. + * @return integrationId + **/ + @ApiModelProperty(example = "reward-unlock-123", required = true, value = "The integration ID to assign to the created customer reward unlock.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public IntegrationUnlockRewardRequest profileIntegrationId(String profileIntegrationId) { + + this.profileIntegrationId = profileIntegrationId; + return this; + } + + /** + * The integration ID of the customer profile unlocking the reward. + * @return profileIntegrationId + **/ + @ApiModelProperty(example = "customer1", required = true, value = "The integration ID of the customer profile unlocking the reward.") + + public String getProfileIntegrationId() { + return profileIntegrationId; + } + + + public void setProfileIntegrationId(String profileIntegrationId) { + this.profileIntegrationId = profileIntegrationId; + } + + + public IntegrationUnlockRewardRequest cardIdentifier(String cardIdentifier) { + + this.cardIdentifier = cardIdentifier; + return this; + } + + /** + * The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + * @return cardIdentifier + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "summer-loyalty-card-0543", value = "The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. ") + + public String getCardIdentifier() { + return cardIdentifier; + } + + + public void setCardIdentifier(String cardIdentifier) { + this.cardIdentifier = cardIdentifier; + } + + + public IntegrationUnlockRewardRequest loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * The ID of the loyalty program from which points will be deducted. Required when the reward has `pointsRequired` configured. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2", value = "The ID of the loyalty program from which points will be deducted. Required when the reward has `pointsRequired` configured.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public IntegrationUnlockRewardRequest subledgerId(String subledgerId) { + + this.subledgerId = subledgerId; + return this; + } + + /** + * The ID of the subledger from which points will be deducted. Required when the reward has `pointsRequired` configured. To specify the main ledger, provide an empty string (\"\"). + * @return subledgerId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "sub1", value = "The ID of the subledger from which points will be deducted. Required when the reward has `pointsRequired` configured. To specify the main ledger, provide an empty string (\"\"). ") + + public String getSubledgerId() { + return subledgerId; + } + + + public void setSubledgerId(String subledgerId) { + this.subledgerId = subledgerId; + } + + + public IntegrationUnlockRewardRequest responseContent(List responseContent) { + + this.responseContent = responseContent; + return this; + } + + public IntegrationUnlockRewardRequest addResponseContentItem(ResponseContentEnum responseContentItem) { + if (this.responseContent == null) { + this.responseContent = new ArrayList(); + } + this.responseContent.add(responseContentItem); + return this; + } + + /** + * Determines which data is included in the response. Add any of the following optional values to the array to get that data in the response: `customerProfile`, `ruleFailureReasons`, `loyalty`. `effects` is always returned regardless of whether it is included here. + * @return responseContent + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[customerProfile, loyalty]", value = "Determines which data is included in the response. Add any of the following optional values to the array to get that data in the response: `customerProfile`, `ruleFailureReasons`, `loyalty`. `effects` is always returned regardless of whether it is included here.") + + public List getResponseContent() { + return responseContent; + } + + + public void setResponseContent(List responseContent) { + this.responseContent = responseContent; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + IntegrationUnlockRewardRequest integrationUnlockRewardRequest = (IntegrationUnlockRewardRequest) o; + return Objects.equals(this.integrationId, integrationUnlockRewardRequest.integrationId) && + Objects.equals(this.profileIntegrationId, integrationUnlockRewardRequest.profileIntegrationId) && + Objects.equals(this.cardIdentifier, integrationUnlockRewardRequest.cardIdentifier) && + Objects.equals(this.loyaltyProgramId, integrationUnlockRewardRequest.loyaltyProgramId) && + Objects.equals(this.subledgerId, integrationUnlockRewardRequest.subledgerId) && + Objects.equals(this.responseContent, integrationUnlockRewardRequest.responseContent); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId, profileIntegrationId, cardIdentifier, loyaltyProgramId, subledgerId, responseContent); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class IntegrationUnlockRewardRequest {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" profileIntegrationId: ").append(toIndentedString(profileIntegrationId)).append("\n"); + sb.append(" cardIdentifier: ").append(toIndentedString(cardIdentifier)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" subledgerId: ").append(toIndentedString(subledgerId)).append("\n"); + sb.append(" responseContent: ").append(toIndentedString(responseContent)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/JoinLoyaltyProgramEffectProps.java b/src/main/java/one/talon/model/JoinLoyaltyProgramEffectProps.java new file mode 100644 index 00000000..277437bc --- /dev/null +++ b/src/main/java/one/talon/model/JoinLoyaltyProgramEffectProps.java @@ -0,0 +1,128 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; + +/** + * This effect indicates that a customer profile was joined to a profile-based loyalty program with the specified join date. > [!note] **Note** > - This effect requires a customer profile. It does not work for anonymous sessions. > - The effect fails if the customer profile has already joined the loyalty program. + */ +@ApiModel(description = "This effect indicates that a customer profile was joined to a profile-based loyalty program with the specified join date. > [!note] **Note** > - This effect requires a customer profile. It does not work for anonymous sessions. > - The effect fails if the customer profile has already joined the loyalty program. ") + +public class JoinLoyaltyProgramEffectProps { + public static final String SERIALIZED_NAME_PROGRAM_ID = "programId"; + @SerializedName(SERIALIZED_NAME_PROGRAM_ID) + private Long programId; + + public static final String SERIALIZED_NAME_JOIN_DATE = "joinDate"; + @SerializedName(SERIALIZED_NAME_JOIN_DATE) + private OffsetDateTime joinDate; + + + public JoinLoyaltyProgramEffectProps programId(Long programId) { + + this.programId = programId; + return this; + } + + /** + * The ID of the loyalty program the customer profile is joined to. + * @return programId + **/ + @ApiModelProperty(example = "5", required = true, value = "The ID of the loyalty program the customer profile is joined to.") + + public Long getProgramId() { + return programId; + } + + + public void setProgramId(Long programId) { + this.programId = programId; + } + + + public JoinLoyaltyProgramEffectProps joinDate(OffsetDateTime joinDate) { + + this.joinDate = joinDate; + return this; + } + + /** + * The date and time when the customer profile joined the loyalty program. + * @return joinDate + **/ + @ApiModelProperty(example = "2026-01-02T03:04:05Z", required = true, value = "The date and time when the customer profile joined the loyalty program.") + + public OffsetDateTime getJoinDate() { + return joinDate; + } + + + public void setJoinDate(OffsetDateTime joinDate) { + this.joinDate = joinDate; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + JoinLoyaltyProgramEffectProps joinLoyaltyProgramEffectProps = (JoinLoyaltyProgramEffectProps) o; + return Objects.equals(this.programId, joinLoyaltyProgramEffectProps.programId) && + Objects.equals(this.joinDate, joinLoyaltyProgramEffectProps.joinDate); + } + + @Override + public int hashCode() { + return Objects.hash(programId, joinDate); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class JoinLoyaltyProgramEffectProps {\n"); + sb.append(" programId: ").append(toIndentedString(programId)).append("\n"); + sb.append(" joinDate: ").append(toIndentedString(joinDate)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPI.java b/src/main/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPI.java index 7166f38c..bfaa5754 100644 --- a/src/main/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPI.java +++ b/src/main/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPI.java @@ -49,6 +49,10 @@ public class LedgerTransactionLogEntryIntegrationAPI { @SerializedName(SERIALIZED_NAME_CUSTOMER_SESSION_ID) private String customerSessionId; + public static final String SERIALIZED_NAME_STORE_INTEGRATION_ID = "storeIntegrationId"; + @SerializedName(SERIALIZED_NAME_STORE_INTEGRATION_ID) + private String storeIntegrationId; + /** * Type of transaction. Possible values: - `addition`: Signifies added points. - `subtraction`: Signifies deducted points. */ @@ -230,6 +234,29 @@ public void setCustomerSessionId(String customerSessionId) { } + public LedgerTransactionLogEntryIntegrationAPI storeIntegrationId(String storeIntegrationId) { + + this.storeIntegrationId = storeIntegrationId; + return this; + } + + /** + * The integration ID of the store where the transaction occurred. Only set for transactions created by a customer session or event that referenced a store. + * @return storeIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "STORE-001", value = "The integration ID of the store where the transaction occurred. Only set for transactions created by a customer session or event that referenced a store.") + + public String getStoreIntegrationId() { + return storeIntegrationId; + } + + + public void setStoreIntegrationId(String storeIntegrationId) { + this.storeIntegrationId = storeIntegrationId; + } + + public LedgerTransactionLogEntryIntegrationAPI type(TypeEnum type) { this.type = type; @@ -460,11 +487,11 @@ public LedgerTransactionLogEntryIntegrationAPI validityDuration(String validityD } /** - * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. + * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. * @return validityDuration **/ @javax.annotation.Nullable - @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") + @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") public String getValidityDuration() { return validityDuration; @@ -489,6 +516,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.created, ledgerTransactionLogEntryIntegrationAPI.created) && Objects.equals(this.programId, ledgerTransactionLogEntryIntegrationAPI.programId) && Objects.equals(this.customerSessionId, ledgerTransactionLogEntryIntegrationAPI.customerSessionId) && + Objects.equals(this.storeIntegrationId, ledgerTransactionLogEntryIntegrationAPI.storeIntegrationId) && Objects.equals(this.type, ledgerTransactionLogEntryIntegrationAPI.type) && Objects.equals(this.name, ledgerTransactionLogEntryIntegrationAPI.name) && Objects.equals(this.startDate, ledgerTransactionLogEntryIntegrationAPI.startDate) && @@ -504,7 +532,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(transactionUUID, created, programId, customerSessionId, type, name, startDate, expiryDate, subledgerId, amount, id, rulesetId, ruleName, flags, validityDuration); + return Objects.hash(transactionUUID, created, programId, customerSessionId, storeIntegrationId, type, name, startDate, expiryDate, subledgerId, amount, id, rulesetId, ruleName, flags, validityDuration); } @@ -516,6 +544,7 @@ public String toString() { sb.append(" created: ").append(toIndentedString(created)).append("\n"); sb.append(" programId: ").append(toIndentedString(programId)).append("\n"); sb.append(" customerSessionId: ").append(toIndentedString(customerSessionId)).append("\n"); + sb.append(" storeIntegrationId: ").append(toIndentedString(storeIntegrationId)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); diff --git a/src/main/java/one/talon/model/ListCheckAttributeBlock.java b/src/main/java/one/talon/model/ListCheckAttributeBlock.java new file mode 100644 index 00000000..29475d5a --- /dev/null +++ b/src/main/java/one/talon/model/ListCheckAttributeBlock.java @@ -0,0 +1,177 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for operators that test list membership against a set of values. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for operators that test list membership against a set of values.") + +public class ListCheckAttributeBlock { + /** + * The list membership operator applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + CONTAINSONEOF("containsOneOf"), + + CONTAINSNONEOF("containsNoneOf"), + + CONTAINSALLOF("containsAllOf"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private Object values; + + + public ListCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The list membership operator applied to the attribute. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The list membership operator applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public ListCheckAttributeBlock values(Object values) { + + this.values = values; + return this; + } + + /** + * The set of values to match against. + * @return values + **/ + @ApiModelProperty(required = true, value = "The set of values to match against.") + + public Object getValues() { + return values; + } + + + public void setValues(Object values) { + this.values = values; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ListCheckAttributeBlock listCheckAttributeBlock = (ListCheckAttributeBlock) o; + return Objects.equals(this.operator, listCheckAttributeBlock.operator) && + Objects.equals(this.values, listCheckAttributeBlock.values); + } + + @Override + public int hashCode() { + return Objects.hash(operator, values); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ListCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ListWithCountCheckAttributeBlock.java b/src/main/java/one/talon/model/ListWithCountCheckAttributeBlock.java new file mode 100644 index 00000000..667d9d8f --- /dev/null +++ b/src/main/java/one/talon/model/ListWithCountCheckAttributeBlock.java @@ -0,0 +1,203 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for operators that test list membership with a minimum or exact count threshold. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for operators that test list membership with a minimum or exact count threshold.") + +public class ListWithCountCheckAttributeBlock { + /** + * The list membership operator with a count threshold applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + CONTAINSATLEAST("containsAtLeast"), + + CONTAINSEXACTLY("containsExactly"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private Object values; + + public static final String SERIALIZED_NAME_COUNT = "count"; + @SerializedName(SERIALIZED_NAME_COUNT) + private Object count; + + + public ListWithCountCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The list membership operator with a count threshold applied to the attribute. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The list membership operator with a count threshold applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public ListWithCountCheckAttributeBlock values(Object values) { + + this.values = values; + return this; + } + + /** + * The set of values to match against. + * @return values + **/ + @ApiModelProperty(required = true, value = "The set of values to match against.") + + public Object getValues() { + return values; + } + + + public void setValues(Object values) { + this.values = values; + } + + + public ListWithCountCheckAttributeBlock count(Object count) { + + this.count = count; + return this; + } + + /** + * The count threshold for this operator. + * @return count + **/ + @ApiModelProperty(example = "2", required = true, value = "The count threshold for this operator.") + + public Object getCount() { + return count; + } + + + public void setCount(Object count) { + this.count = count; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ListWithCountCheckAttributeBlock listWithCountCheckAttributeBlock = (ListWithCountCheckAttributeBlock) o; + return Objects.equals(this.operator, listWithCountCheckAttributeBlock.operator) && + Objects.equals(this.values, listWithCountCheckAttributeBlock.values) && + Objects.equals(this.count, listWithCountCheckAttributeBlock.count); + } + + @Override + public int hashCode() { + return Objects.hash(operator, values, count); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ListWithCountCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append(" count: ").append(toIndentedString(count)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/LocationCheckAttributeBlock.java b/src/main/java/one/talon/model/LocationCheckAttributeBlock.java new file mode 100644 index 00000000..88cde29a --- /dev/null +++ b/src/main/java/one/talon/model/LocationCheckAttributeBlock.java @@ -0,0 +1,175 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * A block variant of `CheckAttributeBlock` for operators that check whether a geographical location is inside a set of geometric areas. + */ +@ApiModel(description = "A block variant of `CheckAttributeBlock` for operators that check whether a geographical location is inside a set of geometric areas.") + +public class LocationCheckAttributeBlock { + /** + * The location membership operator applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + IN("in"), + + NOT_IN_("not(in)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private Object values; + + + public LocationCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The location membership operator applied to the attribute. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The location membership operator applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public LocationCheckAttributeBlock values(Object values) { + + this.values = values; + return this; + } + + /** + * The geometric areas to check the location against. + * @return values + **/ + @ApiModelProperty(required = true, value = "The geometric areas to check the location against.") + + public Object getValues() { + return values; + } + + + public void setValues(Object values) { + this.values = values; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + LocationCheckAttributeBlock locationCheckAttributeBlock = (LocationCheckAttributeBlock) o; + return Objects.equals(this.operator, locationCheckAttributeBlock.operator) && + Objects.equals(this.values, locationCheckAttributeBlock.values); + } + + @Override + public int hashCode() { + return Objects.hash(operator, values); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class LocationCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/LoyaltyProgramLedgers.java b/src/main/java/one/talon/model/LoyaltyProgramLedgers.java index b025e537..c127171c 100644 --- a/src/main/java/one/talon/model/LoyaltyProgramLedgers.java +++ b/src/main/java/one/talon/model/LoyaltyProgramLedgers.java @@ -186,11 +186,11 @@ public LoyaltyProgramLedgers putSubLedgersItem(String key, LedgerInfo subLedgers } /** - * A map containing information about each loyalty subledger. + * A map containing information about each loyalty subledger. Subledgers for which all balances are zero are excluded from the response. * @return subLedgers **/ @javax.annotation.Nullable - @ApiModelProperty(value = "A map containing information about each loyalty subledger.") + @ApiModelProperty(value = "A map containing information about each loyalty subledger. Subledgers for which all balances are zero are excluded from the response.") public Map getSubLedgers() { return subLedgers; diff --git a/src/main/java/one/talon/model/LoyaltyProgramTransaction.java b/src/main/java/one/talon/model/LoyaltyProgramTransaction.java index d38ca810..2c5cadc2 100644 --- a/src/main/java/one/talon/model/LoyaltyProgramTransaction.java +++ b/src/main/java/one/talon/model/LoyaltyProgramTransaction.java @@ -621,11 +621,11 @@ public LoyaltyProgramTransaction validityDuration(String validityDuration) { } /** - * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. + * The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. * @return validityDuration **/ @javax.annotation.Nullable - @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") + @ApiModelProperty(example = "30D", value = "The duration for which the points remain active, relative to the activation date. **Note**: This only applies to points for which `awaitsActivation` is `true` and `expiryDate` is not set. ") public String getValidityDuration() { return validityDuration; diff --git a/src/main/java/one/talon/model/MCPCompleteOAuthSession.java b/src/main/java/one/talon/model/MCPCompleteOAuthSession.java new file mode 100644 index 00000000..09d3c352 --- /dev/null +++ b/src/main/java/one/talon/model/MCPCompleteOAuthSession.java @@ -0,0 +1,98 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * MCPCompleteOAuthSession + */ + +public class MCPCompleteOAuthSession { + public static final String SERIALIZED_NAME_SESSION_ID = "sessionId"; + @SerializedName(SERIALIZED_NAME_SESSION_ID) + private String sessionId; + + + public MCPCompleteOAuthSession sessionId(String sessionId) { + + this.sessionId = sessionId; + return this; + } + + /** + * The pending authorization session ID to complete. + * @return sessionId + **/ + @ApiModelProperty(example = "a3f8c1e2b4d567890123456789abcdef", required = true, value = "The pending authorization session ID to complete.") + + public String getSessionId() { + return sessionId; + } + + + public void setSessionId(String sessionId) { + this.sessionId = sessionId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPCompleteOAuthSession mcPCompleteOAuthSession = (MCPCompleteOAuthSession) o; + return Objects.equals(this.sessionId, mcPCompleteOAuthSession.sessionId); + } + + @Override + public int hashCode() { + return Objects.hash(sessionId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPCompleteOAuthSession {\n"); + sb.append(" sessionId: ").append(toIndentedString(sessionId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthClient.java b/src/main/java/one/talon/model/MCPOAuthClient.java new file mode 100644 index 00000000..6c97a4c9 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthClient.java @@ -0,0 +1,190 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.threeten.bp.OffsetDateTime; + +/** + * MCPOAuthClient + */ + +public class MCPOAuthClient { + public static final String SERIALIZED_NAME_CLIENT_ID = "client_id"; + @SerializedName(SERIALIZED_NAME_CLIENT_ID) + private String clientId; + + public static final String SERIALIZED_NAME_CLIENT_NAME = "client_name"; + @SerializedName(SERIALIZED_NAME_CLIENT_NAME) + private String clientName; + + public static final String SERIALIZED_NAME_REDIRECT_URIS = "redirect_uris"; + @SerializedName(SERIALIZED_NAME_REDIRECT_URIS) + private List redirectUris = new ArrayList(); + + public static final String SERIALIZED_NAME_CREATED_AT = "created_at"; + @SerializedName(SERIALIZED_NAME_CREATED_AT) + private OffsetDateTime createdAt; + + + public MCPOAuthClient clientId(String clientId) { + + this.clientId = clientId; + return this; + } + + /** + * Unique identifier for the OAuth2 client. + * @return clientId + **/ + @ApiModelProperty(example = "a3f8c1e2b4d56789", required = true, value = "Unique identifier for the OAuth2 client.") + + public String getClientId() { + return clientId; + } + + + public void setClientId(String clientId) { + this.clientId = clientId; + } + + + public MCPOAuthClient clientName(String clientName) { + + this.clientName = clientName; + return this; + } + + /** + * Human-readable name for the OAuth2 client. + * @return clientName + **/ + @ApiModelProperty(example = "My MCP Integration", required = true, value = "Human-readable name for the OAuth2 client.") + + public String getClientName() { + return clientName; + } + + + public void setClientName(String clientName) { + this.clientName = clientName; + } + + + public MCPOAuthClient redirectUris(List redirectUris) { + + this.redirectUris = redirectUris; + return this; + } + + public MCPOAuthClient addRedirectUrisItem(String redirectUrisItem) { + this.redirectUris.add(redirectUrisItem); + return this; + } + + /** + * List of allowed redirect URIs for the authorization code flow. + * @return redirectUris + **/ + @ApiModelProperty(example = "[https://example.com/callback, http://localhost:3000/callback]", required = true, value = "List of allowed redirect URIs for the authorization code flow.") + + public List getRedirectUris() { + return redirectUris; + } + + + public void setRedirectUris(List redirectUris) { + this.redirectUris = redirectUris; + } + + + public MCPOAuthClient createdAt(OffsetDateTime createdAt) { + + this.createdAt = createdAt; + return this; + } + + /** + * Timestamp of when the client was registered. + * @return createdAt + **/ + @ApiModelProperty(example = "2026-06-12T10:00Z", required = true, value = "Timestamp of when the client was registered.") + + public OffsetDateTime getCreatedAt() { + return createdAt; + } + + + public void setCreatedAt(OffsetDateTime createdAt) { + this.createdAt = createdAt; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthClient mcPOAuthClient = (MCPOAuthClient) o; + return Objects.equals(this.clientId, mcPOAuthClient.clientId) && + Objects.equals(this.clientName, mcPOAuthClient.clientName) && + Objects.equals(this.redirectUris, mcPOAuthClient.redirectUris) && + Objects.equals(this.createdAt, mcPOAuthClient.createdAt); + } + + @Override + public int hashCode() { + return Objects.hash(clientId, clientName, redirectUris, createdAt); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthClient {\n"); + sb.append(" clientId: ").append(toIndentedString(clientId)).append("\n"); + sb.append(" clientName: ").append(toIndentedString(clientName)).append("\n"); + sb.append(" redirectUris: ").append(toIndentedString(redirectUris)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthCompleteResult.java b/src/main/java/one/talon/model/MCPOAuthCompleteResult.java new file mode 100644 index 00000000..d9ad71ae --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthCompleteResult.java @@ -0,0 +1,98 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * MCPOAuthCompleteResult + */ + +public class MCPOAuthCompleteResult { + public static final String SERIALIZED_NAME_REDIRECT_URL = "redirectUrl"; + @SerializedName(SERIALIZED_NAME_REDIRECT_URL) + private String redirectUrl; + + + public MCPOAuthCompleteResult redirectUrl(String redirectUrl) { + + this.redirectUrl = redirectUrl; + return this; + } + + /** + * The full redirect URL the browser should be sent to, containing the authorization code and state as query parameters. + * @return redirectUrl + **/ + @ApiModelProperty(example = "http://localhost:3000/callback?code=abc123&state=xyz", required = true, value = "The full redirect URL the browser should be sent to, containing the authorization code and state as query parameters.") + + public String getRedirectUrl() { + return redirectUrl; + } + + + public void setRedirectUrl(String redirectUrl) { + this.redirectUrl = redirectUrl; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthCompleteResult mcPOAuthCompleteResult = (MCPOAuthCompleteResult) o; + return Objects.equals(this.redirectUrl, mcPOAuthCompleteResult.redirectUrl); + } + + @Override + public int hashCode() { + return Objects.hash(redirectUrl); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthCompleteResult {\n"); + sb.append(" redirectUrl: ").append(toIndentedString(redirectUrl)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthProtectedResource.java b/src/main/java/one/talon/model/MCPOAuthProtectedResource.java new file mode 100644 index 00000000..8dc8b667 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthProtectedResource.java @@ -0,0 +1,133 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * MCPOAuthProtectedResource + */ + +public class MCPOAuthProtectedResource { + public static final String SERIALIZED_NAME_RESOURCE = "resource"; + @SerializedName(SERIALIZED_NAME_RESOURCE) + private String resource; + + public static final String SERIALIZED_NAME_AUTHORIZATION_SERVERS = "authorization_servers"; + @SerializedName(SERIALIZED_NAME_AUTHORIZATION_SERVERS) + private List authorizationServers = new ArrayList(); + + + public MCPOAuthProtectedResource resource(String resource) { + + this.resource = resource; + return this; + } + + /** + * The URL of the protected resource (the MCP entrypoint). + * @return resource + **/ + @ApiModelProperty(example = "https://mycompany.talon.one/v1/mcp/entrypoint", required = true, value = "The URL of the protected resource (the MCP entrypoint).") + + public String getResource() { + return resource; + } + + + public void setResource(String resource) { + this.resource = resource; + } + + + public MCPOAuthProtectedResource authorizationServers(List authorizationServers) { + + this.authorizationServers = authorizationServers; + return this; + } + + public MCPOAuthProtectedResource addAuthorizationServersItem(String authorizationServersItem) { + this.authorizationServers.add(authorizationServersItem); + return this; + } + + /** + * List of authorization server base URLs that can issue tokens for this resource. + * @return authorizationServers + **/ + @ApiModelProperty(example = "[https://mycompany.talon.one/v1/mcp/auth]", required = true, value = "List of authorization server base URLs that can issue tokens for this resource.") + + public List getAuthorizationServers() { + return authorizationServers; + } + + + public void setAuthorizationServers(List authorizationServers) { + this.authorizationServers = authorizationServers; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthProtectedResource mcPOAuthProtectedResource = (MCPOAuthProtectedResource) o; + return Objects.equals(this.resource, mcPOAuthProtectedResource.resource) && + Objects.equals(this.authorizationServers, mcPOAuthProtectedResource.authorizationServers); + } + + @Override + public int hashCode() { + return Objects.hash(resource, authorizationServers); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthProtectedResource {\n"); + sb.append(" resource: ").append(toIndentedString(resource)).append("\n"); + sb.append(" authorizationServers: ").append(toIndentedString(authorizationServers)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthServerMetadata.java b/src/main/java/one/talon/model/MCPOAuthServerMetadata.java new file mode 100644 index 00000000..48e86c23 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthServerMetadata.java @@ -0,0 +1,283 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * MCPOAuthServerMetadata + */ + +public class MCPOAuthServerMetadata { + public static final String SERIALIZED_NAME_ISSUER = "issuer"; + @SerializedName(SERIALIZED_NAME_ISSUER) + private String issuer; + + public static final String SERIALIZED_NAME_AUTHORIZATION_ENDPOINT = "authorization_endpoint"; + @SerializedName(SERIALIZED_NAME_AUTHORIZATION_ENDPOINT) + private String authorizationEndpoint; + + public static final String SERIALIZED_NAME_TOKEN_ENDPOINT = "token_endpoint"; + @SerializedName(SERIALIZED_NAME_TOKEN_ENDPOINT) + private String tokenEndpoint; + + public static final String SERIALIZED_NAME_REGISTRATION_ENDPOINT = "registration_endpoint"; + @SerializedName(SERIALIZED_NAME_REGISTRATION_ENDPOINT) + private String registrationEndpoint; + + public static final String SERIALIZED_NAME_RESPONSE_TYPES_SUPPORTED = "response_types_supported"; + @SerializedName(SERIALIZED_NAME_RESPONSE_TYPES_SUPPORTED) + private List responseTypesSupported = new ArrayList(); + + public static final String SERIALIZED_NAME_GRANT_TYPES_SUPPORTED = "grant_types_supported"; + @SerializedName(SERIALIZED_NAME_GRANT_TYPES_SUPPORTED) + private List grantTypesSupported = new ArrayList(); + + public static final String SERIALIZED_NAME_CODE_CHALLENGE_METHODS_SUPPORTED = "code_challenge_methods_supported"; + @SerializedName(SERIALIZED_NAME_CODE_CHALLENGE_METHODS_SUPPORTED) + private List codeChallengeMethodsSupported = new ArrayList(); + + + public MCPOAuthServerMetadata issuer(String issuer) { + + this.issuer = issuer; + return this; + } + + /** + * The authorization server's issuer identifier (its base URL). + * @return issuer + **/ + @ApiModelProperty(example = "https://mycompany.talon.one", required = true, value = "The authorization server's issuer identifier (its base URL).") + + public String getIssuer() { + return issuer; + } + + + public void setIssuer(String issuer) { + this.issuer = issuer; + } + + + public MCPOAuthServerMetadata authorizationEndpoint(String authorizationEndpoint) { + + this.authorizationEndpoint = authorizationEndpoint; + return this; + } + + /** + * URL of the authorization endpoint. + * @return authorizationEndpoint + **/ + @ApiModelProperty(example = "https://mycompany.talon.one/v1/mcp/auth/authorize", required = true, value = "URL of the authorization endpoint.") + + public String getAuthorizationEndpoint() { + return authorizationEndpoint; + } + + + public void setAuthorizationEndpoint(String authorizationEndpoint) { + this.authorizationEndpoint = authorizationEndpoint; + } + + + public MCPOAuthServerMetadata tokenEndpoint(String tokenEndpoint) { + + this.tokenEndpoint = tokenEndpoint; + return this; + } + + /** + * URL of the token endpoint. + * @return tokenEndpoint + **/ + @ApiModelProperty(example = "https://mycompany.talon.one/v1/mcp/auth/token", required = true, value = "URL of the token endpoint.") + + public String getTokenEndpoint() { + return tokenEndpoint; + } + + + public void setTokenEndpoint(String tokenEndpoint) { + this.tokenEndpoint = tokenEndpoint; + } + + + public MCPOAuthServerMetadata registrationEndpoint(String registrationEndpoint) { + + this.registrationEndpoint = registrationEndpoint; + return this; + } + + /** + * URL of the client registration endpoint. + * @return registrationEndpoint + **/ + @ApiModelProperty(example = "https://mycompany.talon.one/v1/mcp/auth/register", required = true, value = "URL of the client registration endpoint.") + + public String getRegistrationEndpoint() { + return registrationEndpoint; + } + + + public void setRegistrationEndpoint(String registrationEndpoint) { + this.registrationEndpoint = registrationEndpoint; + } + + + public MCPOAuthServerMetadata responseTypesSupported(List responseTypesSupported) { + + this.responseTypesSupported = responseTypesSupported; + return this; + } + + public MCPOAuthServerMetadata addResponseTypesSupportedItem(String responseTypesSupportedItem) { + this.responseTypesSupported.add(responseTypesSupportedItem); + return this; + } + + /** + * List of supported OAuth2 response types. + * @return responseTypesSupported + **/ + @ApiModelProperty(example = "[code]", required = true, value = "List of supported OAuth2 response types.") + + public List getResponseTypesSupported() { + return responseTypesSupported; + } + + + public void setResponseTypesSupported(List responseTypesSupported) { + this.responseTypesSupported = responseTypesSupported; + } + + + public MCPOAuthServerMetadata grantTypesSupported(List grantTypesSupported) { + + this.grantTypesSupported = grantTypesSupported; + return this; + } + + public MCPOAuthServerMetadata addGrantTypesSupportedItem(String grantTypesSupportedItem) { + this.grantTypesSupported.add(grantTypesSupportedItem); + return this; + } + + /** + * List of supported OAuth2 grant types. + * @return grantTypesSupported + **/ + @ApiModelProperty(example = "[authorization_code]", required = true, value = "List of supported OAuth2 grant types.") + + public List getGrantTypesSupported() { + return grantTypesSupported; + } + + + public void setGrantTypesSupported(List grantTypesSupported) { + this.grantTypesSupported = grantTypesSupported; + } + + + public MCPOAuthServerMetadata codeChallengeMethodsSupported(List codeChallengeMethodsSupported) { + + this.codeChallengeMethodsSupported = codeChallengeMethodsSupported; + return this; + } + + public MCPOAuthServerMetadata addCodeChallengeMethodsSupportedItem(String codeChallengeMethodsSupportedItem) { + this.codeChallengeMethodsSupported.add(codeChallengeMethodsSupportedItem); + return this; + } + + /** + * List of supported PKCE code challenge methods. + * @return codeChallengeMethodsSupported + **/ + @ApiModelProperty(example = "[S256]", required = true, value = "List of supported PKCE code challenge methods.") + + public List getCodeChallengeMethodsSupported() { + return codeChallengeMethodsSupported; + } + + + public void setCodeChallengeMethodsSupported(List codeChallengeMethodsSupported) { + this.codeChallengeMethodsSupported = codeChallengeMethodsSupported; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthServerMetadata mcPOAuthServerMetadata = (MCPOAuthServerMetadata) o; + return Objects.equals(this.issuer, mcPOAuthServerMetadata.issuer) && + Objects.equals(this.authorizationEndpoint, mcPOAuthServerMetadata.authorizationEndpoint) && + Objects.equals(this.tokenEndpoint, mcPOAuthServerMetadata.tokenEndpoint) && + Objects.equals(this.registrationEndpoint, mcPOAuthServerMetadata.registrationEndpoint) && + Objects.equals(this.responseTypesSupported, mcPOAuthServerMetadata.responseTypesSupported) && + Objects.equals(this.grantTypesSupported, mcPOAuthServerMetadata.grantTypesSupported) && + Objects.equals(this.codeChallengeMethodsSupported, mcPOAuthServerMetadata.codeChallengeMethodsSupported); + } + + @Override + public int hashCode() { + return Objects.hash(issuer, authorizationEndpoint, tokenEndpoint, registrationEndpoint, responseTypesSupported, grantTypesSupported, codeChallengeMethodsSupported); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthServerMetadata {\n"); + sb.append(" issuer: ").append(toIndentedString(issuer)).append("\n"); + sb.append(" authorizationEndpoint: ").append(toIndentedString(authorizationEndpoint)).append("\n"); + sb.append(" tokenEndpoint: ").append(toIndentedString(tokenEndpoint)).append("\n"); + sb.append(" registrationEndpoint: ").append(toIndentedString(registrationEndpoint)).append("\n"); + sb.append(" responseTypesSupported: ").append(toIndentedString(responseTypesSupported)).append("\n"); + sb.append(" grantTypesSupported: ").append(toIndentedString(grantTypesSupported)).append("\n"); + sb.append(" codeChallengeMethodsSupported: ").append(toIndentedString(codeChallengeMethodsSupported)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthSessionInfo.java b/src/main/java/one/talon/model/MCPOAuthSessionInfo.java new file mode 100644 index 00000000..d9316ade --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthSessionInfo.java @@ -0,0 +1,157 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.MCPOAuthClient; +import org.threeten.bp.OffsetDateTime; + +/** + * MCPOAuthSessionInfo + */ + +public class MCPOAuthSessionInfo { + public static final String SERIALIZED_NAME_SESSION_ID = "session_id"; + @SerializedName(SERIALIZED_NAME_SESSION_ID) + private String sessionId; + + public static final String SERIALIZED_NAME_EXPIRES_AT = "expires_at"; + @SerializedName(SERIALIZED_NAME_EXPIRES_AT) + private OffsetDateTime expiresAt; + + public static final String SERIALIZED_NAME_CLIENT = "client"; + @SerializedName(SERIALIZED_NAME_CLIENT) + private MCPOAuthClient client; + + + public MCPOAuthSessionInfo sessionId(String sessionId) { + + this.sessionId = sessionId; + return this; + } + + /** + * The identifier of the authorization session. + * @return sessionId + **/ + @ApiModelProperty(example = "a3f8c1e2b4d567890123456789abcdef", required = true, value = "The identifier of the authorization session.") + + public String getSessionId() { + return sessionId; + } + + + public void setSessionId(String sessionId) { + this.sessionId = sessionId; + } + + + public MCPOAuthSessionInfo expiresAt(OffsetDateTime expiresAt) { + + this.expiresAt = expiresAt; + return this; + } + + /** + * The date and time at which the session expires. Date and time. Follows RFC3339 format. + * @return expiresAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2016-03-28T08:34:32Z", value = "The date and time at which the session expires. Date and time. Follows RFC3339 format.") + + public OffsetDateTime getExpiresAt() { + return expiresAt; + } + + + public void setExpiresAt(OffsetDateTime expiresAt) { + this.expiresAt = expiresAt; + } + + + public MCPOAuthSessionInfo client(MCPOAuthClient client) { + + this.client = client; + return this; + } + + /** + * Get client + * @return client + **/ + @ApiModelProperty(required = true, value = "") + + public MCPOAuthClient getClient() { + return client; + } + + + public void setClient(MCPOAuthClient client) { + this.client = client; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthSessionInfo mcPOAuthSessionInfo = (MCPOAuthSessionInfo) o; + return Objects.equals(this.sessionId, mcPOAuthSessionInfo.sessionId) && + Objects.equals(this.expiresAt, mcPOAuthSessionInfo.expiresAt) && + Objects.equals(this.client, mcPOAuthSessionInfo.client); + } + + @Override + public int hashCode() { + return Objects.hash(sessionId, expiresAt, client); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthSessionInfo {\n"); + sb.append(" sessionId: ").append(toIndentedString(sessionId)).append("\n"); + sb.append(" expiresAt: ").append(toIndentedString(expiresAt)).append("\n"); + sb.append(" client: ").append(toIndentedString(client)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthToken.java b/src/main/java/one/talon/model/MCPOAuthToken.java new file mode 100644 index 00000000..603dcff0 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthToken.java @@ -0,0 +1,255 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * MCPOAuthToken + */ + +public class MCPOAuthToken { + public static final String SERIALIZED_NAME_ACCESS_TOKEN = "access_token"; + @SerializedName(SERIALIZED_NAME_ACCESS_TOKEN) + private String accessToken; + + /** + * Token type. Always \"Bearer\". + */ + @JsonAdapter(TokenTypeEnum.Adapter.class) + public enum TokenTypeEnum { + BEARER("Bearer"); + + private String value; + + TokenTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TokenTypeEnum fromValue(String value) { + for (TokenTypeEnum b : TokenTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TokenTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TokenTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TokenTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TOKEN_TYPE = "token_type"; + @SerializedName(SERIALIZED_NAME_TOKEN_TYPE) + private TokenTypeEnum tokenType; + + public static final String SERIALIZED_NAME_EXPIRES_IN = "expires_in"; + @SerializedName(SERIALIZED_NAME_EXPIRES_IN) + private Long expiresIn; + + public static final String SERIALIZED_NAME_REFRESH_TOKEN = "refresh_token"; + @SerializedName(SERIALIZED_NAME_REFRESH_TOKEN) + private String refreshToken; + + public static final String SERIALIZED_NAME_REFRESH_TOKEN_EXPIRES_IN = "refresh_token_expires_in"; + @SerializedName(SERIALIZED_NAME_REFRESH_TOKEN_EXPIRES_IN) + private Long refreshTokenExpiresIn; + + + public MCPOAuthToken accessToken(String accessToken) { + + this.accessToken = accessToken; + return this; + } + + /** + * Bearer access token. + * @return accessToken + **/ + @ApiModelProperty(example = "mcpoa:4a3b2c1d...", required = true, value = "Bearer access token.") + + public String getAccessToken() { + return accessToken; + } + + + public void setAccessToken(String accessToken) { + this.accessToken = accessToken; + } + + + public MCPOAuthToken tokenType(TokenTypeEnum tokenType) { + + this.tokenType = tokenType; + return this; + } + + /** + * Token type. Always \"Bearer\". + * @return tokenType + **/ + @ApiModelProperty(example = "Bearer", required = true, value = "Token type. Always \"Bearer\".") + + public TokenTypeEnum getTokenType() { + return tokenType; + } + + + public void setTokenType(TokenTypeEnum tokenType) { + this.tokenType = tokenType; + } + + + public MCPOAuthToken expiresIn(Long expiresIn) { + + this.expiresIn = expiresIn; + return this; + } + + /** + * Seconds until the access token expires. + * @return expiresIn + **/ + @ApiModelProperty(example = "3600", required = true, value = "Seconds until the access token expires.") + + public Long getExpiresIn() { + return expiresIn; + } + + + public void setExpiresIn(Long expiresIn) { + this.expiresIn = expiresIn; + } + + + public MCPOAuthToken refreshToken(String refreshToken) { + + this.refreshToken = refreshToken; + return this; + } + + /** + * Refresh token for obtaining a new access token. + * @return refreshToken + **/ + @ApiModelProperty(example = "mcpor:9f8e7d6c...", required = true, value = "Refresh token for obtaining a new access token.") + + public String getRefreshToken() { + return refreshToken; + } + + + public void setRefreshToken(String refreshToken) { + this.refreshToken = refreshToken; + } + + + public MCPOAuthToken refreshTokenExpiresIn(Long refreshTokenExpiresIn) { + + this.refreshTokenExpiresIn = refreshTokenExpiresIn; + return this; + } + + /** + * Seconds until the refresh token expires. + * @return refreshTokenExpiresIn + **/ + @ApiModelProperty(example = "2592000", required = true, value = "Seconds until the refresh token expires.") + + public Long getRefreshTokenExpiresIn() { + return refreshTokenExpiresIn; + } + + + public void setRefreshTokenExpiresIn(Long refreshTokenExpiresIn) { + this.refreshTokenExpiresIn = refreshTokenExpiresIn; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthToken mcPOAuthToken = (MCPOAuthToken) o; + return Objects.equals(this.accessToken, mcPOAuthToken.accessToken) && + Objects.equals(this.tokenType, mcPOAuthToken.tokenType) && + Objects.equals(this.expiresIn, mcPOAuthToken.expiresIn) && + Objects.equals(this.refreshToken, mcPOAuthToken.refreshToken) && + Objects.equals(this.refreshTokenExpiresIn, mcPOAuthToken.refreshTokenExpiresIn); + } + + @Override + public int hashCode() { + return Objects.hash(accessToken, tokenType, expiresIn, refreshToken, refreshTokenExpiresIn); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthToken {\n"); + sb.append(" accessToken: ").append(toIndentedString(accessToken)).append("\n"); + sb.append(" tokenType: ").append(toIndentedString(tokenType)).append("\n"); + sb.append(" expiresIn: ").append(toIndentedString(expiresIn)).append("\n"); + sb.append(" refreshToken: ").append(toIndentedString(refreshToken)).append("\n"); + sb.append(" refreshTokenExpiresIn: ").append(toIndentedString(refreshTokenExpiresIn)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthTokenError.java b/src/main/java/one/talon/model/MCPOAuthTokenError.java new file mode 100644 index 00000000..34822885 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthTokenError.java @@ -0,0 +1,178 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * MCPOAuthTokenError + */ + +public class MCPOAuthTokenError { + /** + * RFC 6749 §5.2 error code. + */ + @JsonAdapter(ErrorEnum.Adapter.class) + public enum ErrorEnum { + INVALID_REQUEST("invalid_request"), + + INVALID_CLIENT("invalid_client"), + + INVALID_GRANT("invalid_grant"), + + UNSUPPORTED_GRANT_TYPE("unsupported_grant_type"); + + private String value; + + ErrorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ErrorEnum fromValue(String value) { + for (ErrorEnum b : ErrorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ErrorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ErrorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ErrorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ERROR = "error"; + @SerializedName(SERIALIZED_NAME_ERROR) + private ErrorEnum error; + + public static final String SERIALIZED_NAME_ERROR_DESCRIPTION = "error_description"; + @SerializedName(SERIALIZED_NAME_ERROR_DESCRIPTION) + private String errorDescription; + + + public MCPOAuthTokenError error(ErrorEnum error) { + + this.error = error; + return this; + } + + /** + * RFC 6749 §5.2 error code. + * @return error + **/ + @ApiModelProperty(example = "invalid_grant", required = true, value = "RFC 6749 §5.2 error code.") + + public ErrorEnum getError() { + return error; + } + + + public void setError(ErrorEnum error) { + this.error = error; + } + + + public MCPOAuthTokenError errorDescription(String errorDescription) { + + this.errorDescription = errorDescription; + return this; + } + + /** + * Human-readable description of the error. + * @return errorDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "authorization code is invalid, already used, or expired", value = "Human-readable description of the error.") + + public String getErrorDescription() { + return errorDescription; + } + + + public void setErrorDescription(String errorDescription) { + this.errorDescription = errorDescription; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthTokenError mcPOAuthTokenError = (MCPOAuthTokenError) o; + return Objects.equals(this.error, mcPOAuthTokenError.error) && + Objects.equals(this.errorDescription, mcPOAuthTokenError.errorDescription); + } + + @Override + public int hashCode() { + return Objects.hash(error, errorDescription); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthTokenError {\n"); + sb.append(" error: ").append(toIndentedString(error)).append("\n"); + sb.append(" errorDescription: ").append(toIndentedString(errorDescription)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MCPOAuthTokenRequest.java b/src/main/java/one/talon/model/MCPOAuthTokenRequest.java new file mode 100644 index 00000000..5d9104a8 --- /dev/null +++ b/src/main/java/one/talon/model/MCPOAuthTokenRequest.java @@ -0,0 +1,290 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * MCPOAuthTokenRequest + */ + +public class MCPOAuthTokenRequest { + /** + * OAuth2 grant type. + */ + @JsonAdapter(GrantTypeEnum.Adapter.class) + public enum GrantTypeEnum { + AUTHORIZATION_CODE("authorization_code"), + + REFRESH_TOKEN("refresh_token"); + + private String value; + + GrantTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static GrantTypeEnum fromValue(String value) { + for (GrantTypeEnum b : GrantTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final GrantTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public GrantTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return GrantTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_GRANT_TYPE = "grant_type"; + @SerializedName(SERIALIZED_NAME_GRANT_TYPE) + private GrantTypeEnum grantType; + + public static final String SERIALIZED_NAME_CODE = "code"; + @SerializedName(SERIALIZED_NAME_CODE) + private String code; + + public static final String SERIALIZED_NAME_CLIENT_ID = "client_id"; + @SerializedName(SERIALIZED_NAME_CLIENT_ID) + private String clientId; + + public static final String SERIALIZED_NAME_REDIRECT_URI = "redirect_uri"; + @SerializedName(SERIALIZED_NAME_REDIRECT_URI) + private String redirectUri; + + public static final String SERIALIZED_NAME_CODE_VERIFIER = "code_verifier"; + @SerializedName(SERIALIZED_NAME_CODE_VERIFIER) + private String codeVerifier; + + public static final String SERIALIZED_NAME_REFRESH_TOKEN = "refresh_token"; + @SerializedName(SERIALIZED_NAME_REFRESH_TOKEN) + private String refreshToken; + + + public MCPOAuthTokenRequest grantType(GrantTypeEnum grantType) { + + this.grantType = grantType; + return this; + } + + /** + * OAuth2 grant type. + * @return grantType + **/ + @ApiModelProperty(example = "authorization_code", required = true, value = "OAuth2 grant type.") + + public GrantTypeEnum getGrantType() { + return grantType; + } + + + public void setGrantType(GrantTypeEnum grantType) { + this.grantType = grantType; + } + + + public MCPOAuthTokenRequest code(String code) { + + this.code = code; + return this; + } + + /** + * Authorization code. Required for `authorization_code` grant. + * @return code + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "4a3b2c1d9e6f78901234567890abcdef", value = "Authorization code. Required for `authorization_code` grant.") + + public String getCode() { + return code; + } + + + public void setCode(String code) { + this.code = code; + } + + + public MCPOAuthTokenRequest clientId(String clientId) { + + this.clientId = clientId; + return this; + } + + /** + * Client ID. Required for `authorization_code` grant. + * @return clientId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a3f8c1e2b4d56789", value = "Client ID. Required for `authorization_code` grant.") + + public String getClientId() { + return clientId; + } + + + public void setClientId(String clientId) { + this.clientId = clientId; + } + + + public MCPOAuthTokenRequest redirectUri(String redirectUri) { + + this.redirectUri = redirectUri; + return this; + } + + /** + * Redirect URI. Required for `authorization_code` grant. + * @return redirectUri + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "http://localhost:3000/callback", value = "Redirect URI. Required for `authorization_code` grant.") + + public String getRedirectUri() { + return redirectUri; + } + + + public void setRedirectUri(String redirectUri) { + this.redirectUri = redirectUri; + } + + + public MCPOAuthTokenRequest codeVerifier(String codeVerifier) { + + this.codeVerifier = codeVerifier; + return this; + } + + /** + * PKCE code verifier. Required for `authorization_code` grant. + * @return codeVerifier + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk", value = "PKCE code verifier. Required for `authorization_code` grant.") + + public String getCodeVerifier() { + return codeVerifier; + } + + + public void setCodeVerifier(String codeVerifier) { + this.codeVerifier = codeVerifier; + } + + + public MCPOAuthTokenRequest refreshToken(String refreshToken) { + + this.refreshToken = refreshToken; + return this; + } + + /** + * Refresh token. Required for `refresh_token` grant. + * @return refreshToken + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "mcpor:9f8e7d6c", value = "Refresh token. Required for `refresh_token` grant.") + + public String getRefreshToken() { + return refreshToken; + } + + + public void setRefreshToken(String refreshToken) { + this.refreshToken = refreshToken; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MCPOAuthTokenRequest mcPOAuthTokenRequest = (MCPOAuthTokenRequest) o; + return Objects.equals(this.grantType, mcPOAuthTokenRequest.grantType) && + Objects.equals(this.code, mcPOAuthTokenRequest.code) && + Objects.equals(this.clientId, mcPOAuthTokenRequest.clientId) && + Objects.equals(this.redirectUri, mcPOAuthTokenRequest.redirectUri) && + Objects.equals(this.codeVerifier, mcPOAuthTokenRequest.codeVerifier) && + Objects.equals(this.refreshToken, mcPOAuthTokenRequest.refreshToken); + } + + @Override + public int hashCode() { + return Objects.hash(grantType, code, clientId, redirectUri, codeVerifier, refreshToken); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MCPOAuthTokenRequest {\n"); + sb.append(" grantType: ").append(toIndentedString(grantType)).append("\n"); + sb.append(" code: ").append(toIndentedString(code)).append("\n"); + sb.append(" clientId: ").append(toIndentedString(clientId)).append("\n"); + sb.append(" redirectUri: ").append(toIndentedString(redirectUri)).append("\n"); + sb.append(" codeVerifier: ").append(toIndentedString(codeVerifier)).append("\n"); + sb.append(" refreshToken: ").append(toIndentedString(refreshToken)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MapSelectorStep.java b/src/main/java/one/talon/model/MapSelectorStep.java new file mode 100644 index 00000000..2a180a12 --- /dev/null +++ b/src/main/java/one/talon/model/MapSelectorStep.java @@ -0,0 +1,172 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Transforms each item using an expression. + */ +@ApiModel(description = "Transforms each item using an expression.") + +public class MapSelectorStep { + /** + * A step discriminator of type `map`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + MAP("map"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_EXPRESSION = "expression"; + @SerializedName(SERIALIZED_NAME_EXPRESSION) + private String expression; + + + public MapSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `map`. + * @return type + **/ + @ApiModelProperty(example = "map", required = true, value = "A step discriminator of type `map`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public MapSelectorStep expression(String expression) { + + this.expression = expression; + return this; + } + + /** + * The attribute path each item is mapped to. + * @return expression + **/ + @ApiModelProperty(example = "$Item.Price", required = true, value = "The attribute path each item is mapped to.") + + public String getExpression() { + return expression; + } + + + public void setExpression(String expression) { + this.expression = expression; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + MapSelectorStep mapSelectorStep = (MapSelectorStep) o; + return Objects.equals(this.type, mapSelectorStep.type) && + Objects.equals(this.expression, mapSelectorStep.expression); + } + + @Override + public int hashCode() { + return Objects.hash(type, expression); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class MapSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" expression: ").append(toIndentedString(expression)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/MultipleAudiencesItem.java b/src/main/java/one/talon/model/MultipleAudiencesItem.java index a4181d04..63245ce9 100644 --- a/src/main/java/one/talon/model/MultipleAudiencesItem.java +++ b/src/main/java/one/talon/model/MultipleAudiencesItem.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; /** @@ -42,6 +44,10 @@ public class MultipleAudiencesItem { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) private String integrationId; @@ -166,6 +172,37 @@ public void setName(String name) { } + public MultipleAudiencesItem subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public MultipleAudiencesItem addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + public MultipleAudiencesItem integrationId(String integrationId) { this.integrationId = integrationId; @@ -222,13 +259,14 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.id, multipleAudiencesItem.id) && Objects.equals(this.created, multipleAudiencesItem.created) && Objects.equals(this.name, multipleAudiencesItem.name) && + Objects.equals(this.subscribedApplicationsIds, multipleAudiencesItem.subscribedApplicationsIds) && Objects.equals(this.integrationId, multipleAudiencesItem.integrationId) && Objects.equals(this.status, multipleAudiencesItem.status); } @Override public int hashCode() { - return Objects.hash(id, created, name, integrationId, status); + return Objects.hash(id, created, name, subscribedApplicationsIds, integrationId, status); } @@ -239,6 +277,7 @@ public String toString() { sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" created: ").append(toIndentedString(created)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/NewApplication.java b/src/main/java/one/talon/model/NewApplication.java index ab8fd03a..3cad12fe 100644 --- a/src/main/java/one/talon/model/NewApplication.java +++ b/src/main/java/one/talon/model/NewApplication.java @@ -26,6 +26,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; /** @@ -244,6 +245,10 @@ public DefaultDiscountAdditionalCostPerItemScopeEnum read(final JsonReader jsonR @SerializedName(SERIALIZED_NAME_ENABLE_CAMPAIGN_STATE_MANAGEMENT) private Boolean enableCampaignStateManagement; + public static final String SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS = "bestPriorPriceSettings"; + @SerializedName(SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS) + private BestPriorPriceSettings bestPriorPriceSettings; + public NewApplication name(String name) { @@ -618,6 +623,29 @@ public void setEnableCampaignStateManagement(Boolean enableCampaignStateManageme } + public NewApplication bestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + + this.bestPriorPriceSettings = bestPriorPriceSettings; + return this; + } + + /** + * Get bestPriorPriceSettings + * @return bestPriorPriceSettings + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public BestPriorPriceSettings getBestPriorPriceSettings() { + return bestPriorPriceSettings; + } + + + public void setBestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + this.bestPriorPriceSettings = bestPriorPriceSettings; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -642,12 +670,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.enablePartialDiscounts, newApplication.enablePartialDiscounts) && Objects.equals(this.defaultDiscountAdditionalCostPerItemScope, newApplication.defaultDiscountAdditionalCostPerItemScope) && Objects.equals(this.key, newApplication.key) && - Objects.equals(this.enableCampaignStateManagement, newApplication.enableCampaignStateManagement); + Objects.equals(this.enableCampaignStateManagement, newApplication.enableCampaignStateManagement) && + Objects.equals(this.bestPriorPriceSettings, newApplication.bestPriorPriceSettings); } @Override public int hashCode() { - return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, key, enableCampaignStateManagement); + return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, key, enableCampaignStateManagement, bestPriorPriceSettings); } @@ -671,6 +700,7 @@ public String toString() { sb.append(" defaultDiscountAdditionalCostPerItemScope: ").append(toIndentedString(defaultDiscountAdditionalCostPerItemScope)).append("\n"); sb.append(" key: ").append(toIndentedString(key)).append("\n"); sb.append(" enableCampaignStateManagement: ").append(toIndentedString(enableCampaignStateManagement)).append("\n"); + sb.append(" bestPriorPriceSettings: ").append(toIndentedString(bestPriorPriceSettings)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/NewApplicationCIFExpression.java b/src/main/java/one/talon/model/NewApplicationCIFExpression.java index 2f91590b..78dad576 100644 --- a/src/main/java/one/talon/model/NewApplicationCIFExpression.java +++ b/src/main/java/one/talon/model/NewApplicationCIFExpression.java @@ -109,7 +109,7 @@ public NewApplicationCIFExpression addExpressionItem(Object expressionItem) { * @return expression **/ @javax.annotation.Nullable - @ApiModelProperty(example = "{expr=[filter, [., Session, CartItems], [[Item], [catch, false, [=, [., Item, Category], Kitchen]]]]}", value = "Arbitrary additional JSON data associated with the Application cart item filter.") + @ApiModelProperty(example = "{expr=[filter, [., Session, CartItems], [[Item], [catch, false, [contains, [., Item, Category], Kitchen]]]]}", value = "Arbitrary additional JSON data associated with the Application cart item filter.") public List getExpression() { return expression; diff --git a/src/main/java/one/talon/model/NewAudience.java b/src/main/java/one/talon/model/NewAudience.java index 9ba4fb39..c0c1c270 100644 --- a/src/main/java/one/talon/model/NewAudience.java +++ b/src/main/java/one/talon/model/NewAudience.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; /** @@ -42,6 +44,10 @@ public class NewAudience { @SerializedName(SERIALIZED_NAME_DESCRIPTION) private String description; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public static final String SERIALIZED_NAME_INTEGRATION = "integration"; @SerializedName(SERIALIZED_NAME_INTEGRATION) private String integration; @@ -127,6 +133,37 @@ public void setDescription(String description) { } + public NewAudience subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public NewAudience addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + public NewAudience integration(String integration) { this.integration = integration; @@ -231,6 +268,7 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.name, newAudience.name) && Objects.equals(this.sandbox, newAudience.sandbox) && Objects.equals(this.description, newAudience.description) && + Objects.equals(this.subscribedApplicationsIds, newAudience.subscribedApplicationsIds) && Objects.equals(this.integration, newAudience.integration) && Objects.equals(this.integrationId, newAudience.integrationId) && Objects.equals(this.createdIn3rdParty, newAudience.createdIn3rdParty) && @@ -239,7 +277,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(name, sandbox, description, integration, integrationId, createdIn3rdParty, lastUpdate); + return Objects.hash(name, sandbox, description, subscribedApplicationsIds, integration, integrationId, createdIn3rdParty, lastUpdate); } @@ -250,6 +288,7 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append(" integration: ").append(toIndentedString(integration)).append("\n"); sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append(" createdIn3rdParty: ").append(toIndentedString(createdIn3rdParty)).append("\n"); diff --git a/src/main/java/one/talon/model/NewCampaign.java b/src/main/java/one/talon/model/NewCampaign.java index 85c745fa..320a08de 100644 --- a/src/main/java/one/talon/model/NewCampaign.java +++ b/src/main/java/one/talon/model/NewCampaign.java @@ -134,7 +134,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/NewCampaignTemplate.java b/src/main/java/one/talon/model/NewCampaignTemplate.java index e4d968e5..b5e73322 100644 --- a/src/main/java/one/talon/model/NewCampaignTemplate.java +++ b/src/main/java/one/talon/model/NewCampaignTemplate.java @@ -132,7 +132,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/NewCoupons.java b/src/main/java/one/talon/model/NewCoupons.java index 36b35a75..f5909d56 100644 --- a/src/main/java/one/talon/model/NewCoupons.java +++ b/src/main/java/one/talon/model/NewCoupons.java @@ -62,6 +62,10 @@ public class NewCoupons { @SerializedName(SERIALIZED_NAME_NUMBER_OF_COUPONS) private Long numberOfCoupons; + public static final String SERIALIZED_NAME_BATCH_ID = "batchId"; + @SerializedName(SERIALIZED_NAME_BATCH_ID) + private String batchId; + public static final String SERIALIZED_NAME_UNIQUE_PREFIX = "uniquePrefix"; @SerializedName(SERIALIZED_NAME_UNIQUE_PREFIX) private String uniquePrefix; @@ -90,6 +94,14 @@ public class NewCoupons { @SerializedName(SERIALIZED_NAME_IMPLICITLY_RESERVED) private Boolean implicitlyReserved; + public static final String SERIALIZED_NAME_SUPPORT_REQUEST_ID = "supportRequestId"; + @SerializedName(SERIALIZED_NAME_SUPPORT_REQUEST_ID) + private Long supportRequestId; + + public static final String SERIALIZED_NAME_SUPPORT_REQUEST_NOTE = "supportRequestNote"; + @SerializedName(SERIALIZED_NAME_SUPPORT_REQUEST_NOTE) + private String supportRequestNote; + public NewCoupons usageLimit(Long usageLimit) { @@ -264,6 +276,29 @@ public void setNumberOfCoupons(Long numberOfCoupons) { } + public NewCoupons batchId(String batchId) { + + this.batchId = batchId; + return this; + } + + /** + * The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically. + * @return batchId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "3rdparty_fjsieoaa", value = "The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically.") + + public String getBatchId() { + return batchId; + } + + + public void setBatchId(String batchId) { + this.batchId = batchId; + } + + public NewCoupons uniquePrefix(String uniquePrefix) { this.uniquePrefix = uniquePrefix; @@ -433,6 +468,52 @@ public void setImplicitlyReserved(Boolean implicitlyReserved) { } + public NewCoupons supportRequestId(Long supportRequestId) { + + this.supportRequestId = supportRequestId; + return this; + } + + /** + * The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed. + * @return supportRequestId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed.") + + public Long getSupportRequestId() { + return supportRequestId; + } + + + public void setSupportRequestId(Long supportRequestId) { + this.supportRequestId = supportRequestId; + } + + + public NewCoupons supportRequestNote(String supportRequestNote) { + + this.supportRequestNote = supportRequestNote; + return this; + } + + /** + * A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided. + * @return supportRequestNote + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Approved as compensation for the delayed order.", value = "A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided.") + + public String getSupportRequestNote() { + return supportRequestNote; + } + + + public void setSupportRequestNote(String supportRequestNote) { + this.supportRequestNote = supportRequestNote; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -449,18 +530,21 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.expiryDate, newCoupons.expiryDate) && Objects.equals(this.limits, newCoupons.limits) && Objects.equals(this.numberOfCoupons, newCoupons.numberOfCoupons) && + Objects.equals(this.batchId, newCoupons.batchId) && Objects.equals(this.uniquePrefix, newCoupons.uniquePrefix) && Objects.equals(this.attributes, newCoupons.attributes) && Objects.equals(this.recipientIntegrationId, newCoupons.recipientIntegrationId) && Objects.equals(this.validCharacters, newCoupons.validCharacters) && Objects.equals(this.couponPattern, newCoupons.couponPattern) && Objects.equals(this.isReservationMandatory, newCoupons.isReservationMandatory) && - Objects.equals(this.implicitlyReserved, newCoupons.implicitlyReserved); + Objects.equals(this.implicitlyReserved, newCoupons.implicitlyReserved) && + Objects.equals(this.supportRequestId, newCoupons.supportRequestId) && + Objects.equals(this.supportRequestNote, newCoupons.supportRequestNote); } @Override public int hashCode() { - return Objects.hash(usageLimit, discountLimit, reservationLimit, startDate, expiryDate, limits, numberOfCoupons, uniquePrefix, attributes, recipientIntegrationId, validCharacters, couponPattern, isReservationMandatory, implicitlyReserved); + return Objects.hash(usageLimit, discountLimit, reservationLimit, startDate, expiryDate, limits, numberOfCoupons, batchId, uniquePrefix, attributes, recipientIntegrationId, validCharacters, couponPattern, isReservationMandatory, implicitlyReserved, supportRequestId, supportRequestNote); } @@ -475,6 +559,7 @@ public String toString() { sb.append(" expiryDate: ").append(toIndentedString(expiryDate)).append("\n"); sb.append(" limits: ").append(toIndentedString(limits)).append("\n"); sb.append(" numberOfCoupons: ").append(toIndentedString(numberOfCoupons)).append("\n"); + sb.append(" batchId: ").append(toIndentedString(batchId)).append("\n"); sb.append(" uniquePrefix: ").append(toIndentedString(uniquePrefix)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); sb.append(" recipientIntegrationId: ").append(toIndentedString(recipientIntegrationId)).append("\n"); @@ -482,6 +567,8 @@ public String toString() { sb.append(" couponPattern: ").append(toIndentedString(couponPattern)).append("\n"); sb.append(" isReservationMandatory: ").append(toIndentedString(isReservationMandatory)).append("\n"); sb.append(" implicitlyReserved: ").append(toIndentedString(implicitlyReserved)).append("\n"); + sb.append(" supportRequestId: ").append(toIndentedString(supportRequestId)).append("\n"); + sb.append(" supportRequestNote: ").append(toIndentedString(supportRequestNote)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/NewCouponsForMultipleRecipients.java b/src/main/java/one/talon/model/NewCouponsForMultipleRecipients.java index 3f02abd5..a0dbe356 100644 --- a/src/main/java/one/talon/model/NewCouponsForMultipleRecipients.java +++ b/src/main/java/one/talon/model/NewCouponsForMultipleRecipients.java @@ -53,6 +53,10 @@ public class NewCouponsForMultipleRecipients { @SerializedName(SERIALIZED_NAME_EXPIRY_DATE) private OffsetDateTime expiryDate; + public static final String SERIALIZED_NAME_BATCH_ID = "batchId"; + @SerializedName(SERIALIZED_NAME_BATCH_ID) + private String batchId; + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; @SerializedName(SERIALIZED_NAME_ATTRIBUTES) private Object attributes; @@ -190,6 +194,29 @@ public void setExpiryDate(OffsetDateTime expiryDate) { } + public NewCouponsForMultipleRecipients batchId(String batchId) { + + this.batchId = batchId; + return this; + } + + /** + * The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically. + * @return batchId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "3rdparty_fjsieoaa", value = "The batch ID that all coupons created by the request will bear. If omitted, a batch ID is generated automatically.") + + public String getBatchId() { + return batchId; + } + + + public void setBatchId(String batchId) { + this.batchId = batchId; + } + + public NewCouponsForMultipleRecipients attributes(Object attributes) { this.attributes = attributes; @@ -308,6 +335,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.reservationLimit, newCouponsForMultipleRecipients.reservationLimit) && Objects.equals(this.startDate, newCouponsForMultipleRecipients.startDate) && Objects.equals(this.expiryDate, newCouponsForMultipleRecipients.expiryDate) && + Objects.equals(this.batchId, newCouponsForMultipleRecipients.batchId) && Objects.equals(this.attributes, newCouponsForMultipleRecipients.attributes) && Objects.equals(this.recipientsIntegrationIds, newCouponsForMultipleRecipients.recipientsIntegrationIds) && Objects.equals(this.validCharacters, newCouponsForMultipleRecipients.validCharacters) && @@ -316,7 +344,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(usageLimit, discountLimit, reservationLimit, startDate, expiryDate, attributes, recipientsIntegrationIds, validCharacters, couponPattern); + return Objects.hash(usageLimit, discountLimit, reservationLimit, startDate, expiryDate, batchId, attributes, recipientsIntegrationIds, validCharacters, couponPattern); } @@ -329,6 +357,7 @@ public String toString() { sb.append(" reservationLimit: ").append(toIndentedString(reservationLimit)).append("\n"); sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); sb.append(" expiryDate: ").append(toIndentedString(expiryDate)).append("\n"); + sb.append(" batchId: ").append(toIndentedString(batchId)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); sb.append(" recipientsIntegrationIds: ").append(toIndentedString(recipientsIntegrationIds)).append("\n"); sb.append(" validCharacters: ").append(toIndentedString(validCharacters)).append("\n"); diff --git a/src/main/java/one/talon/model/NewCustomerSession.java b/src/main/java/one/talon/model/NewCustomerSession.java index 141dc0df..f6dd5a63 100644 --- a/src/main/java/one/talon/model/NewCustomerSession.java +++ b/src/main/java/one/talon/model/NewCustomerSession.java @@ -46,7 +46,7 @@ public class NewCustomerSession { private String referral; /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). */ @JsonAdapter(StateEnum.Adapter.class) public enum StateEnum { @@ -193,11 +193,11 @@ public NewCustomerSession state(StateEnum state) { } /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). * @return state **/ @javax.annotation.Nullable - @ApiModelProperty(example = "open", value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. `closed` → `cancelled` or `partially_returned` 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") + @ApiModelProperty(example = "open", value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. `closed` -> `cancelled` or `partially_returned` 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") public StateEnum getState() { return state; diff --git a/src/main/java/one/talon/model/NewCustomerSessionV2.java b/src/main/java/one/talon/model/NewCustomerSessionV2.java index 7fdba98b..330e777d 100644 --- a/src/main/java/one/talon/model/NewCustomerSessionV2.java +++ b/src/main/java/one/talon/model/NewCustomerSessionV2.java @@ -61,8 +61,12 @@ public class NewCustomerSessionV2 { @SerializedName(SERIALIZED_NAME_LOYALTY_CARDS) private List loyaltyCards = null; + public static final String SERIALIZED_NAME_REWARD_INTEGRATION_IDS = "rewardIntegrationIds"; + @SerializedName(SERIALIZED_NAME_REWARD_INTEGRATION_IDS) + private List rewardIntegrationIds = null; + /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). */ @JsonAdapter(StateEnum.Adapter.class) public enum StateEnum { @@ -299,6 +303,37 @@ public void setLoyaltyCards(List loyaltyCards) { } + public NewCustomerSessionV2 rewardIntegrationIds(List rewardIntegrationIds) { + + this.rewardIntegrationIds = rewardIntegrationIds; + return this; + } + + public NewCustomerSessionV2 addRewardIntegrationIdsItem(String rewardIntegrationIdsItem) { + if (this.rewardIntegrationIds == null) { + this.rewardIntegrationIds = new ArrayList(); + } + this.rewardIntegrationIds.add(rewardIntegrationIdsItem); + return this; + } + + /** + * The integration IDs of the unlocked rewards that can be used in this session. + * @return rewardIntegrationIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90]", value = "The integration IDs of the unlocked rewards that can be used in this session. ") + + public List getRewardIntegrationIds() { + return rewardIntegrationIds; + } + + + public void setRewardIntegrationIds(List rewardIntegrationIds) { + this.rewardIntegrationIds = rewardIntegrationIds; + } + + public NewCustomerSessionV2 state(StateEnum state) { this.state = state; @@ -306,11 +341,11 @@ public NewCustomerSessionV2 state(StateEnum state) { } /** - * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). + * Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). * @return state **/ @javax.annotation.Nullable - @ApiModelProperty(example = "open", value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` → `closed` 2. `open` → `cancelled` 3. Either: - `closed` → `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` → `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` → `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` → `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") + @ApiModelProperty(example = "open", value = "Indicates the current state of the session. Sessions can be created as `open` or `closed`. The state transitions are: 1. `open` -> `closed` 2. `open` -> `cancelled` 3. Either: - `closed` -> `cancelled` (**only** via [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2)) or - `closed` -> `partially_returned` (**only** via [Return cart items](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/returnCartItems)) - `closed` -> `open` (**only** via [Reopen customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession)) 4. `partially_returned` -> `cancelled` For more information, see [Customer session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions). ") public StateEnum getState() { return state; @@ -484,6 +519,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.couponCodes, newCustomerSessionV2.couponCodes) && Objects.equals(this.referralCode, newCustomerSessionV2.referralCode) && Objects.equals(this.loyaltyCards, newCustomerSessionV2.loyaltyCards) && + Objects.equals(this.rewardIntegrationIds, newCustomerSessionV2.rewardIntegrationIds) && Objects.equals(this.state, newCustomerSessionV2.state) && Objects.equals(this.cartItems, newCustomerSessionV2.cartItems) && Objects.equals(this.experimentVariantAllocations, newCustomerSessionV2.experimentVariantAllocations) && @@ -494,7 +530,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, couponCodes, referralCode, loyaltyCards, state, cartItems, experimentVariantAllocations, additionalCosts, identifiers, attributes); + return Objects.hash(profileId, storeIntegrationId, evaluableCampaignIds, couponCodes, referralCode, loyaltyCards, rewardIntegrationIds, state, cartItems, experimentVariantAllocations, additionalCosts, identifiers, attributes); } @@ -508,6 +544,7 @@ public String toString() { sb.append(" couponCodes: ").append(toIndentedString(couponCodes)).append("\n"); sb.append(" referralCode: ").append(toIndentedString(referralCode)).append("\n"); sb.append(" loyaltyCards: ").append(toIndentedString(loyaltyCards)).append("\n"); + sb.append(" rewardIntegrationIds: ").append(toIndentedString(rewardIntegrationIds)).append("\n"); sb.append(" state: ").append(toIndentedString(state)).append("\n"); sb.append(" cartItems: ").append(toIndentedString(cartItems)).append("\n"); sb.append(" experimentVariantAllocations: ").append(toIndentedString(experimentVariantAllocations)).append("\n"); diff --git a/src/main/java/one/talon/model/NewDigitalPass.java b/src/main/java/one/talon/model/NewDigitalPass.java new file mode 100644 index 00000000..cab43c18 --- /dev/null +++ b/src/main/java/one/talon/model/NewDigitalPass.java @@ -0,0 +1,299 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * NewDigitalPass + */ + +public class NewDigitalPass { + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_PASS_TEMPLATE_ID = "passTemplateId"; + @SerializedName(SERIALIZED_NAME_PASS_TEMPLATE_ID) + private String passTemplateId; + + public static final String SERIALIZED_NAME_PROFILE_ID = "profileId"; + @SerializedName(SERIALIZED_NAME_PROFILE_ID) + private String profileId; + + public static final String SERIALIZED_NAME_LOYALTY_CARD_ID = "loyaltyCardId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_CARD_ID) + private String loyaltyCardId; + + /** + * The wallet platform the pass is generated for. + */ + @JsonAdapter(PlatformEnum.Adapter.class) + public enum PlatformEnum { + APPLE("apple"), + + GOOGLE("google"); + + private String value; + + PlatformEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static PlatformEnum fromValue(String value) { + for (PlatformEnum b : PlatformEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final PlatformEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public PlatformEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return PlatformEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_PLATFORM = "platform"; + @SerializedName(SERIALIZED_NAME_PLATFORM) + private PlatformEnum platform; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Map attributes = null; + + + public NewDigitalPass loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * The ID of the associated loyalty program. + * minimum: 1 + * @return loyaltyProgramId + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the associated loyalty program.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public NewDigitalPass passTemplateId(String passTemplateId) { + + this.passTemplateId = passTemplateId; + return this; + } + + /** + * The ID of the digital pass template used to generate the pass. + * @return passTemplateId + **/ + @ApiModelProperty(example = "tmpl_summer_loyalty", required = true, value = "The ID of the digital pass template used to generate the pass. ") + + public String getPassTemplateId() { + return passTemplateId; + } + + + public void setPassTemplateId(String passTemplateId) { + this.passTemplateId = passTemplateId; + } + + + public NewDigitalPass profileId(String profileId) { + + this.profileId = profileId; + return this; + } + + /** + * The integration ID of the customer profile the pass is issued for. + * @return profileId + **/ + @ApiModelProperty(example = "12412412421", required = true, value = "The integration ID of the customer profile the pass is issued for.") + + public String getProfileId() { + return profileId; + } + + + public void setProfileId(String profileId) { + this.profileId = profileId; + } + + + public NewDigitalPass loyaltyCardId(String loyaltyCardId) { + + this.loyaltyCardId = loyaltyCardId; + return this; + } + + /** + * The identifier of the loyalty card the pass is issued for. **Note**: Only applicable for card-based loyalty programs. + * @return loyaltyCardId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "summer-loyalty-0e2f", value = "The identifier of the loyalty card the pass is issued for. **Note**: Only applicable for card-based loyalty programs. ") + + public String getLoyaltyCardId() { + return loyaltyCardId; + } + + + public void setLoyaltyCardId(String loyaltyCardId) { + this.loyaltyCardId = loyaltyCardId; + } + + + public NewDigitalPass platform(PlatformEnum platform) { + + this.platform = platform; + return this; + } + + /** + * The wallet platform the pass is generated for. + * @return platform + **/ + @ApiModelProperty(example = "google", required = true, value = "The wallet platform the pass is generated for.") + + public PlatformEnum getPlatform() { + return platform; + } + + + public void setPlatform(PlatformEnum platform) { + this.platform = platform; + } + + + public NewDigitalPass attributes(Map attributes) { + + this.attributes = attributes; + return this; + } + + public NewDigitalPass putAttributesItem(String key, String attributesItem) { + if (this.attributes == null) { + this.attributes = new HashMap(); + } + this.attributes.put(key, attributesItem); + return this; + } + + /** + * A map of placeholder values that you provide to fill in the pass template. These values are not validated against the template. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "{\"hm_member_name\":\"Jane Doe\"}", value = "A map of placeholder values that you provide to fill in the pass template. These values are not validated against the template. ") + + public Map getAttributes() { + return attributes; + } + + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NewDigitalPass newDigitalPass = (NewDigitalPass) o; + return Objects.equals(this.loyaltyProgramId, newDigitalPass.loyaltyProgramId) && + Objects.equals(this.passTemplateId, newDigitalPass.passTemplateId) && + Objects.equals(this.profileId, newDigitalPass.profileId) && + Objects.equals(this.loyaltyCardId, newDigitalPass.loyaltyCardId) && + Objects.equals(this.platform, newDigitalPass.platform) && + Objects.equals(this.attributes, newDigitalPass.attributes); + } + + @Override + public int hashCode() { + return Objects.hash(loyaltyProgramId, passTemplateId, profileId, loyaltyCardId, platform, attributes); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NewDigitalPass {\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" passTemplateId: ").append(toIndentedString(passTemplateId)).append("\n"); + sb.append(" profileId: ").append(toIndentedString(profileId)).append("\n"); + sb.append(" loyaltyCardId: ").append(toIndentedString(loyaltyCardId)).append("\n"); + sb.append(" platform: ").append(toIndentedString(platform)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/NewEvent.java b/src/main/java/one/talon/model/NewEvent.java index 25885c5c..6939877c 100644 --- a/src/main/java/one/talon/model/NewEvent.java +++ b/src/main/java/one/talon/model/NewEvent.java @@ -103,10 +103,10 @@ public NewEvent type(String type) { } /** - * A string representing the event. Must not be a reserved event name. + * The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event. * @return type **/ - @ApiModelProperty(example = "pageViewed", required = true, value = "A string representing the event. Must not be a reserved event name.") + @ApiModelProperty(example = "pageViewed", required = true, value = "The name of the event. Must be a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events), not a built-in event.") public String getType() { return type; diff --git a/src/main/java/one/talon/model/NewEventV3Entity.java b/src/main/java/one/talon/model/NewEventV3Entity.java new file mode 100644 index 00000000..216e99dd --- /dev/null +++ b/src/main/java/one/talon/model/NewEventV3Entity.java @@ -0,0 +1,98 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * NewEventV3Entity + */ + +public class NewEventV3Entity { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + + public NewEventV3Entity integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The unique ID of the event. Only one event with this ID can be registered. + * @return integrationId + **/ + @ApiModelProperty(example = "175KJPS947296", required = true, value = "The unique ID of the event. Only one event with this ID can be registered. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NewEventV3Entity newEventV3Entity = (NewEventV3Entity) o; + return Objects.equals(this.integrationId, newEventV3Entity.integrationId); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NewEventV3Entity {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/NewExperiment.java b/src/main/java/one/talon/model/NewExperiment.java index 6bed3cd8..1e8e0ffc 100644 --- a/src/main/java/one/talon/model/NewExperiment.java +++ b/src/main/java/one/talon/model/NewExperiment.java @@ -38,6 +38,65 @@ public class NewExperiment { @SerializedName(SERIALIZED_NAME_CAMPAIGN) private NewCampaign campaign; + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + */ + @JsonAdapter(GoalTypeEnum.Adapter.class) + public enum GoalTypeEnum { + OTHER("other"), + + MAXIMIZE_REVENUE("maximize_revenue"), + + MAXIMIZE_ITEMS_SOLD("maximize_items_sold"), + + OPTIMIZE_DISCOUNT_EFFICIENCY("optimize_discount_efficiency"); + + private String value; + + GoalTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static GoalTypeEnum fromValue(String value) { + for (GoalTypeEnum b : GoalTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final GoalTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public GoalTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return GoalTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_GOAL_TYPE = "goalType"; + @SerializedName(SERIALIZED_NAME_GOAL_TYPE) + private GoalTypeEnum goalType = GoalTypeEnum.OTHER; + + public static final String SERIALIZED_NAME_GOAL_DESCRIPTION = "goalDescription"; + @SerializedName(SERIALIZED_NAME_GOAL_DESCRIPTION) + private String goalDescription; + public NewExperiment isVariantAssignmentExternal(Boolean isVariantAssignmentExternal) { @@ -83,6 +142,51 @@ public void setCampaign(NewCampaign campaign) { } + public NewExperiment goalType(GoalTypeEnum goalType) { + + this.goalType = goalType; + return this; + } + + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. + * @return goalType + **/ + @ApiModelProperty(required = true, value = "The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. ") + + public GoalTypeEnum getGoalType() { + return goalType; + } + + + public void setGoalType(GoalTypeEnum goalType) { + this.goalType = goalType; + } + + + public NewExperiment goalDescription(String goalDescription) { + + this.goalDescription = goalDescription; + return this; + } + + /** + * A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. + * @return goalDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Offering free shipping will increase average order revenue more than a 10% discount", value = "A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. ") + + public String getGoalDescription() { + return goalDescription; + } + + + public void setGoalDescription(String goalDescription) { + this.goalDescription = goalDescription; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -93,12 +197,14 @@ public boolean equals(java.lang.Object o) { } NewExperiment newExperiment = (NewExperiment) o; return Objects.equals(this.isVariantAssignmentExternal, newExperiment.isVariantAssignmentExternal) && - Objects.equals(this.campaign, newExperiment.campaign); + Objects.equals(this.campaign, newExperiment.campaign) && + Objects.equals(this.goalType, newExperiment.goalType) && + Objects.equals(this.goalDescription, newExperiment.goalDescription); } @Override public int hashCode() { - return Objects.hash(isVariantAssignmentExternal, campaign); + return Objects.hash(isVariantAssignmentExternal, campaign, goalType, goalDescription); } @@ -108,6 +214,8 @@ public String toString() { sb.append("class NewExperiment {\n"); sb.append(" isVariantAssignmentExternal: ").append(toIndentedString(isVariantAssignmentExternal)).append("\n"); sb.append(" campaign: ").append(toIndentedString(campaign)).append("\n"); + sb.append(" goalType: ").append(toIndentedString(goalType)).append("\n"); + sb.append(" goalDescription: ").append(toIndentedString(goalDescription)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/NewIntegrationHubCoupons.java b/src/main/java/one/talon/model/NewIntegrationHubCoupons.java new file mode 100644 index 00000000..0963190a --- /dev/null +++ b/src/main/java/one/talon/model/NewIntegrationHubCoupons.java @@ -0,0 +1,614 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.LimitConfig; +import org.threeten.bp.OffsetDateTime; + +/** + * NewIntegrationHubCoupons + */ + +public class NewIntegrationHubCoupons { + public static final String SERIALIZED_NAME_USAGE_LIMIT = "usageLimit"; + @SerializedName(SERIALIZED_NAME_USAGE_LIMIT) + private Long usageLimit; + + public static final String SERIALIZED_NAME_DISCOUNT_LIMIT = "discountLimit"; + @SerializedName(SERIALIZED_NAME_DISCOUNT_LIMIT) + private BigDecimal discountLimit; + + public static final String SERIALIZED_NAME_RESERVATION_LIMIT = "reservationLimit"; + @SerializedName(SERIALIZED_NAME_RESERVATION_LIMIT) + private Long reservationLimit; + + public static final String SERIALIZED_NAME_START_DATE = "startDate"; + @SerializedName(SERIALIZED_NAME_START_DATE) + private OffsetDateTime startDate; + + public static final String SERIALIZED_NAME_EXPIRY_DATE = "expiryDate"; + @SerializedName(SERIALIZED_NAME_EXPIRY_DATE) + private OffsetDateTime expiryDate; + + public static final String SERIALIZED_NAME_LIMITS = "limits"; + @SerializedName(SERIALIZED_NAME_LIMITS) + private List limits = null; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_BATCH_ID = "batchId"; + @SerializedName(SERIALIZED_NAME_BATCH_ID) + private String batchId; + + public static final String SERIALIZED_NAME_NUMBER_OF_COUPONS = "numberOfCoupons"; + @SerializedName(SERIALIZED_NAME_NUMBER_OF_COUPONS) + private Long numberOfCoupons; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + public static final String SERIALIZED_NAME_VALID_CHARACTERS = "validCharacters"; + @SerializedName(SERIALIZED_NAME_VALID_CHARACTERS) + private List validCharacters = null; + + public static final String SERIALIZED_NAME_COUPON_PATTERN = "couponPattern"; + @SerializedName(SERIALIZED_NAME_COUPON_PATTERN) + private String couponPattern; + + public static final String SERIALIZED_NAME_IS_RESERVATION_MANDATORY = "isReservationMandatory"; + @SerializedName(SERIALIZED_NAME_IS_RESERVATION_MANDATORY) + private Boolean isReservationMandatory = false; + + public static final String SERIALIZED_NAME_IMPLICITLY_RESERVED = "implicitlyReserved"; + @SerializedName(SERIALIZED_NAME_IMPLICITLY_RESERVED) + private Boolean implicitlyReserved; + + public static final String SERIALIZED_NAME_RECIPIENT_INTEGRATION_ID = "recipientIntegrationId"; + @SerializedName(SERIALIZED_NAME_RECIPIENT_INTEGRATION_ID) + private String recipientIntegrationId; + + public static final String SERIALIZED_NAME_SUPPORT_REQUEST_ID = "supportRequestId"; + @SerializedName(SERIALIZED_NAME_SUPPORT_REQUEST_ID) + private Long supportRequestId; + + public static final String SERIALIZED_NAME_SUPPORT_REQUEST_NOTE = "supportRequestNote"; + @SerializedName(SERIALIZED_NAME_SUPPORT_REQUEST_NOTE) + private String supportRequestNote; + + + public NewIntegrationHubCoupons usageLimit(Long usageLimit) { + + this.usageLimit = usageLimit; + return this; + } + + /** + * The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. + * minimum: 0 + * maximum: 999999 + * @return usageLimit + **/ + @ApiModelProperty(example = "100", required = true, value = "The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply. ") + + public Long getUsageLimit() { + return usageLimit; + } + + + public void setUsageLimit(Long usageLimit) { + this.usageLimit = usageLimit; + } + + + public NewIntegrationHubCoupons discountLimit(BigDecimal discountLimit) { + + this.discountLimit = discountLimit; + return this; + } + + /** + * The total discount value that the code can give. Typically used to represent a gift card value. + * minimum: 0 + * maximum: 1E+15 + * @return discountLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "30.0", value = "The total discount value that the code can give. Typically used to represent a gift card value. ") + + public BigDecimal getDiscountLimit() { + return discountLimit; + } + + + public void setDiscountLimit(BigDecimal discountLimit) { + this.discountLimit = discountLimit; + } + + + public NewIntegrationHubCoupons reservationLimit(Long reservationLimit) { + + this.reservationLimit = reservationLimit; + return this; + } + + /** + * The number of reservations that can be made with this coupon code. + * minimum: 0 + * maximum: 999999 + * @return reservationLimit + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "45", value = "The number of reservations that can be made with this coupon code. ") + + public Long getReservationLimit() { + return reservationLimit; + } + + + public void setReservationLimit(Long reservationLimit) { + this.reservationLimit = reservationLimit; + } + + + public NewIntegrationHubCoupons startDate(OffsetDateTime startDate) { + + this.startDate = startDate; + return this; + } + + /** + * Timestamp at which point the coupon becomes valid. + * @return startDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2020-01-24T14:15:22Z", value = "Timestamp at which point the coupon becomes valid.") + + public OffsetDateTime getStartDate() { + return startDate; + } + + + public void setStartDate(OffsetDateTime startDate) { + this.startDate = startDate; + } + + + public NewIntegrationHubCoupons expiryDate(OffsetDateTime expiryDate) { + + this.expiryDate = expiryDate; + return this; + } + + /** + * Expiration date of the coupon. Coupon never expires if this is omitted. + * @return expiryDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2023-08-24T14:15:22Z", value = "Expiration date of the coupon. Coupon never expires if this is omitted.") + + public OffsetDateTime getExpiryDate() { + return expiryDate; + } + + + public void setExpiryDate(OffsetDateTime expiryDate) { + this.expiryDate = expiryDate; + } + + + public NewIntegrationHubCoupons limits(List limits) { + + this.limits = limits; + return this; + } + + public NewIntegrationHubCoupons addLimitsItem(LimitConfig limitsItem) { + if (this.limits == null) { + this.limits = new ArrayList(); + } + this.limits.add(limitsItem); + return this; + } + + /** + * Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured. + * @return limits + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured. ") + + public List getLimits() { + return limits; + } + + + public void setLimits(List limits) { + this.limits = limits; + } + + + public NewIntegrationHubCoupons applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application the coupons will belong to. + * @return applicationId + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the Application the coupons will belong to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public NewIntegrationHubCoupons campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * The ID of the Campaign the coupons will belong to. + * @return campaignId + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the Campaign the coupons will belong to.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public NewIntegrationHubCoupons batchId(String batchId) { + + this.batchId = batchId; + return this; + } + + /** + * An identifier for the batch of coupons being created. + * @return batchId + **/ + @ApiModelProperty(example = "abcdef123", required = true, value = "An identifier for the batch of coupons being created.") + + public String getBatchId() { + return batchId; + } + + + public void setBatchId(String batchId) { + this.batchId = batchId; + } + + + public NewIntegrationHubCoupons numberOfCoupons(Long numberOfCoupons) { + + this.numberOfCoupons = numberOfCoupons; + return this; + } + + /** + * The number of new coupon codes to generate for the campaign. Must be at least 1. + * @return numberOfCoupons + **/ + @ApiModelProperty(example = "100", required = true, value = "The number of new coupon codes to generate for the campaign. Must be at least 1.") + + public Long getNumberOfCoupons() { + return numberOfCoupons; + } + + + public void setNumberOfCoupons(Long numberOfCoupons) { + this.numberOfCoupons = numberOfCoupons; + } + + + public NewIntegrationHubCoupons attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Arbitrary properties associated with this item. + * @return attributes + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "{\"campaignSource\":\"cep-integration\"}", value = "Arbitrary properties associated with this item.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public NewIntegrationHubCoupons validCharacters(List validCharacters) { + + this.validCharacters = validCharacters; + return this; + } + + public NewIntegrationHubCoupons addValidCharactersItem(String validCharactersItem) { + if (this.validCharacters == null) { + this.validCharacters = new ArrayList(); + } + this.validCharacters.add(validCharactersItem); + return this; + } + + /** + * List of characters used to generate the random parts of a code. By default, the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. + * @return validCharacters + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[A, B, C]", value = "List of characters used to generate the random parts of a code. By default, the list of characters is equivalent to the `[A-Z, 0-9]` regular expression. ") + + public List getValidCharacters() { + return validCharacters; + } + + + public void setValidCharacters(List validCharacters) { + this.validCharacters = validCharacters; + } + + + public NewIntegrationHubCoupons couponPattern(String couponPattern) { + + this.couponPattern = couponPattern; + return this; + } + + /** + * The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. + * @return couponPattern + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "CEP-####-####", value = "The pattern used to generate coupon codes. The character `#` is a placeholder and is replaced by a random character from the `validCharacters` set. ") + + public String getCouponPattern() { + return couponPattern; + } + + + public void setCouponPattern(String couponPattern) { + this.couponPattern = couponPattern; + } + + + public NewIntegrationHubCoupons isReservationMandatory(Boolean isReservationMandatory) { + + this.isReservationMandatory = isReservationMandatory; + return this; + } + + /** + * An indication of whether the code can be redeemed only if it has been reserved first. + * @return isReservationMandatory + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "An indication of whether the code can be redeemed only if it has been reserved first.") + + public Boolean getIsReservationMandatory() { + return isReservationMandatory; + } + + + public void setIsReservationMandatory(Boolean isReservationMandatory) { + this.isReservationMandatory = isReservationMandatory; + } + + + public NewIntegrationHubCoupons implicitlyReserved(Boolean implicitlyReserved) { + + this.implicitlyReserved = implicitlyReserved; + return this; + } + + /** + * An indication of whether the coupon is implicitly reserved for all customers. + * @return implicitlyReserved + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "An indication of whether the coupon is implicitly reserved for all customers.") + + public Boolean getImplicitlyReserved() { + return implicitlyReserved; + } + + + public void setImplicitlyReserved(Boolean implicitlyReserved) { + this.implicitlyReserved = implicitlyReserved; + } + + + public NewIntegrationHubCoupons recipientIntegrationId(String recipientIntegrationId) { + + this.recipientIntegrationId = recipientIntegrationId; + return this; + } + + /** + * The integration ID for this coupon's beneficiary's profile. + * @return recipientIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "URNGV8294NV", value = "The integration ID for this coupon's beneficiary's profile.") + + public String getRecipientIntegrationId() { + return recipientIntegrationId; + } + + + public void setRecipientIntegrationId(String recipientIntegrationId) { + this.recipientIntegrationId = recipientIntegrationId; + } + + + public NewIntegrationHubCoupons supportRequestId(Long supportRequestId) { + + this.supportRequestId = supportRequestId; + return this; + } + + /** + * The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed. + * @return supportRequestId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The identifier of the support request to link to the coupon creation. The request must exist and not yet be processed.") + + public Long getSupportRequestId() { + return supportRequestId; + } + + + public void setSupportRequestId(Long supportRequestId) { + this.supportRequestId = supportRequestId; + } + + + public NewIntegrationHubCoupons supportRequestNote(String supportRequestNote) { + + this.supportRequestNote = supportRequestNote; + return this; + } + + /** + * A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided. + * @return supportRequestNote + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Approved as compensation for the delayed order.", value = "A note recorded when the linked support request is approved or rejected. Applied when `supportRequestId` is provided.") + + public String getSupportRequestNote() { + return supportRequestNote; + } + + + public void setSupportRequestNote(String supportRequestNote) { + this.supportRequestNote = supportRequestNote; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NewIntegrationHubCoupons newIntegrationHubCoupons = (NewIntegrationHubCoupons) o; + return Objects.equals(this.usageLimit, newIntegrationHubCoupons.usageLimit) && + Objects.equals(this.discountLimit, newIntegrationHubCoupons.discountLimit) && + Objects.equals(this.reservationLimit, newIntegrationHubCoupons.reservationLimit) && + Objects.equals(this.startDate, newIntegrationHubCoupons.startDate) && + Objects.equals(this.expiryDate, newIntegrationHubCoupons.expiryDate) && + Objects.equals(this.limits, newIntegrationHubCoupons.limits) && + Objects.equals(this.applicationId, newIntegrationHubCoupons.applicationId) && + Objects.equals(this.campaignId, newIntegrationHubCoupons.campaignId) && + Objects.equals(this.batchId, newIntegrationHubCoupons.batchId) && + Objects.equals(this.numberOfCoupons, newIntegrationHubCoupons.numberOfCoupons) && + Objects.equals(this.attributes, newIntegrationHubCoupons.attributes) && + Objects.equals(this.validCharacters, newIntegrationHubCoupons.validCharacters) && + Objects.equals(this.couponPattern, newIntegrationHubCoupons.couponPattern) && + Objects.equals(this.isReservationMandatory, newIntegrationHubCoupons.isReservationMandatory) && + Objects.equals(this.implicitlyReserved, newIntegrationHubCoupons.implicitlyReserved) && + Objects.equals(this.recipientIntegrationId, newIntegrationHubCoupons.recipientIntegrationId) && + Objects.equals(this.supportRequestId, newIntegrationHubCoupons.supportRequestId) && + Objects.equals(this.supportRequestNote, newIntegrationHubCoupons.supportRequestNote); + } + + @Override + public int hashCode() { + return Objects.hash(usageLimit, discountLimit, reservationLimit, startDate, expiryDate, limits, applicationId, campaignId, batchId, numberOfCoupons, attributes, validCharacters, couponPattern, isReservationMandatory, implicitlyReserved, recipientIntegrationId, supportRequestId, supportRequestNote); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NewIntegrationHubCoupons {\n"); + sb.append(" usageLimit: ").append(toIndentedString(usageLimit)).append("\n"); + sb.append(" discountLimit: ").append(toIndentedString(discountLimit)).append("\n"); + sb.append(" reservationLimit: ").append(toIndentedString(reservationLimit)).append("\n"); + sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); + sb.append(" expiryDate: ").append(toIndentedString(expiryDate)).append("\n"); + sb.append(" limits: ").append(toIndentedString(limits)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" batchId: ").append(toIndentedString(batchId)).append("\n"); + sb.append(" numberOfCoupons: ").append(toIndentedString(numberOfCoupons)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" validCharacters: ").append(toIndentedString(validCharacters)).append("\n"); + sb.append(" couponPattern: ").append(toIndentedString(couponPattern)).append("\n"); + sb.append(" isReservationMandatory: ").append(toIndentedString(isReservationMandatory)).append("\n"); + sb.append(" implicitlyReserved: ").append(toIndentedString(implicitlyReserved)).append("\n"); + sb.append(" recipientIntegrationId: ").append(toIndentedString(recipientIntegrationId)).append("\n"); + sb.append(" supportRequestId: ").append(toIndentedString(supportRequestId)).append("\n"); + sb.append(" supportRequestNote: ").append(toIndentedString(supportRequestNote)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/NewInternalAudience.java b/src/main/java/one/talon/model/NewInternalAudience.java index c6228622..4a7c34b9 100644 --- a/src/main/java/one/talon/model/NewInternalAudience.java +++ b/src/main/java/one/talon/model/NewInternalAudience.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; /** * NewInternalAudience @@ -41,6 +43,10 @@ public class NewInternalAudience { @SerializedName(SERIALIZED_NAME_DESCRIPTION) private String description; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public NewInternalAudience name(String name) { @@ -110,6 +116,37 @@ public void setDescription(String description) { } + public NewInternalAudience subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public NewInternalAudience addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -121,12 +158,13 @@ public boolean equals(java.lang.Object o) { NewInternalAudience newInternalAudience = (NewInternalAudience) o; return Objects.equals(this.name, newInternalAudience.name) && Objects.equals(this.sandbox, newInternalAudience.sandbox) && - Objects.equals(this.description, newInternalAudience.description); + Objects.equals(this.description, newInternalAudience.description) && + Objects.equals(this.subscribedApplicationsIds, newInternalAudience.subscribedApplicationsIds); } @Override public int hashCode() { - return Objects.hash(name, sandbox, description); + return Objects.hash(name, sandbox, description, subscribedApplicationsIds); } @@ -137,6 +175,7 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/NewMCPOAuthClient.java b/src/main/java/one/talon/model/NewMCPOAuthClient.java new file mode 100644 index 00000000..3e749c83 --- /dev/null +++ b/src/main/java/one/talon/model/NewMCPOAuthClient.java @@ -0,0 +1,133 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * NewMCPOAuthClient + */ + +public class NewMCPOAuthClient { + public static final String SERIALIZED_NAME_CLIENT_NAME = "client_name"; + @SerializedName(SERIALIZED_NAME_CLIENT_NAME) + private String clientName; + + public static final String SERIALIZED_NAME_REDIRECT_URIS = "redirect_uris"; + @SerializedName(SERIALIZED_NAME_REDIRECT_URIS) + private List redirectUris = new ArrayList(); + + + public NewMCPOAuthClient clientName(String clientName) { + + this.clientName = clientName; + return this; + } + + /** + * Human-readable name for the OAuth2 client. + * @return clientName + **/ + @ApiModelProperty(example = "My MCP Integration", required = true, value = "Human-readable name for the OAuth2 client.") + + public String getClientName() { + return clientName; + } + + + public void setClientName(String clientName) { + this.clientName = clientName; + } + + + public NewMCPOAuthClient redirectUris(List redirectUris) { + + this.redirectUris = redirectUris; + return this; + } + + public NewMCPOAuthClient addRedirectUrisItem(String redirectUrisItem) { + this.redirectUris.add(redirectUrisItem); + return this; + } + + /** + * List of allowed redirect URIs for the authorization code flow. At least one URI is required. + * @return redirectUris + **/ + @ApiModelProperty(example = "[http://localhost:3000/callback]", required = true, value = "List of allowed redirect URIs for the authorization code flow. At least one URI is required.") + + public List getRedirectUris() { + return redirectUris; + } + + + public void setRedirectUris(List redirectUris) { + this.redirectUris = redirectUris; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NewMCPOAuthClient newMCPOAuthClient = (NewMCPOAuthClient) o; + return Objects.equals(this.clientName, newMCPOAuthClient.clientName) && + Objects.equals(this.redirectUris, newMCPOAuthClient.redirectUris); + } + + @Override + public int hashCode() { + return Objects.hash(clientName, redirectUris); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NewMCPOAuthClient {\n"); + sb.append(" clientName: ").append(toIndentedString(clientName)).append("\n"); + sb.append(" redirectUris: ").append(toIndentedString(redirectUris)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/NewMultipleAudiencesItem.java b/src/main/java/one/talon/model/NewMultipleAudiencesItem.java index f8f03bbc..df8e7615 100644 --- a/src/main/java/one/talon/model/NewMultipleAudiencesItem.java +++ b/src/main/java/one/talon/model/NewMultipleAudiencesItem.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; /** * NewMultipleAudiencesItem @@ -33,6 +35,10 @@ public class NewMultipleAudiencesItem { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) private String integrationId; @@ -60,6 +66,37 @@ public void setName(String name) { } + public NewMultipleAudiencesItem subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public NewMultipleAudiencesItem addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + public NewMultipleAudiencesItem integrationId(String integrationId) { this.integrationId = integrationId; @@ -93,12 +130,13 @@ public boolean equals(java.lang.Object o) { } NewMultipleAudiencesItem newMultipleAudiencesItem = (NewMultipleAudiencesItem) o; return Objects.equals(this.name, newMultipleAudiencesItem.name) && + Objects.equals(this.subscribedApplicationsIds, newMultipleAudiencesItem.subscribedApplicationsIds) && Objects.equals(this.integrationId, newMultipleAudiencesItem.integrationId); } @Override public int hashCode() { - return Objects.hash(name, integrationId); + return Objects.hash(name, subscribedApplicationsIds, integrationId); } @@ -107,6 +145,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class NewMultipleAudiencesItem {\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/NewRevisionVersion.java b/src/main/java/one/talon/model/NewRevisionVersion.java index 126ba715..aefea913 100644 --- a/src/main/java/one/talon/model/NewRevisionVersion.java +++ b/src/main/java/one/talon/model/NewRevisionVersion.java @@ -93,7 +93,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/NewReward.java b/src/main/java/one/talon/model/NewReward.java index 72539bce..20ae71c8 100644 --- a/src/main/java/one/talon/model/NewReward.java +++ b/src/main/java/one/talon/model/NewReward.java @@ -25,6 +25,9 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; /** * NewReward @@ -51,6 +54,22 @@ public class NewReward { @SerializedName(SERIALIZED_NAME_SANDBOX) private Boolean sandbox; + public static final String SERIALIZED_NAME_ELIGIBILITY_CONDITIONS = "eligibilityConditions"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY_CONDITIONS) + private Rule eligibilityConditions; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private Rule rule; + + public static final String SERIALIZED_NAME_BINDINGS = "bindings"; + @SerializedName(SERIALIZED_NAME_BINDINGS) + private List bindings = null; + + public static final String SERIALIZED_NAME_POINTS_REQUIRED = "pointsRequired"; + @SerializedName(SERIALIZED_NAME_POINTS_REQUIRED) + private List pointsRequired = null; + public NewReward name(String name) { @@ -168,6 +187,114 @@ public void setSandbox(Boolean sandbox) { } + public NewReward eligibilityConditions(Rule eligibilityConditions) { + + this.eligibilityConditions = eligibilityConditions; + return this; + } + + /** + * Get eligibilityConditions + * @return eligibilityConditions + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getEligibilityConditions() { + return eligibilityConditions; + } + + + public void setEligibilityConditions(Rule eligibilityConditions) { + this.eligibilityConditions = eligibilityConditions; + } + + + public NewReward rule(Rule rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getRule() { + return rule; + } + + + public void setRule(Rule rule) { + this.rule = rule; + } + + + public NewReward bindings(List bindings) { + + this.bindings = bindings; + return this; + } + + public NewReward addBindingsItem(Binding bindingsItem) { + if (this.bindings == null) { + this.bindings = new ArrayList(); + } + this.bindings.add(bindingsItem); + return this; + } + + /** + * A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. + * @return bindings + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[]", value = "A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules.") + + public List getBindings() { + return bindings; + } + + + public void setBindings(List bindings) { + this.bindings = bindings; + } + + + public NewReward pointsRequired(List pointsRequired) { + + this.pointsRequired = pointsRequired; + return this; + } + + public NewReward addPointsRequiredItem(RewardPointsRequired pointsRequiredItem) { + if (this.pointsRequired == null) { + this.pointsRequired = new ArrayList(); + } + this.pointsRequired.add(pointsRequiredItem); + return this; + } + + /** + * The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. + * @return pointsRequired + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. ") + + public List getPointsRequired() { + return pointsRequired; + } + + + public void setPointsRequired(List pointsRequired) { + this.pointsRequired = pointsRequired; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -181,12 +308,16 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.apiName, newReward.apiName) && Objects.equals(this.description, newReward.description) && Objects.equals(this.applicationIds, newReward.applicationIds) && - Objects.equals(this.sandbox, newReward.sandbox); + Objects.equals(this.sandbox, newReward.sandbox) && + Objects.equals(this.eligibilityConditions, newReward.eligibilityConditions) && + Objects.equals(this.rule, newReward.rule) && + Objects.equals(this.bindings, newReward.bindings) && + Objects.equals(this.pointsRequired, newReward.pointsRequired); } @Override public int hashCode() { - return Objects.hash(name, apiName, description, applicationIds, sandbox); + return Objects.hash(name, apiName, description, applicationIds, sandbox, eligibilityConditions, rule, bindings, pointsRequired); } @@ -199,6 +330,10 @@ public String toString() { sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" applicationIds: ").append(toIndentedString(applicationIds)).append("\n"); sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); + sb.append(" eligibilityConditions: ").append(toIndentedString(eligibilityConditions)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" bindings: ").append(toIndentedString(bindings)).append("\n"); + sb.append(" pointsRequired: ").append(toIndentedString(pointsRequired)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/NewRiskNotification.java b/src/main/java/one/talon/model/NewRiskNotification.java new file mode 100644 index 00000000..c94e0996 --- /dev/null +++ b/src/main/java/one/talon/model/NewRiskNotification.java @@ -0,0 +1,302 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Data for creating a new risk notification. + */ +@ApiModel(description = "Data for creating a new risk notification.") + +public class NewRiskNotification { + /** + * The entity type to analyze within the given time frame. + */ + @JsonAdapter(EntityEnum.Adapter.class) + public enum EntityEnum { + PROFILE("customer_profile"), + + SESSION("customer_session"); + + private String value; + + EntityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static EntityEnum fromValue(String value) { + for (EntityEnum b : EntityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final EntityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public EntityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return EntityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private EntityEnum entity; + + /** + * The activity metric to analyze within the given entity. + */ + @JsonAdapter(ActivityEnum.Adapter.class) + public enum ActivityEnum { + LOYALTY_POINTS_EARNED("loyalty_points_earned"), + + DISCOUNTED_AMOUNT("discounted_amount"), + + COMPLETED_ORDERS("completed_orders"), + + COUPON_ATTEMPTS("coupon_attempts"); + + private String value; + + ActivityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivityEnum fromValue(String value) { + for (ActivityEnum b : ActivityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVITY = "activity"; + @SerializedName(SERIALIZED_NAME_ACTIVITY) + private ActivityEnum activity; + + /** + * The rolling time window for risk evaluation. + */ + @JsonAdapter(TimeFrameEnum.Adapter.class) + public enum TimeFrameEnum { + _1D("1D"), + + _7D("7D"), + + _30D("30D"); + + private String value; + + TimeFrameEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TimeFrameEnum fromValue(String value) { + for (TimeFrameEnum b : TimeFrameEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TimeFrameEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TimeFrameEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TimeFrameEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TIME_FRAME = "timeFrame"; + @SerializedName(SERIALIZED_NAME_TIME_FRAME) + private TimeFrameEnum timeFrame; + + + public NewRiskNotification entity(EntityEnum entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type to analyze within the given time frame. + * @return entity + **/ + @ApiModelProperty(example = "customer_profile", required = true, value = "The entity type to analyze within the given time frame.") + + public EntityEnum getEntity() { + return entity; + } + + + public void setEntity(EntityEnum entity) { + this.entity = entity; + } + + + public NewRiskNotification activity(ActivityEnum activity) { + + this.activity = activity; + return this; + } + + /** + * The activity metric to analyze within the given entity. + * @return activity + **/ + @ApiModelProperty(example = "loyalty_points_earned", required = true, value = "The activity metric to analyze within the given entity.") + + public ActivityEnum getActivity() { + return activity; + } + + + public void setActivity(ActivityEnum activity) { + this.activity = activity; + } + + + public NewRiskNotification timeFrame(TimeFrameEnum timeFrame) { + + this.timeFrame = timeFrame; + return this; + } + + /** + * The rolling time window for risk evaluation. + * @return timeFrame + **/ + @ApiModelProperty(example = "7D", required = true, value = "The rolling time window for risk evaluation.") + + public TimeFrameEnum getTimeFrame() { + return timeFrame; + } + + + public void setTimeFrame(TimeFrameEnum timeFrame) { + this.timeFrame = timeFrame; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NewRiskNotification newRiskNotification = (NewRiskNotification) o; + return Objects.equals(this.entity, newRiskNotification.entity) && + Objects.equals(this.activity, newRiskNotification.activity) && + Objects.equals(this.timeFrame, newRiskNotification.timeFrame); + } + + @Override + public int hashCode() { + return Objects.hash(entity, activity, timeFrame); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NewRiskNotification {\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); + sb.append(" timeFrame: ").append(toIndentedString(timeFrame)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/PassthroughBlock.java b/src/main/java/one/talon/model/PassthroughBlock.java new file mode 100644 index 00000000..5acdfc10 --- /dev/null +++ b/src/main/java/one/talon/model/PassthroughBlock.java @@ -0,0 +1,199 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block representing a Talang expression that could not be mapped to a typed block. The expression is preserved in its raw Talang array form for diagnostic and round-trip purposes. + */ +@ApiModel(description = "A block representing a Talang expression that could not be mapped to a typed block. The expression is preserved in its raw Talang array form for diagnostic and round-trip purposes.") + +public class PassthroughBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + /** + * The type discriminator for this block. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + PASSTHROUGH("passthrough"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_EXPRESSION = "expression"; + @SerializedName(SERIALIZED_NAME_EXPRESSION) + private List expression = new ArrayList(); + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public PassthroughBlock type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The type discriminator for this block. + * @return type + **/ + @ApiModelProperty(required = true, value = "The type discriminator for this block.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public PassthroughBlock expression(List expression) { + + this.expression = expression; + return this; + } + + public PassthroughBlock addExpressionItem(Object expressionItem) { + this.expression.add(expressionItem); + return this; + } + + /** + * The raw Talang expression as an array. For a function call, the first element is the function name and subsequent elements are its arguments. For any other expression (for example a bare attribute path or a literal value), this is a single-element array containing that value. + * @return expression + **/ + @ApiModelProperty(required = true, value = "The raw Talang expression as an array. For a function call, the first element is the function name and subsequent elements are its arguments. For any other expression (for example a bare attribute path or a literal value), this is a single-element array containing that value.") + + public List getExpression() { + return expression; + } + + + public void setExpression(List expression) { + this.expression = expression; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + PassthroughBlock passthroughBlock = (PassthroughBlock) o; + return Objects.equals(this.id, passthroughBlock.id) && + Objects.equals(this.type, passthroughBlock.type) && + Objects.equals(this.expression, passthroughBlock.expression); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, expression); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class PassthroughBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" expression: ").append(toIndentedString(expression)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/PriceHistoryRequest.java b/src/main/java/one/talon/model/PriceHistoryRequest.java index d8739456..2b4f2a47 100644 --- a/src/main/java/one/talon/model/PriceHistoryRequest.java +++ b/src/main/java/one/talon/model/PriceHistoryRequest.java @@ -53,7 +53,7 @@ public PriceHistoryRequest sku(String sku) { * The SKU of the item for which the historical prices are being retrieved. * @return sku **/ - @ApiModelProperty(example = "", required = true, value = "The SKU of the item for which the historical prices are being retrieved.") + @ApiModelProperty(example = "SKU1241028", required = true, value = "The SKU of the item for which the historical prices are being retrieved.") public String getSku() { return sku; diff --git a/src/main/java/one/talon/model/PriceHistoryResponse.java b/src/main/java/one/talon/model/PriceHistoryResponse.java index 14fe214e..6d4b7f9f 100644 --- a/src/main/java/one/talon/model/PriceHistoryResponse.java +++ b/src/main/java/one/talon/model/PriceHistoryResponse.java @@ -51,7 +51,7 @@ public PriceHistoryResponse sku(String sku) { * The SKU of the item for which historical prices should be retrieved. * @return sku **/ - @ApiModelProperty(example = "", required = true, value = "The SKU of the item for which historical prices should be retrieved.") + @ApiModelProperty(example = "SKU1241028", required = true, value = "The SKU of the item for which historical prices should be retrieved.") public String getSku() { return sku; diff --git a/src/main/java/one/talon/model/RedeemLoyaltyPointsBlock.java b/src/main/java/one/talon/model/RedeemLoyaltyPointsBlock.java new file mode 100644 index 00000000..ec7ed21e --- /dev/null +++ b/src/main/java/one/talon/model/RedeemLoyaltyPointsBlock.java @@ -0,0 +1,292 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RedeemLoyaltyPointsBlockProgram; + +/** + * A block that deducts a specified amount of points from a customer's loyalty program balance, optionally from a named subledger. + */ +@ApiModel(description = "A block that deducts a specified amount of points from a customer's loyalty program balance, optionally from a named subledger.") + +public class RedeemLoyaltyPointsBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_PROGRAM = "program"; + @SerializedName(SERIALIZED_NAME_PROGRAM) + private RedeemLoyaltyPointsBlockProgram program; + + public static final String SERIALIZED_NAME_SUBLEDGER = "subledger"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER) + private String subledger; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public RedeemLoyaltyPointsBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public RedeemLoyaltyPointsBlock program(RedeemLoyaltyPointsBlockProgram program) { + + this.program = program; + return this; + } + + /** + * Get program + * @return program + **/ + @ApiModelProperty(required = true, value = "") + + public RedeemLoyaltyPointsBlockProgram getProgram() { + return program; + } + + + public void setProgram(RedeemLoyaltyPointsBlockProgram program) { + this.program = program; + } + + + public RedeemLoyaltyPointsBlock subledger(String subledger) { + + this.subledger = subledger; + return this; + } + + /** + * The name of the subledger to deduct points from. Can be empty if this block deducts from the loyalty program's main ledger instead of a subledger. + * @return subledger + **/ + @ApiModelProperty(example = "main", required = true, value = "The name of the subledger to deduct points from. Can be empty if this block deducts from the loyalty program's main ledger instead of a subledger.") + + public String getSubledger() { + return subledger; + } + + + public void setSubledger(String subledger) { + this.subledger = subledger; + } + + + public RedeemLoyaltyPointsBlock value(Object value) { + + this.value = value; + return this; + } + + /** + * Number of points to deduct. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time. + * @return value + **/ + @ApiModelProperty(required = true, value = "Number of points to deduct. Either a numeric scalar or a `{{expression}}` string that resolves to a number at evaluation time.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public RedeemLoyaltyPointsBlock name(String name) { + + this.name = name; + return this; + } + + /** + * A custom description recorded as the reason for the point deduction. + * @return name + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Purchase Deduction", value = "A custom description recorded as the reason for the point deduction.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public RedeemLoyaltyPointsBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public RedeemLoyaltyPointsBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Promotion blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Promotion blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RedeemLoyaltyPointsBlock redeemLoyaltyPointsBlock = (RedeemLoyaltyPointsBlock) o; + return Objects.equals(this.id, redeemLoyaltyPointsBlock.id) && + Objects.equals(this.type, redeemLoyaltyPointsBlock.type) && + Objects.equals(this.tags, redeemLoyaltyPointsBlock.tags) && + Objects.equals(this.program, redeemLoyaltyPointsBlock.program) && + Objects.equals(this.subledger, redeemLoyaltyPointsBlock.subledger) && + Objects.equals(this.value, redeemLoyaltyPointsBlock.value) && + Objects.equals(this.name, redeemLoyaltyPointsBlock.name) && + Objects.equals(this.onFailure, redeemLoyaltyPointsBlock.onFailure); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, program, subledger, value, name, onFailure); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RedeemLoyaltyPointsBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" program: ").append(toIndentedString(program)).append("\n"); + sb.append(" subledger: ").append(toIndentedString(subledger)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RedeemLoyaltyPointsBlockProgram.java b/src/main/java/one/talon/model/RedeemLoyaltyPointsBlockProgram.java new file mode 100644 index 00000000..29e3e30d --- /dev/null +++ b/src/main/java/one/talon/model/RedeemLoyaltyPointsBlockProgram.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The loyalty program whose balance points are deducted from. + */ +@ApiModel(description = "The loyalty program whose balance points are deducted from.") + +public class RedeemLoyaltyPointsBlockProgram { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + + public RedeemLoyaltyPointsBlockProgram id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the loyalty program. + * @return id + **/ + @ApiModelProperty(example = "10", required = true, value = "The ID of the loyalty program.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RedeemLoyaltyPointsBlockProgram name(String name) { + + this.name = name; + return this; + } + + /** + * The internal name of the loyalty program. + * @return name + **/ + @ApiModelProperty(example = "MainProgram", required = true, value = "The internal name of the loyalty program.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public RedeemLoyaltyPointsBlockProgram title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the loyalty program. + * @return title + **/ + @ApiModelProperty(example = "Main Loyalty Program", required = true, value = "The display name of the loyalty program.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RedeemLoyaltyPointsBlockProgram redeemLoyaltyPointsBlockProgram = (RedeemLoyaltyPointsBlockProgram) o; + return Objects.equals(this.id, redeemLoyaltyPointsBlockProgram.id) && + Objects.equals(this.name, redeemLoyaltyPointsBlockProgram.name) && + Objects.equals(this.title, redeemLoyaltyPointsBlockProgram.title); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RedeemLoyaltyPointsBlockProgram {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RedeemReferralEffectProps.java b/src/main/java/one/talon/model/RedeemReferralEffectProps.java index 2efba89e..34bfcb05 100644 --- a/src/main/java/one/talon/model/RedeemReferralEffectProps.java +++ b/src/main/java/one/talon/model/RedeemReferralEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * This effect is **deprecated**. The properties specific to the \"redeemReferral\" effect. This gets triggered whenever the referral code is valid, and a rule was triggered that contains a \"redeem referral\" effect. + * This effect is **deprecated**. It has been replaced by the `acceptReferral` effect. This effect indicates that the referral code is valid and has been redeemed. */ -@ApiModel(description = "This effect is **deprecated**. The properties specific to the \"redeemReferral\" effect. This gets triggered whenever the referral code is valid, and a rule was triggered that contains a \"redeem referral\" effect. ") +@ApiModel(description = "This effect is **deprecated**. It has been replaced by the `acceptReferral` effect. This effect indicates that the referral code is valid and has been redeemed. ") public class RedeemReferralEffectProps { public static final String SERIALIZED_NAME_ID = "id"; diff --git a/src/main/java/one/talon/model/RedeemableCoupon.java b/src/main/java/one/talon/model/RedeemableCoupon.java new file mode 100644 index 00000000..2242f44a --- /dev/null +++ b/src/main/java/one/talon/model/RedeemableCoupon.java @@ -0,0 +1,210 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * RedeemableCoupon + */ + +public class RedeemableCoupon { + public static final String SERIALIZED_NAME_COUPON_ID = "couponId"; + @SerializedName(SERIALIZED_NAME_COUPON_ID) + private Long couponId; + + public static final String SERIALIZED_NAME_COUPON_CODE = "couponCode"; + @SerializedName(SERIALIZED_NAME_COUPON_CODE) + private String couponCode; + + public static final String SERIALIZED_NAME_USAGE_COUNTER = "usageCounter"; + @SerializedName(SERIALIZED_NAME_USAGE_COUNTER) + private Long usageCounter; + + public static final String SERIALIZED_NAME_USAGE_LIMIT = "usageLimit"; + @SerializedName(SERIALIZED_NAME_USAGE_LIMIT) + private Long usageLimit; + + public static final String SERIALIZED_NAME_CAMPAIGN_NAME = "campaignName"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_NAME) + private String campaignName; + + + public RedeemableCoupon couponId(Long couponId) { + + this.couponId = couponId; + return this; + } + + /** + * The internal ID of the coupon. + * @return couponId + **/ + @ApiModelProperty(example = "34", required = true, value = "The internal ID of the coupon.") + + public Long getCouponId() { + return couponId; + } + + + public void setCouponId(Long couponId) { + this.couponId = couponId; + } + + + public RedeemableCoupon couponCode(String couponCode) { + + this.couponCode = couponCode; + return this; + } + + /** + * The coupon code. + * @return couponCode + **/ + @ApiModelProperty(example = "SUMMER10", required = true, value = "The coupon code.") + + public String getCouponCode() { + return couponCode; + } + + + public void setCouponCode(String couponCode) { + this.couponCode = couponCode; + } + + + public RedeemableCoupon usageCounter(Long usageCounter) { + + this.usageCounter = usageCounter; + return this; + } + + /** + * The number of times the coupon has been successfully redeemed. + * @return usageCounter + **/ + @ApiModelProperty(example = "3", required = true, value = "The number of times the coupon has been successfully redeemed.") + + public Long getUsageCounter() { + return usageCounter; + } + + + public void setUsageCounter(Long usageCounter) { + this.usageCounter = usageCounter; + } + + + public RedeemableCoupon usageLimit(Long usageLimit) { + + this.usageLimit = usageLimit; + return this; + } + + /** + * The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits still apply. + * @return usageLimit + **/ + @ApiModelProperty(example = "10", required = true, value = "The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits still apply.") + + public Long getUsageLimit() { + return usageLimit; + } + + + public void setUsageLimit(Long usageLimit) { + this.usageLimit = usageLimit; + } + + + public RedeemableCoupon campaignName(String campaignName) { + + this.campaignName = campaignName; + return this; + } + + /** + * The name of the campaign that owns the coupon. + * @return campaignName + **/ + @ApiModelProperty(example = "Summer Sale 2026", required = true, value = "The name of the campaign that owns the coupon.") + + public String getCampaignName() { + return campaignName; + } + + + public void setCampaignName(String campaignName) { + this.campaignName = campaignName; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RedeemableCoupon redeemableCoupon = (RedeemableCoupon) o; + return Objects.equals(this.couponId, redeemableCoupon.couponId) && + Objects.equals(this.couponCode, redeemableCoupon.couponCode) && + Objects.equals(this.usageCounter, redeemableCoupon.usageCounter) && + Objects.equals(this.usageLimit, redeemableCoupon.usageLimit) && + Objects.equals(this.campaignName, redeemableCoupon.campaignName); + } + + @Override + public int hashCode() { + return Objects.hash(couponId, couponCode, usageCounter, usageLimit, campaignName); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RedeemableCoupon {\n"); + sb.append(" couponId: ").append(toIndentedString(couponId)).append("\n"); + sb.append(" couponCode: ").append(toIndentedString(couponCode)).append("\n"); + sb.append(" usageCounter: ").append(toIndentedString(usageCounter)).append("\n"); + sb.append(" usageLimit: ").append(toIndentedString(usageLimit)).append("\n"); + sb.append(" campaignName: ").append(toIndentedString(campaignName)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ReduceSelectorStep.java b/src/main/java/one/talon/model/ReduceSelectorStep.java new file mode 100644 index 00000000..769535c2 --- /dev/null +++ b/src/main/java/one/talon/model/ReduceSelectorStep.java @@ -0,0 +1,225 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Aggregates items into a single value. + */ +@ApiModel(description = "Aggregates items into a single value.") + +public class ReduceSelectorStep { + /** + * A step discriminator of type `reduce`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + REDUCE("reduce"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + /** + * The aggregation operator applied to the items produced by the preceding step: - `max`, `min`, and `sum` operate on numeric values. - `count` returns the number of items. - `empty` reports whether the list is empty. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + MAX("max"), + + MIN("min"), + + SUM("sum"), + + COUNT("count"), + + EMPTY("empty"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + + public ReduceSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `reduce`. + * @return type + **/ + @ApiModelProperty(example = "reduce", required = true, value = "A step discriminator of type `reduce`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public ReduceSelectorStep operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The aggregation operator applied to the items produced by the preceding step: - `max`, `min`, and `sum` operate on numeric values. - `count` returns the number of items. - `empty` reports whether the list is empty. + * @return operator + **/ + @ApiModelProperty(example = "sum", required = true, value = "The aggregation operator applied to the items produced by the preceding step: - `max`, `min`, and `sum` operate on numeric values. - `count` returns the number of items. - `empty` reports whether the list is empty. ") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReduceSelectorStep reduceSelectorStep = (ReduceSelectorStep) o; + return Objects.equals(this.type, reduceSelectorStep.type) && + Objects.equals(this.operator, reduceSelectorStep.operator); + } + + @Override + public int hashCode() { + return Objects.hash(type, operator); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReduceSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ReferralCreatedEffectProps.java b/src/main/java/one/talon/model/ReferralCreatedEffectProps.java index 24e84747..8a9db7be 100644 --- a/src/main/java/one/talon/model/ReferralCreatedEffectProps.java +++ b/src/main/java/one/talon/model/ReferralCreatedEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"referralCreated\" effect. This gets triggered whenever a validated rule contained a \"create referral\" effect, and a referral code was created for a customer. See \"createdReferrals\" on the response for all details of this referral code. + * The `referralCreated` effect behaves similarly to [couponCreated](https://docs.talon.one/docs/dev/integration-api/api-effects#couponcreated). If the `friendProfileIntegrationId` parameter is empty, the referral code can be redeemed by anyone. */ -@ApiModel(description = "The properties specific to the \"referralCreated\" effect. This gets triggered whenever a validated rule contained a \"create referral\" effect, and a referral code was created for a customer. See \"createdReferrals\" on the response for all details of this referral code.") +@ApiModel(description = "The `referralCreated` effect behaves similarly to [couponCreated](https://docs.talon.one/docs/dev/integration-api/api-effects#couponcreated). If the `friendProfileIntegrationId` parameter is empty, the referral code can be redeemed by anyone.") public class ReferralCreatedEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -42,10 +42,10 @@ public ReferralCreatedEffectProps value(String value) { } /** - * The referral code that was created. + * The referral code provided in the session. * @return value **/ - @ApiModelProperty(required = true, value = "The referral code that was created.") + @ApiModelProperty(required = true, value = "The referral code provided in the session.") public String getValue() { return value; diff --git a/src/main/java/one/talon/model/RejectCouponEffectProps.java b/src/main/java/one/talon/model/RejectCouponEffectProps.java index 31afe0b2..11ba1b29 100644 --- a/src/main/java/one/talon/model/RejectCouponEffectProps.java +++ b/src/main/java/one/talon/model/RejectCouponEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"rejectCoupon\" effect. This gets triggered whenever the coupon was rejected. See rejectionReason for more info on why. + * This effect indicates that the coupon code supplied couldn't be used. You should handle this effect by informing their user the coupon code is invalid. */ -@ApiModel(description = "The properties specific to the \"rejectCoupon\" effect. This gets triggered whenever the coupon was rejected. See rejectionReason for more info on why.") +@ApiModel(description = "This effect indicates that the coupon code supplied couldn't be used. You should handle this effect by informing their user the coupon code is invalid.") public class RejectCouponEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -84,10 +84,10 @@ public RejectCouponEffectProps rejectionReason(String rejectionReason) { } /** - * The reason why this coupon was rejected. + * The reason why the code was rejected. - `CampaignLimitReached`: The campaign-wide coupon code redemption limit has been reached. - `CouponExpired`: The coupon is expired. - `CouponLimitReached`: The coupon redemption limit or a campaign budget was reached. - `CouponNotFound`: The coupon code is incorrect. - `CouponPartOfNotRunningCampaign`: The campaign the coupon belongs to is currently not active. The campaignId field contains the ID of that campaign. - `CouponRecipientDoesNotMatch`: The given coupon value does not match the recipient or the coupon is linked to a `recipientIntegrationID` but there is no profile in the session. - `CouponRejectedByCondition`: Other conditions failed in the rule or all conditions passed but the `Coupon code is valid` condition is not present. - `CouponStartDateInFuture`: The coupon isn't active yet. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` cannot be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific coupon redemption limit has been reached. - `CouponPartOfNotTriggeredCampaign`: The campaign the coupon belongs to was not triggered during evaluation (an exclusive or stackable campaign). The `campaignId` field contains the ID of that campaign. - `CouponReservationRequired`: The coupon's `isReservationMandatory` property is `true`, but the profile does not have a reservation. - `ProfileRequired`: The coupon's `isReservationMandatory` property is `true` or a [campaign profile budget](https://docs.talon.one/docs/product/campaigns/settings/manage-campaign-budgets) was set, but no profile exists in the session. * @return rejectionReason **/ - @ApiModelProperty(required = true, value = "The reason why this coupon was rejected.") + @ApiModelProperty(required = true, value = "The reason why the code was rejected. - `CampaignLimitReached`: The campaign-wide coupon code redemption limit has been reached. - `CouponExpired`: The coupon is expired. - `CouponLimitReached`: The coupon redemption limit or a campaign budget was reached. - `CouponNotFound`: The coupon code is incorrect. - `CouponPartOfNotRunningCampaign`: The campaign the coupon belongs to is currently not active. The campaignId field contains the ID of that campaign. - `CouponRecipientDoesNotMatch`: The given coupon value does not match the recipient or the coupon is linked to a `recipientIntegrationID` but there is no profile in the session. - `CouponRejectedByCondition`: Other conditions failed in the rule or all conditions passed but the `Coupon code is valid` condition is not present. - `CouponStartDateInFuture`: The coupon isn't active yet. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` cannot be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific coupon redemption limit has been reached. - `CouponPartOfNotTriggeredCampaign`: The campaign the coupon belongs to was not triggered during evaluation (an exclusive or stackable campaign). The `campaignId` field contains the ID of that campaign. - `CouponReservationRequired`: The coupon's `isReservationMandatory` property is `true`, but the profile does not have a reservation. - `ProfileRequired`: The coupon's `isReservationMandatory` property is `true` or a [campaign profile budget](https://docs.talon.one/docs/product/campaigns/settings/manage-campaign-budgets) was set, but no profile exists in the session.") public String getRejectionReason() { return rejectionReason; @@ -175,11 +175,11 @@ public RejectCouponEffectProps campaignExclusionReason(String campaignExclusionR } /** - * The reason why the campaign was not applied. + * The reason why the campaign the coupon belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and coupon conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the coupon is part of an archived campaign. * @return campaignExclusionReason **/ @javax.annotation.Nullable - @ApiModelProperty(example = "CampaignGaveLowerDiscount", value = "The reason why the campaign was not applied.") + @ApiModelProperty(example = "CampaignGaveLowerDiscount", value = "The reason why the campaign the coupon belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and coupon conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the coupon is part of an archived campaign.") public String getCampaignExclusionReason() { return campaignExclusionReason; diff --git a/src/main/java/one/talon/model/RejectReferralEffectProps.java b/src/main/java/one/talon/model/RejectReferralEffectProps.java index c2229a49..31d3563f 100644 --- a/src/main/java/one/talon/model/RejectReferralEffectProps.java +++ b/src/main/java/one/talon/model/RejectReferralEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"rejectReferral\" effect. This gets triggered whenever the referral code was rejected. See rejectionReason for more info on why. + * This effect indicates that the provided referral code is invalid. */ -@ApiModel(description = "The properties specific to the \"rejectReferral\" effect. This gets triggered whenever the referral code was rejected. See rejectionReason for more info on why.") +@ApiModel(description = "This effect indicates that the provided referral code is invalid.") public class RejectReferralEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -62,10 +62,10 @@ public RejectReferralEffectProps value(String value) { } /** - * The referral code that was rejected. + * The referral code that was rejected * @return value **/ - @ApiModelProperty(required = true, value = "The referral code that was rejected.") + @ApiModelProperty(required = true, value = "The referral code that was rejected") public String getValue() { return value; @@ -84,10 +84,10 @@ public RejectReferralEffectProps rejectionReason(String rejectionReason) { } /** - * The reason why this referral code was rejected. + * The reason why the code was rejected. - `AdvocateNotFound`: The advocate was not found. - `CampaignLimitReached`: The campaign-wide referral code redemption limit has been reached. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` can not be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific referral code redemption limit has been reached. - `ReferralCustomerAlreadyReferred`: The friend is already referred. - `ReferralExpired`: The transferred referral code is expired. - `ReferralLimitReached`: The referral code redemption limit has been reached. - `ReferralNotFound`: The transferred referral code is wrong. - `ReferralPartOfNotRunningCampaign`: The campaign the referral code belongs to is currently not active. The campaign ID field shows the ID of that campaign. - `ReferralRecipientDoesNotMatch`: The given referral code value does not match the recipient. - `ReferralRecipientIdSameAsAdvocate`: The recipient (friend) has the same id as the advocate. - `ReferralRejectedByCondition`: The referral code is valid and in an active campaign, but there were other conditions in that campaign's rules that were not met. - `ReferralStartDateInFuture`: The transferred referral code isn't active yet. - `ReferralPartOfNotTriggeredCampaign`: The campaign the referral code belongs to was not triggered during evaluation (an exclusive or stackable campaign). The campaign ID field shows the ID of that campaign. * @return rejectionReason **/ - @ApiModelProperty(required = true, value = "The reason why this referral code was rejected.") + @ApiModelProperty(required = true, value = "The reason why the code was rejected. - `AdvocateNotFound`: The advocate was not found. - `CampaignLimitReached`: The campaign-wide referral code redemption limit has been reached. - `EffectCouldNotBeApplied`: One of the effects in the campaign wasn't applied because a limit for that effect was reached (most common use case will be `setDiscount` can not be applied because a discount limit is reached). - `ProfileLimitReached`: The profile-specific referral code redemption limit has been reached. - `ReferralCustomerAlreadyReferred`: The friend is already referred. - `ReferralExpired`: The transferred referral code is expired. - `ReferralLimitReached`: The referral code redemption limit has been reached. - `ReferralNotFound`: The transferred referral code is wrong. - `ReferralPartOfNotRunningCampaign`: The campaign the referral code belongs to is currently not active. The campaign ID field shows the ID of that campaign. - `ReferralRecipientDoesNotMatch`: The given referral code value does not match the recipient. - `ReferralRecipientIdSameAsAdvocate`: The recipient (friend) has the same id as the advocate. - `ReferralRejectedByCondition`: The referral code is valid and in an active campaign, but there were other conditions in that campaign's rules that were not met. - `ReferralStartDateInFuture`: The transferred referral code isn't active yet. - `ReferralPartOfNotTriggeredCampaign`: The campaign the referral code belongs to was not triggered during evaluation (an exclusive or stackable campaign). The campaign ID field shows the ID of that campaign.") public String getRejectionReason() { return rejectionReason; @@ -175,11 +175,11 @@ public RejectReferralEffectProps campaignExclusionReason(String campaignExclusio } /** - * The reason why the campaign was not applied. + * The reason why the campaign the referral belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and referral conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the referral is part of an archived campaign. * @return campaignExclusionReason **/ @javax.annotation.Nullable - @ApiModelProperty(example = "CampaignGaveLowerDiscount", value = "The reason why the campaign was not applied.") + @ApiModelProperty(example = "CampaignGaveLowerDiscount", value = "The reason why the campaign the referral belongs to was excluded during [campaign evaluation](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation), when `rejectionReason` was `CouponPartOfNotTriggeredCampaign`. Its possible values are: - `CampaignGaveLowerDiscount`: The required campaign and referral conditions were met, but another campaign in a [Highest discount value](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group offered a higher discount value. - `CampaignIsNotFirst`: The campaign was not evaluated because another campaign in a [First campaign](https://docs.talon.one/docs/product/applications/manage-campaign-evaluation#set-campaign-evaluation-mode) group was picked and evaluated first. - `CampaignNotInEvaluationSet`: The campaign did not meet other evaluation requirements, for example, because the referral is part of an archived campaign.") public String getCampaignExclusionReason() { return campaignExclusionReason; diff --git a/src/main/java/one/talon/model/RemoveFromAudienceEffectProps.java b/src/main/java/one/talon/model/RemoveFromAudienceEffectProps.java index aeeac3a6..f9353ea8 100644 --- a/src/main/java/one/talon/model/RemoveFromAudienceEffectProps.java +++ b/src/main/java/one/talon/model/RemoveFromAudienceEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"removeFromAudience\" effect. This gets triggered whenever a validated rule contains a \"removeFromAudience\" effect. + * This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Remove customer from an audience** selected is validated. It indicates that a customer was removed from an audience and is returned when a customer session is opened, updated, or closed. */ -@ApiModel(description = "The properties specific to the \"removeFromAudience\" effect. This gets triggered whenever a validated rule contains a \"removeFromAudience\" effect.") +@ApiModel(description = "This effect is triggered when a rule containing an [Update audience](https://docs.talon.one/docs/product/rules/effects/use-effects#update-an-audience) effect with **Remove customer from an audience** selected is validated. It indicates that a customer was removed from an audience and is returned when a customer session is opened, updated, or closed.") public class RemoveFromAudienceEffectProps { public static final String SERIALIZED_NAME_AUDIENCE_ID = "audienceId"; diff --git a/src/main/java/one/talon/model/ReserveCouponBlock.java b/src/main/java/one/talon/model/ReserveCouponBlock.java new file mode 100644 index 00000000..24cb6dc9 --- /dev/null +++ b/src/main/java/one/talon/model/ReserveCouponBlock.java @@ -0,0 +1,141 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A block that reserve a coupon during a customer session. + */ +@ApiModel(description = "A block that reserve a coupon during a customer session.") + +public class ReserveCouponBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public ReserveCouponBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReserveCouponBlock reserveCouponBlock = (ReserveCouponBlock) o; + return Objects.equals(this.id, reserveCouponBlock.id) && + Objects.equals(this.type, reserveCouponBlock.type) && + Objects.equals(this.tags, reserveCouponBlock.tags); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReserveCouponBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ReserveCouponEffectProps.java b/src/main/java/one/talon/model/ReserveCouponEffectProps.java index d198faed..ef839d62 100644 --- a/src/main/java/one/talon/model/ReserveCouponEffectProps.java +++ b/src/main/java/one/talon/model/ReserveCouponEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"reserveCoupon\" effect. This gets triggered whenever a validated rule contained a \"reserve coupon\" effect. This reserves the coupon currently on scope to the profile on scope. + * This effect indicates that the given coupon code was reserved for the given customer. Talon.One provides soft and hard reservations. For more information, see [Reserve a coupon code](https://docs.talon.one/docs/product/rules/effects/use-effects#reserve-a-coupon-code). */ -@ApiModel(description = "The properties specific to the \"reserveCoupon\" effect. This gets triggered whenever a validated rule contained a \"reserve coupon\" effect. This reserves the coupon currently on scope to the profile on scope.") +@ApiModel(description = "This effect indicates that the given coupon code was reserved for the given customer. Talon.One provides soft and hard reservations. For more information, see [Reserve a coupon code](https://docs.talon.one/docs/product/rules/effects/use-effects#reserve-a-coupon-code).") public class ReserveCouponEffectProps { public static final String SERIALIZED_NAME_COUPON_VALUE = "couponValue"; @@ -50,10 +50,10 @@ public ReserveCouponEffectProps couponValue(String couponValue) { } /** - * The value of the coupon currently on scope. + * The coupon code that was created. * @return couponValue **/ - @ApiModelProperty(required = true, value = "The value of the coupon currently on scope.") + @ApiModelProperty(required = true, value = "The coupon code that was created.") public String getCouponValue() { return couponValue; @@ -72,10 +72,10 @@ public ReserveCouponEffectProps profileIntegrationId(String profileIntegrationId } /** - * The ID of this customer profile in the third-party integration. + * The integration identifier of the customer for whom this coupon was reserved. * @return profileIntegrationId **/ - @ApiModelProperty(required = true, value = "The ID of this customer profile in the third-party integration.") + @ApiModelProperty(required = true, value = "The integration identifier of the customer for whom this coupon was reserved.") public String getProfileIntegrationId() { return profileIntegrationId; diff --git a/src/main/java/one/talon/model/ResponseContentObject.java b/src/main/java/one/talon/model/ResponseContentObject.java index e4ccbcc1..5c881000 100644 --- a/src/main/java/one/talon/model/ResponseContentObject.java +++ b/src/main/java/one/talon/model/ResponseContentObject.java @@ -46,7 +46,13 @@ public enum ResponseContentEnum { AWARDEDGIVEAWAYS("awardedGiveaways"), - RULEFAILUREREASONS("ruleFailureReasons"); + RULEFAILUREREASONS("ruleFailureReasons"), + + CAMPAIGNELIGIBILITY("campaignEligibility"), + + ACHIEVEMENTS("achievements"), + + UNLOCKEDREWARDS("unlockedRewards"); private String value; diff --git a/src/main/java/one/talon/model/ReverseSelectorStep.java b/src/main/java/one/talon/model/ReverseSelectorStep.java new file mode 100644 index 00000000..71c864a4 --- /dev/null +++ b/src/main/java/one/talon/model/ReverseSelectorStep.java @@ -0,0 +1,144 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Reverses the order of the items. + */ +@ApiModel(description = "Reverses the order of the items.") + +public class ReverseSelectorStep { + /** + * A step discriminator of type `reverse`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + REVERSE("reverse"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + + public ReverseSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `reverse`. + * @return type + **/ + @ApiModelProperty(example = "reverse", required = true, value = "A step discriminator of type `reverse`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReverseSelectorStep reverseSelectorStep = (ReverseSelectorStep) o; + return Objects.equals(this.type, reverseSelectorStep.type); + } + + @Override + public int hashCode() { + return Objects.hash(type); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReverseSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ReviewRisksRequest.java b/src/main/java/one/talon/model/ReviewRisksRequest.java new file mode 100644 index 00000000..734104d8 --- /dev/null +++ b/src/main/java/one/talon/model/ReviewRisksRequest.java @@ -0,0 +1,105 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * ReviewRisksRequest + */ + +public class ReviewRisksRequest { + public static final String SERIALIZED_NAME_RISK_IDS = "riskIds"; + @SerializedName(SERIALIZED_NAME_RISK_IDS) + private List riskIds = new ArrayList(); + + + public ReviewRisksRequest riskIds(List riskIds) { + + this.riskIds = riskIds; + return this; + } + + public ReviewRisksRequest addRiskIdsItem(Long riskIdsItem) { + this.riskIds.add(riskIdsItem); + return this; + } + + /** + * The IDs of the risks to move to `In review` status. + * @return riskIds + **/ + @ApiModelProperty(example = "[1, 2, 3]", required = true, value = "The IDs of the risks to move to `In review` status.") + + public List getRiskIds() { + return riskIds; + } + + + public void setRiskIds(List riskIds) { + this.riskIds = riskIds; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReviewRisksRequest reviewRisksRequest = (ReviewRisksRequest) o; + return Objects.equals(this.riskIds, reviewRisksRequest.riskIds); + } + + @Override + public int hashCode() { + return Objects.hash(riskIds); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReviewRisksRequest {\n"); + sb.append(" riskIds: ").append(toIndentedString(riskIds)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RevisionVersion.java b/src/main/java/one/talon/model/RevisionVersion.java index 20c69034..1809b3be 100644 --- a/src/main/java/one/talon/model/RevisionVersion.java +++ b/src/main/java/one/talon/model/RevisionVersion.java @@ -125,7 +125,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/Reward.java b/src/main/java/one/talon/model/Reward.java index 6fdb18b9..c61a0cb7 100644 --- a/src/main/java/one/talon/model/Reward.java +++ b/src/main/java/one/talon/model/Reward.java @@ -25,6 +25,9 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; import org.threeten.bp.OffsetDateTime; /** @@ -64,6 +67,26 @@ public class Reward { @SerializedName(SERIALIZED_NAME_SANDBOX) private Boolean sandbox; + public static final String SERIALIZED_NAME_ELIGIBILITY_CONDITIONS = "eligibilityConditions"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY_CONDITIONS) + private Rule eligibilityConditions; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private Rule rule; + + public static final String SERIALIZED_NAME_BINDINGS = "bindings"; + @SerializedName(SERIALIZED_NAME_BINDINGS) + private List bindings = null; + + public static final String SERIALIZED_NAME_POINTS_REQUIRED = "pointsRequired"; + @SerializedName(SERIALIZED_NAME_POINTS_REQUIRED) + private List pointsRequired = null; + + public static final String SERIALIZED_NAME_MODIFIED = "modified"; + @SerializedName(SERIALIZED_NAME_MODIFIED) + private OffsetDateTime modified; + /** * The status of the reward. */ @@ -298,6 +321,137 @@ public void setSandbox(Boolean sandbox) { } + public Reward eligibilityConditions(Rule eligibilityConditions) { + + this.eligibilityConditions = eligibilityConditions; + return this; + } + + /** + * Get eligibilityConditions + * @return eligibilityConditions + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getEligibilityConditions() { + return eligibilityConditions; + } + + + public void setEligibilityConditions(Rule eligibilityConditions) { + this.eligibilityConditions = eligibilityConditions; + } + + + public Reward rule(Rule rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getRule() { + return rule; + } + + + public void setRule(Rule rule) { + this.rule = rule; + } + + + public Reward bindings(List bindings) { + + this.bindings = bindings; + return this; + } + + public Reward addBindingsItem(Binding bindingsItem) { + if (this.bindings == null) { + this.bindings = new ArrayList(); + } + this.bindings.add(bindingsItem); + return this; + } + + /** + * A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. + * @return bindings + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[]", value = "A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules.") + + public List getBindings() { + return bindings; + } + + + public void setBindings(List bindings) { + this.bindings = bindings; + } + + + public Reward pointsRequired(List pointsRequired) { + + this.pointsRequired = pointsRequired; + return this; + } + + public Reward addPointsRequiredItem(RewardPointsRequired pointsRequiredItem) { + if (this.pointsRequired == null) { + this.pointsRequired = new ArrayList(); + } + this.pointsRequired.add(pointsRequiredItem); + return this; + } + + /** + * The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. + * @return pointsRequired + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** When creating a reward, the `id` of each entry is ignored and a new entry is always created. ") + + public List getPointsRequired() { + return pointsRequired; + } + + + public void setPointsRequired(List pointsRequired) { + this.pointsRequired = pointsRequired; + } + + + public Reward modified(OffsetDateTime modified) { + + this.modified = modified; + return this; + } + + /** + * The timestamp when the reward was last updated in RFC3339 format. + * @return modified + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The timestamp when the reward was last updated in RFC3339 format.") + + public OffsetDateTime getModified() { + return modified; + } + + + public void setModified(OffsetDateTime modified) { + this.modified = modified; + } + + public Reward status(StatusEnum status) { this.status = status; @@ -337,12 +491,17 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.description, reward.description) && Objects.equals(this.applicationIds, reward.applicationIds) && Objects.equals(this.sandbox, reward.sandbox) && + Objects.equals(this.eligibilityConditions, reward.eligibilityConditions) && + Objects.equals(this.rule, reward.rule) && + Objects.equals(this.bindings, reward.bindings) && + Objects.equals(this.pointsRequired, reward.pointsRequired) && + Objects.equals(this.modified, reward.modified) && Objects.equals(this.status, reward.status); } @Override public int hashCode() { - return Objects.hash(id, created, accountId, name, apiName, description, applicationIds, sandbox, status); + return Objects.hash(id, created, accountId, name, apiName, description, applicationIds, sandbox, eligibilityConditions, rule, bindings, pointsRequired, modified, status); } @@ -358,6 +517,11 @@ public String toString() { sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" applicationIds: ").append(toIndentedString(applicationIds)).append("\n"); sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); + sb.append(" eligibilityConditions: ").append(toIndentedString(eligibilityConditions)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" bindings: ").append(toIndentedString(bindings)).append("\n"); + sb.append(" pointsRequired: ").append(toIndentedString(pointsRequired)).append("\n"); + sb.append(" modified: ").append(toIndentedString(modified)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/RewardCatalogItem.java b/src/main/java/one/talon/model/RewardCatalogItem.java new file mode 100644 index 00000000..82b52d96 --- /dev/null +++ b/src/main/java/one/talon/model/RewardCatalogItem.java @@ -0,0 +1,255 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardEligibility; +import one.talon.model.RewardPointsRequired; +import one.talon.model.RuleMetadata; + +/** + * A reward returned by the rewards catalog Integration API endpoint. + */ +@ApiModel(description = "A reward returned by the rewards catalog Integration API endpoint.") + +public class RewardCatalogItem { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_POINTS_REQUIRED = "pointsRequired"; + @SerializedName(SERIALIZED_NAME_POINTS_REQUIRED) + private List pointsRequired = null; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private RuleMetadata rule; + + public static final String SERIALIZED_NAME_ELIGIBILITY = "eligibility"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY) + private RewardEligibility eligibility; + + + public RewardCatalogItem id(Long id) { + + this.id = id; + return this; + } + + /** + * The unique ID of the reward. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The unique ID of the reward.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RewardCatalogItem name(String name) { + + this.name = name; + return this; + } + + /** + * The customer-facing name of the reward. + * @return name + **/ + @ApiModelProperty(example = "10% Off Coupon", required = true, value = "The customer-facing name of the reward.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public RewardCatalogItem description(String description) { + + this.description = description; + return this; + } + + /** + * The customer-facing description of the reward. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Applies to next order", value = "The customer-facing description of the reward.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public RewardCatalogItem pointsRequired(List pointsRequired) { + + this.pointsRequired = pointsRequired; + return this; + } + + public RewardCatalogItem addPointsRequiredItem(RewardPointsRequired pointsRequiredItem) { + if (this.pointsRequired == null) { + this.pointsRequired = new ArrayList(); + } + this.pointsRequired.add(pointsRequiredItem); + return this; + } + + /** + * The loyalty points required to activate the reward. + * @return pointsRequired + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The loyalty points required to activate the reward.") + + public List getPointsRequired() { + return pointsRequired; + } + + + public void setPointsRequired(List pointsRequired) { + this.pointsRequired = pointsRequired; + } + + + public RewardCatalogItem rule(RuleMetadata rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @ApiModelProperty(required = true, value = "") + + public RuleMetadata getRule() { + return rule; + } + + + public void setRule(RuleMetadata rule) { + this.rule = rule; + } + + + public RewardCatalogItem eligibility(RewardEligibility eligibility) { + + this.eligibility = eligibility; + return this; + } + + /** + * Get eligibility + * @return eligibility + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public RewardEligibility getEligibility() { + return eligibility; + } + + + public void setEligibility(RewardEligibility eligibility) { + this.eligibility = eligibility; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardCatalogItem rewardCatalogItem = (RewardCatalogItem) o; + return Objects.equals(this.id, rewardCatalogItem.id) && + Objects.equals(this.name, rewardCatalogItem.name) && + Objects.equals(this.description, rewardCatalogItem.description) && + Objects.equals(this.pointsRequired, rewardCatalogItem.pointsRequired) && + Objects.equals(this.rule, rewardCatalogItem.rule) && + Objects.equals(this.eligibility, rewardCatalogItem.eligibility); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, description, pointsRequired, rule, eligibility); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardCatalogItem {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" pointsRequired: ").append(toIndentedString(pointsRequired)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" eligibility: ").append(toIndentedString(eligibility)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RewardEligibility.java b/src/main/java/one/talon/model/RewardEligibility.java new file mode 100644 index 00000000..b90210f2 --- /dev/null +++ b/src/main/java/one/talon/model/RewardEligibility.java @@ -0,0 +1,139 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardEligibilityFailureDetails; + +/** + * The customer's eligibility for the reward based on the specified customer profile or loyalty card. + */ +@ApiModel(description = "The customer's eligibility for the reward based on the specified customer profile or loyalty card.") + +public class RewardEligibility { + public static final String SERIALIZED_NAME_PASSED = "passed"; + @SerializedName(SERIALIZED_NAME_PASSED) + private Boolean passed; + + public static final String SERIALIZED_NAME_DETAILS = "details"; + @SerializedName(SERIALIZED_NAME_DETAILS) + private List details = null; + + + public RewardEligibility passed(Boolean passed) { + + this.passed = passed; + return this; + } + + /** + * Indicates whether the customer is eligible for the reward. + * @return passed + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates whether the customer is eligible for the reward.") + + public Boolean getPassed() { + return passed; + } + + + public void setPassed(Boolean passed) { + this.passed = passed; + } + + + public RewardEligibility details(List details) { + + this.details = details; + return this; + } + + public RewardEligibility addDetailsItem(RewardEligibilityFailureDetails detailsItem) { + if (this.details == null) { + this.details = new ArrayList(); + } + this.details.add(detailsItem); + return this; + } + + /** + * The reasons the customer is not eligible for the reward. Empty when `passed` is `true`. + * @return details + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The reasons the customer is not eligible for the reward. Empty when `passed` is `true`.") + + public List getDetails() { + return details; + } + + + public void setDetails(List details) { + this.details = details; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardEligibility rewardEligibility = (RewardEligibility) o; + return Objects.equals(this.passed, rewardEligibility.passed) && + Objects.equals(this.details, rewardEligibility.details); + } + + @Override + public int hashCode() { + return Objects.hash(passed, details); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardEligibility {\n"); + sb.append(" passed: ").append(toIndentedString(passed)).append("\n"); + sb.append(" details: ").append(toIndentedString(details)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RewardEligibilityFailureDetails.java b/src/main/java/one/talon/model/RewardEligibilityFailureDetails.java new file mode 100644 index 00000000..847583d4 --- /dev/null +++ b/src/main/java/one/talon/model/RewardEligibilityFailureDetails.java @@ -0,0 +1,179 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The details about why the customer is not eligible for the reward. + */ +@ApiModel(description = "The details about why the customer is not eligible for the reward.") + +public class RewardEligibilityFailureDetails { + /** + * A code identifying why the customer is not eligible for the reward. + */ + @JsonAdapter(FailureCodeEnum.Adapter.class) + public enum FailureCodeEnum { + CONDITION_NOT_MET("CONDITION_NOT_MET"), + + INSUFFICIENT_BALANCE("INSUFFICIENT_BALANCE"), + + CARD_REQUIRED("CARD_REQUIRED"), + + PROFILE_REQUIRED("PROFILE_REQUIRED"); + + private String value; + + FailureCodeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static FailureCodeEnum fromValue(String value) { + for (FailureCodeEnum b : FailureCodeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final FailureCodeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public FailureCodeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return FailureCodeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_FAILURE_CODE = "failureCode"; + @SerializedName(SERIALIZED_NAME_FAILURE_CODE) + private FailureCodeEnum failureCode; + + public static final String SERIALIZED_NAME_CONDITION_INDEX = "conditionIndex"; + @SerializedName(SERIALIZED_NAME_CONDITION_INDEX) + private Long conditionIndex; + + + public RewardEligibilityFailureDetails failureCode(FailureCodeEnum failureCode) { + + this.failureCode = failureCode; + return this; + } + + /** + * A code identifying why the customer is not eligible for the reward. + * @return failureCode + **/ + @ApiModelProperty(example = "CONDITION_NOT_MET", required = true, value = "A code identifying why the customer is not eligible for the reward.") + + public FailureCodeEnum getFailureCode() { + return failureCode; + } + + + public void setFailureCode(FailureCodeEnum failureCode) { + this.failureCode = failureCode; + } + + + public RewardEligibilityFailureDetails conditionIndex(Long conditionIndex) { + + this.conditionIndex = conditionIndex; + return this; + } + + /** + * The index of the eligibility condition that the customer did not meet. Only applicable when `failureCode` is `CONDITION_NOT_MET`. + * @return conditionIndex + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "0", value = "The index of the eligibility condition that the customer did not meet. Only applicable when `failureCode` is `CONDITION_NOT_MET`.") + + public Long getConditionIndex() { + return conditionIndex; + } + + + public void setConditionIndex(Long conditionIndex) { + this.conditionIndex = conditionIndex; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardEligibilityFailureDetails rewardEligibilityFailureDetails = (RewardEligibilityFailureDetails) o; + return Objects.equals(this.failureCode, rewardEligibilityFailureDetails.failureCode) && + Objects.equals(this.conditionIndex, rewardEligibilityFailureDetails.conditionIndex); + } + + @Override + public int hashCode() { + return Objects.hash(failureCode, conditionIndex); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardEligibilityFailureDetails {\n"); + sb.append(" failureCode: ").append(toIndentedString(failureCode)).append("\n"); + sb.append(" conditionIndex: ").append(toIndentedString(conditionIndex)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RewardPointsRequired.java b/src/main/java/one/talon/model/RewardPointsRequired.java new file mode 100644 index 00000000..161e6d81 --- /dev/null +++ b/src/main/java/one/talon/model/RewardPointsRequired.java @@ -0,0 +1,186 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * The loyalty points required to activate a reward. + */ +@ApiModel(description = "The loyalty points required to activate a reward.") + +public class RewardPointsRequired { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_AMOUNT = "amount"; + @SerializedName(SERIALIZED_NAME_AMOUNT) + private BigDecimal amount; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_SUBLEDGER_ID = "subledgerId"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER_ID) + private String subledgerId; + + + public RewardPointsRequired id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the `pointsRequired` entry. When updating a reward, include this property to update an existing entry. Omit it to create a new one. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "1", value = "The ID of the `pointsRequired` entry. When updating a reward, include this property to update an existing entry. Omit it to create a new one. ") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RewardPointsRequired amount(BigDecimal amount) { + + this.amount = amount; + return this; + } + + /** + * The number of loyalty points required to activate the reward. + * minimum: 0 + * @return amount + **/ + @ApiModelProperty(example = "500.0", required = true, value = "The number of loyalty points required to activate the reward.") + + public BigDecimal getAmount() { + return amount; + } + + + public void setAmount(BigDecimal amount) { + this.amount = amount; + } + + + public RewardPointsRequired loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * The ID of the associated loyalty program. + * @return loyaltyProgramId + **/ + @ApiModelProperty(example = "10", required = true, value = "The ID of the associated loyalty program.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public RewardPointsRequired subledgerId(String subledgerId) { + + this.subledgerId = subledgerId; + return this; + } + + /** + * The ID of the subledger within the loyalty program from which points are deducted when activating the reward. To specify the main ledger, provide an empty string (\"\"). + * @return subledgerId + **/ + @ApiModelProperty(example = "mysubledger", required = true, value = "The ID of the subledger within the loyalty program from which points are deducted when activating the reward. To specify the main ledger, provide an empty string (\"\"). ") + + public String getSubledgerId() { + return subledgerId; + } + + + public void setSubledgerId(String subledgerId) { + this.subledgerId = subledgerId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardPointsRequired rewardPointsRequired = (RewardPointsRequired) o; + return Objects.equals(this.id, rewardPointsRequired.id) && + Objects.equals(this.amount, rewardPointsRequired.amount) && + Objects.equals(this.loyaltyProgramId, rewardPointsRequired.loyaltyProgramId) && + Objects.equals(this.subledgerId, rewardPointsRequired.subledgerId); + } + + @Override + public int hashCode() { + return Objects.hash(id, amount, loyaltyProgramId, subledgerId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardPointsRequired {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" amount: ").append(toIndentedString(amount)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" subledgerId: ").append(toIndentedString(subledgerId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RewardUnlockRejection.java b/src/main/java/one/talon/model/RewardUnlockRejection.java new file mode 100644 index 00000000..5be0cacf --- /dev/null +++ b/src/main/java/one/talon/model/RewardUnlockRejection.java @@ -0,0 +1,135 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RuleFailureReason; + +/** + * Returned when a reward unlock is rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. + */ +@ApiModel(description = "Returned when a reward unlock is rejected by the Rule Engine, for example because the customer already unlocked this reward, the customer has insufficient points, or the reward's eligibility conditions are not met. ") + +public class RewardUnlockRejection { + public static final String SERIALIZED_NAME_MESSAGE = "message"; + @SerializedName(SERIALIZED_NAME_MESSAGE) + private String message; + + public static final String SERIALIZED_NAME_RULE_FAILURE_REASONS = "ruleFailureReasons"; + @SerializedName(SERIALIZED_NAME_RULE_FAILURE_REASONS) + private List ruleFailureReasons = new ArrayList(); + + + public RewardUnlockRejection message(String message) { + + this.message = message; + return this; + } + + /** + * A human-readable summary of why the reward unlock was rejected. + * @return message + **/ + @ApiModelProperty(example = "reward unlock rejected", required = true, value = "A human-readable summary of why the reward unlock was rejected.") + + public String getMessage() { + return message; + } + + + public void setMessage(String message) { + this.message = message; + } + + + public RewardUnlockRejection ruleFailureReasons(List ruleFailureReasons) { + + this.ruleFailureReasons = ruleFailureReasons; + return this; + } + + public RewardUnlockRejection addRuleFailureReasonsItem(RuleFailureReason ruleFailureReasonsItem) { + this.ruleFailureReasons.add(ruleFailureReasonsItem); + return this; + } + + /** + * The reasons why the reward could not be unlocked. + * @return ruleFailureReasons + **/ + @ApiModelProperty(required = true, value = "The reasons why the reward could not be unlocked.") + + public List getRuleFailureReasons() { + return ruleFailureReasons; + } + + + public void setRuleFailureReasons(List ruleFailureReasons) { + this.ruleFailureReasons = ruleFailureReasons; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardUnlockRejection rewardUnlockRejection = (RewardUnlockRejection) o; + return Objects.equals(this.message, rewardUnlockRejection.message) && + Objects.equals(this.ruleFailureReasons, rewardUnlockRejection.ruleFailureReasons); + } + + @Override + public int hashCode() { + return Objects.hash(message, ruleFailureReasons); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardUnlockRejection {\n"); + sb.append(" message: ").append(toIndentedString(message)).append("\n"); + sb.append(" ruleFailureReasons: ").append(toIndentedString(ruleFailureReasons)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RewardWithUnlocks.java b/src/main/java/one/talon/model/RewardWithUnlocks.java new file mode 100644 index 00000000..56689fcc --- /dev/null +++ b/src/main/java/one/talon/model/RewardWithUnlocks.java @@ -0,0 +1,253 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CustomerReward; +import one.talon.model.RuleMetadata; + +/** + * A reward and details of each time a customer profile has unlocked it. + */ +@ApiModel(description = "A reward and details of each time a customer profile has unlocked it.") + +public class RewardWithUnlocks { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private RuleMetadata rule; + + public static final String SERIALIZED_NAME_UNLOCKED = "unlocked"; + @SerializedName(SERIALIZED_NAME_UNLOCKED) + private List unlocked = null; + + + public RewardWithUnlocks id(Long id) { + + this.id = id; + return this; + } + + /** + * The unique ID of the reward. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The unique ID of the reward.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RewardWithUnlocks integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * A unique identifier used to reference the reward in API integrations. + * @return integrationId + **/ + @ApiModelProperty(example = "free-coffee", required = true, value = "A unique identifier used to reference the reward in API integrations.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public RewardWithUnlocks name(String name) { + + this.name = name; + return this; + } + + /** + * The customer-facing name of the reward. + * @return name + **/ + @ApiModelProperty(example = "10% Off Coupon", required = true, value = "The customer-facing name of the reward.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public RewardWithUnlocks description(String description) { + + this.description = description; + return this; + } + + /** + * Customer-facing description of the reward. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Applies to next order", value = "Customer-facing description of the reward.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public RewardWithUnlocks rule(RuleMetadata rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @ApiModelProperty(required = true, value = "") + + public RuleMetadata getRule() { + return rule; + } + + + public void setRule(RuleMetadata rule) { + this.rule = rule; + } + + + public RewardWithUnlocks unlocked(List unlocked) { + + this.unlocked = unlocked; + return this; + } + + public RewardWithUnlocks addUnlockedItem(CustomerReward unlockedItem) { + if (this.unlocked == null) { + this.unlocked = new ArrayList(); + } + this.unlocked.add(unlockedItem); + return this; + } + + /** + * The customer profile's unlocks of this reward that are not yet `used`. + * @return unlocked + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The customer profile's unlocks of this reward that are not yet `used`.") + + public List getUnlocked() { + return unlocked; + } + + + public void setUnlocked(List unlocked) { + this.unlocked = unlocked; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RewardWithUnlocks rewardWithUnlocks = (RewardWithUnlocks) o; + return Objects.equals(this.id, rewardWithUnlocks.id) && + Objects.equals(this.integrationId, rewardWithUnlocks.integrationId) && + Objects.equals(this.name, rewardWithUnlocks.name) && + Objects.equals(this.description, rewardWithUnlocks.description) && + Objects.equals(this.rule, rewardWithUnlocks.rule) && + Objects.equals(this.unlocked, rewardWithUnlocks.unlocked); + } + + @Override + public int hashCode() { + return Objects.hash(id, integrationId, name, description, rule, unlocked); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RewardWithUnlocks {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" unlocked: ").append(toIndentedString(unlocked)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Risk.java b/src/main/java/one/talon/model/Risk.java new file mode 100644 index 00000000..3ac2eecb --- /dev/null +++ b/src/main/java/one/talon/model/Risk.java @@ -0,0 +1,903 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.LocalDate; +import org.threeten.bp.OffsetDateTime; + +/** + * A risk detected by the anomaly detection service for one Application group. + */ +@ApiModel(description = "A risk detected by the anomaly detection service for one Application group.") + +public class Risk { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + public static final String SERIALIZED_NAME_NOTIFICATION_ID = "notificationId"; + @SerializedName(SERIALIZED_NAME_NOTIFICATION_ID) + private Long notificationId; + + public static final String SERIALIZED_NAME_FEATURE_DATE = "featureDate"; + @SerializedName(SERIALIZED_NAME_FEATURE_DATE) + private LocalDate featureDate; + + public static final String SERIALIZED_NAME_GROUP_KEY = "groupKey"; + @SerializedName(SERIALIZED_NAME_GROUP_KEY) + private String groupKey; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + /** + * The triage lifecycle status of this risk. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + ACTIVE("active"), + + IN_REVIEW("in_review"), + + CONFIRMED("confirmed"), + + DISCARDED("discarded"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + /** + * The critical classification bucket of this risk. + */ + @JsonAdapter(CriticalityEnum.Adapter.class) + public enum CriticalityEnum { + CRITICAL("critical"), + + NOT_CRITICAL("not_critical"); + + private String value; + + CriticalityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static CriticalityEnum fromValue(String value) { + for (CriticalityEnum b : CriticalityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final CriticalityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public CriticalityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return CriticalityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_CRITICALITY = "criticality"; + @SerializedName(SERIALIZED_NAME_CRITICALITY) + private CriticalityEnum criticality; + + /** + * The entity type the risk was detected in. + */ + @JsonAdapter(EntityEnum.Adapter.class) + public enum EntityEnum { + PROFILE("customer_profile"), + + SESSION("customer_session"); + + private String value; + + EntityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static EntityEnum fromValue(String value) { + for (EntityEnum b : EntityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final EntityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public EntityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return EntityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private EntityEnum entity; + + /** + * The activity metric the risk was detected in. + */ + @JsonAdapter(ActivityEnum.Adapter.class) + public enum ActivityEnum { + LOYALTY_POINTS_EARNED("loyalty_points_earned"), + + DISCOUNTED_AMOUNT("discounted_amount"), + + COMPLETED_ORDERS("completed_orders"), + + COUPON_ATTEMPTS("coupon_attempts"); + + private String value; + + ActivityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivityEnum fromValue(String value) { + for (ActivityEnum b : ActivityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVITY = "activity"; + @SerializedName(SERIALIZED_NAME_ACTIVITY) + private ActivityEnum activity; + + /** + * The rolling time window of the risk evaluation. + */ + @JsonAdapter(TimeFrameEnum.Adapter.class) + public enum TimeFrameEnum { + _1D("1D"), + + _7D("7D"), + + _30D("30D"); + + private String value; + + TimeFrameEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TimeFrameEnum fromValue(String value) { + for (TimeFrameEnum b : TimeFrameEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TimeFrameEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TimeFrameEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TimeFrameEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TIME_FRAME = "timeFrame"; + @SerializedName(SERIALIZED_NAME_TIME_FRAME) + private TimeFrameEnum timeFrame; + + public static final String SERIALIZED_NAME_REPORTED_DATE = "reportedDate"; + @SerializedName(SERIALIZED_NAME_REPORTED_DATE) + private OffsetDateTime reportedDate; + + public static final String SERIALIZED_NAME_AFFECTED_ENTITY_COUNT = "affectedEntityCount"; + @SerializedName(SERIALIZED_NAME_AFFECTED_ENTITY_COUNT) + private Long affectedEntityCount; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + /** + * The reason this risk was discarded. Only present on discarded risks. + */ + @JsonAdapter(DiscardReasonEnum.Adapter.class) + public enum DiscardReasonEnum { + EXPECTED_BEHAVIOR("expected_behavior"), + + OTHER("other"); + + private String value; + + DiscardReasonEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static DiscardReasonEnum fromValue(String value) { + for (DiscardReasonEnum b : DiscardReasonEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final DiscardReasonEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public DiscardReasonEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return DiscardReasonEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_DISCARD_REASON = "discardReason"; + @SerializedName(SERIALIZED_NAME_DISCARD_REASON) + private DiscardReasonEnum discardReason; + + public static final String SERIALIZED_NAME_STATUS_COMMENT = "statusComment"; + @SerializedName(SERIALIZED_NAME_STATUS_COMMENT) + private String statusComment; + + public static final String SERIALIZED_NAME_STATUS_CHANGED_BY = "statusChangedBy"; + @SerializedName(SERIALIZED_NAME_STATUS_CHANGED_BY) + private Long statusChangedBy; + + public static final String SERIALIZED_NAME_STATUS_CHANGED_AT = "statusChangedAt"; + @SerializedName(SERIALIZED_NAME_STATUS_CHANGED_AT) + private OffsetDateTime statusChangedAt; + + public static final String SERIALIZED_NAME_MODIFIED = "modified"; + @SerializedName(SERIALIZED_NAME_MODIFIED) + private OffsetDateTime modified; + + + public Risk id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of this entity. + * @return id + **/ + @ApiModelProperty(example = "6", required = true, value = "The internal ID of this entity.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public Risk created(OffsetDateTime created) { + + this.created = created; + return this; + } + + /** + * The time this entity was created. + * @return created + **/ + @ApiModelProperty(example = "2020-06-10T09:05:27.993483Z", required = true, value = "The time this entity was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + public void setCreated(OffsetDateTime created) { + this.created = created; + } + + + public Risk notificationId(Long notificationId) { + + this.notificationId = notificationId; + return this; + } + + /** + * The ID of the risk notification rule that flagged this risk. + * @return notificationId + **/ + @ApiModelProperty(example = "3", required = true, value = "The ID of the risk notification rule that flagged this risk.") + + public Long getNotificationId() { + return notificationId; + } + + + public void setNotificationId(Long notificationId) { + this.notificationId = notificationId; + } + + + public Risk featureDate(LocalDate featureDate) { + + this.featureDate = featureDate; + return this; + } + + /** + * The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. + * @return featureDate + **/ + @ApiModelProperty(example = "Fri Jun 05 00:00:00 GMT 2026", required = true, value = "The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. ") + + public LocalDate getFeatureDate() { + return featureDate; + } + + + public void setFeatureDate(LocalDate featureDate) { + this.featureDate = featureDate; + } + + + public Risk groupKey(String groupKey) { + + this.groupKey = groupKey; + return this; + } + + /** + * The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. + * @return groupKey + **/ + @ApiModelProperty(example = "7", required = true, value = "The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. ") + + public String getGroupKey() { + return groupKey; + } + + + public void setGroupKey(String groupKey) { + this.groupKey = groupKey; + } + + + public Risk applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application this risk belongs to. Absent for global metrics. + * @return applicationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The ID of the Application this risk belongs to. Absent for global metrics.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public Risk status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The triage lifecycle status of this risk. + * @return status + **/ + @ApiModelProperty(example = "active", required = true, value = "The triage lifecycle status of this risk.") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + public Risk criticality(CriticalityEnum criticality) { + + this.criticality = criticality; + return this; + } + + /** + * The critical classification bucket of this risk. + * @return criticality + **/ + @ApiModelProperty(example = "critical", required = true, value = "The critical classification bucket of this risk.") + + public CriticalityEnum getCriticality() { + return criticality; + } + + + public void setCriticality(CriticalityEnum criticality) { + this.criticality = criticality; + } + + + public Risk entity(EntityEnum entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type the risk was detected in. + * @return entity + **/ + @ApiModelProperty(example = "customer_profile", required = true, value = "The entity type the risk was detected in.") + + public EntityEnum getEntity() { + return entity; + } + + + public void setEntity(EntityEnum entity) { + this.entity = entity; + } + + + public Risk activity(ActivityEnum activity) { + + this.activity = activity; + return this; + } + + /** + * The activity metric the risk was detected in. + * @return activity + **/ + @ApiModelProperty(example = "discounted_amount", required = true, value = "The activity metric the risk was detected in.") + + public ActivityEnum getActivity() { + return activity; + } + + + public void setActivity(ActivityEnum activity) { + this.activity = activity; + } + + + public Risk timeFrame(TimeFrameEnum timeFrame) { + + this.timeFrame = timeFrame; + return this; + } + + /** + * The rolling time window of the risk evaluation. + * @return timeFrame + **/ + @ApiModelProperty(example = "7D", required = true, value = "The rolling time window of the risk evaluation.") + + public TimeFrameEnum getTimeFrame() { + return timeFrame; + } + + + public void setTimeFrame(TimeFrameEnum timeFrame) { + this.timeFrame = timeFrame; + } + + + public Risk reportedDate(OffsetDateTime reportedDate) { + + this.reportedDate = reportedDate; + return this; + } + + /** + * The time the ML service reported this risk. + * @return reportedDate + **/ + @ApiModelProperty(example = "2026-06-05T06:26:13.698884Z", required = true, value = "The time the ML service reported this risk.") + + public OffsetDateTime getReportedDate() { + return reportedDate; + } + + + public void setReportedDate(OffsetDateTime reportedDate) { + this.reportedDate = reportedDate; + } + + + public Risk affectedEntityCount(Long affectedEntityCount) { + + this.affectedEntityCount = affectedEntityCount; + return this; + } + + /** + * The total number of entities affected by this risk. + * @return affectedEntityCount + **/ + @ApiModelProperty(example = "4437", required = true, value = "The total number of entities affected by this risk.") + + public Long getAffectedEntityCount() { + return affectedEntityCount; + } + + + public void setAffectedEntityCount(Long affectedEntityCount) { + this.affectedEntityCount = affectedEntityCount; + } + + + public Risk description(String description) { + + this.description = description; + return this; + } + + /** + * Human-readable description of the detected anomaly. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Unusual discount usage detected for 4437 customer profiles.", value = "Human-readable description of the detected anomaly.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public Risk discardReason(DiscardReasonEnum discardReason) { + + this.discardReason = discardReason; + return this; + } + + /** + * The reason this risk was discarded. Only present on discarded risks. + * @return discardReason + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "expected_behavior", value = "The reason this risk was discarded. Only present on discarded risks.") + + public DiscardReasonEnum getDiscardReason() { + return discardReason; + } + + + public void setDiscardReason(DiscardReasonEnum discardReason) { + this.discardReason = discardReason; + } + + + public Risk statusComment(String statusComment) { + + this.statusComment = statusComment; + return this; + } + + /** + * The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. + * @return statusComment + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Investigated with the customer and fixed the loyalty rule.", value = "The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. ") + + public String getStatusComment() { + return statusComment; + } + + + public void setStatusComment(String statusComment) { + this.statusComment = statusComment; + } + + + public Risk statusChangedBy(Long statusChangedBy) { + + this.statusChangedBy = statusChangedBy; + return this; + } + + /** + * The ID of the user who performed the latest reclassification action. + * @return statusChangedBy + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The ID of the user who performed the latest reclassification action.") + + public Long getStatusChangedBy() { + return statusChangedBy; + } + + + public void setStatusChangedBy(Long statusChangedBy) { + this.statusChangedBy = statusChangedBy; + } + + + public Risk statusChangedAt(OffsetDateTime statusChangedAt) { + + this.statusChangedAt = statusChangedAt; + return this; + } + + /** + * The time of the latest reclassification action. + * @return statusChangedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2026-06-06T09:12:45Z", value = "The time of the latest reclassification action.") + + public OffsetDateTime getStatusChangedAt() { + return statusChangedAt; + } + + + public void setStatusChangedAt(OffsetDateTime statusChangedAt) { + this.statusChangedAt = statusChangedAt; + } + + + public Risk modified(OffsetDateTime modified) { + + this.modified = modified; + return this; + } + + /** + * Timestamp of the most recent update. + * @return modified + **/ + @ApiModelProperty(example = "2026-06-05T06:26:13.698884Z", required = true, value = "Timestamp of the most recent update.") + + public OffsetDateTime getModified() { + return modified; + } + + + public void setModified(OffsetDateTime modified) { + this.modified = modified; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Risk risk = (Risk) o; + return Objects.equals(this.id, risk.id) && + Objects.equals(this.created, risk.created) && + Objects.equals(this.notificationId, risk.notificationId) && + Objects.equals(this.featureDate, risk.featureDate) && + Objects.equals(this.groupKey, risk.groupKey) && + Objects.equals(this.applicationId, risk.applicationId) && + Objects.equals(this.status, risk.status) && + Objects.equals(this.criticality, risk.criticality) && + Objects.equals(this.entity, risk.entity) && + Objects.equals(this.activity, risk.activity) && + Objects.equals(this.timeFrame, risk.timeFrame) && + Objects.equals(this.reportedDate, risk.reportedDate) && + Objects.equals(this.affectedEntityCount, risk.affectedEntityCount) && + Objects.equals(this.description, risk.description) && + Objects.equals(this.discardReason, risk.discardReason) && + Objects.equals(this.statusComment, risk.statusComment) && + Objects.equals(this.statusChangedBy, risk.statusChangedBy) && + Objects.equals(this.statusChangedAt, risk.statusChangedAt) && + Objects.equals(this.modified, risk.modified); + } + + @Override + public int hashCode() { + return Objects.hash(id, created, notificationId, featureDate, groupKey, applicationId, status, criticality, entity, activity, timeFrame, reportedDate, affectedEntityCount, description, discardReason, statusComment, statusChangedBy, statusChangedAt, modified); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Risk {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" notificationId: ").append(toIndentedString(notificationId)).append("\n"); + sb.append(" featureDate: ").append(toIndentedString(featureDate)).append("\n"); + sb.append(" groupKey: ").append(toIndentedString(groupKey)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" criticality: ").append(toIndentedString(criticality)).append("\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); + sb.append(" timeFrame: ").append(toIndentedString(timeFrame)).append("\n"); + sb.append(" reportedDate: ").append(toIndentedString(reportedDate)).append("\n"); + sb.append(" affectedEntityCount: ").append(toIndentedString(affectedEntityCount)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" discardReason: ").append(toIndentedString(discardReason)).append("\n"); + sb.append(" statusComment: ").append(toIndentedString(statusComment)).append("\n"); + sb.append(" statusChangedBy: ").append(toIndentedString(statusChangedBy)).append("\n"); + sb.append(" statusChangedAt: ").append(toIndentedString(statusChangedAt)).append("\n"); + sb.append(" modified: ").append(toIndentedString(modified)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RiskAffectedEntityItem.java b/src/main/java/one/talon/model/RiskAffectedEntityItem.java new file mode 100644 index 00000000..c2fad70d --- /dev/null +++ b/src/main/java/one/talon/model/RiskAffectedEntityItem.java @@ -0,0 +1,258 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * A single entity flagged as anomalous within a risk. + */ +@ApiModel(description = "A single entity flagged as anomalous within a risk.") + +public class RiskAffectedEntityItem { + public static final String SERIALIZED_NAME_ENTITY_ID = "entityId"; + @SerializedName(SERIALIZED_NAME_ENTITY_ID) + private String entityId; + + public static final String SERIALIZED_NAME_ACTIVITY_VALUE = "activityValue"; + @SerializedName(SERIALIZED_NAME_ACTIVITY_VALUE) + private Double activityValue; + + public static final String SERIALIZED_NAME_THRESHOLD = "threshold"; + @SerializedName(SERIALIZED_NAME_THRESHOLD) + private Double threshold; + + public static final String SERIALIZED_NAME_SEVERITY_RATIO = "severityRatio"; + @SerializedName(SERIALIZED_NAME_SEVERITY_RATIO) + private Double severityRatio; + + /** + * The critical classification bucket of this entity. + */ + @JsonAdapter(CriticalityEnum.Adapter.class) + public enum CriticalityEnum { + CRITICAL("critical"), + + NOT_CRITICAL("not_critical"); + + private String value; + + CriticalityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static CriticalityEnum fromValue(String value) { + for (CriticalityEnum b : CriticalityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final CriticalityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public CriticalityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return CriticalityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_CRITICALITY = "criticality"; + @SerializedName(SERIALIZED_NAME_CRITICALITY) + private CriticalityEnum criticality; + + + public RiskAffectedEntityItem entityId(String entityId) { + + this.entityId = entityId; + return this; + } + + /** + * The integration ID of the affected entity. + * @return entityId + **/ + @ApiModelProperty(example = "174165415", required = true, value = "The integration ID of the affected entity.") + + public String getEntityId() { + return entityId; + } + + + public void setEntityId(String entityId) { + this.entityId = entityId; + } + + + public RiskAffectedEntityItem activityValue(Double activityValue) { + + this.activityValue = activityValue; + return this; + } + + /** + * The observed value of the monitored activity metric for this entity. + * @return activityValue + **/ + @ApiModelProperty(example = "2898.2", required = true, value = "The observed value of the monitored activity metric for this entity.") + + public Double getActivityValue() { + return activityValue; + } + + + public void setActivityValue(Double activityValue) { + this.activityValue = activityValue; + } + + + public RiskAffectedEntityItem threshold(Double threshold) { + + this.threshold = threshold; + return this; + } + + /** + * The anomaly threshold computed for the entity's Application group. + * @return threshold + **/ + @ApiModelProperty(example = "60.0", required = true, value = "The anomaly threshold computed for the entity's Application group.") + + public Double getThreshold() { + return threshold; + } + + + public void setThreshold(Double threshold) { + this.threshold = threshold; + } + + + public RiskAffectedEntityItem severityRatio(Double severityRatio) { + + this.severityRatio = severityRatio; + return this; + } + + /** + * The ratio of the observed value to the threshold. + * @return severityRatio + **/ + @ApiModelProperty(example = "48.3", required = true, value = "The ratio of the observed value to the threshold.") + + public Double getSeverityRatio() { + return severityRatio; + } + + + public void setSeverityRatio(Double severityRatio) { + this.severityRatio = severityRatio; + } + + + public RiskAffectedEntityItem criticality(CriticalityEnum criticality) { + + this.criticality = criticality; + return this; + } + + /** + * The critical classification bucket of this entity. + * @return criticality + **/ + @ApiModelProperty(example = "critical", required = true, value = "The critical classification bucket of this entity.") + + public CriticalityEnum getCriticality() { + return criticality; + } + + + public void setCriticality(CriticalityEnum criticality) { + this.criticality = criticality; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RiskAffectedEntityItem riskAffectedEntityItem = (RiskAffectedEntityItem) o; + return Objects.equals(this.entityId, riskAffectedEntityItem.entityId) && + Objects.equals(this.activityValue, riskAffectedEntityItem.activityValue) && + Objects.equals(this.threshold, riskAffectedEntityItem.threshold) && + Objects.equals(this.severityRatio, riskAffectedEntityItem.severityRatio) && + Objects.equals(this.criticality, riskAffectedEntityItem.criticality); + } + + @Override + public int hashCode() { + return Objects.hash(entityId, activityValue, threshold, severityRatio, criticality); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RiskAffectedEntityItem {\n"); + sb.append(" entityId: ").append(toIndentedString(entityId)).append("\n"); + sb.append(" activityValue: ").append(toIndentedString(activityValue)).append("\n"); + sb.append(" threshold: ").append(toIndentedString(threshold)).append("\n"); + sb.append(" severityRatio: ").append(toIndentedString(severityRatio)).append("\n"); + sb.append(" criticality: ").append(toIndentedString(criticality)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RiskCriticalityUpdate.java b/src/main/java/one/talon/model/RiskCriticalityUpdate.java new file mode 100644 index 00000000..d020a637 --- /dev/null +++ b/src/main/java/one/talon/model/RiskCriticalityUpdate.java @@ -0,0 +1,178 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * RiskCriticalityUpdate + */ + +public class RiskCriticalityUpdate { + public static final String SERIALIZED_NAME_RISK_IDS = "riskIds"; + @SerializedName(SERIALIZED_NAME_RISK_IDS) + private List riskIds = new ArrayList(); + + /** + * The criticality to assign to risks. Only `not_critical` is accepted: critical risks can be reclassified as non-critical, but not the other way around. + */ + @JsonAdapter(CriticalityEnum.Adapter.class) + public enum CriticalityEnum { + NOT_CRITICAL("not_critical"); + + private String value; + + CriticalityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static CriticalityEnum fromValue(String value) { + for (CriticalityEnum b : CriticalityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final CriticalityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public CriticalityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return CriticalityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_CRITICALITY = "criticality"; + @SerializedName(SERIALIZED_NAME_CRITICALITY) + private CriticalityEnum criticality; + + + public RiskCriticalityUpdate riskIds(List riskIds) { + + this.riskIds = riskIds; + return this; + } + + public RiskCriticalityUpdate addRiskIdsItem(Long riskIdsItem) { + this.riskIds.add(riskIdsItem); + return this; + } + + /** + * The IDs of the risks to reclassify. + * @return riskIds + **/ + @ApiModelProperty(example = "[1, 2, 3]", required = true, value = "The IDs of the risks to reclassify.") + + public List getRiskIds() { + return riskIds; + } + + + public void setRiskIds(List riskIds) { + this.riskIds = riskIds; + } + + + public RiskCriticalityUpdate criticality(CriticalityEnum criticality) { + + this.criticality = criticality; + return this; + } + + /** + * The criticality to assign to risks. Only `not_critical` is accepted: critical risks can be reclassified as non-critical, but not the other way around. + * @return criticality + **/ + @ApiModelProperty(example = "not_critical", required = true, value = "The criticality to assign to risks. Only `not_critical` is accepted: critical risks can be reclassified as non-critical, but not the other way around. ") + + public CriticalityEnum getCriticality() { + return criticality; + } + + + public void setCriticality(CriticalityEnum criticality) { + this.criticality = criticality; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RiskCriticalityUpdate riskCriticalityUpdate = (RiskCriticalityUpdate) o; + return Objects.equals(this.riskIds, riskCriticalityUpdate.riskIds) && + Objects.equals(this.criticality, riskCriticalityUpdate.criticality); + } + + @Override + public int hashCode() { + return Objects.hash(riskIds, criticality); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RiskCriticalityUpdate {\n"); + sb.append(" riskIds: ").append(toIndentedString(riskIds)).append("\n"); + sb.append(" criticality: ").append(toIndentedString(criticality)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RiskDetail.java b/src/main/java/one/talon/model/RiskDetail.java new file mode 100644 index 00000000..e88f5fbc --- /dev/null +++ b/src/main/java/one/talon/model/RiskDetail.java @@ -0,0 +1,939 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RiskAffectedEntityItem; +import org.threeten.bp.LocalDate; +import org.threeten.bp.OffsetDateTime; + +/** + * Details of a risk, including its most severely affected entities. + */ +@ApiModel(description = "Details of a risk, including its most severely affected entities.") + +public class RiskDetail { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + public static final String SERIALIZED_NAME_NOTIFICATION_ID = "notificationId"; + @SerializedName(SERIALIZED_NAME_NOTIFICATION_ID) + private Long notificationId; + + public static final String SERIALIZED_NAME_FEATURE_DATE = "featureDate"; + @SerializedName(SERIALIZED_NAME_FEATURE_DATE) + private LocalDate featureDate; + + public static final String SERIALIZED_NAME_GROUP_KEY = "groupKey"; + @SerializedName(SERIALIZED_NAME_GROUP_KEY) + private String groupKey; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + /** + * The triage lifecycle status of this risk. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + ACTIVE("active"), + + IN_REVIEW("in_review"), + + CONFIRMED("confirmed"), + + DISCARDED("discarded"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + /** + * The critical classification bucket of this risk. + */ + @JsonAdapter(CriticalityEnum.Adapter.class) + public enum CriticalityEnum { + CRITICAL("critical"), + + NOT_CRITICAL("not_critical"); + + private String value; + + CriticalityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static CriticalityEnum fromValue(String value) { + for (CriticalityEnum b : CriticalityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final CriticalityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public CriticalityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return CriticalityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_CRITICALITY = "criticality"; + @SerializedName(SERIALIZED_NAME_CRITICALITY) + private CriticalityEnum criticality; + + /** + * The entity type the risk was detected in. + */ + @JsonAdapter(EntityEnum.Adapter.class) + public enum EntityEnum { + PROFILE("customer_profile"), + + SESSION("customer_session"); + + private String value; + + EntityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static EntityEnum fromValue(String value) { + for (EntityEnum b : EntityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final EntityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public EntityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return EntityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private EntityEnum entity; + + /** + * The activity metric the risk was detected in. + */ + @JsonAdapter(ActivityEnum.Adapter.class) + public enum ActivityEnum { + LOYALTY_POINTS_EARNED("loyalty_points_earned"), + + DISCOUNTED_AMOUNT("discounted_amount"), + + COMPLETED_ORDERS("completed_orders"), + + COUPON_ATTEMPTS("coupon_attempts"); + + private String value; + + ActivityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivityEnum fromValue(String value) { + for (ActivityEnum b : ActivityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVITY = "activity"; + @SerializedName(SERIALIZED_NAME_ACTIVITY) + private ActivityEnum activity; + + /** + * The rolling time window of the risk evaluation. + */ + @JsonAdapter(TimeFrameEnum.Adapter.class) + public enum TimeFrameEnum { + _1D("1D"), + + _7D("7D"), + + _30D("30D"); + + private String value; + + TimeFrameEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TimeFrameEnum fromValue(String value) { + for (TimeFrameEnum b : TimeFrameEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TimeFrameEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TimeFrameEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TimeFrameEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TIME_FRAME = "timeFrame"; + @SerializedName(SERIALIZED_NAME_TIME_FRAME) + private TimeFrameEnum timeFrame; + + public static final String SERIALIZED_NAME_REPORTED_DATE = "reportedDate"; + @SerializedName(SERIALIZED_NAME_REPORTED_DATE) + private OffsetDateTime reportedDate; + + public static final String SERIALIZED_NAME_AFFECTED_ENTITY_COUNT = "affectedEntityCount"; + @SerializedName(SERIALIZED_NAME_AFFECTED_ENTITY_COUNT) + private Long affectedEntityCount; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + /** + * The reason this risk was discarded. Only present on discarded risks. + */ + @JsonAdapter(DiscardReasonEnum.Adapter.class) + public enum DiscardReasonEnum { + EXPECTED_BEHAVIOR("expected_behavior"), + + OTHER("other"); + + private String value; + + DiscardReasonEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static DiscardReasonEnum fromValue(String value) { + for (DiscardReasonEnum b : DiscardReasonEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final DiscardReasonEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public DiscardReasonEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return DiscardReasonEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_DISCARD_REASON = "discardReason"; + @SerializedName(SERIALIZED_NAME_DISCARD_REASON) + private DiscardReasonEnum discardReason; + + public static final String SERIALIZED_NAME_STATUS_COMMENT = "statusComment"; + @SerializedName(SERIALIZED_NAME_STATUS_COMMENT) + private String statusComment; + + public static final String SERIALIZED_NAME_STATUS_CHANGED_BY = "statusChangedBy"; + @SerializedName(SERIALIZED_NAME_STATUS_CHANGED_BY) + private Long statusChangedBy; + + public static final String SERIALIZED_NAME_STATUS_CHANGED_AT = "statusChangedAt"; + @SerializedName(SERIALIZED_NAME_STATUS_CHANGED_AT) + private OffsetDateTime statusChangedAt; + + public static final String SERIALIZED_NAME_MODIFIED = "modified"; + @SerializedName(SERIALIZED_NAME_MODIFIED) + private OffsetDateTime modified; + + public static final String SERIALIZED_NAME_AFFECTED_ENTITIES = "affectedEntities"; + @SerializedName(SERIALIZED_NAME_AFFECTED_ENTITIES) + private List affectedEntities = new ArrayList(); + + + public RiskDetail id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of this entity. + * @return id + **/ + @ApiModelProperty(example = "6", required = true, value = "The internal ID of this entity.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RiskDetail created(OffsetDateTime created) { + + this.created = created; + return this; + } + + /** + * The time this entity was created. + * @return created + **/ + @ApiModelProperty(example = "2020-06-10T09:05:27.993483Z", required = true, value = "The time this entity was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + public void setCreated(OffsetDateTime created) { + this.created = created; + } + + + public RiskDetail notificationId(Long notificationId) { + + this.notificationId = notificationId; + return this; + } + + /** + * The ID of the risk notification rule that flagged this risk. + * @return notificationId + **/ + @ApiModelProperty(example = "3", required = true, value = "The ID of the risk notification rule that flagged this risk.") + + public Long getNotificationId() { + return notificationId; + } + + + public void setNotificationId(Long notificationId) { + this.notificationId = notificationId; + } + + + public RiskDetail featureDate(LocalDate featureDate) { + + this.featureDate = featureDate; + return this; + } + + /** + * The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. + * @return featureDate + **/ + @ApiModelProperty(example = "Fri Jun 05 00:00:00 GMT 2026", required = true, value = "The date of the activity data in which this risk was detected. The anomaly detection pipeline scores complete 24-hour cycles, so this is always the day before the risk was reported, not the reporting date itself. ") + + public LocalDate getFeatureDate() { + return featureDate; + } + + + public void setFeatureDate(LocalDate featureDate) { + this.featureDate = featureDate; + } + + + public RiskDetail groupKey(String groupKey) { + + this.groupKey = groupKey; + return this; + } + + /** + * The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. + * @return groupKey + **/ + @ApiModelProperty(example = "7", required = true, value = "The Application group this risk was detected in. Contains the Application ID, or `__GLOBAL__` for metrics that are not grouped by Application. ") + + public String getGroupKey() { + return groupKey; + } + + + public void setGroupKey(String groupKey) { + this.groupKey = groupKey; + } + + + public RiskDetail applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application this risk belongs to. Absent for global metrics. + * @return applicationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The ID of the Application this risk belongs to. Absent for global metrics.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public RiskDetail status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The triage lifecycle status of this risk. + * @return status + **/ + @ApiModelProperty(example = "active", required = true, value = "The triage lifecycle status of this risk.") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + public RiskDetail criticality(CriticalityEnum criticality) { + + this.criticality = criticality; + return this; + } + + /** + * The critical classification bucket of this risk. + * @return criticality + **/ + @ApiModelProperty(example = "critical", required = true, value = "The critical classification bucket of this risk.") + + public CriticalityEnum getCriticality() { + return criticality; + } + + + public void setCriticality(CriticalityEnum criticality) { + this.criticality = criticality; + } + + + public RiskDetail entity(EntityEnum entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type the risk was detected in. + * @return entity + **/ + @ApiModelProperty(example = "customer_profile", required = true, value = "The entity type the risk was detected in.") + + public EntityEnum getEntity() { + return entity; + } + + + public void setEntity(EntityEnum entity) { + this.entity = entity; + } + + + public RiskDetail activity(ActivityEnum activity) { + + this.activity = activity; + return this; + } + + /** + * The activity metric the risk was detected in. + * @return activity + **/ + @ApiModelProperty(example = "discounted_amount", required = true, value = "The activity metric the risk was detected in.") + + public ActivityEnum getActivity() { + return activity; + } + + + public void setActivity(ActivityEnum activity) { + this.activity = activity; + } + + + public RiskDetail timeFrame(TimeFrameEnum timeFrame) { + + this.timeFrame = timeFrame; + return this; + } + + /** + * The rolling time window of the risk evaluation. + * @return timeFrame + **/ + @ApiModelProperty(example = "7D", required = true, value = "The rolling time window of the risk evaluation.") + + public TimeFrameEnum getTimeFrame() { + return timeFrame; + } + + + public void setTimeFrame(TimeFrameEnum timeFrame) { + this.timeFrame = timeFrame; + } + + + public RiskDetail reportedDate(OffsetDateTime reportedDate) { + + this.reportedDate = reportedDate; + return this; + } + + /** + * The time the ML service reported this risk. + * @return reportedDate + **/ + @ApiModelProperty(example = "2026-06-05T06:26:13.698884Z", required = true, value = "The time the ML service reported this risk.") + + public OffsetDateTime getReportedDate() { + return reportedDate; + } + + + public void setReportedDate(OffsetDateTime reportedDate) { + this.reportedDate = reportedDate; + } + + + public RiskDetail affectedEntityCount(Long affectedEntityCount) { + + this.affectedEntityCount = affectedEntityCount; + return this; + } + + /** + * The total number of entities affected by this risk. + * @return affectedEntityCount + **/ + @ApiModelProperty(example = "4437", required = true, value = "The total number of entities affected by this risk.") + + public Long getAffectedEntityCount() { + return affectedEntityCount; + } + + + public void setAffectedEntityCount(Long affectedEntityCount) { + this.affectedEntityCount = affectedEntityCount; + } + + + public RiskDetail description(String description) { + + this.description = description; + return this; + } + + /** + * Human-readable description of the detected anomaly. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Unusual discount usage detected for 4437 customer profiles.", value = "Human-readable description of the detected anomaly.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public RiskDetail discardReason(DiscardReasonEnum discardReason) { + + this.discardReason = discardReason; + return this; + } + + /** + * The reason this risk was discarded. Only present on discarded risks. + * @return discardReason + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "expected_behavior", value = "The reason this risk was discarded. Only present on discarded risks.") + + public DiscardReasonEnum getDiscardReason() { + return discardReason; + } + + + public void setDiscardReason(DiscardReasonEnum discardReason) { + this.discardReason = discardReason; + } + + + public RiskDetail statusComment(String statusComment) { + + this.statusComment = statusComment; + return this; + } + + /** + * The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. + * @return statusComment + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Investigated with the customer and fixed the loyalty rule.", value = "The free-text details of the latest reclassification action: the description for resolving confirmed risks, or the details for discarding risks. ") + + public String getStatusComment() { + return statusComment; + } + + + public void setStatusComment(String statusComment) { + this.statusComment = statusComment; + } + + + public RiskDetail statusChangedBy(Long statusChangedBy) { + + this.statusChangedBy = statusChangedBy; + return this; + } + + /** + * The ID of the user who performed the latest reclassification action. + * @return statusChangedBy + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The ID of the user who performed the latest reclassification action.") + + public Long getStatusChangedBy() { + return statusChangedBy; + } + + + public void setStatusChangedBy(Long statusChangedBy) { + this.statusChangedBy = statusChangedBy; + } + + + public RiskDetail statusChangedAt(OffsetDateTime statusChangedAt) { + + this.statusChangedAt = statusChangedAt; + return this; + } + + /** + * The time of the latest reclassification action. + * @return statusChangedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2026-06-06T09:12:45Z", value = "The time of the latest reclassification action.") + + public OffsetDateTime getStatusChangedAt() { + return statusChangedAt; + } + + + public void setStatusChangedAt(OffsetDateTime statusChangedAt) { + this.statusChangedAt = statusChangedAt; + } + + + public RiskDetail modified(OffsetDateTime modified) { + + this.modified = modified; + return this; + } + + /** + * Timestamp of the most recent update. + * @return modified + **/ + @ApiModelProperty(example = "2026-06-05T06:26:13.698884Z", required = true, value = "Timestamp of the most recent update.") + + public OffsetDateTime getModified() { + return modified; + } + + + public void setModified(OffsetDateTime modified) { + this.modified = modified; + } + + + public RiskDetail affectedEntities(List affectedEntities) { + + this.affectedEntities = affectedEntities; + return this; + } + + public RiskDetail addAffectedEntitiesItem(RiskAffectedEntityItem affectedEntitiesItem) { + this.affectedEntities.add(affectedEntitiesItem); + return this; + } + + /** + * The affected entities with the highest severity ratios, in descending order. + * @return affectedEntities + **/ + @ApiModelProperty(required = true, value = "The affected entities with the highest severity ratios, in descending order.") + + public List getAffectedEntities() { + return affectedEntities; + } + + + public void setAffectedEntities(List affectedEntities) { + this.affectedEntities = affectedEntities; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RiskDetail riskDetail = (RiskDetail) o; + return Objects.equals(this.id, riskDetail.id) && + Objects.equals(this.created, riskDetail.created) && + Objects.equals(this.notificationId, riskDetail.notificationId) && + Objects.equals(this.featureDate, riskDetail.featureDate) && + Objects.equals(this.groupKey, riskDetail.groupKey) && + Objects.equals(this.applicationId, riskDetail.applicationId) && + Objects.equals(this.status, riskDetail.status) && + Objects.equals(this.criticality, riskDetail.criticality) && + Objects.equals(this.entity, riskDetail.entity) && + Objects.equals(this.activity, riskDetail.activity) && + Objects.equals(this.timeFrame, riskDetail.timeFrame) && + Objects.equals(this.reportedDate, riskDetail.reportedDate) && + Objects.equals(this.affectedEntityCount, riskDetail.affectedEntityCount) && + Objects.equals(this.description, riskDetail.description) && + Objects.equals(this.discardReason, riskDetail.discardReason) && + Objects.equals(this.statusComment, riskDetail.statusComment) && + Objects.equals(this.statusChangedBy, riskDetail.statusChangedBy) && + Objects.equals(this.statusChangedAt, riskDetail.statusChangedAt) && + Objects.equals(this.modified, riskDetail.modified) && + Objects.equals(this.affectedEntities, riskDetail.affectedEntities); + } + + @Override + public int hashCode() { + return Objects.hash(id, created, notificationId, featureDate, groupKey, applicationId, status, criticality, entity, activity, timeFrame, reportedDate, affectedEntityCount, description, discardReason, statusComment, statusChangedBy, statusChangedAt, modified, affectedEntities); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RiskDetail {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" notificationId: ").append(toIndentedString(notificationId)).append("\n"); + sb.append(" featureDate: ").append(toIndentedString(featureDate)).append("\n"); + sb.append(" groupKey: ").append(toIndentedString(groupKey)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" criticality: ").append(toIndentedString(criticality)).append("\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); + sb.append(" timeFrame: ").append(toIndentedString(timeFrame)).append("\n"); + sb.append(" reportedDate: ").append(toIndentedString(reportedDate)).append("\n"); + sb.append(" affectedEntityCount: ").append(toIndentedString(affectedEntityCount)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" discardReason: ").append(toIndentedString(discardReason)).append("\n"); + sb.append(" statusComment: ").append(toIndentedString(statusComment)).append("\n"); + sb.append(" statusChangedBy: ").append(toIndentedString(statusChangedBy)).append("\n"); + sb.append(" statusChangedAt: ").append(toIndentedString(statusChangedAt)).append("\n"); + sb.append(" modified: ").append(toIndentedString(modified)).append("\n"); + sb.append(" affectedEntities: ").append(toIndentedString(affectedEntities)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RiskNotification.java b/src/main/java/one/talon/model/RiskNotification.java new file mode 100644 index 00000000..745b9462 --- /dev/null +++ b/src/main/java/one/talon/model/RiskNotification.java @@ -0,0 +1,415 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; + +/** + * A risk notification configuration rule. + */ +@ApiModel(description = "A risk notification configuration rule.") + +public class RiskNotification { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + /** + * The entity type to analyze within the given time frame. + */ + @JsonAdapter(EntityEnum.Adapter.class) + public enum EntityEnum { + PROFILE("customer_profile"), + + SESSION("customer_session"); + + private String value; + + EntityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static EntityEnum fromValue(String value) { + for (EntityEnum b : EntityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final EntityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public EntityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return EntityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private EntityEnum entity; + + /** + * The activity metric to analyze within the given entity. + */ + @JsonAdapter(ActivityEnum.Adapter.class) + public enum ActivityEnum { + LOYALTY_POINTS_EARNED("loyalty_points_earned"), + + DISCOUNTED_AMOUNT("discounted_amount"), + + COMPLETED_ORDERS("completed_orders"), + + COUPON_ATTEMPTS("coupon_attempts"); + + private String value; + + ActivityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivityEnum fromValue(String value) { + for (ActivityEnum b : ActivityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVITY = "activity"; + @SerializedName(SERIALIZED_NAME_ACTIVITY) + private ActivityEnum activity; + + /** + * The rolling time window for risk evaluation. + */ + @JsonAdapter(TimeFrameEnum.Adapter.class) + public enum TimeFrameEnum { + _1D("1D"), + + _7D("7D"), + + _30D("30D"); + + private String value; + + TimeFrameEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TimeFrameEnum fromValue(String value) { + for (TimeFrameEnum b : TimeFrameEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TimeFrameEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TimeFrameEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TimeFrameEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TIME_FRAME = "timeFrame"; + @SerializedName(SERIALIZED_NAME_TIME_FRAME) + private TimeFrameEnum timeFrame; + + public static final String SERIALIZED_NAME_ACTIVE = "active"; + @SerializedName(SERIALIZED_NAME_ACTIVE) + private Boolean active; + + public static final String SERIALIZED_NAME_MODIFIED = "modified"; + @SerializedName(SERIALIZED_NAME_MODIFIED) + private OffsetDateTime modified; + + + public RiskNotification id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of this entity. + * @return id + **/ + @ApiModelProperty(example = "6", required = true, value = "The internal ID of this entity.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public RiskNotification created(OffsetDateTime created) { + + this.created = created; + return this; + } + + /** + * The time this entity was created. + * @return created + **/ + @ApiModelProperty(example = "2020-06-10T09:05:27.993483Z", required = true, value = "The time this entity was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + public void setCreated(OffsetDateTime created) { + this.created = created; + } + + + public RiskNotification entity(EntityEnum entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type to analyze within the given time frame. + * @return entity + **/ + @ApiModelProperty(example = "customer_profile", required = true, value = "The entity type to analyze within the given time frame.") + + public EntityEnum getEntity() { + return entity; + } + + + public void setEntity(EntityEnum entity) { + this.entity = entity; + } + + + public RiskNotification activity(ActivityEnum activity) { + + this.activity = activity; + return this; + } + + /** + * The activity metric to analyze within the given entity. + * @return activity + **/ + @ApiModelProperty(example = "loyalty_points_earned", required = true, value = "The activity metric to analyze within the given entity.") + + public ActivityEnum getActivity() { + return activity; + } + + + public void setActivity(ActivityEnum activity) { + this.activity = activity; + } + + + public RiskNotification timeFrame(TimeFrameEnum timeFrame) { + + this.timeFrame = timeFrame; + return this; + } + + /** + * The rolling time window for risk evaluation. + * @return timeFrame + **/ + @ApiModelProperty(example = "7D", required = true, value = "The rolling time window for risk evaluation.") + + public TimeFrameEnum getTimeFrame() { + return timeFrame; + } + + + public void setTimeFrame(TimeFrameEnum timeFrame) { + this.timeFrame = timeFrame; + } + + + public RiskNotification active(Boolean active) { + + this.active = active; + return this; + } + + /** + * Indicates whether this risk notification is active. + * @return active + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates whether this risk notification is active.") + + public Boolean getActive() { + return active; + } + + + public void setActive(Boolean active) { + this.active = active; + } + + + public RiskNotification modified(OffsetDateTime modified) { + + this.modified = modified; + return this; + } + + /** + * Timestamp of the most recent update. + * @return modified + **/ + @ApiModelProperty(example = "2026-04-16T09:05:27.993483Z", required = true, value = "Timestamp of the most recent update.") + + public OffsetDateTime getModified() { + return modified; + } + + + public void setModified(OffsetDateTime modified) { + this.modified = modified; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RiskNotification riskNotification = (RiskNotification) o; + return Objects.equals(this.id, riskNotification.id) && + Objects.equals(this.created, riskNotification.created) && + Objects.equals(this.entity, riskNotification.entity) && + Objects.equals(this.activity, riskNotification.activity) && + Objects.equals(this.timeFrame, riskNotification.timeFrame) && + Objects.equals(this.active, riskNotification.active) && + Objects.equals(this.modified, riskNotification.modified); + } + + @Override + public int hashCode() { + return Objects.hash(id, created, entity, activity, timeFrame, active, modified); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RiskNotification {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); + sb.append(" timeFrame: ").append(toIndentedString(timeFrame)).append("\n"); + sb.append(" active: ").append(toIndentedString(active)).append("\n"); + sb.append(" modified: ").append(toIndentedString(modified)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RoleV2ApplicationDetails.java b/src/main/java/one/talon/model/RoleV2ApplicationDetails.java index b03ee5a9..64bd5591 100644 --- a/src/main/java/one/talon/model/RoleV2ApplicationDetails.java +++ b/src/main/java/one/talon/model/RoleV2ApplicationDetails.java @@ -23,7 +23,6 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; -import one.talon.model.RolesV2Thresholds; /** * RoleV2ApplicationDetails @@ -46,10 +45,6 @@ public class RoleV2ApplicationDetails { @SerializedName(SERIALIZED_NAME_TOOLS) private String tools; - public static final String SERIALIZED_NAME_THRESHOLDS = "thresholds"; - @SerializedName(SERIALIZED_NAME_THRESHOLDS) - private RolesV2Thresholds thresholds; - public RoleV2ApplicationDetails application(String application) { @@ -143,29 +138,6 @@ public void setTools(String tools) { } - public RoleV2ApplicationDetails thresholds(RolesV2Thresholds thresholds) { - - this.thresholds = thresholds; - return this; - } - - /** - * Get thresholds - * @return thresholds - **/ - @javax.annotation.Nullable - @ApiModelProperty(value = "") - - public RolesV2Thresholds getThresholds() { - return thresholds; - } - - - public void setThresholds(RolesV2Thresholds thresholds) { - this.thresholds = thresholds; - } - - @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -178,13 +150,12 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.application, roleV2ApplicationDetails.application) && Objects.equals(this.campaign, roleV2ApplicationDetails.campaign) && Objects.equals(this.draftCampaign, roleV2ApplicationDetails.draftCampaign) && - Objects.equals(this.tools, roleV2ApplicationDetails.tools) && - Objects.equals(this.thresholds, roleV2ApplicationDetails.thresholds); + Objects.equals(this.tools, roleV2ApplicationDetails.tools); } @Override public int hashCode() { - return Objects.hash(application, campaign, draftCampaign, tools, thresholds); + return Objects.hash(application, campaign, draftCampaign, tools); } @@ -196,7 +167,6 @@ public String toString() { sb.append(" campaign: ").append(toIndentedString(campaign)).append("\n"); sb.append(" draftCampaign: ").append(toIndentedString(draftCampaign)).append("\n"); sb.append(" tools: ").append(toIndentedString(tools)).append("\n"); - sb.append(" thresholds: ").append(toIndentedString(thresholds)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/RoleV2Permissions.java b/src/main/java/one/talon/model/RoleV2Permissions.java index 1013fae6..1cf60109 100644 --- a/src/main/java/one/talon/model/RoleV2Permissions.java +++ b/src/main/java/one/talon/model/RoleV2Permissions.java @@ -27,6 +27,7 @@ import java.util.List; import one.talon.model.RoleV2PermissionSet; import one.talon.model.RoleV2RolesGroup; +import one.talon.model.RolesV2Thresholds; /** * RoleV2Permissions @@ -41,6 +42,10 @@ public class RoleV2Permissions { @SerializedName(SERIALIZED_NAME_ROLES) private RoleV2RolesGroup roles; + public static final String SERIALIZED_NAME_THRESHOLDS = "thresholds"; + @SerializedName(SERIALIZED_NAME_THRESHOLDS) + private List thresholds = null; + public RoleV2Permissions permissionSets(List permissionSets) { @@ -96,6 +101,37 @@ public void setRoles(RoleV2RolesGroup roles) { } + public RoleV2Permissions thresholds(List thresholds) { + + this.thresholds = thresholds; + return this; + } + + public RoleV2Permissions addThresholdsItem(RolesV2Thresholds thresholdsItem) { + if (this.thresholds == null) { + this.thresholds = new ArrayList(); + } + this.thresholds.add(thresholdsItem); + return this; + } + + /** + * Support user limits for actions that require admin approval within the given application. + * @return thresholds + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Support user limits for actions that require admin approval within the given application.") + + public List getThresholds() { + return thresholds; + } + + + public void setThresholds(List thresholds) { + this.thresholds = thresholds; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -106,12 +142,13 @@ public boolean equals(java.lang.Object o) { } RoleV2Permissions roleV2Permissions = (RoleV2Permissions) o; return Objects.equals(this.permissionSets, roleV2Permissions.permissionSets) && - Objects.equals(this.roles, roleV2Permissions.roles); + Objects.equals(this.roles, roleV2Permissions.roles) && + Objects.equals(this.thresholds, roleV2Permissions.thresholds); } @Override public int hashCode() { - return Objects.hash(permissionSets, roles); + return Objects.hash(permissionSets, roles, thresholds); } @@ -121,6 +158,7 @@ public String toString() { sb.append("class RoleV2Permissions {\n"); sb.append(" permissionSets: ").append(toIndentedString(permissionSets)).append("\n"); sb.append(" roles: ").append(toIndentedString(roles)).append("\n"); + sb.append(" thresholds: ").append(toIndentedString(thresholds)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/RolesV2Thresholds.java b/src/main/java/one/talon/model/RolesV2Thresholds.java index 4ce3b314..a0ba2f61 100644 --- a/src/main/java/one/talon/model/RolesV2Thresholds.java +++ b/src/main/java/one/talon/model/RolesV2Thresholds.java @@ -29,11 +29,38 @@ */ public class RolesV2Thresholds { + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + public static final String SERIALIZED_NAME_LOYALTY_POINTS_LIMIT = "loyaltyPointsLimit"; @SerializedName(SERIALIZED_NAME_LOYALTY_POINTS_LIMIT) private Long loyaltyPointsLimit; + public RolesV2Thresholds loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "8", value = "Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + public RolesV2Thresholds loyaltyPointsLimit(Long loyaltyPointsLimit) { this.loyaltyPointsLimit = loyaltyPointsLimit; @@ -66,12 +93,13 @@ public boolean equals(java.lang.Object o) { return false; } RolesV2Thresholds rolesV2Thresholds = (RolesV2Thresholds) o; - return Objects.equals(this.loyaltyPointsLimit, rolesV2Thresholds.loyaltyPointsLimit); + return Objects.equals(this.loyaltyProgramId, rolesV2Thresholds.loyaltyProgramId) && + Objects.equals(this.loyaltyPointsLimit, rolesV2Thresholds.loyaltyPointsLimit); } @Override public int hashCode() { - return Objects.hash(loyaltyPointsLimit); + return Objects.hash(loyaltyProgramId, loyaltyPointsLimit); } @@ -79,6 +107,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class RolesV2Thresholds {\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); sb.append(" loyaltyPointsLimit: ").append(toIndentedString(loyaltyPointsLimit)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/RollbackAddedLoyaltyPointsEffectProps.java b/src/main/java/one/talon/model/RollbackAddedLoyaltyPointsEffectProps.java index e91945fd..122e3346 100644 --- a/src/main/java/one/talon/model/RollbackAddedLoyaltyPointsEffectProps.java +++ b/src/main/java/one/talon/model/RollbackAddedLoyaltyPointsEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"rollbackAddedLoyaltyPoints\" effect. This gets triggered whenever previously a closed session with an addLoyaltyPoints effect is cancelled. + * This effect is triggered in the following cases: - A session was cancelled in which loyalty points have been added. - A session was partially returned and loyalty point were added by the returned items. See [returning items](https://docs.talon.one/docs/dev/tutorials/partially-return-a-session). If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which items the loyalty points were rolled back for. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user for whom the loyalty points are rolled back. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points were originally added. */ -@ApiModel(description = "The properties specific to the \"rollbackAddedLoyaltyPoints\" effect. This gets triggered whenever previously a closed session with an addLoyaltyPoints effect is cancelled.") +@ApiModel(description = "This effect is triggered in the following cases: - A session was cancelled in which loyalty points have been added. - A session was partially returned and loyalty point were added by the returned items. See [returning items](https://docs.talon.one/docs/dev/tutorials/partially-return-a-session). If you use the [Add loyalty points per item effect](https://docs.talon.one/docs/product/rules/effects/available-effects#reward-effects), use the `cartItemPosition` property to identify which items the loyalty points were rolled back for. If you use **Add loyalty points per item** and if the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the item unit in its line item. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `recipientIntegrationId` property to identify the user for whom the loyalty points are rolled back. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points were originally added.") public class RollbackAddedLoyaltyPointsEffectProps { public static final String SERIALIZED_NAME_PROGRAM_ID = "programId"; @@ -71,10 +71,10 @@ public RollbackAddedLoyaltyPointsEffectProps programId(Long programId) { } /** - * The ID of the loyalty program where the points were originally added. + * The ID of the loyalty program where these points were rolled back. * @return programId **/ - @ApiModelProperty(required = true, value = "The ID of the loyalty program where the points were originally added.") + @ApiModelProperty(required = true, value = "The ID of the loyalty program where these points were rolled back.") public Long getProgramId() { return programId; @@ -93,10 +93,10 @@ public RollbackAddedLoyaltyPointsEffectProps subLedgerId(String subLedgerId) { } /** - * The ID of the subledger within the loyalty program where these points were originally added. + * The ID of the subledger within the loyalty program where these points were rolled back. * @return subLedgerId **/ - @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program where these points were originally added.") + @ApiModelProperty(required = true, value = "The ID of the subledger within the loyalty program where these points were rolled back.") public String getSubLedgerId() { return subLedgerId; @@ -137,10 +137,10 @@ public RollbackAddedLoyaltyPointsEffectProps recipientIntegrationId(String recip } /** - * The user for whom these points were originally added. + * The user for whom these points were rolled back. * @return recipientIntegrationId **/ - @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The user for whom these points were originally added.") + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The user for whom these points were rolled back.") public String getRecipientIntegrationId() { return recipientIntegrationId; @@ -159,10 +159,10 @@ public RollbackAddedLoyaltyPointsEffectProps transactionUUID(String transactionU } /** - * The identifier of 'deduction' entry added to the ledger as the `addLoyaltyPoints` effect is rolled back. + * The identifier of this loyalty point transaction. * @return transactionUUID **/ - @ApiModelProperty(required = true, value = "The identifier of 'deduction' entry added to the ledger as the `addLoyaltyPoints` effect is rolled back.") + @ApiModelProperty(required = true, value = "The identifier of this loyalty point transaction.") public String getTransactionUUID() { return transactionUUID; @@ -181,11 +181,11 @@ public RollbackAddedLoyaltyPointsEffectProps cartItemPosition(BigDecimal cartIte } /** - * The index of the item in the cart items for which the loyalty points were rolled back. + * (_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were rolled back. * @return cartItemPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The index of the item in the cart items for which the loyalty points were rolled back.") + @ApiModelProperty(value = "(_Add points per cart item_ only.) The index of the item in the `cartItem` object for which these points were rolled back.") public BigDecimal getCartItemPosition() { return cartItemPosition; @@ -204,11 +204,11 @@ public RollbackAddedLoyaltyPointsEffectProps cartItemSubPosition(BigDecimal cart } /** - * For cart items with `quantity` > 1, the sub-position indicates to which item the loyalty points were rolled back. + * (_Add points per cart item_ ) The index of the item unit in its line item. * @return cartItemSubPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "For cart items with `quantity` > 1, the sub-position indicates to which item the loyalty points were rolled back. ") + @ApiModelProperty(value = "(_Add points per cart item_ ) The index of the item unit in its line item.") public BigDecimal getCartItemSubPosition() { return cartItemSubPosition; diff --git a/src/main/java/one/talon/model/RollbackCouponEffectProps.java b/src/main/java/one/talon/model/RollbackCouponEffectProps.java index 6a78ca76..2d072e21 100644 --- a/src/main/java/one/talon/model/RollbackCouponEffectProps.java +++ b/src/main/java/one/talon/model/RollbackCouponEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"rollbackCoupon\" effect. This gets triggered whenever previously closed session is now cancelled and a coupon redemption was cancelled on our internal usage limit counters. + * This effect indicates that a coupon code redemption has been rolled back. The coupon becomes redeemable again. The effect is triggered when you [cancel](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state) a session where a coupon was accepted. See an example of use in the [cancelling a session tutorial](https://docs.talon.one/docs/dev/tutorials/roll-back-effects). */ -@ApiModel(description = "The properties specific to the \"rollbackCoupon\" effect. This gets triggered whenever previously closed session is now cancelled and a coupon redemption was cancelled on our internal usage limit counters.") +@ApiModel(description = "This effect indicates that a coupon code redemption has been rolled back. The coupon becomes redeemable again. The effect is triggered when you [cancel](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state) a session where a coupon was accepted. See an example of use in the [cancelling a session tutorial](https://docs.talon.one/docs/dev/tutorials/roll-back-effects).") public class RollbackCouponEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -42,10 +42,10 @@ public RollbackCouponEffectProps value(String value) { } /** - * The coupon code whose usage has been rolled back. + * The coupon code whose redemption has been rolled back. * @return value **/ - @ApiModelProperty(required = true, value = "The coupon code whose usage has been rolled back.") + @ApiModelProperty(required = true, value = "The coupon code whose redemption has been rolled back.") public String getValue() { return value; diff --git a/src/main/java/one/talon/model/RollbackDeductedLoyaltyPointsEffectProps.java b/src/main/java/one/talon/model/RollbackDeductedLoyaltyPointsEffectProps.java index c4f5b8bb..dfe55229 100644 --- a/src/main/java/one/talon/model/RollbackDeductedLoyaltyPointsEffectProps.java +++ b/src/main/java/one/talon/model/RollbackDeductedLoyaltyPointsEffectProps.java @@ -27,9 +27,9 @@ import org.threeten.bp.OffsetDateTime; /** - * The properties specific to the \"rollbackDeductedLoyaltyPoints\" effect. This effect is triggered whenever a previously closed session is cancelled and a deductLoyaltyPoints effect was revoked. + * This effect is triggered in the following cases: - A session is _cancelled_ and this session deducted loyalty points. The rollback action returns the redeemed loyalty points to the customer. - A session is impacted by a _partial return_. Only added loyalty points that are still **pending** are rolled back. - A session in which loyalty points were spent is reopened. See the [session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). If you set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/profile-based/profile-based-overview), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points are reimbursed. */ -@ApiModel(description = "The properties specific to the \"rollbackDeductedLoyaltyPoints\" effect. This effect is triggered whenever a previously closed session is cancelled and a deductLoyaltyPoints effect was revoked.") +@ApiModel(description = "This effect is triggered in the following cases: - A session is _cancelled_ and this session deducted loyalty points. The rollback action returns the redeemed loyalty points to the customer. - A session is impacted by a _partial return_. Only added loyalty points that are still **pending** are rolled back. - A session in which loyalty points were spent is reopened. See the [session states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). If you set custom activation and expiration dates for the loyalty points, use the `startDate` and `expiryDate` properties to identify when the reward will be active and when will expire. If the loyalty program is [profile-based](https://docs.talon.one/docs/product/loyalty-programs/profile-based/profile-based-overview), use the `recipientIntegrationId` property to identify the user who receives the loyalty points. If the loyalty program is [card-based](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types), use the `cardIdentifier` property to identify the loyalty card where the points are reimbursed.") public class RollbackDeductedLoyaltyPointsEffectProps { public static final String SERIALIZED_NAME_PROGRAM_ID = "programId"; @@ -116,10 +116,10 @@ public RollbackDeductedLoyaltyPointsEffectProps value(BigDecimal value) { } /** - * The amount of reimbursed points that were added. + * The amount of points that were reimbursed. * @return value **/ - @ApiModelProperty(required = true, value = "The amount of reimbursed points that were added.") + @ApiModelProperty(required = true, value = "The amount of points that were reimbursed.") public BigDecimal getValue() { return value; @@ -160,11 +160,11 @@ public RollbackDeductedLoyaltyPointsEffectProps startDate(OffsetDateTime startDa } /** - * Date after which the reimbursed points will be valid. + * The date after which the reimbursed points will be valid. * @return startDate **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Date after which the reimbursed points will be valid.") + @ApiModelProperty(value = "The date after which the reimbursed points will be valid.") public OffsetDateTime getStartDate() { return startDate; @@ -183,11 +183,11 @@ public RollbackDeductedLoyaltyPointsEffectProps expiryDate(OffsetDateTime expiry } /** - * Date after which the reimbursed points will expire. + * The date after which the reimbursed points will expire. * @return expiryDate **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Date after which the reimbursed points will expire.") + @ApiModelProperty(value = "The date after which the reimbursed points will expire.") public OffsetDateTime getExpiryDate() { return expiryDate; @@ -206,10 +206,10 @@ public RollbackDeductedLoyaltyPointsEffectProps transactionUUID(String transacti } /** - * The identifier of 'addition' entries added to the ledger as the `deductLoyaltyPoints` effect is rolled back. + * The identifier of this loyalty point transaction. * @return transactionUUID **/ - @ApiModelProperty(required = true, value = "The identifier of 'addition' entries added to the ledger as the `deductLoyaltyPoints` effect is rolled back.") + @ApiModelProperty(required = true, value = "The identifier of this loyalty point transaction.") public String getTransactionUUID() { return transactionUUID; diff --git a/src/main/java/one/talon/model/RollbackDiscountEffectProps.java b/src/main/java/one/talon/model/RollbackDiscountEffectProps.java index cd457ba1..c122f4c3 100644 --- a/src/main/java/one/talon/model/RollbackDiscountEffectProps.java +++ b/src/main/java/one/talon/model/RollbackDiscountEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"rollbackDiscount\" effect. This gets triggered whenever previously closed session is now cancelled or partially returned and a setDiscount effect was cancelled on our internal discount limit counters. + * This effect indicates that a discounted session, cart item, or additional cost has been cancelled or partially returned. This effect can only happen when you set the status of a session to `cancel` or the status changes to `partially_returned`. If the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the specific item unit in its line item. See the example below. */ -@ApiModel(description = "The properties specific to the \"rollbackDiscount\" effect. This gets triggered whenever previously closed session is now cancelled or partially returned and a setDiscount effect was cancelled on our internal discount limit counters.") +@ApiModel(description = "This effect indicates that a discounted session, cart item, or additional cost has been cancelled or partially returned. This effect can only happen when you set the status of a session to `cancel` or the status changes to `partially_returned`. If the session contains some cart items with _quantity > 1_, use the `cartItemSubPosition` property to identify the specific item unit in its line item. See the example below.") public class RollbackDiscountEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -67,10 +67,10 @@ public RollbackDiscountEffectProps name(String name) { } /** - * The name of the \"setDiscount\" effect that was rolled back. + * The name of the discount effect that was rolled back. * @return name **/ - @ApiModelProperty(required = true, value = "The name of the \"setDiscount\" effect that was rolled back.") + @ApiModelProperty(required = true, value = "The name of the discount effect that was rolled back.") public String getName() { return name; @@ -89,10 +89,10 @@ public RollbackDiscountEffectProps value(BigDecimal value) { } /** - * The value of the discount that was rolled back. + * The monetary value of the discount that was rolled back. * @return value **/ - @ApiModelProperty(required = true, value = "The value of the discount that was rolled back.") + @ApiModelProperty(required = true, value = "The monetary value of the discount that was rolled back.") public BigDecimal getValue() { return value; @@ -111,11 +111,11 @@ public RollbackDiscountEffectProps cartItemPosition(BigDecimal cartItemPosition) } /** - * The index of the item in the cart items for which the discount was rolled back. + * The index of the item in the `cartItem` object whose discount was rolled back, or the unit containing the additional cost whose discount was rolled back. * @return cartItemPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The index of the item in the cart items for which the discount was rolled back.") + @ApiModelProperty(value = "The index of the item in the `cartItem` object whose discount was rolled back, or the unit containing the additional cost whose discount was rolled back.") public BigDecimal getCartItemPosition() { return cartItemPosition; @@ -134,11 +134,11 @@ public RollbackDiscountEffectProps cartItemSubPosition(BigDecimal cartItemSubPos } /** - * For cart items with `quantity` > 1, the subposition returns the index of the item unit in its line item. + * The index of the item unit in its line item for which the discount was rolled back. * @return cartItemSubPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "For cart items with `quantity` > 1, the subposition returns the index of the item unit in its line item. ") + @ApiModelProperty(value = "The index of the item unit in its line item for which the discount was rolled back.") public BigDecimal getCartItemSubPosition() { return cartItemSubPosition; @@ -157,11 +157,11 @@ public RollbackDiscountEffectProps additionalCostId(Long additionalCostId) { } /** - * The ID of the additional cost that was rolled back. + * _Only when rolling back [setDiscountPerAdditionalCost](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcost) and [setDiscountPerAdditionalCostPerItem](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcostperitem)_ The ID of the additional cost to be discounted. * @return additionalCostId **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The ID of the additional cost that was rolled back.") + @ApiModelProperty(value = "_Only when rolling back [setDiscountPerAdditionalCost](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcost) and [setDiscountPerAdditionalCostPerItem](https://docs.talon.one/docs/dev/integration-api/api-effects#setdiscountperadditionalcostperitem)_ The ID of the additional cost to be discounted.") public Long getAdditionalCostId() { return additionalCostId; @@ -180,11 +180,11 @@ public RollbackDiscountEffectProps additionalCost(String additionalCost) { } /** - * The name of the additional cost that was rolled back. + * The API name of the additional cost whose discount was rolled back. * @return additionalCost **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the additional cost that was rolled back.") + @ApiModelProperty(value = "The API name of the additional cost whose discount was rolled back.") public String getAdditionalCost() { return additionalCost; @@ -203,11 +203,11 @@ public RollbackDiscountEffectProps scope(String scope) { } /** - * The scope of the rolled back discount - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` + * The scope of the rolled back discount. - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` * @return scope **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The scope of the rolled back discount - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal` ") + @ApiModelProperty(value = "The scope of the rolled back discount. - For a discount per session, it can be one of `cartItems`, `additionalCosts` or `sessionTotal` - For a discount per item, it can be one of `price`, `additionalCosts` or `itemTotal`") public String getScope() { return scope; diff --git a/src/main/java/one/talon/model/RollbackIncreasedAchievementProgressEffectProps.java b/src/main/java/one/talon/model/RollbackIncreasedAchievementProgressEffectProps.java index 106067a0..9f2a604c 100644 --- a/src/main/java/one/talon/model/RollbackIncreasedAchievementProgressEffectProps.java +++ b/src/main/java/one/talon/model/RollbackIncreasedAchievementProgressEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"rollbackIncreasedAchievementProgress\" effect. This gets triggered whenever a closed session where the `increaseAchievementProgress` effect was triggered is cancelled. This is applicable only when the customer has not completed the achievement. + * This effect indicates that the customer's progress in an achievement was rolled back. The Rule Engine triggers this effect when you cancel or [reopen a customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession) that previously validated the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect and triggered the [increaseAchievementProgress](https://docs.talon.one/docs/dev/integration-api/api-effects#increaseachievementprogress) API effect. The effect is also triggered for completed achievements if the **Allow progress rollback for completed achievements** setting is enabled. You can enable this through the [Campaign Manager](https://docs.talon.one/docs/product/achievements/manage-achievements) or the [Management API](https://docs.talon.one/management-api#tag/Achievements/operation/createAchievement) by setting the `achievementAllowRollbackAfterCompletion` property to `true`. This setting only applies to one-time and recurring on expiration achievements. */ -@ApiModel(description = "The properties specific to the \"rollbackIncreasedAchievementProgress\" effect. This gets triggered whenever a closed session where the `increaseAchievementProgress` effect was triggered is cancelled. This is applicable only when the customer has not completed the achievement.") +@ApiModel(description = "This effect indicates that the customer's progress in an achievement was rolled back. The Rule Engine triggers this effect when you cancel or [reopen a customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/reopenCustomerSession) that previously validated the [Update customer progress](https://docs.talon.one/docs/product/rules/effects/use-effects#update-customer-progress) effect and triggered the [increaseAchievementProgress](https://docs.talon.one/docs/dev/integration-api/api-effects#increaseachievementprogress) API effect. The effect is also triggered for completed achievements if the **Allow progress rollback for completed achievements** setting is enabled. You can enable this through the [Campaign Manager](https://docs.talon.one/docs/product/achievements/manage-achievements) or the [Management API](https://docs.talon.one/management-api#tag/Achievements/operation/createAchievement) by setting the `achievementAllowRollbackAfterCompletion` property to `true`. This setting only applies to one-time and recurring on expiration achievements.") public class RollbackIncreasedAchievementProgressEffectProps { public static final String SERIALIZED_NAME_ACHIEVEMENT_ID = "achievementId"; @@ -129,10 +129,10 @@ public RollbackIncreasedAchievementProgressEffectProps decreaseProgressBy(BigDec } /** - * The value by which the customer's current progress in the achievement is decreased. + * The value by which the customer's current progress in the achievement has decreased. * @return decreaseProgressBy **/ - @ApiModelProperty(required = true, value = "The value by which the customer's current progress in the achievement is decreased.") + @ApiModelProperty(required = true, value = "The value by which the customer's current progress in the achievement has decreased.") public BigDecimal getDecreaseProgressBy() { return decreaseProgressBy; diff --git a/src/main/java/one/talon/model/RollbackReferralEffectProps.java b/src/main/java/one/talon/model/RollbackReferralEffectProps.java index 63341154..9d85b995 100644 --- a/src/main/java/one/talon/model/RollbackReferralEffectProps.java +++ b/src/main/java/one/talon/model/RollbackReferralEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"rollbackReferral\" effect. This gets triggered whenever previously closed session is now cancelled and a referral redemption was cancelled on our internal usage limit counters. + * This effect indicates that the redemption of the referral code has been rolled back. It triggers when a closed session that redeemed a referral is gets cancelled. The code becomes redeemable again. For more information about session states, see [Managing states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states). */ -@ApiModel(description = "The properties specific to the \"rollbackReferral\" effect. This gets triggered whenever previously closed session is now cancelled and a referral redemption was cancelled on our internal usage limit counters.") +@ApiModel(description = "This effect indicates that the redemption of the referral code has been rolled back. It triggers when a closed session that redeemed a referral is gets cancelled. The code becomes redeemable again. For more information about session states, see [Managing states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states).") public class RollbackReferralEffectProps { public static final String SERIALIZED_NAME_VALUE = "value"; @@ -42,10 +42,10 @@ public RollbackReferralEffectProps value(String value) { } /** - * The referral code whose usage has been rolled back. + * The referral code to be rolled back. * @return value **/ - @ApiModelProperty(required = true, value = "The referral code whose usage has been rolled back.") + @ApiModelProperty(required = true, value = "The referral code to be rolled back.") public String getValue() { return value; diff --git a/src/main/java/one/talon/model/RollbackUseRewardEffectProps.java b/src/main/java/one/talon/model/RollbackUseRewardEffectProps.java new file mode 100644 index 00000000..4557948c --- /dev/null +++ b/src/main/java/one/talon/model/RollbackUseRewardEffectProps.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * This effect is triggered when a reward usage has been rolled back by a session cancellation. + */ +@ApiModel(description = "This effect is triggered when a reward usage has been rolled back by a session cancellation.") + +public class RollbackUseRewardEffectProps { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + + public RollbackUseRewardEffectProps integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID of the customer reward that was rolled back. + * @return integrationId + **/ + @ApiModelProperty(example = "5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90", required = true, value = "The integration ID of the customer reward that was rolled back.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public RollbackUseRewardEffectProps rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward that was rolled back. + * @return rewardId + **/ + @ApiModelProperty(example = "5", required = true, value = "The ID of the reward that was rolled back.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + + public RollbackUseRewardEffectProps applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application the reward belongs to. + * @return applicationId + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the Application the reward belongs to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RollbackUseRewardEffectProps rollbackUseRewardEffectProps = (RollbackUseRewardEffectProps) o; + return Objects.equals(this.integrationId, rollbackUseRewardEffectProps.integrationId) && + Objects.equals(this.rewardId, rollbackUseRewardEffectProps.rewardId) && + Objects.equals(this.applicationId, rollbackUseRewardEffectProps.applicationId); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId, rewardId, applicationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RollbackUseRewardEffectProps {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RuleEligibility.java b/src/main/java/one/talon/model/RuleEligibility.java new file mode 100644 index 00000000..018e0636 --- /dev/null +++ b/src/main/java/one/talon/model/RuleEligibility.java @@ -0,0 +1,158 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RuleEligibilityFailureDetails; + +/** + * The customer's eligibility for a rule in the current session, based on whether all of the rule's conditions were met. + */ +@ApiModel(description = "The customer's eligibility for a rule in the current session, based on whether all of the rule's conditions were met.") + +public class RuleEligibility { + public static final String SERIALIZED_NAME_PASSED = "passed"; + @SerializedName(SERIALIZED_NAME_PASSED) + private Boolean passed; + + public static final String SERIALIZED_NAME_COUPON_CODE = "couponCode"; + @SerializedName(SERIALIZED_NAME_COUPON_CODE) + private String couponCode; + + public static final String SERIALIZED_NAME_DETAILS = "details"; + @SerializedName(SERIALIZED_NAME_DETAILS) + private RuleEligibilityFailureDetails details; + + + public RuleEligibility passed(Boolean passed) { + + this.passed = passed; + return this; + } + + /** + * Indicates whether the customer was eligible for the rule in the current session, based on whether all of the rule's conditions were met. + * @return passed + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates whether the customer was eligible for the rule in the current session, based on whether all of the rule's conditions were met.") + + public Boolean getPassed() { + return passed; + } + + + public void setPassed(Boolean passed) { + this.passed = passed; + } + + + public RuleEligibility couponCode(String couponCode) { + + this.couponCode = couponCode; + return this; + } + + /** + * The coupon code used to check a customer's eligibility for the rule in the current session, if applicable. + * @return couponCode + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The coupon code used to check a customer's eligibility for the rule in the current session, if applicable.") + + public String getCouponCode() { + return couponCode; + } + + + public void setCouponCode(String couponCode) { + this.couponCode = couponCode; + } + + + public RuleEligibility details(RuleEligibilityFailureDetails details) { + + this.details = details; + return this; + } + + /** + * Get details + * @return details + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public RuleEligibilityFailureDetails getDetails() { + return details; + } + + + public void setDetails(RuleEligibilityFailureDetails details) { + this.details = details; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RuleEligibility ruleEligibility = (RuleEligibility) o; + return Objects.equals(this.passed, ruleEligibility.passed) && + Objects.equals(this.couponCode, ruleEligibility.couponCode) && + Objects.equals(this.details, ruleEligibility.details); + } + + @Override + public int hashCode() { + return Objects.hash(passed, couponCode, details); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RuleEligibility {\n"); + sb.append(" passed: ").append(toIndentedString(passed)).append("\n"); + sb.append(" couponCode: ").append(toIndentedString(couponCode)).append("\n"); + sb.append(" details: ").append(toIndentedString(details)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RuleEligibilityFailureDetails.java b/src/main/java/one/talon/model/RuleEligibilityFailureDetails.java new file mode 100644 index 00000000..4c759bb5 --- /dev/null +++ b/src/main/java/one/talon/model/RuleEligibilityFailureDetails.java @@ -0,0 +1,348 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The details about why the customer was not eligible for the rule in the current session. + */ +@ApiModel(description = "The details about why the customer was not eligible for the rule in the current session.") + +public class RuleEligibilityFailureDetails { + /** + * A code identifying why the customer was not eligible for the rule in the current session. + */ + @JsonAdapter(FailureCodeEnum.Adapter.class) + public enum FailureCodeEnum { + CONDITION_NOT_MET("CONDITION_NOT_MET"), + + EFFECT_FAILED("EFFECT_FAILED"); + + private String value; + + FailureCodeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static FailureCodeEnum fromValue(String value) { + for (FailureCodeEnum b : FailureCodeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final FailureCodeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public FailureCodeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return FailureCodeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_FAILURE_CODE = "failureCode"; + @SerializedName(SERIALIZED_NAME_FAILURE_CODE) + private FailureCodeEnum failureCode; + + public static final String SERIALIZED_NAME_COUPON_I_D = "couponID"; + @SerializedName(SERIALIZED_NAME_COUPON_I_D) + private Long couponID; + + public static final String SERIALIZED_NAME_COUPON_VALUE = "couponValue"; + @SerializedName(SERIALIZED_NAME_COUPON_VALUE) + private String couponValue; + + public static final String SERIALIZED_NAME_REFERRAL_I_D = "referralID"; + @SerializedName(SERIALIZED_NAME_REFERRAL_I_D) + private Long referralID; + + public static final String SERIALIZED_NAME_REFERRAL_VALUE = "referralValue"; + @SerializedName(SERIALIZED_NAME_REFERRAL_VALUE) + private String referralValue; + + public static final String SERIALIZED_NAME_CONDITION_INDEX = "conditionIndex"; + @SerializedName(SERIALIZED_NAME_CONDITION_INDEX) + private Long conditionIndex; + + public static final String SERIALIZED_NAME_EFFECT_INDEX = "effectIndex"; + @SerializedName(SERIALIZED_NAME_EFFECT_INDEX) + private Long effectIndex; + + public static final String SERIALIZED_NAME_DETAILS = "details"; + @SerializedName(SERIALIZED_NAME_DETAILS) + private String details; + + + public RuleEligibilityFailureDetails failureCode(FailureCodeEnum failureCode) { + + this.failureCode = failureCode; + return this; + } + + /** + * A code identifying why the customer was not eligible for the rule in the current session. + * @return failureCode + **/ + @ApiModelProperty(required = true, value = "A code identifying why the customer was not eligible for the rule in the current session.") + + public FailureCodeEnum getFailureCode() { + return failureCode; + } + + + public void setFailureCode(FailureCodeEnum failureCode) { + this.failureCode = failureCode; + } + + + public RuleEligibilityFailureDetails couponID(Long couponID) { + + this.couponID = couponID; + return this; + } + + /** + * The ID of the coupon that was being evaluated when the rule failed. + * @return couponID + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "4928", value = "The ID of the coupon that was being evaluated when the rule failed. ") + + public Long getCouponID() { + return couponID; + } + + + public void setCouponID(Long couponID) { + this.couponID = couponID; + } + + + public RuleEligibilityFailureDetails couponValue(String couponValue) { + + this.couponValue = couponValue; + return this; + } + + /** + * The coupon code that was being evaluated when the rule failed. + * @return couponValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The coupon code that was being evaluated when the rule failed. ") + + public String getCouponValue() { + return couponValue; + } + + + public void setCouponValue(String couponValue) { + this.couponValue = couponValue; + } + + + public RuleEligibilityFailureDetails referralID(Long referralID) { + + this.referralID = referralID; + return this; + } + + /** + * The ID of the referral that was being evaluated when the rule failed. + * @return referralID + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The ID of the referral that was being evaluated when the rule failed. ") + + public Long getReferralID() { + return referralID; + } + + + public void setReferralID(Long referralID) { + this.referralID = referralID; + } + + + public RuleEligibilityFailureDetails referralValue(String referralValue) { + + this.referralValue = referralValue; + return this; + } + + /** + * The referral code that was being evaluated when the rule failed. + * @return referralValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The referral code that was being evaluated when the rule failed. ") + + public String getReferralValue() { + return referralValue; + } + + + public void setReferralValue(String referralValue) { + this.referralValue = referralValue; + } + + + public RuleEligibilityFailureDetails conditionIndex(Long conditionIndex) { + + this.conditionIndex = conditionIndex; + return this; + } + + /** + * The index of the condition that caused the rule to fail. + * @return conditionIndex + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The index of the condition that caused the rule to fail.") + + public Long getConditionIndex() { + return conditionIndex; + } + + + public void setConditionIndex(Long conditionIndex) { + this.conditionIndex = conditionIndex; + } + + + public RuleEligibilityFailureDetails effectIndex(Long effectIndex) { + + this.effectIndex = effectIndex; + return this; + } + + /** + * The index of the effect that caused the rule to fail. + * @return effectIndex + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The index of the effect that caused the rule to fail.") + + public Long getEffectIndex() { + return effectIndex; + } + + + public void setEffectIndex(Long effectIndex) { + this.effectIndex = effectIndex; + } + + + public RuleEligibilityFailureDetails details(String details) { + + this.details = details; + return this; + } + + /** + * Additional details about the failure. + * @return details + **/ + @ApiModelProperty(required = true, value = "Additional details about the failure.") + + public String getDetails() { + return details; + } + + + public void setDetails(String details) { + this.details = details; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RuleEligibilityFailureDetails ruleEligibilityFailureDetails = (RuleEligibilityFailureDetails) o; + return Objects.equals(this.failureCode, ruleEligibilityFailureDetails.failureCode) && + Objects.equals(this.couponID, ruleEligibilityFailureDetails.couponID) && + Objects.equals(this.couponValue, ruleEligibilityFailureDetails.couponValue) && + Objects.equals(this.referralID, ruleEligibilityFailureDetails.referralID) && + Objects.equals(this.referralValue, ruleEligibilityFailureDetails.referralValue) && + Objects.equals(this.conditionIndex, ruleEligibilityFailureDetails.conditionIndex) && + Objects.equals(this.effectIndex, ruleEligibilityFailureDetails.effectIndex) && + Objects.equals(this.details, ruleEligibilityFailureDetails.details); + } + + @Override + public int hashCode() { + return Objects.hash(failureCode, couponID, couponValue, referralID, referralValue, conditionIndex, effectIndex, details); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RuleEligibilityFailureDetails {\n"); + sb.append(" failureCode: ").append(toIndentedString(failureCode)).append("\n"); + sb.append(" couponID: ").append(toIndentedString(couponID)).append("\n"); + sb.append(" couponValue: ").append(toIndentedString(couponValue)).append("\n"); + sb.append(" referralID: ").append(toIndentedString(referralID)).append("\n"); + sb.append(" referralValue: ").append(toIndentedString(referralValue)).append("\n"); + sb.append(" conditionIndex: ").append(toIndentedString(conditionIndex)).append("\n"); + sb.append(" effectIndex: ").append(toIndentedString(effectIndex)).append("\n"); + sb.append(" details: ").append(toIndentedString(details)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RuleFailureReason.java b/src/main/java/one/talon/model/RuleFailureReason.java index c6b2f0cf..10335343 100644 --- a/src/main/java/one/talon/model/RuleFailureReason.java +++ b/src/main/java/one/talon/model/RuleFailureReason.java @@ -58,6 +58,14 @@ public class RuleFailureReason { @SerializedName(SERIALIZED_NAME_REFERRAL_VALUE) private String referralValue; + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + + public static final String SERIALIZED_NAME_REWARD_INTEGRATION_ID = "rewardIntegrationId"; + @SerializedName(SERIALIZED_NAME_REWARD_INTEGRATION_ID) + private String rewardIntegrationId; + public static final String SERIALIZED_NAME_RULE_INDEX = "ruleIndex"; @SerializedName(SERIALIZED_NAME_RULE_INDEX) private Long ruleIndex; @@ -245,6 +253,52 @@ public void setReferralValue(String referralValue) { } + public RuleFailureReason rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward that was being evaluated at the time of the rule failure. + * @return rewardId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The ID of the reward that was being evaluated at the time of the rule failure.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + + public RuleFailureReason rewardIntegrationId(String rewardIntegrationId) { + + this.rewardIntegrationId = rewardIntegrationId; + return this; + } + + /** + * The integration ID of the reward that was being evaluated at the time of the rule failure. + * @return rewardIntegrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90", value = "The integration ID of the reward that was being evaluated at the time of the rule failure.") + + public String getRewardIntegrationId() { + return rewardIntegrationId; + } + + + public void setRewardIntegrationId(String rewardIntegrationId) { + this.rewardIntegrationId = rewardIntegrationId; + } + + public RuleFailureReason ruleIndex(Long ruleIndex) { this.ruleIndex = ruleIndex; @@ -420,6 +474,8 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.couponValue, ruleFailureReason.couponValue) && Objects.equals(this.referralID, ruleFailureReason.referralID) && Objects.equals(this.referralValue, ruleFailureReason.referralValue) && + Objects.equals(this.rewardId, ruleFailureReason.rewardId) && + Objects.equals(this.rewardIntegrationId, ruleFailureReason.rewardIntegrationId) && Objects.equals(this.ruleIndex, ruleFailureReason.ruleIndex) && Objects.equals(this.ruleName, ruleFailureReason.ruleName) && Objects.equals(this.conditionIndex, ruleFailureReason.conditionIndex) && @@ -431,7 +487,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(campaignID, campaignName, rulesetID, couponID, couponValue, referralID, referralValue, ruleIndex, ruleName, conditionIndex, effectIndex, details, evaluationGroupID, evaluationGroupMode); + return Objects.hash(campaignID, campaignName, rulesetID, couponID, couponValue, referralID, referralValue, rewardId, rewardIntegrationId, ruleIndex, ruleName, conditionIndex, effectIndex, details, evaluationGroupID, evaluationGroupMode); } @@ -446,6 +502,8 @@ public String toString() { sb.append(" couponValue: ").append(toIndentedString(couponValue)).append("\n"); sb.append(" referralID: ").append(toIndentedString(referralID)).append("\n"); sb.append(" referralValue: ").append(toIndentedString(referralValue)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); + sb.append(" rewardIntegrationId: ").append(toIndentedString(rewardIntegrationId)).append("\n"); sb.append(" ruleIndex: ").append(toIndentedString(ruleIndex)).append("\n"); sb.append(" ruleName: ").append(toIndentedString(ruleName)).append("\n"); sb.append(" conditionIndex: ").append(toIndentedString(conditionIndex)).append("\n"); diff --git a/src/main/java/one/talon/model/RuleMetadataEligibility.java b/src/main/java/one/talon/model/RuleMetadataEligibility.java new file mode 100644 index 00000000..3f538727 --- /dev/null +++ b/src/main/java/one/talon/model/RuleMetadataEligibility.java @@ -0,0 +1,221 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RuleEligibility; + +/** + * RuleMetadataEligibility + */ + +public class RuleMetadataEligibility { + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_DISPLAY_NAME = "displayName"; + @SerializedName(SERIALIZED_NAME_DISPLAY_NAME) + private String displayName; + + public static final String SERIALIZED_NAME_DISPLAY_DESCRIPTION = "displayDescription"; + @SerializedName(SERIALIZED_NAME_DISPLAY_DESCRIPTION) + private String displayDescription; + + public static final String SERIALIZED_NAME_RELATED_DATA = "relatedData"; + @SerializedName(SERIALIZED_NAME_RELATED_DATA) + private String relatedData; + + public static final String SERIALIZED_NAME_ELIGIBILITY = "eligibility"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY) + private List eligibility = new ArrayList(); + + + public RuleMetadataEligibility title(String title) { + + this.title = title; + return this; + } + + /** + * A short description of the rule. + * @return title + **/ + @ApiModelProperty(example = "Give discount via coupon", required = true, value = "A short description of the rule.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public RuleMetadataEligibility displayName(String displayName) { + + this.displayName = displayName; + return this; + } + + /** + * A customer-facing name for the rule. + * @return displayName + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "20% off all shoes!", value = "A customer-facing name for the rule.") + + public String getDisplayName() { + return displayName; + } + + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + + public RuleMetadataEligibility displayDescription(String displayDescription) { + + this.displayDescription = displayDescription; + return this; + } + + /** + * A customer-facing description that explains the details of the rule. For example, this property can contain details about eligibility requirements, reward timelines, or terms and conditions. + * @return displayDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Get a 20% discount on all shoes during Thanksgiving! Offer valid till Dec 5 only.", value = "A customer-facing description that explains the details of the rule. For example, this property can contain details about eligibility requirements, reward timelines, or terms and conditions. ") + + public String getDisplayDescription() { + return displayDescription; + } + + + public void setDisplayDescription(String displayDescription) { + this.displayDescription = displayDescription; + } + + + public RuleMetadataEligibility relatedData(String relatedData) { + + this.relatedData = relatedData; + return this; + } + + /** + * Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. + * @return relatedData + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "https://example.com/discounts/20-off-shoes.png", value = "Any additional data associated with the rule, such as an image URL, vendor name, or a content management system (CMS) ID. ") + + public String getRelatedData() { + return relatedData; + } + + + public void setRelatedData(String relatedData) { + this.relatedData = relatedData; + } + + + public RuleMetadataEligibility eligibility(List eligibility) { + + this.eligibility = eligibility; + return this; + } + + public RuleMetadataEligibility addEligibilityItem(RuleEligibility eligibilityItem) { + this.eligibility.add(eligibilityItem); + return this; + } + + /** + * Get eligibility + * @return eligibility + **/ + @ApiModelProperty(required = true, value = "") + + public List getEligibility() { + return eligibility; + } + + + public void setEligibility(List eligibility) { + this.eligibility = eligibility; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RuleMetadataEligibility ruleMetadataEligibility = (RuleMetadataEligibility) o; + return Objects.equals(this.title, ruleMetadataEligibility.title) && + Objects.equals(this.displayName, ruleMetadataEligibility.displayName) && + Objects.equals(this.displayDescription, ruleMetadataEligibility.displayDescription) && + Objects.equals(this.relatedData, ruleMetadataEligibility.relatedData) && + Objects.equals(this.eligibility, ruleMetadataEligibility.eligibility); + } + + @Override + public int hashCode() { + return Objects.hash(title, displayName, displayDescription, relatedData, eligibility); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RuleMetadataEligibility {\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" displayName: ").append(toIndentedString(displayName)).append("\n"); + sb.append(" displayDescription: ").append(toIndentedString(displayDescription)).append("\n"); + sb.append(" relatedData: ").append(toIndentedString(relatedData)).append("\n"); + sb.append(" eligibility: ").append(toIndentedString(eligibility)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RuleV2.java b/src/main/java/one/talon/model/RuleV2.java new file mode 100644 index 00000000..563e318d --- /dev/null +++ b/src/main/java/one/talon/model/RuleV2.java @@ -0,0 +1,221 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * Shared fields common to all V2 rule types. + */ +@ApiModel(description = "Shared fields common to all V2 rule types.") + +public class RuleV2 { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_PARENT_ID = "parentId"; + @SerializedName(SERIALIZED_NAME_PARENT_ID) + private String parentId; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_BLOCKS = "blocks"; + @SerializedName(SERIALIZED_NAME_BLOCKS) + private List blocks = new ArrayList(); + + + public RuleV2 id(String id) { + + this.id = id; + return this; + } + + /** + * Unique identifier of the rule. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier of the rule.") + + public String getId() { + return id; + } + + + public void setId(String id) { + this.id = id; + } + + + public RuleV2 parentId(String parentId) { + + this.parentId = parentId; + return this; + } + + /** + * ID of the parent rule, if any. + * @return parentId + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "ID of the parent rule, if any.") + + public String getParentId() { + return parentId; + } + + + public void setParentId(String parentId) { + this.parentId = parentId; + } + + + public RuleV2 title(String title) { + + this.title = title; + return this; + } + + /** + * A short description of the rule. + * @return title + **/ + @ApiModelProperty(example = "10% off for loyalty members", required = true, value = "A short description of the rule.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public RuleV2 description(String description) { + + this.description = description; + return this; + } + + /** + * A longer description of the rule. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "A longer description of the rule.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public RuleV2 blocks(List blocks) { + + this.blocks = blocks; + return this; + } + + public RuleV2 addBlocksItem(Object blocksItem) { + this.blocks.add(blocksItem); + return this; + } + + /** + * The condition and effect blocks that make up this rule. + * @return blocks + **/ + @ApiModelProperty(required = true, value = "The condition and effect blocks that make up this rule.") + + public List getBlocks() { + return blocks; + } + + + public void setBlocks(List blocks) { + this.blocks = blocks; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RuleV2 ruleV2 = (RuleV2) o; + return Objects.equals(this.id, ruleV2.id) && + Objects.equals(this.parentId, ruleV2.parentId) && + Objects.equals(this.title, ruleV2.title) && + Objects.equals(this.description, ruleV2.description) && + Objects.equals(this.blocks, ruleV2.blocks); + } + + @Override + public int hashCode() { + return Objects.hash(id, parentId, title, description, blocks); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RuleV2 {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" parentId: ").append(toIndentedString(parentId)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" blocks: ").append(toIndentedString(blocks)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/RulesetV2.java b/src/main/java/one/talon/model/RulesetV2.java new file mode 100644 index 00000000..2613fc95 --- /dev/null +++ b/src/main/java/one/talon/model/RulesetV2.java @@ -0,0 +1,328 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.Bundle; +import one.talon.model.RuleV2; +import one.talon.model.Selector; +import one.talon.model.TemplateParameter; +import org.threeten.bp.OffsetDateTime; + +/** + * Ruleset in the V2 JSON block format. + */ +@ApiModel(description = "Ruleset in the V2 JSON block format.") + +public class RulesetV2 { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + public static final String SERIALIZED_NAME_USER_ID = "userId"; + @SerializedName(SERIALIZED_NAME_USER_ID) + private Long userId; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_TEMPLATE_ID = "templateId"; + @SerializedName(SERIALIZED_NAME_TEMPLATE_ID) + private Long templateId; + + public static final String SERIALIZED_NAME_ACTIVATED_AT = "activatedAt"; + @SerializedName(SERIALIZED_NAME_ACTIVATED_AT) + private OffsetDateTime activatedAt; + + public static final String SERIALIZED_NAME_PROMOTION_RULES = "promotionRules"; + @SerializedName(SERIALIZED_NAME_PROMOTION_RULES) + private List promotionRules = new ArrayList(); + + public static final String SERIALIZED_NAME_STRIKETHROUGH_RULES = "strikethroughRules"; + @SerializedName(SERIALIZED_NAME_STRIKETHROUGH_RULES) + private List strikethroughRules = null; + + public static final String SERIALIZED_NAME_SELECTORS = "selectors"; + @SerializedName(SERIALIZED_NAME_SELECTORS) + private List selectors = null; + + public static final String SERIALIZED_NAME_BUNDLES = "bundles"; + @SerializedName(SERIALIZED_NAME_BUNDLES) + private List bundles = null; + + public static final String SERIALIZED_NAME_PARAMETERS = "parameters"; + @SerializedName(SERIALIZED_NAME_PARAMETERS) + private List parameters = null; + + + /** + * Internal ID of this entity. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "6", value = "Internal ID of this entity.") + + public Long getId() { + return id; + } + + + + + /** + * The time this entity was created. + * @return created + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The time this entity was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + + + /** + * The ID of the user that created this ruleset. + * @return userId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "385", value = "The ID of the user that created this ruleset.") + + public Long getUserId() { + return userId; + } + + + + + /** + * The ID of the campaign that owns this entity. + * @return campaignId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "320", value = "The ID of the campaign that owns this entity.") + + public Long getCampaignId() { + return campaignId; + } + + + + + /** + * The ID of the campaign template that owns this entity. + * @return templateId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "3", value = "The ID of the campaign template that owns this entity.") + + public Long getTemplateId() { + return templateId; + } + + + + + /** + * Timestamp indicating when this ruleset was activated. + * @return activatedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Timestamp indicating when this ruleset was activated.") + + public OffsetDateTime getActivatedAt() { + return activatedAt; + } + + + + + public RulesetV2 promotionRules(List promotionRules) { + + this.promotionRules = promotionRules; + return this; + } + + public RulesetV2 addPromotionRulesItem(RuleV2 promotionRulesItem) { + this.promotionRules.add(promotionRulesItem); + return this; + } + + /** + * Set of promotion rules. + * @return promotionRules + **/ + @ApiModelProperty(required = true, value = "Set of promotion rules.") + + public List getPromotionRules() { + return promotionRules; + } + + + public void setPromotionRules(List promotionRules) { + this.promotionRules = promotionRules; + } + + + public RulesetV2 strikethroughRules(List strikethroughRules) { + + this.strikethroughRules = strikethroughRules; + return this; + } + + public RulesetV2 addStrikethroughRulesItem(RuleV2 strikethroughRulesItem) { + if (this.strikethroughRules == null) { + this.strikethroughRules = new ArrayList(); + } + this.strikethroughRules.add(strikethroughRulesItem); + return this; + } + + /** + * Set of strikethrough rules. + * @return strikethroughRules + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Set of strikethrough rules.") + + public List getStrikethroughRules() { + return strikethroughRules; + } + + + public void setStrikethroughRules(List strikethroughRules) { + this.strikethroughRules = strikethroughRules; + } + + + /** + * Variable bindings of type selector. + * @return selectors + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Variable bindings of type selector.") + + public List getSelectors() { + return selectors; + } + + + + + /** + * Variable bindings of type bundle. + * @return bundles + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Variable bindings of type bundle.") + + public List getBundles() { + return bundles; + } + + + + + /** + * Variable bindings of type template parameter. + * @return parameters + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Variable bindings of type template parameter.") + + public List getParameters() { + return parameters; + } + + + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RulesetV2 rulesetV2 = (RulesetV2) o; + return Objects.equals(this.id, rulesetV2.id) && + Objects.equals(this.created, rulesetV2.created) && + Objects.equals(this.userId, rulesetV2.userId) && + Objects.equals(this.campaignId, rulesetV2.campaignId) && + Objects.equals(this.templateId, rulesetV2.templateId) && + Objects.equals(this.activatedAt, rulesetV2.activatedAt) && + Objects.equals(this.promotionRules, rulesetV2.promotionRules) && + Objects.equals(this.strikethroughRules, rulesetV2.strikethroughRules) && + Objects.equals(this.selectors, rulesetV2.selectors) && + Objects.equals(this.bundles, rulesetV2.bundles) && + Objects.equals(this.parameters, rulesetV2.parameters); + } + + @Override + public int hashCode() { + return Objects.hash(id, created, userId, campaignId, templateId, activatedAt, promotionRules, strikethroughRules, selectors, bundles, parameters); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RulesetV2 {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" templateId: ").append(toIndentedString(templateId)).append("\n"); + sb.append(" activatedAt: ").append(toIndentedString(activatedAt)).append("\n"); + sb.append(" promotionRules: ").append(toIndentedString(promotionRules)).append("\n"); + sb.append(" strikethroughRules: ").append(toIndentedString(strikethroughRules)).append("\n"); + sb.append(" selectors: ").append(toIndentedString(selectors)).append("\n"); + sb.append(" bundles: ").append(toIndentedString(bundles)).append("\n"); + sb.append(" parameters: ").append(toIndentedString(parameters)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SamlConnection.java b/src/main/java/one/talon/model/SamlConnection.java index d7b2cb01..1c9abe09 100644 --- a/src/main/java/one/talon/model/SamlConnection.java +++ b/src/main/java/one/talon/model/SamlConnection.java @@ -35,6 +35,10 @@ public class SamlConnection { @SerializedName(SERIALIZED_NAME_ASSERTION_CONSUMER_SERVICE_U_R_L) private String assertionConsumerServiceURL; + public static final String SERIALIZED_NAME_CERTIFICATE_EXPIRY = "certificateExpiry"; + @SerializedName(SERIALIZED_NAME_CERTIFICATE_EXPIRY) + private OffsetDateTime certificateExpiry; + public static final String SERIALIZED_NAME_ACCOUNT_ID = "accountId"; @SerializedName(SERIALIZED_NAME_ACCOUNT_ID) private Long accountId; @@ -98,6 +102,29 @@ public void setAssertionConsumerServiceURL(String assertionConsumerServiceURL) { } + public SamlConnection certificateExpiry(OffsetDateTime certificateExpiry) { + + this.certificateExpiry = certificateExpiry; + return this; + } + + /** + * The expiry date of the X.509 certificate. + * @return certificateExpiry + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2021-07-20T21:59Z", value = "The expiry date of the X.509 certificate.") + + public OffsetDateTime getCertificateExpiry() { + return certificateExpiry; + } + + + public void setCertificateExpiry(OffsetDateTime certificateExpiry) { + this.certificateExpiry = certificateExpiry; + } + + public SamlConnection accountId(Long accountId) { this.accountId = accountId; @@ -330,6 +357,7 @@ public boolean equals(java.lang.Object o) { } SamlConnection samlConnection = (SamlConnection) o; return Objects.equals(this.assertionConsumerServiceURL, samlConnection.assertionConsumerServiceURL) && + Objects.equals(this.certificateExpiry, samlConnection.certificateExpiry) && Objects.equals(this.accountId, samlConnection.accountId) && Objects.equals(this.name, samlConnection.name) && Objects.equals(this.enabled, samlConnection.enabled) && @@ -344,7 +372,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(assertionConsumerServiceURL, accountId, name, enabled, issuer, signOnURL, signOutURL, metadataURL, audienceURI, id, created); + return Objects.hash(assertionConsumerServiceURL, certificateExpiry, accountId, name, enabled, issuer, signOnURL, signOutURL, metadataURL, audienceURI, id, created); } @@ -353,6 +381,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class SamlConnection {\n"); sb.append(" assertionConsumerServiceURL: ").append(toIndentedString(assertionConsumerServiceURL)).append("\n"); + sb.append(" certificateExpiry: ").append(toIndentedString(certificateExpiry)).append("\n"); sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); diff --git a/src/main/java/one/talon/model/ScalarCheckAttributeBlock.java b/src/main/java/one/talon/model/ScalarCheckAttributeBlock.java new file mode 100644 index 00000000..ae8167b1 --- /dev/null +++ b/src/main/java/one/talon/model/ScalarCheckAttributeBlock.java @@ -0,0 +1,205 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for operators that compare an attribute against a single value. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for operators that compare an attribute against a single value.") + +public class ScalarCheckAttributeBlock { + /** + * The comparison operator applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + EQUALS("equals"), + + NOT_EQUALS_("not(equals)"), + + LESSTHAN("lessThan"), + + LESSTHANOREQUAL("lessThanOrEqual"), + + GREATERTHAN("greaterThan"), + + GREATERTHANOREQUAL("greaterThanOrEqual"), + + CONTAINS("contains"), + + NOT_CONTAINS_("not(contains)"), + + MATCHESREGEXP("matchesRegexp"), + + STARTSWITH("startsWith"), + + ENDSWITH("endsWith"), + + ONEOF("oneOf"), + + NOT_ONEOF_("not(oneOf)"), + + INCOLLECTION("inCollection"), + + NOT_INCOLLECTION_("not(inCollection)"), + + AFTER("after"), + + BEFORE("before"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + + public ScalarCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The comparison operator applied to the attribute. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The comparison operator applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public ScalarCheckAttributeBlock value(Object value) { + + this.value = value; + return this; + } + + /** + * The comparison value for this operator. + * @return value + **/ + @ApiModelProperty(example = "100", required = true, value = "The comparison value for this operator.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ScalarCheckAttributeBlock scalarCheckAttributeBlock = (ScalarCheckAttributeBlock) o; + return Objects.equals(this.operator, scalarCheckAttributeBlock.operator) && + Objects.equals(this.value, scalarCheckAttributeBlock.value); + } + + @Override + public int hashCode() { + return Objects.hash(operator, value); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ScalarCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ScimBaseUserName.java b/src/main/java/one/talon/model/ScimBaseUserName.java index 4f04ab5d..78934eeb 100644 --- a/src/main/java/one/talon/model/ScimBaseUserName.java +++ b/src/main/java/one/talon/model/ScimBaseUserName.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The components of the user’s real name. + * The components of the user's real name. */ -@ApiModel(description = "The components of the user’s real name.") +@ApiModel(description = "The components of the user's real name.") public class ScimBaseUserName { public static final String SERIALIZED_NAME_FORMATTED = "formatted"; diff --git a/src/main/java/one/talon/model/SelectSelectorStep.java b/src/main/java/one/talon/model/SelectSelectorStep.java new file mode 100644 index 00000000..f230827d --- /dev/null +++ b/src/main/java/one/talon/model/SelectSelectorStep.java @@ -0,0 +1,366 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Picks a subset of the items by count, range, or exact position. The `operator` determines which additional fields are required: - `many` selects items from `from` (`start` or `end`) and is limited by `count`. - `between` selects items between integer indices `from` and `to`. - `one` selects the single item at `index`. + */ +@ApiModel(description = "Picks a subset of the items by count, range, or exact position. The `operator` determines which additional fields are required: - `many` selects items from `from` (`start` or `end`) and is limited by `count`. - `between` selects items between integer indices `from` and `to`. - `one` selects the single item at `index`.") + +public class SelectSelectorStep { + /** + * A step discriminator of type `select`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + SELECT("select"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + /** + * The selection operator applied to the items. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + MANY("many"), + + BETWEEN("between"), + + ONE("one"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_FROM = "from"; + @SerializedName(SERIALIZED_NAME_FROM) + private Object from; + + public static final String SERIALIZED_NAME_TO = "to"; + @SerializedName(SERIALIZED_NAME_TO) + private Integer to; + + public static final String SERIALIZED_NAME_COUNT = "count"; + @SerializedName(SERIALIZED_NAME_COUNT) + private Integer count; + + public static final String SERIALIZED_NAME_INDEX = "index"; + @SerializedName(SERIALIZED_NAME_INDEX) + private Integer index; + + public static final String SERIALIZED_NAME_PARTIAL = "partial"; + @SerializedName(SERIALIZED_NAME_PARTIAL) + private Boolean partial; + + + public SelectSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `select`. + * @return type + **/ + @ApiModelProperty(example = "select", required = true, value = "A step discriminator of type `select`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public SelectSelectorStep operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The selection operator applied to the items. + * @return operator + **/ + @ApiModelProperty(example = "many", required = true, value = "The selection operator applied to the items.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public SelectSelectorStep from(Object from) { + + this.from = from; + return this; + } + + /** + * The starting value of the selection. For the `many` operator this is the string `start` or `end`; for the `between` operator this is an integer start index. No discriminator is needed since the string and integer branches are distinguishable by JSON type alone. + * @return from + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The starting value of the selection. For the `many` operator this is the string `start` or `end`; for the `between` operator this is an integer start index. No discriminator is needed since the string and integer branches are distinguishable by JSON type alone.") + + public Object getFrom() { + return from; + } + + + public void setFrom(Object from) { + this.from = from; + } + + + public SelectSelectorStep to(Integer to) { + + this.to = to; + return this; + } + + /** + * The end index for the `between` operator. The item at this index is not included. + * @return to + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "7", value = "The end index for the `between` operator. The item at this index is not included.") + + public Integer getTo() { + return to; + } + + + public void setTo(Integer to) { + this.to = to; + } + + + public SelectSelectorStep count(Integer count) { + + this.count = count; + return this; + } + + /** + * The maximum number of items to select for the `many` operator. + * @return count + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "5", value = "The maximum number of items to select for the `many` operator.") + + public Integer getCount() { + return count; + } + + + public void setCount(Integer count) { + this.count = count; + } + + + public SelectSelectorStep index(Integer index) { + + this.index = index; + return this; + } + + /** + * The exact position of the item to select for the `one` operator. + * @return index + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "0", value = "The exact position of the item to select for the `one` operator.") + + public Integer getIndex() { + return index; + } + + + public void setIndex(Integer index) { + this.index = index; + } + + + public SelectSelectorStep partial(Boolean partial) { + + this.partial = partial; + return this; + } + + /** + * Indicates if the step returns fewer items than requested when the source list is shorter than the range needs. Always `true` for the `many` and `between` operators; not present for `one`, which fails instead of returning a partial result. + * @return partial + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "Indicates if the step returns fewer items than requested when the source list is shorter than the range needs. Always `true` for the `many` and `between` operators; not present for `one`, which fails instead of returning a partial result.") + + public Boolean getPartial() { + return partial; + } + + + public void setPartial(Boolean partial) { + this.partial = partial; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SelectSelectorStep selectSelectorStep = (SelectSelectorStep) o; + return Objects.equals(this.type, selectSelectorStep.type) && + Objects.equals(this.operator, selectSelectorStep.operator) && + Objects.equals(this.from, selectSelectorStep.from) && + Objects.equals(this.to, selectSelectorStep.to) && + Objects.equals(this.count, selectSelectorStep.count) && + Objects.equals(this.index, selectSelectorStep.index) && + Objects.equals(this.partial, selectSelectorStep.partial); + } + + @Override + public int hashCode() { + return Objects.hash(type, operator, from, to, count, index, partial); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SelectSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" from: ").append(toIndentedString(from)).append("\n"); + sb.append(" to: ").append(toIndentedString(to)).append("\n"); + sb.append(" count: ").append(toIndentedString(count)).append("\n"); + sb.append(" index: ").append(toIndentedString(index)).append("\n"); + sb.append(" partial: ").append(toIndentedString(partial)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/Selector.java b/src/main/java/one/talon/model/Selector.java new file mode 100644 index 00000000..1827187b --- /dev/null +++ b/src/main/java/one/talon/model/Selector.java @@ -0,0 +1,235 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * A named pipeline of steps (filter, sort, map, etc.) that filters or transforms a list of cart items. Replaces `cartItemFilter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. + */ +@ApiModel(description = "A named pipeline of steps (filter, sort, map, etc.) that filters or transforms a list of cart items. Replaces `cartItemFilter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets.") + +public class Selector { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + /** + * A binding of type `selector`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + SELECTOR("selector"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_SOURCE = "source"; + @SerializedName(SERIALIZED_NAME_SOURCE) + private String source; + + public static final String SERIALIZED_NAME_STEPS = "steps"; + @SerializedName(SERIALIZED_NAME_STEPS) + private List steps = new ArrayList(); + + + public Selector name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the selector binding. + * @return name + **/ + @ApiModelProperty(example = "discountedCartItems", required = true, value = "The name of the selector binding.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public Selector type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A binding of type `selector`. + * @return type + **/ + @ApiModelProperty(example = "selector", required = true, value = "A binding of type `selector`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public Selector source(String source) { + + this.source = source; + return this; + } + + /** + * The attribute path the pipeline draws items from. + * @return source + **/ + @ApiModelProperty(example = "$Session.CartItems", required = true, value = "The attribute path the pipeline draws items from.") + + public String getSource() { + return source; + } + + + public void setSource(String source) { + this.source = source; + } + + + public Selector steps(List steps) { + + this.steps = steps; + return this; + } + + public Selector addStepsItem(Object stepsItem) { + this.steps.add(stepsItem); + return this; + } + + /** + * Ordered pipeline steps applied to the source items. + * @return steps + **/ + @ApiModelProperty(required = true, value = "Ordered pipeline steps applied to the source items.") + + public List getSteps() { + return steps; + } + + + public void setSteps(List steps) { + this.steps = steps; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Selector selector = (Selector) o; + return Objects.equals(this.name, selector.name) && + Objects.equals(this.type, selector.type) && + Objects.equals(this.source, selector.source) && + Objects.equals(this.steps, selector.steps); + } + + @Override + public int hashCode() { + return Objects.hash(name, type, source, steps); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class Selector {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" source: ").append(toIndentedString(source)).append("\n"); + sb.append(" steps: ").append(toIndentedString(steps)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SelectorValueMapRef.java b/src/main/java/one/talon/model/SelectorValueMapRef.java new file mode 100644 index 00000000..d45a5d6b --- /dev/null +++ b/src/main/java/one/talon/model/SelectorValueMapRef.java @@ -0,0 +1,99 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * A reference to a value map by its internal ID. + */ +@ApiModel(description = "A reference to a value map by its internal ID.") + +public class SelectorValueMapRef { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + + public SelectorValueMapRef id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of the referenced value map. + * @return id + **/ + @ApiModelProperty(example = "12", required = true, value = "The internal ID of the referenced value map.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SelectorValueMapRef selectorValueMapRef = (SelectorValueMapRef) o; + return Objects.equals(this.id, selectorValueMapRef.id); + } + + @Override + public int hashCode() { + return Objects.hash(id); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SelectorValueMapRef {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SetDiscountEffectProps.java b/src/main/java/one/talon/model/SetDiscountEffectProps.java index 98520650..bc06b8e1 100644 --- a/src/main/java/one/talon/model/SetDiscountEffectProps.java +++ b/src/main/java/one/talon/model/SetDiscountEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"setDiscount\" effect. This gets triggered whenever a validated rule contained a \"set discount\" effect. This is a discount that should be applied on the scope of defined with it. + * This effect indicates that a discount should be set on the total shopping cart value of the current order with the given label and amount. The discount should overwrite any existing discount with the same name. The most recent integration state update always returns the latest values for **all** effects, effectively overwriting any previous effects. Enabling [partial discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches `0`. Use the `desiredValue` property to identify the original value of the discount. */ -@ApiModel(description = "The properties specific to the \"setDiscount\" effect. This gets triggered whenever a validated rule contained a \"set discount\" effect. This is a discount that should be applied on the scope of defined with it.") +@ApiModel(description = "This effect indicates that a discount should be set on the total shopping cart value of the current order with the given label and amount. The discount should overwrite any existing discount with the same name. The most recent integration state update always returns the latest values for **all** effects, effectively overwriting any previous effects. Enabling [partial discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches `0`. Use the `desiredValue` property to identify the original value of the discount.") public class SetDiscountEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -55,10 +55,10 @@ public SetDiscountEffectProps name(String name) { } /** - * The name / description of this discount + * The name or description of this discount. * @return name **/ - @ApiModelProperty(required = true, value = "The name / description of this discount") + @ApiModelProperty(required = true, value = "The name or description of this discount.") public String getName() { return name; @@ -77,10 +77,10 @@ public SetDiscountEffectProps value(BigDecimal value) { } /** - * The total monetary value of the discount. + * The monetary value of the effective discount. * @return value **/ - @ApiModelProperty(required = true, value = "The total monetary value of the discount.") + @ApiModelProperty(required = true, value = "The monetary value of the effective discount.") public BigDecimal getValue() { return value; @@ -99,11 +99,11 @@ public SetDiscountEffectProps scope(String scope) { } /** - * The scope which the discount was applied on, can be one of (cartItems,additionalCosts,sessionTotal). + * What the discount applies to. Possible values: - `cartItems`: Discount on the price of the items. - `additionalCosts`: Discount on the [additional costs](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the items. - `sessionTotal`: Discount on the total value of the customer session. **Note:** [Cascading discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#cascading-discounts) must be enabled for this property to be returned. * @return scope **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The scope which the discount was applied on, can be one of (cartItems,additionalCosts,sessionTotal).") + @ApiModelProperty(value = "What the discount applies to. Possible values: - `cartItems`: Discount on the price of the items. - `additionalCosts`: Discount on the [additional costs](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the items. - `sessionTotal`: Discount on the total value of the customer session. **Note:** [Cascading discounts](https://docs.talon.one/docs/product/applications/manage-general-settings#cascading-discounts) must be enabled for this property to be returned.") public String getScope() { return scope; @@ -122,11 +122,11 @@ public SetDiscountEffectProps desiredValue(BigDecimal desiredValue) { } /** - * The original value of the discount. + * _(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations. * @return desiredValue **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The original value of the discount.") + @ApiModelProperty(value = "_(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations.") public BigDecimal getDesiredValue() { return desiredValue; diff --git a/src/main/java/one/talon/model/SetDiscountPerAdditionalCostEffectProps.java b/src/main/java/one/talon/model/SetDiscountPerAdditionalCostEffectProps.java index b53fc8f8..8dc4a886 100644 --- a/src/main/java/one/talon/model/SetDiscountPerAdditionalCostEffectProps.java +++ b/src/main/java/one/talon/model/SetDiscountPerAdditionalCostEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"setDiscountPerAdditionalCost\" effect. This gets triggered whenever a validated rule contained a \"set per additional cost discount\" effect. This is a discount that should be applied on a specific additional cost. + * This effect indicates that a discount that should be applied on a specific additional cost. It is triggered whenever a rule containing a **Discount additional cost** effect is validated. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points. */ -@ApiModel(description = "The properties specific to the \"setDiscountPerAdditionalCost\" effect. This gets triggered whenever a validated rule contained a \"set per additional cost discount\" effect. This is a discount that should be applied on a specific additional cost.") +@ApiModel(description = "This effect indicates that a discount that should be applied on a specific additional cost. It is triggered whenever a rule containing a **Discount additional cost** effect is validated. Enabling [partial rewards](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-rewards) allows a rule that would fail because of insufficient budget to pass. The rule still fails when the budget reaches 0. Use the `desiredValue` property to identify the original amount of loyalty points.") public class SetDiscountPerAdditionalCostEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -59,10 +59,10 @@ public SetDiscountPerAdditionalCostEffectProps name(String name) { } /** - * The name / description of this discount + * The name of the discount. * @return name **/ - @ApiModelProperty(required = true, value = "The name / description of this discount") + @ApiModelProperty(required = true, value = "The name of the discount.") public String getName() { return name; @@ -81,10 +81,10 @@ public SetDiscountPerAdditionalCostEffectProps additionalCostId(Long additionalC } /** - * The ID of the additional cost. + * The identifier of the additional cost. * @return additionalCostId **/ - @ApiModelProperty(required = true, value = "The ID of the additional cost.") + @ApiModelProperty(required = true, value = "The identifier of the additional cost.") public Long getAdditionalCostId() { return additionalCostId; @@ -103,10 +103,10 @@ public SetDiscountPerAdditionalCostEffectProps additionalCost(String additionalC } /** - * The name of the additional cost. + * The API name of the additional cost. * @return additionalCost **/ - @ApiModelProperty(required = true, value = "The name of the additional cost.") + @ApiModelProperty(required = true, value = "The API name of the additional cost.") public String getAdditionalCost() { return additionalCost; @@ -125,10 +125,10 @@ public SetDiscountPerAdditionalCostEffectProps value(BigDecimal value) { } /** - * The total monetary value of the discount. + * The monetary value of the discount to apply. * @return value **/ - @ApiModelProperty(required = true, value = "The total monetary value of the discount.") + @ApiModelProperty(required = true, value = "The monetary value of the discount to apply.") public BigDecimal getValue() { return value; @@ -147,11 +147,11 @@ public SetDiscountPerAdditionalCostEffectProps desiredValue(BigDecimal desiredVa } /** - * The original value of the discount. + * _(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations. * @return desiredValue **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The original value of the discount.") + @ApiModelProperty(value = "_(Partial discounts enabled only)_ The monetary value of the discount to be applied without considering budget limitations.") public BigDecimal getDesiredValue() { return desiredValue; diff --git a/src/main/java/one/talon/model/SetDiscountPerAdditionalCostPerItemEffectProps.java b/src/main/java/one/talon/model/SetDiscountPerAdditionalCostPerItemEffectProps.java index e3f47df8..5d03ba84 100644 --- a/src/main/java/one/talon/model/SetDiscountPerAdditionalCostPerItemEffectProps.java +++ b/src/main/java/one/talon/model/SetDiscountPerAdditionalCostPerItemEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"setDiscountPerAdditionalCostPerItem\" effect. This gets triggered whenever a validated rule contained a \"set discount per additional cost per item\" effect. This is a discount that should be applied on a specific additional cost in a specific item. + * This effect indicates that a discount of a specific additional cost within a specific item should be applied. It gets triggered whenever a rule containing a **Discount additional cost per item** effect is validated. Use this effect when **all** items in the cart have an additional cost. If one of more items do not have an additional cost, the rule will fail. */ -@ApiModel(description = "The properties specific to the \"setDiscountPerAdditionalCostPerItem\" effect. This gets triggered whenever a validated rule contained a \"set discount per additional cost per item\" effect. This is a discount that should be applied on a specific additional cost in a specific item.") +@ApiModel(description = "This effect indicates that a discount of a specific additional cost within a specific item should be applied. It gets triggered whenever a rule containing a **Discount additional cost per item** effect is validated. Use this effect when **all** items in the cart have an additional cost. If one of more items do not have an additional cost, the rule will fail.") public class SetDiscountPerAdditionalCostPerItemEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -67,10 +67,10 @@ public SetDiscountPerAdditionalCostPerItemEffectProps name(String name) { } /** - * The name / description of this discount + * The description of this discount. `#number` is appended to the name. It is equal to the `position` property. * @return name **/ - @ApiModelProperty(required = true, value = "The name / description of this discount") + @ApiModelProperty(required = true, value = "The description of this discount. `#number` is appended to the name. It is equal to the `position` property.") public String getName() { return name; @@ -89,10 +89,10 @@ public SetDiscountPerAdditionalCostPerItemEffectProps additionalCostId(Long addi } /** - * The ID of the additional cost. + * The identifier of the additional cost to be discounted. * @return additionalCostId **/ - @ApiModelProperty(required = true, value = "The ID of the additional cost.") + @ApiModelProperty(required = true, value = "The identifier of the additional cost to be discounted.") public Long getAdditionalCostId() { return additionalCostId; @@ -111,10 +111,10 @@ public SetDiscountPerAdditionalCostPerItemEffectProps value(BigDecimal value) { } /** - * The total monetary value of the discount. + * The monetary value of the effective discount applied to the item's additional cost. * @return value **/ - @ApiModelProperty(required = true, value = "The total monetary value of the discount.") + @ApiModelProperty(required = true, value = "The monetary value of the effective discount applied to the item's additional cost.") public BigDecimal getValue() { return value; @@ -133,10 +133,10 @@ public SetDiscountPerAdditionalCostPerItemEffectProps position(BigDecimal positi } /** - * The index of the item in the cart item list containing the additional cost to be discounted. + * The index of the item in the `cartItem` object containing the additional cost that this discount applies to. * @return position **/ - @ApiModelProperty(required = true, value = "The index of the item in the cart item list containing the additional cost to be discounted.") + @ApiModelProperty(required = true, value = "The index of the item in the `cartItem` object containing the additional cost that this discount applies to.") public BigDecimal getPosition() { return position; @@ -155,11 +155,11 @@ public SetDiscountPerAdditionalCostPerItemEffectProps subPosition(BigDecimal sub } /** - * For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. + * The index of the item unit in its line item. * @return subPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. ") + @ApiModelProperty(value = "The index of the item unit in its line item.") public BigDecimal getSubPosition() { return subPosition; @@ -178,10 +178,10 @@ public SetDiscountPerAdditionalCostPerItemEffectProps additionalCost(String addi } /** - * The name of the additional cost. + * The API name of the additional cost to be discounted. * @return additionalCost **/ - @ApiModelProperty(required = true, value = "The name of the additional cost.") + @ApiModelProperty(required = true, value = "The API name of the additional cost to be discounted.") public String getAdditionalCost() { return additionalCost; @@ -200,11 +200,11 @@ public SetDiscountPerAdditionalCostPerItemEffectProps desiredValue(BigDecimal de } /** - * Only with [partial discounts enabled](https://docs.talon.one/docs/product/campaigns/campaign-evaluation/#partial-discounts). Represents the monetary value of the discount to be applied to additional discount without considering budget limitations. + * _[(Partial discounts enabled only)](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts)_. The monetary value of the discount to be applied to the additional cost without considering budget limitations. * @return desiredValue **/ @javax.annotation.Nullable - @ApiModelProperty(value = "Only with [partial discounts enabled](https://docs.talon.one/docs/product/campaigns/campaign-evaluation/#partial-discounts). Represents the monetary value of the discount to be applied to additional discount without considering budget limitations. ") + @ApiModelProperty(value = "_[(Partial discounts enabled only)](https://docs.talon.one/docs/product/applications/manage-general-settings#partial-discounts)_. The monetary value of the discount to be applied to the additional cost without considering budget limitations.") public BigDecimal getDesiredValue() { return desiredValue; diff --git a/src/main/java/one/talon/model/SetDiscountPerItemEffectProps.java b/src/main/java/one/talon/model/SetDiscountPerItemEffectProps.java index 1399e3db..c3dde3e0 100644 --- a/src/main/java/one/talon/model/SetDiscountPerItemEffectProps.java +++ b/src/main/java/one/talon/model/SetDiscountPerItemEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the `setDiscountPerItem` effect, triggered whenever a validated rule contained a \"set per item discount\" effect. This is a discount that will be applied either on a specific item, on a specific item + additional cost or on all additional costs per item. This depends on the chosen scope. + * This effect schema is returned when you use the **Discount individual items**, **Discount individual items pro rata**, or **Discount individual item in bundles** effect in a rule. It indicates that a discount per item should be applied on the specific item specified in the effect. The properties it contains depends on: - Whether you used a pro rata effect or not. - Whether you used an effect with bundles or not. - Whether the partial discount feature is enabled. */ -@ApiModel(description = "The properties specific to the `setDiscountPerItem` effect, triggered whenever a validated rule contained a \"set per item discount\" effect. This is a discount that will be applied either on a specific item, on a specific item + additional cost or on all additional costs per item. This depends on the chosen scope. ") +@ApiModel(description = "This effect schema is returned when you use the **Discount individual items**, **Discount individual items pro rata**, or **Discount individual item in bundles** effect in a rule. It indicates that a discount per item should be applied on the specific item specified in the effect. The properties it contains depends on: - Whether you used a pro rata effect or not. - Whether you used an effect with bundles or not. - Whether the partial discount feature is enabled.") public class SetDiscountPerItemEffectProps { public static final String SERIALIZED_NAME_NAME = "name"; @@ -91,10 +91,10 @@ public SetDiscountPerItemEffectProps name(String name) { } /** - * The name of the discount. Contains a hashtag character indicating the index of the position of the item the discount applies to. It is identical to the value of the `position` property. + * The description of this discount. `#number` is equal to the `position` property. * @return name **/ - @ApiModelProperty(required = true, value = "The name of the discount. Contains a hashtag character indicating the index of the position of the item the discount applies to. It is identical to the value of the `position` property. ") + @ApiModelProperty(required = true, value = "The description of this discount. `#number` is equal to the `position` property.") public String getName() { return name; @@ -113,10 +113,10 @@ public SetDiscountPerItemEffectProps value(BigDecimal value) { } /** - * The total monetary value of the discount. + * The monetary value of the effective discount applied to the item. * @return value **/ - @ApiModelProperty(required = true, value = "The total monetary value of the discount.") + @ApiModelProperty(required = true, value = "The monetary value of the effective discount applied to the item.") public BigDecimal getValue() { return value; @@ -135,10 +135,10 @@ public SetDiscountPerItemEffectProps position(BigDecimal position) { } /** - * The index of the item in the cart items list on which this discount should be applied. + * The index of the item in the `cartItem` object on which this discount should be applied. * @return position **/ - @ApiModelProperty(required = true, value = "The index of the item in the cart items list on which this discount should be applied.") + @ApiModelProperty(required = true, value = "The index of the item in the `cartItem` object on which this discount should be applied.") public BigDecimal getPosition() { return position; @@ -157,11 +157,11 @@ public SetDiscountPerItemEffectProps subPosition(BigDecimal subPosition) { } /** - * For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. + * The index of the item unit in its line item. * @return subPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "For cart items with `quantity` > 1, the sub position indicates which item the discount applies to. ") + @ApiModelProperty(value = "The index of the item unit in its line item.") public BigDecimal getSubPosition() { return subPosition; @@ -180,11 +180,11 @@ public SetDiscountPerItemEffectProps desiredValue(BigDecimal desiredValue) { } /** - * The original value of the discount. + * _(Partial discounts enabled only)_ The monetary value of the discount to be applied to the item without considering budget limitations. * @return desiredValue **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The original value of the discount.") + @ApiModelProperty(value = "_(Partial discounts enabled only)_ The monetary value of the discount to be applied to the item without considering budget limitations.") public BigDecimal getDesiredValue() { return desiredValue; @@ -203,11 +203,11 @@ public SetDiscountPerItemEffectProps scope(String scope) { } /** - * The scope of the discount: - `additionalCosts`: The discount applies to all the additional costs of the item. - `itemTotal`: The discount applies to the price of the item + the additional costs of the item. - `price`: The discount applies to the price of the item. + * What the discount applies to. Possible values: - `price`: discount on the price of the item. - `additionalCosts`: discount on the [additional cost](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the item. - `itemTotal`: discount on the sum of price + additional cost of the item. * @return scope **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The scope of the discount: - `additionalCosts`: The discount applies to all the additional costs of the item. - `itemTotal`: The discount applies to the price of the item + the additional costs of the item. - `price`: The discount applies to the price of the item. ") + @ApiModelProperty(value = "What the discount applies to. Possible values: - `price`: discount on the price of the item. - `additionalCosts`: discount on the [additional cost](https://docs.talon.one/docs/product/account/dev-tools/manage-additional-costs) of the item. - `itemTotal`: discount on the sum of price + additional cost of the item.") public String getScope() { return scope; @@ -226,11 +226,11 @@ public SetDiscountPerItemEffectProps totalDiscount(BigDecimal totalDiscount) { } /** - * The total discount given if this effect is a result of a prorated discount. + * _(Pro rata discounts only)_ The monetary value of the total effective discount * @return totalDiscount **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The total discount given if this effect is a result of a prorated discount.") + @ApiModelProperty(value = "_(Pro rata discounts only)_ The monetary value of the total effective discount") public BigDecimal getTotalDiscount() { return totalDiscount; @@ -249,11 +249,11 @@ public SetDiscountPerItemEffectProps desiredTotalDiscount(BigDecimal desiredTota } /** - * The original total discount to give if this effect is a result of a prorated discount. + * _(Pro rata discounts only)_ The monetary value of the total discount to be applied without considering budget limitations * @return desiredTotalDiscount **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The original total discount to give if this effect is a result of a prorated discount.") + @ApiModelProperty(value = "_(Pro rata discounts only)_ The monetary value of the total discount to be applied without considering budget limitations") public BigDecimal getDesiredTotalDiscount() { return desiredTotalDiscount; @@ -272,11 +272,11 @@ public SetDiscountPerItemEffectProps bundleIndex(Long bundleIndex) { } /** - * The position of the bundle in a list of item bundles created from the same bundle definition. + * _(Discounts with bundles only)_ The position of the specific item bundle in the list of bundles created from the same bundle definition. * @return bundleIndex **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The position of the bundle in a list of item bundles created from the same bundle definition.") + @ApiModelProperty(value = "_(Discounts with bundles only)_ The position of the specific item bundle in the list of bundles created from the same bundle definition.") public Long getBundleIndex() { return bundleIndex; @@ -295,11 +295,11 @@ public SetDiscountPerItemEffectProps bundleName(String bundleName) { } /** - * The name of the bundle definition. + * _(Discounts with bundles only)_ The name of the bundle definition. * @return bundleName **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The name of the bundle definition.") + @ApiModelProperty(value = "_(Discounts with bundles only)_ The name of the bundle definition.") public String getBundleName() { return bundleName; @@ -318,11 +318,11 @@ public SetDiscountPerItemEffectProps targetedItemPosition(BigDecimal targetedIte } /** - * The index of the targeted bundle item on which the applied discount is based. + * _(Discounting individual item in bundles only)_ The index of the targeted bundle item on which the applied discount is based. * @return targetedItemPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The index of the targeted bundle item on which the applied discount is based.") + @ApiModelProperty(value = "_(Discounting individual item in bundles only)_ The index of the targeted bundle item on which the applied discount is based.") public BigDecimal getTargetedItemPosition() { return targetedItemPosition; @@ -341,11 +341,11 @@ public SetDiscountPerItemEffectProps targetedItemSubPosition(BigDecimal targeted } /** - * The sub-position of the targeted bundle item on which the applied discount is based. + * _(Discounting individual item in bundles only)_ The sub-position of the targeted bundle item on which the applied discount is based. * @return targetedItemSubPosition **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The sub-position of the targeted bundle item on which the applied discount is based. ") + @ApiModelProperty(value = "_(Discounting individual item in bundles only)_ The sub-position of the targeted bundle item on which the applied discount is based.") public BigDecimal getTargetedItemSubPosition() { return targetedItemSubPosition; diff --git a/src/main/java/one/talon/model/SetLoyaltyPointsExpiryDateEffectProps.java b/src/main/java/one/talon/model/SetLoyaltyPointsExpiryDateEffectProps.java index 36996edf..2a19612d 100644 --- a/src/main/java/one/talon/model/SetLoyaltyPointsExpiryDateEffectProps.java +++ b/src/main/java/one/talon/model/SetLoyaltyPointsExpiryDateEffectProps.java @@ -29,9 +29,9 @@ import org.threeten.bp.OffsetDateTime; /** - * The properties specific to the \"setLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"set expiry date\" effect. The current expiry date gets set to the date given in the effect. + * This effect updates the expiry date of all active, pending, and unlimited point transactions to a specific date. */ -@ApiModel(description = "The properties specific to the \"setLoyaltyPointsExpiryDate\" effect. This gets triggered when a validated rule contains the \"set expiry date\" effect. The current expiry date gets set to the date given in the effect. ") +@ApiModel(description = "This effect updates the expiry date of all active, pending, and unlimited point transactions to a specific date. ") public class SetLoyaltyPointsExpiryDateEffectProps { public static final String SERIALIZED_NAME_PROGRAM_ID = "programId"; diff --git a/src/main/java/one/talon/model/ShowBundleMetadataEffectProps.java b/src/main/java/one/talon/model/ShowBundleMetadataEffectProps.java index eaf7c736..45b7e21e 100644 --- a/src/main/java/one/talon/model/ShowBundleMetadataEffectProps.java +++ b/src/main/java/one/talon/model/ShowBundleMetadataEffectProps.java @@ -28,9 +28,9 @@ import java.util.List; /** - * This effect is **deprecated**. The properties specific to the \"ShowBundleMetadata\" effect. This effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle. + * This effect is **deprecated**. The `ShowBundleMetadata` effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle. */ -@ApiModel(description = "This effect is **deprecated**. The properties specific to the \"ShowBundleMetadata\" effect. This effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle. ") +@ApiModel(description = "This effect is **deprecated**. The `ShowBundleMetadata` effect contains information that allows you to associate the discounts from a rule in a bundle campaign with specific cart items. This way you can distinguish from \"normal\" discounts that were not the result of a product bundle.") public class ShowBundleMetadataEffectProps { public static final String SERIALIZED_NAME_DESCRIPTION = "description"; diff --git a/src/main/java/one/talon/model/ShowNotificationBlock.java b/src/main/java/one/talon/model/ShowNotificationBlock.java new file mode 100644 index 00000000..2f512685 --- /dev/null +++ b/src/main/java/one/talon/model/ShowNotificationBlock.java @@ -0,0 +1,302 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * A block that displays a notification to the customer with a configurable type, title, and optional body message. + */ +@ApiModel(description = "A block that displays a notification to the customer with a configurable type, title, and optional body message.") + +public class ShowNotificationBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_NOTIFICATION_TYPE = "notificationType"; + @SerializedName(SERIALIZED_NAME_NOTIFICATION_TYPE) + private String notificationType; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_BODY = "body"; + @SerializedName(SERIALIZED_NAME_BODY) + private String body; + + public static final String SERIALIZED_NAME_ON_FAILURE = "onFailure"; + @SerializedName(SERIALIZED_NAME_ON_FAILURE) + private List onFailure = null; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public ShowNotificationBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public ShowNotificationBlock notificationType(String notificationType) { + + this.notificationType = notificationType; + return this; + } + + /** + * The type of notification to display. + * @return notificationType + **/ + @ApiModelProperty(example = "Info", required = true, value = "The type of notification to display.") + + public String getNotificationType() { + return notificationType; + } + + + public void setNotificationType(String notificationType) { + this.notificationType = notificationType; + } + + + public ShowNotificationBlock title(String title) { + + this.title = title; + return this; + } + + /** + * The notification heading shown to the customer. + * @return title + **/ + @ApiModelProperty(example = "You earned a reward!", required = true, value = "The notification heading shown to the customer.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public ShowNotificationBlock body(String body) { + + this.body = body; + return this; + } + + /** + * The notification body text. Supports template placeholders (e.g. \"{{$Session.Total}}\") evaluated at rule execution time. + * @return body + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "You saved $10 on your order.", value = "The notification body text. Supports template placeholders (e.g. \"{{$Session.Total}}\") evaluated at rule execution time.") + + public String getBody() { + return body; + } + + + public void setBody(String body) { + this.body = body; + } + + + public ShowNotificationBlock onFailure(List onFailure) { + + this.onFailure = onFailure; + return this; + } + + public ShowNotificationBlock addOnFailureItem(Object onFailureItem) { + if (this.onFailure == null) { + this.onFailure = new ArrayList(); + } + this.onFailure.add(onFailureItem); + return this; + } + + /** + * Blocks evaluated when this block fails or returns false. + * @return onFailure + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Blocks evaluated when this block fails or returns false.") + + public List getOnFailure() { + return onFailure; + } + + + public void setOnFailure(List onFailure) { + this.onFailure = onFailure; + } + + + public ShowNotificationBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public ShowNotificationBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ShowNotificationBlock showNotificationBlock = (ShowNotificationBlock) o; + return Objects.equals(this.id, showNotificationBlock.id) && + Objects.equals(this.type, showNotificationBlock.type) && + Objects.equals(this.tags, showNotificationBlock.tags) && + Objects.equals(this.notificationType, showNotificationBlock.notificationType) && + Objects.equals(this.title, showNotificationBlock.title) && + Objects.equals(this.body, showNotificationBlock.body) && + Objects.equals(this.onFailure, showNotificationBlock.onFailure) && + Objects.equals(this.onError, showNotificationBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, notificationType, title, body, onFailure, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ShowNotificationBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" notificationType: ").append(toIndentedString(notificationType)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" body: ").append(toIndentedString(body)).append("\n"); + sb.append(" onFailure: ").append(toIndentedString(onFailure)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/ShowNotificationEffectProps.java b/src/main/java/one/talon/model/ShowNotificationEffectProps.java index 408cd7b1..ff5b12c3 100644 --- a/src/main/java/one/talon/model/ShowNotificationEffectProps.java +++ b/src/main/java/one/talon/model/ShowNotificationEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"showNotification\" effect. This gets triggered whenever a validated rule contained a \"show notification\" effect. + * You can use notifications to inform customers of certain events. There are four types of notification messages: - `Info` - `Offer` - `Error` - `Misc` It is up to you to use the Rule Builder to decide why and when to show notifications. Notifications can be used as both rule effects and failure effects. A common use case is to display the notification at the top of the cart view in your web app. You can use the notification type to vary the styling of the notification message. */ -@ApiModel(description = "The properties specific to the \"showNotification\" effect. This gets triggered whenever a validated rule contained a \"show notification\" effect.") +@ApiModel(description = "You can use notifications to inform customers of certain events. There are four types of notification messages: - `Info` - `Offer` - `Error` - `Misc` It is up to you to use the Rule Builder to decide why and when to show notifications. Notifications can be used as both rule effects and failure effects. A common use case is to display the notification at the top of the cart view in your web app. You can use the notification type to vary the styling of the notification message.") public class ShowNotificationEffectProps { public static final String SERIALIZED_NAME_NOTIFICATION_TYPE = "notificationType"; @@ -50,10 +50,10 @@ public ShowNotificationEffectProps notificationType(String notificationType) { } /** - * The type of notification that should be shown (e.g. error/warning/info). + * The type of notification. * @return notificationType **/ - @ApiModelProperty(required = true, value = "The type of notification that should be shown (e.g. error/warning/info).") + @ApiModelProperty(required = true, value = "The type of notification.") public String getNotificationType() { return notificationType; @@ -72,10 +72,10 @@ public ShowNotificationEffectProps title(String title) { } /** - * Title of the notification. + * The title of the notification. * @return title **/ - @ApiModelProperty(required = true, value = "Title of the notification.") + @ApiModelProperty(required = true, value = "The title of the notification.") public String getTitle() { return title; @@ -94,10 +94,10 @@ public ShowNotificationEffectProps body(String body) { } /** - * Body of the notification. + * The body of the notification. * @return body **/ - @ApiModelProperty(required = true, value = "Body of the notification.") + @ApiModelProperty(required = true, value = "The body of the notification.") public String getBody() { return body; diff --git a/src/main/java/one/talon/model/SortSelectorStep.java b/src/main/java/one/talon/model/SortSelectorStep.java new file mode 100644 index 00000000..ca198fca --- /dev/null +++ b/src/main/java/one/talon/model/SortSelectorStep.java @@ -0,0 +1,180 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.SortSelectorStepField; + +/** + * Sorts items by one or more field expressions. + */ +@ApiModel(description = "Sorts items by one or more field expressions.") + +public class SortSelectorStep { + /** + * A step discriminator of type `sort`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + SORT("sort"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_FIELDS = "fields"; + @SerializedName(SERIALIZED_NAME_FIELDS) + private List fields = new ArrayList(); + + + public SortSelectorStep type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A step discriminator of type `sort`. + * @return type + **/ + @ApiModelProperty(example = "sort", required = true, value = "A step discriminator of type `sort`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public SortSelectorStep fields(List fields) { + + this.fields = fields; + return this; + } + + public SortSelectorStep addFieldsItem(SortSelectorStepField fieldsItem) { + this.fields.add(fieldsItem); + return this; + } + + /** + * One or more fields to sort by, applied in order. Each field has its own direction. + * @return fields + **/ + @ApiModelProperty(required = true, value = "One or more fields to sort by, applied in order. Each field has its own direction.") + + public List getFields() { + return fields; + } + + + public void setFields(List fields) { + this.fields = fields; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SortSelectorStep sortSelectorStep = (SortSelectorStep) o; + return Objects.equals(this.type, sortSelectorStep.type) && + Objects.equals(this.fields, sortSelectorStep.fields); + } + + @Override + public int hashCode() { + return Objects.hash(type, fields); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SortSelectorStep {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" fields: ").append(toIndentedString(fields)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SortSelectorStepField.java b/src/main/java/one/talon/model/SortSelectorStepField.java new file mode 100644 index 00000000..d3e728f4 --- /dev/null +++ b/src/main/java/one/talon/model/SortSelectorStepField.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * SortSelectorStepField + */ + +public class SortSelectorStepField { + public static final String SERIALIZED_NAME_EXPRESSION = "expression"; + @SerializedName(SERIALIZED_NAME_EXPRESSION) + private String expression; + + /** + * The sort direction for this field. + */ + @JsonAdapter(DirectionEnum.Adapter.class) + public enum DirectionEnum { + ASC("asc"), + + DESC("desc"); + + private String value; + + DirectionEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static DirectionEnum fromValue(String value) { + for (DirectionEnum b : DirectionEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final DirectionEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public DirectionEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return DirectionEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_DIRECTION = "direction"; + @SerializedName(SERIALIZED_NAME_DIRECTION) + private DirectionEnum direction; + + + public SortSelectorStepField expression(String expression) { + + this.expression = expression; + return this; + } + + /** + * The attribute path the items are sorted by. + * @return expression + **/ + @ApiModelProperty(example = "$Item.Price", required = true, value = "The attribute path the items are sorted by.") + + public String getExpression() { + return expression; + } + + + public void setExpression(String expression) { + this.expression = expression; + } + + + public SortSelectorStepField direction(DirectionEnum direction) { + + this.direction = direction; + return this; + } + + /** + * The sort direction for this field. + * @return direction + **/ + @ApiModelProperty(example = "asc", required = true, value = "The sort direction for this field.") + + public DirectionEnum getDirection() { + return direction; + } + + + public void setDirection(DirectionEnum direction) { + this.direction = direction; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SortSelectorStepField sortSelectorStepField = (SortSelectorStepField) o; + return Objects.equals(this.expression, sortSelectorStepField.expression) && + Objects.equals(this.direction, sortSelectorStepField.direction); + } + + @Override + public int hashCode() { + return Objects.hash(expression, direction); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SortSelectorStepField {\n"); + sb.append(" expression: ").append(toIndentedString(expression)).append("\n"); + sb.append(" direction: ").append(toIndentedString(direction)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/StartAchievementProgressEffectProps.java b/src/main/java/one/talon/model/StartAchievementProgressEffectProps.java new file mode 100644 index 00000000..f1d6234d --- /dev/null +++ b/src/main/java/one/talon/model/StartAchievementProgressEffectProps.java @@ -0,0 +1,243 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.threeten.bp.OffsetDateTime; + +/** + * This effect indicates that the customer's progress in an achievement was started during the current session. The progress value is set to 0. It is triggered when a rule using the [Start achievement progress](https://docs.talon.one/docs/product/rules/effects/use-effects#start-achievement-progress) effect is successfully validated. This effect only marks the start of progress tracking. It can fire together with `increaseAchievementProgress` when progress starts and increases at the same time. In that case, both effects share the same `progressTrackerId`, `startDate`, and `endDate`. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), each iteration also gets its own `startDate` and `endDate`. + */ +@ApiModel(description = "This effect indicates that the customer's progress in an achievement was started during the current session. The progress value is set to 0. It is triggered when a rule using the [Start achievement progress](https://docs.talon.one/docs/product/rules/effects/use-effects#start-achievement-progress) effect is successfully validated. This effect only marks the start of progress tracking. It can fire together with `increaseAchievementProgress` when progress starts and increases at the same time. In that case, both effects share the same `progressTrackerId`, `startDate`, and `endDate`. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), each iteration also gets its own `startDate` and `endDate`. ") + +public class StartAchievementProgressEffectProps { + public static final String SERIALIZED_NAME_ACHIEVEMENT_ID = "achievementId"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENT_ID) + private Long achievementId; + + public static final String SERIALIZED_NAME_ACHIEVEMENT_NAME = "achievementName"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENT_NAME) + private String achievementName; + + public static final String SERIALIZED_NAME_PROGRESS_TRACKER_ID = "progressTrackerId"; + @SerializedName(SERIALIZED_NAME_PROGRESS_TRACKER_ID) + private Long progressTrackerId; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private BigDecimal target; + + public static final String SERIALIZED_NAME_START_DATE = "startDate"; + @SerializedName(SERIALIZED_NAME_START_DATE) + private OffsetDateTime startDate; + + public static final String SERIALIZED_NAME_END_DATE = "endDate"; + @SerializedName(SERIALIZED_NAME_END_DATE) + private OffsetDateTime endDate; + + + public StartAchievementProgressEffectProps achievementId(Long achievementId) { + + this.achievementId = achievementId; + return this; + } + + /** + * The ID of the achievement. + * @return achievementId + **/ + @ApiModelProperty(example = "10", required = true, value = "The ID of the achievement.") + + public Long getAchievementId() { + return achievementId; + } + + + public void setAchievementId(Long achievementId) { + this.achievementId = achievementId; + } + + + public StartAchievementProgressEffectProps achievementName(String achievementName) { + + this.achievementName = achievementName; + return this; + } + + /** + * The name of the achievement. + * @return achievementName + **/ + @ApiModelProperty(example = "FreeCoffee10Orders", required = true, value = "The name of the achievement.") + + public String getAchievementName() { + return achievementName; + } + + + public void setAchievementName(String achievementName) { + this.achievementName = achievementName; + } + + + public StartAchievementProgressEffectProps progressTrackerId(Long progressTrackerId) { + + this.progressTrackerId = progressTrackerId; + return this; + } + + /** + * The ID of the customer's progress tracker for this achievement. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration. + * @return progressTrackerId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The ID of the customer's progress tracker for this achievement. For [on-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements), this effect generates a unique ID for each iteration.") + + public Long getProgressTrackerId() { + return progressTrackerId; + } + + + public void setProgressTrackerId(Long progressTrackerId) { + this.progressTrackerId = progressTrackerId; + } + + + public StartAchievementProgressEffectProps target(BigDecimal target) { + + this.target = target; + return this; + } + + /** + * The target value to complete the achievement. + * @return target + **/ + @ApiModelProperty(example = "10.0", required = true, value = "The target value to complete the achievement.") + + public BigDecimal getTarget() { + return target; + } + + + public void setTarget(BigDecimal target) { + this.target = target; + } + + + public StartAchievementProgressEffectProps startDate(OffsetDateTime startDate) { + + this.startDate = startDate; + return this; + } + + /** + * Timestamp at which the customer's progress started. + * @return startDate + **/ + @ApiModelProperty(example = "2026-04-16T15:25:37Z", required = true, value = "Timestamp at which the customer's progress started.") + + public OffsetDateTime getStartDate() { + return startDate; + } + + + public void setStartDate(OffsetDateTime startDate) { + this.startDate = startDate; + } + + + public StartAchievementProgressEffectProps endDate(OffsetDateTime endDate) { + + this.endDate = endDate; + return this; + } + + /** + * Timestamp at which this progress period ends. Only returned for achievements that have a fixed end date. [On-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements) have no end date. + * @return endDate + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2026-04-30T11:24:59Z", value = "Timestamp at which this progress period ends. Only returned for achievements that have a fixed end date. [On-completion achievements](https://docs.talon.one/docs/product/campaigns/achievements/overview#recurring-on-completion-achievements) have no end date.") + + public OffsetDateTime getEndDate() { + return endDate; + } + + + public void setEndDate(OffsetDateTime endDate) { + this.endDate = endDate; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + StartAchievementProgressEffectProps startAchievementProgressEffectProps = (StartAchievementProgressEffectProps) o; + return Objects.equals(this.achievementId, startAchievementProgressEffectProps.achievementId) && + Objects.equals(this.achievementName, startAchievementProgressEffectProps.achievementName) && + Objects.equals(this.progressTrackerId, startAchievementProgressEffectProps.progressTrackerId) && + Objects.equals(this.target, startAchievementProgressEffectProps.target) && + Objects.equals(this.startDate, startAchievementProgressEffectProps.startDate) && + Objects.equals(this.endDate, startAchievementProgressEffectProps.endDate); + } + + @Override + public int hashCode() { + return Objects.hash(achievementId, achievementName, progressTrackerId, target, startDate, endDate); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class StartAchievementProgressEffectProps {\n"); + sb.append(" achievementId: ").append(toIndentedString(achievementId)).append("\n"); + sb.append(" achievementName: ").append(toIndentedString(achievementName)).append("\n"); + sb.append(" progressTrackerId: ").append(toIndentedString(progressTrackerId)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); + sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/StrikethroughLabelingNotification.java b/src/main/java/one/talon/model/StrikethroughLabelingNotification.java index d303efb6..55677ae5 100644 --- a/src/main/java/one/talon/model/StrikethroughLabelingNotification.java +++ b/src/main/java/one/talon/model/StrikethroughLabelingNotification.java @@ -36,7 +36,7 @@ public class StrikethroughLabelingNotification { /** - * The version of the strikethrough pricing notification. + * The version of the strikethrough pricing notification. Set for **scheduled** strikethrough pricing updates only. */ @JsonAdapter(VersionEnum.Adapter.class) public enum VersionEnum { @@ -169,11 +169,11 @@ public StrikethroughLabelingNotification version(VersionEnum version) { } /** - * The version of the strikethrough pricing notification. + * The version of the strikethrough pricing notification. Set for **scheduled** strikethrough pricing updates only. * @return version **/ @javax.annotation.Nullable - @ApiModelProperty(value = "The version of the strikethrough pricing notification.") + @ApiModelProperty(value = "The version of the strikethrough pricing notification. Set for **scheduled** strikethrough pricing updates only. ") public VersionEnum getVersion() { return version; diff --git a/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemEffectProps.java b/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemEffectProps.java index 1c87e9e6..f68b62fd 100644 --- a/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemEffectProps.java +++ b/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemEffectProps.java @@ -50,10 +50,10 @@ public StrikethroughSetDiscountPerItemEffectProps name(String name) { } /** - * effect name. + * The effect name. * @return name **/ - @ApiModelProperty(example = "1EuroOff", required = true, value = "effect name.") + @ApiModelProperty(example = "1EuroOff", required = true, value = "The effect name.") public String getName() { return name; @@ -72,10 +72,10 @@ public StrikethroughSetDiscountPerItemEffectProps value(Object value) { } /** - * discount value. + * The discount value. * @return value **/ - @ApiModelProperty(example = "1", required = true, value = "discount value.") + @ApiModelProperty(example = "1", required = true, value = "The discount value.") public Object getValue() { return value; @@ -94,11 +94,11 @@ public StrikethroughSetDiscountPerItemEffectProps excludedFromPriceHistory(Boole } /** - * Get excludedFromPriceHistory + * When set to `true`, the applied discount is excluded from the item's price history. * @return excludedFromPriceHistory **/ @javax.annotation.Nullable - @ApiModelProperty(value = "") + @ApiModelProperty(value = "When set to `true`, the applied discount is excluded from the item's price history.") public Boolean getExcludedFromPriceHistory() { return excludedFromPriceHistory; diff --git a/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemMemberEffectProps.java b/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemMemberEffectProps.java index 4771a98f..6b454016 100644 --- a/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemMemberEffectProps.java +++ b/src/main/java/one/talon/model/StrikethroughSetDiscountPerItemMemberEffectProps.java @@ -46,10 +46,10 @@ public StrikethroughSetDiscountPerItemMemberEffectProps name(String name) { } /** - * effect name. + * The effect name. * @return name **/ - @ApiModelProperty(example = "10% off members only", required = true, value = "effect name.") + @ApiModelProperty(example = "10% off members only", required = true, value = "The effect name.") public String getName() { return name; @@ -68,10 +68,10 @@ public StrikethroughSetDiscountPerItemMemberEffectProps value(Object value) { } /** - * discount value. + * The discount value. * @return value **/ - @ApiModelProperty(example = "9", required = true, value = "discount value.") + @ApiModelProperty(example = "9", required = true, value = "The discount value.") public Object getValue() { return value; diff --git a/src/main/java/one/talon/model/SupportCustomerProfile.java b/src/main/java/one/talon/model/SupportCustomerProfile.java new file mode 100644 index 00000000..c017634a --- /dev/null +++ b/src/main/java/one/talon/model/SupportCustomerProfile.java @@ -0,0 +1,219 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.ApplicationMembership; +import org.threeten.bp.OffsetDateTime; + +/** + * SupportCustomerProfile + */ + +public class SupportCustomerProfile { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_ATTRIBUTES = "attributes"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES) + private Object attributes; + + public static final String SERIALIZED_NAME_APPLICATION_MEMBERSHIPS = "applicationMemberships"; + @SerializedName(SERIALIZED_NAME_APPLICATION_MEMBERSHIPS) + private List applicationMemberships = new ArrayList(); + + + public SupportCustomerProfile id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of the customer profile. + * @return id + **/ + @ApiModelProperty(example = "6", required = true, value = "The internal ID of the customer profile.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public SupportCustomerProfile created(OffsetDateTime created) { + + this.created = created; + return this; + } + + /** + * The time the customer profile was created. + * @return created + **/ + @ApiModelProperty(example = "2020-06-10T09:05:27.993483Z", required = true, value = "The time the customer profile was created.") + + public OffsetDateTime getCreated() { + return created; + } + + + public void setCreated(OffsetDateTime created) { + this.created = created; + } + + + public SupportCustomerProfile integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID set by your integration layer. + * @return integrationId + **/ + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The integration ID set by your integration layer.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public SupportCustomerProfile attributes(Object attributes) { + + this.attributes = attributes; + return this; + } + + /** + * Arbitrary properties associated with this item. + * @return attributes + **/ + @ApiModelProperty(example = "{\"Language\":\"english\",\"ShippingCountry\":\"DE\"}", required = true, value = "Arbitrary properties associated with this item.") + + public Object getAttributes() { + return attributes; + } + + + public void setAttributes(Object attributes) { + this.attributes = attributes; + } + + + public SupportCustomerProfile applicationMemberships(List applicationMemberships) { + + this.applicationMemberships = applicationMemberships; + return this; + } + + public SupportCustomerProfile addApplicationMembershipsItem(ApplicationMembership applicationMembershipsItem) { + this.applicationMemberships.add(applicationMembershipsItem); + return this; + } + + /** + * The applications the customer belongs to. + * @return applicationMemberships + **/ + @ApiModelProperty(required = true, value = "The applications the customer belongs to.") + + public List getApplicationMemberships() { + return applicationMemberships; + } + + + public void setApplicationMemberships(List applicationMemberships) { + this.applicationMemberships = applicationMemberships; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SupportCustomerProfile supportCustomerProfile = (SupportCustomerProfile) o; + return Objects.equals(this.id, supportCustomerProfile.id) && + Objects.equals(this.created, supportCustomerProfile.created) && + Objects.equals(this.integrationId, supportCustomerProfile.integrationId) && + Objects.equals(this.attributes, supportCustomerProfile.attributes) && + Objects.equals(this.applicationMemberships, supportCustomerProfile.applicationMemberships); + } + + @Override + public int hashCode() { + return Objects.hash(id, created, integrationId, attributes, applicationMemberships); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SupportCustomerProfile {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); + sb.append(" applicationMemberships: ").append(toIndentedString(applicationMemberships)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SupportRequest.java b/src/main/java/one/talon/model/SupportRequest.java new file mode 100644 index 00000000..bcbaad08 --- /dev/null +++ b/src/main/java/one/talon/model/SupportRequest.java @@ -0,0 +1,630 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; + +/** + * Summary of a support request created by a customer support agent. + */ +@ApiModel(description = "Summary of a support request created by a customer support agent.") + +public class SupportRequest { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_SUBLEDGER_ID = "subledgerId"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER_ID) + private Long subledgerId; + + public static final String SERIALIZED_NAME_CREATED_BY_USER = "createdByUser"; + @SerializedName(SERIALIZED_NAME_CREATED_BY_USER) + private String createdByUser; + + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + @SerializedName(SERIALIZED_NAME_CREATED_AT) + private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_CUSTOMER_PROFILE_ID = "customerProfileId"; + @SerializedName(SERIALIZED_NAME_CUSTOMER_PROFILE_ID) + private String customerProfileId; + + /** + * Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. + */ + @JsonAdapter(RequestTypeEnum.Adapter.class) + public enum RequestTypeEnum { + GIFT_CARD("gift_card"), + + PERSONAL_COUPON("personal_coupon"), + + LOYALTY_POINTS_ADDED("loyalty_points_added"), + + LOYALTY_POINTS_DEDUCTED("loyalty_points_deducted"); + + private String value; + + RequestTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RequestTypeEnum fromValue(String value) { + for (RequestTypeEnum b : RequestTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RequestTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RequestTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RequestTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_REQUEST_TYPE = "requestType"; + @SerializedName(SERIALIZED_NAME_REQUEST_TYPE) + private RequestTypeEnum requestType; + + public static final String SERIALIZED_NAME_REQUEST_VALUE = "requestValue"; + @SerializedName(SERIALIZED_NAME_REQUEST_VALUE) + private Float requestValue; + + public static final String SERIALIZED_NAME_REQUEST_NOTE = "requestNote"; + @SerializedName(SERIALIZED_NAME_REQUEST_NOTE) + private String requestNote; + + /** + * Current status of the support request. + */ + @JsonAdapter(RequestStatusEnum.Adapter.class) + public enum RequestStatusEnum { + PENDING_APPROVAL("pending_approval"), + + APPROVED("approved"), + + REJECTED("rejected"), + + EXPIRED("expired"); + + private String value; + + RequestStatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RequestStatusEnum fromValue(String value) { + for (RequestStatusEnum b : RequestStatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RequestStatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RequestStatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RequestStatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_REQUEST_STATUS = "requestStatus"; + @SerializedName(SERIALIZED_NAME_REQUEST_STATUS) + private RequestStatusEnum requestStatus; + + public static final String SERIALIZED_NAME_PROCESSED_AT = "processedAt"; + @SerializedName(SERIALIZED_NAME_PROCESSED_AT) + private OffsetDateTime processedAt; + + public static final String SERIALIZED_NAME_PROCESSING_NOTE = "processingNote"; + @SerializedName(SERIALIZED_NAME_PROCESSING_NOTE) + private String processingNote; + + public static final String SERIALIZED_NAME_PROCESSED_BY_USER = "processedByUser"; + @SerializedName(SERIALIZED_NAME_PROCESSED_BY_USER) + private String processedByUser; + + public static final String SERIALIZED_NAME_COUPON_CODE = "couponCode"; + @SerializedName(SERIALIZED_NAME_COUPON_CODE) + private String couponCode; + + + public SupportRequest id(Long id) { + + this.id = id; + return this; + } + + /** + * Identifier of the support request. + * @return id + **/ + @ApiModelProperty(example = "1", required = true, value = "Identifier of the support request.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public SupportRequest applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL. + * @return applicationId + **/ + @ApiModelProperty(example = "322", required = true, value = "Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public SupportRequest campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * Identifier of the campaign where the coupon or gift card is created. + * @return campaignId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "Identifier of the campaign where the coupon or gift card is created.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public SupportRequest loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * Identifier of the loyalty program where the points are added or deducted. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "8", value = "Identifier of the loyalty program where the points are added or deducted.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public SupportRequest subledgerId(Long subledgerId) { + + this.subledgerId = subledgerId; + return this; + } + + /** + * Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically. + * @return subledgerId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "123", value = "Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically.") + + public Long getSubledgerId() { + return subledgerId; + } + + + public void setSubledgerId(Long subledgerId) { + this.subledgerId = subledgerId; + } + + + public SupportRequest createdByUser(String createdByUser) { + + this.createdByUser = createdByUser; + return this; + } + + /** + * Email address of the customer support agent who created the support request. + * @return createdByUser + **/ + @ApiModelProperty(example = "support.agent.name@company.com", required = true, value = "Email address of the customer support agent who created the support request.") + + public String getCreatedByUser() { + return createdByUser; + } + + + public void setCreatedByUser(String createdByUser) { + this.createdByUser = createdByUser; + } + + + public SupportRequest createdAt(OffsetDateTime createdAt) { + + this.createdAt = createdAt; + return this; + } + + /** + * Timestamp when the request was made. + * @return createdAt + **/ + @ApiModelProperty(example = "2025-07-20T22:00Z", required = true, value = "Timestamp when the request was made.") + + public OffsetDateTime getCreatedAt() { + return createdAt; + } + + + public void setCreatedAt(OffsetDateTime createdAt) { + this.createdAt = createdAt; + } + + + public SupportRequest customerProfileId(String customerProfileId) { + + this.customerProfileId = customerProfileId; + return this; + } + + /** + * Integration ID of the customer profile linked to the support request. + * @return customerProfileId + **/ + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "Integration ID of the customer profile linked to the support request.") + + public String getCustomerProfileId() { + return customerProfileId; + } + + + public void setCustomerProfileId(String customerProfileId) { + this.customerProfileId = customerProfileId; + } + + + public SupportRequest requestType(RequestTypeEnum requestType) { + + this.requestType = requestType; + return this; + } + + /** + * Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. + * @return requestType + **/ + @ApiModelProperty(example = "personal_coupon", required = true, value = "Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions.") + + public RequestTypeEnum getRequestType() { + return requestType; + } + + + public void setRequestType(RequestTypeEnum requestType) { + this.requestType = requestType; + } + + + public SupportRequest requestValue(Float requestValue) { + + this.requestValue = requestValue; + return this; + } + + /** + * Requested monetary balance of the gift card or the number of loyalty points to be added or deducted. + * @return requestValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "20.5", value = "Requested monetary balance of the gift card or the number of loyalty points to be added or deducted.") + + public Float getRequestValue() { + return requestValue; + } + + + public void setRequestValue(Float requestValue) { + this.requestValue = requestValue; + } + + + public SupportRequest requestNote(String requestNote) { + + this.requestNote = requestNote; + return this; + } + + /** + * Notes attached to the support request. + * @return requestNote + **/ + @ApiModelProperty(example = "Support request for coupon failure.", required = true, value = "Notes attached to the support request.") + + public String getRequestNote() { + return requestNote; + } + + + public void setRequestNote(String requestNote) { + this.requestNote = requestNote; + } + + + public SupportRequest requestStatus(RequestStatusEnum requestStatus) { + + this.requestStatus = requestStatus; + return this; + } + + /** + * Current status of the support request. + * @return requestStatus + **/ + @ApiModelProperty(example = "approved", required = true, value = "Current status of the support request.") + + public RequestStatusEnum getRequestStatus() { + return requestStatus; + } + + + public void setRequestStatus(RequestStatusEnum requestStatus) { + this.requestStatus = requestStatus; + } + + + public SupportRequest processedAt(OffsetDateTime processedAt) { + + this.processedAt = processedAt; + return this; + } + + /** + * Timestamp when the request was approved or rejected. + * @return processedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "2025-07-20T22:10Z", value = "Timestamp when the request was approved or rejected.") + + public OffsetDateTime getProcessedAt() { + return processedAt; + } + + + public void setProcessedAt(OffsetDateTime processedAt) { + this.processedAt = processedAt; + } + + + public SupportRequest processingNote(String processingNote) { + + this.processingNote = processingNote; + return this; + } + + /** + * Notes attached by the admin when rejecting or approving a request. + * @return processingNote + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Rejected as the customer was awarded points already.", value = "Notes attached by the admin when rejecting or approving a request.") + + public String getProcessingNote() { + return processingNote; + } + + + public void setProcessingNote(String processingNote) { + this.processingNote = processingNote; + } + + + public SupportRequest processedByUser(String processedByUser) { + + this.processedByUser = processedByUser; + return this; + } + + /** + * Email address of the admin who approved or rejected the support request. + * @return processedByUser + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "admin.name@company.com", value = "Email address of the admin who approved or rejected the support request.") + + public String getProcessedByUser() { + return processedByUser; + } + + + public void setProcessedByUser(String processedByUser) { + this.processedByUser = processedByUser; + } + + + public SupportRequest couponCode(String couponCode) { + + this.couponCode = couponCode; + return this; + } + + /** + * Coupon code associated with the approved support request. + * @return couponCode + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "SUMMER-2025-XYZ", value = "Coupon code associated with the approved support request.") + + public String getCouponCode() { + return couponCode; + } + + + public void setCouponCode(String couponCode) { + this.couponCode = couponCode; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SupportRequest supportRequest = (SupportRequest) o; + return Objects.equals(this.id, supportRequest.id) && + Objects.equals(this.applicationId, supportRequest.applicationId) && + Objects.equals(this.campaignId, supportRequest.campaignId) && + Objects.equals(this.loyaltyProgramId, supportRequest.loyaltyProgramId) && + Objects.equals(this.subledgerId, supportRequest.subledgerId) && + Objects.equals(this.createdByUser, supportRequest.createdByUser) && + Objects.equals(this.createdAt, supportRequest.createdAt) && + Objects.equals(this.customerProfileId, supportRequest.customerProfileId) && + Objects.equals(this.requestType, supportRequest.requestType) && + Objects.equals(this.requestValue, supportRequest.requestValue) && + Objects.equals(this.requestNote, supportRequest.requestNote) && + Objects.equals(this.requestStatus, supportRequest.requestStatus) && + Objects.equals(this.processedAt, supportRequest.processedAt) && + Objects.equals(this.processingNote, supportRequest.processingNote) && + Objects.equals(this.processedByUser, supportRequest.processedByUser) && + Objects.equals(this.couponCode, supportRequest.couponCode); + } + + @Override + public int hashCode() { + return Objects.hash(id, applicationId, campaignId, loyaltyProgramId, subledgerId, createdByUser, createdAt, customerProfileId, requestType, requestValue, requestNote, requestStatus, processedAt, processingNote, processedByUser, couponCode); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SupportRequest {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" subledgerId: ").append(toIndentedString(subledgerId)).append("\n"); + sb.append(" createdByUser: ").append(toIndentedString(createdByUser)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" customerProfileId: ").append(toIndentedString(customerProfileId)).append("\n"); + sb.append(" requestType: ").append(toIndentedString(requestType)).append("\n"); + sb.append(" requestValue: ").append(toIndentedString(requestValue)).append("\n"); + sb.append(" requestNote: ").append(toIndentedString(requestNote)).append("\n"); + sb.append(" requestStatus: ").append(toIndentedString(requestStatus)).append("\n"); + sb.append(" processedAt: ").append(toIndentedString(processedAt)).append("\n"); + sb.append(" processingNote: ").append(toIndentedString(processingNote)).append("\n"); + sb.append(" processedByUser: ").append(toIndentedString(processedByUser)).append("\n"); + sb.append(" couponCode: ").append(toIndentedString(couponCode)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/SupportRequestInput.java b/src/main/java/one/talon/model/SupportRequestInput.java new file mode 100644 index 00000000..4325bdf7 --- /dev/null +++ b/src/main/java/one/talon/model/SupportRequestInput.java @@ -0,0 +1,349 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * SupportRequestInput + */ + +public class SupportRequestInput { + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_CAMPAIGN_ID = "campaignId"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_ID) + private Long campaignId; + + public static final String SERIALIZED_NAME_LOYALTY_PROGRAM_ID = "loyaltyProgramId"; + @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAM_ID) + private Long loyaltyProgramId; + + public static final String SERIALIZED_NAME_SUBLEDGER_ID = "subledgerId"; + @SerializedName(SERIALIZED_NAME_SUBLEDGER_ID) + private Long subledgerId; + + public static final String SERIALIZED_NAME_CUSTOMER_PROFILE_ID = "customerProfileId"; + @SerializedName(SERIALIZED_NAME_CUSTOMER_PROFILE_ID) + private String customerProfileId; + + /** + * Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. + */ + @JsonAdapter(RequestTypeEnum.Adapter.class) + public enum RequestTypeEnum { + GIFT_CARD("gift_card"), + + PERSONAL_COUPON("personal_coupon"), + + LOYALTY_POINTS_ADDED("loyalty_points_added"), + + LOYALTY_POINTS_DEDUCTED("loyalty_points_deducted"); + + private String value; + + RequestTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RequestTypeEnum fromValue(String value) { + for (RequestTypeEnum b : RequestTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RequestTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RequestTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RequestTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_REQUEST_TYPE = "requestType"; + @SerializedName(SERIALIZED_NAME_REQUEST_TYPE) + private RequestTypeEnum requestType; + + public static final String SERIALIZED_NAME_REQUEST_VALUE = "requestValue"; + @SerializedName(SERIALIZED_NAME_REQUEST_VALUE) + private Float requestValue; + + public static final String SERIALIZED_NAME_REQUEST_NOTE = "requestNote"; + @SerializedName(SERIALIZED_NAME_REQUEST_NOTE) + private String requestNote; + + + public SupportRequestInput applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL. + * @return applicationId + **/ + @ApiModelProperty(example = "322", required = true, value = "Identifier of the Application connected to the loyalty program or the campaign. It is displayed in your Talon.One deployment URL.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public SupportRequestInput campaignId(Long campaignId) { + + this.campaignId = campaignId; + return this; + } + + /** + * Identifier of the campaign where the coupon or gift card is created. + * @return campaignId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "100", value = "Identifier of the campaign where the coupon or gift card is created.") + + public Long getCampaignId() { + return campaignId; + } + + + public void setCampaignId(Long campaignId) { + this.campaignId = campaignId; + } + + + public SupportRequestInput loyaltyProgramId(Long loyaltyProgramId) { + + this.loyaltyProgramId = loyaltyProgramId; + return this; + } + + /** + * Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. + * @return loyaltyProgramId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "8", value = "Identifier of the loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint.") + + public Long getLoyaltyProgramId() { + return loyaltyProgramId; + } + + + public void setLoyaltyProgramId(Long loyaltyProgramId) { + this.loyaltyProgramId = loyaltyProgramId; + } + + + public SupportRequestInput subledgerId(Long subledgerId) { + + this.subledgerId = subledgerId; + return this; + } + + /** + * Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically. + * @return subledgerId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "123", value = "Identifier of the subledger the points are added to or deducted from. If there is no existing subledger with this ID, the subledger is created automatically.") + + public Long getSubledgerId() { + return subledgerId; + } + + + public void setSubledgerId(Long subledgerId) { + this.subledgerId = subledgerId; + } + + + public SupportRequestInput customerProfileId(String customerProfileId) { + + this.customerProfileId = customerProfileId; + return this; + } + + /** + * Integration ID of the customer profile linked to the support request. + * @return customerProfileId + **/ + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "Integration ID of the customer profile linked to the support request.") + + public String getCustomerProfileId() { + return customerProfileId; + } + + + public void setCustomerProfileId(String customerProfileId) { + this.customerProfileId = customerProfileId; + } + + + public SupportRequestInput requestType(RequestTypeEnum requestType) { + + this.requestType = requestType; + return this; + } + + /** + * Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions. + * @return requestType + **/ + @ApiModelProperty(example = "personal_coupon", required = true, value = "Type of reward requested, including gift cards, personal coupons, and loyalty point additions or deductions.") + + public RequestTypeEnum getRequestType() { + return requestType; + } + + + public void setRequestType(RequestTypeEnum requestType) { + this.requestType = requestType; + } + + + public SupportRequestInput requestValue(Float requestValue) { + + this.requestValue = requestValue; + return this; + } + + /** + * Requested monetary balance of the gift card or the number of loyalty points to be added or deducted. + * @return requestValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "20.5", value = "Requested monetary balance of the gift card or the number of loyalty points to be added or deducted.") + + public Float getRequestValue() { + return requestValue; + } + + + public void setRequestValue(Float requestValue) { + this.requestValue = requestValue; + } + + + public SupportRequestInput requestNote(String requestNote) { + + this.requestNote = requestNote; + return this; + } + + /** + * Notes attached to the support request. + * @return requestNote + **/ + @ApiModelProperty(example = "Support request for coupon failure.", required = true, value = "Notes attached to the support request.") + + public String getRequestNote() { + return requestNote; + } + + + public void setRequestNote(String requestNote) { + this.requestNote = requestNote; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SupportRequestInput supportRequestInput = (SupportRequestInput) o; + return Objects.equals(this.applicationId, supportRequestInput.applicationId) && + Objects.equals(this.campaignId, supportRequestInput.campaignId) && + Objects.equals(this.loyaltyProgramId, supportRequestInput.loyaltyProgramId) && + Objects.equals(this.subledgerId, supportRequestInput.subledgerId) && + Objects.equals(this.customerProfileId, supportRequestInput.customerProfileId) && + Objects.equals(this.requestType, supportRequestInput.requestType) && + Objects.equals(this.requestValue, supportRequestInput.requestValue) && + Objects.equals(this.requestNote, supportRequestInput.requestNote); + } + + @Override + public int hashCode() { + return Objects.hash(applicationId, campaignId, loyaltyProgramId, subledgerId, customerProfileId, requestType, requestValue, requestNote); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SupportRequestInput {\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" campaignId: ").append(toIndentedString(campaignId)).append("\n"); + sb.append(" loyaltyProgramId: ").append(toIndentedString(loyaltyProgramId)).append("\n"); + sb.append(" subledgerId: ").append(toIndentedString(subledgerId)).append("\n"); + sb.append(" customerProfileId: ").append(toIndentedString(customerProfileId)).append("\n"); + sb.append(" requestType: ").append(toIndentedString(requestType)).append("\n"); + sb.append(" requestValue: ").append(toIndentedString(requestValue)).append("\n"); + sb.append(" requestNote: ").append(toIndentedString(requestNote)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TalangAttribute.java b/src/main/java/one/talon/model/TalangAttribute.java index 61cea476..e41e7442 100644 --- a/src/main/java/one/talon/model/TalangAttribute.java +++ b/src/main/java/one/talon/model/TalangAttribute.java @@ -74,7 +74,11 @@ public enum EntityEnum { STORE("Store"), - ACHIEVEMENTS("Achievements"); + ACHIEVEMENTS("Achievements"), + + ADVANCEDEVENT("AdvancedEvent"), + + ADVANCEDEVENTCONNECTEDSESSION("AdvancedEventConnectedSession"); private String value; diff --git a/src/main/java/one/talon/model/TemplateParameter.java b/src/main/java/one/talon/model/TemplateParameter.java new file mode 100644 index 00000000..be6b40fc --- /dev/null +++ b/src/main/java/one/talon/model/TemplateParameter.java @@ -0,0 +1,271 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * A named parameter definition that exposes a configurable value in a campaign template. Replaces `templateParameter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets. + */ +@ApiModel(description = "A named parameter definition that exposes a configurable value in a campaign template. Replaces `templateParameter` [bindings](https://docs.talon.one/management-api#tag/Campaigns/operation/getRuleset.responses.200.bindings) in V1 rulesets.") + +public class TemplateParameter { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_VALUE_TYPE = "valueType"; + @SerializedName(SERIALIZED_NAME_VALUE_TYPE) + private String valueType; + + public static final String SERIALIZED_NAME_MIN_VALUE = "minValue"; + @SerializedName(SERIALIZED_NAME_MIN_VALUE) + private BigDecimal minValue; + + public static final String SERIALIZED_NAME_MAX_VALUE = "maxValue"; + @SerializedName(SERIALIZED_NAME_MAX_VALUE) + private BigDecimal maxValue; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTE) + private Long attribute; + + + public TemplateParameter name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the template parameter. + * @return name + **/ + @ApiModelProperty(example = "minCartTotal", required = true, value = "The name of the template parameter.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public TemplateParameter value(Object value) { + + this.value = value; + return this; + } + + /** + * The parameter's bound value. Its type depends on the `valueType`. + * @return value + **/ + @ApiModelProperty(example = "50", required = true, value = "The parameter's bound value. Its type depends on the `valueType`.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public TemplateParameter valueType(String valueType) { + + this.valueType = valueType; + return this; + } + + /** + * The data type of the value, derived from the bound expression (for example `number`, `string`, `boolean`, `percent`, `time`, `(list string)`, or `(list number)`). + * @return valueType + **/ + @ApiModelProperty(example = "number", required = true, value = "The data type of the value, derived from the bound expression (for example `number`, `string`, `boolean`, `percent`, `time`, `(list string)`, or `(list number)`).") + + public String getValueType() { + return valueType; + } + + + public void setValueType(String valueType) { + this.valueType = valueType; + } + + + public TemplateParameter minValue(BigDecimal minValue) { + + this.minValue = minValue; + return this; + } + + /** + * The minimum value allowed for this parameter. + * @return minValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "0.0", value = "The minimum value allowed for this parameter.") + + public BigDecimal getMinValue() { + return minValue; + } + + + public void setMinValue(BigDecimal minValue) { + this.minValue = minValue; + } + + + public TemplateParameter maxValue(BigDecimal maxValue) { + + this.maxValue = maxValue; + return this; + } + + /** + * The maximum value allowed for this parameter. + * @return maxValue + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "10000.0", value = "The maximum value allowed for this parameter.") + + public BigDecimal getMaxValue() { + return maxValue; + } + + + public void setMaxValue(BigDecimal maxValue) { + this.maxValue = maxValue; + } + + + public TemplateParameter description(String description) { + + this.description = description; + return this; + } + + /** + * A human-readable description of the parameter shown when creating campaigns from the template. + * @return description + **/ + @ApiModelProperty(example = "Minimum cart total to trigger the campaign.", required = true, value = "A human-readable description of the parameter shown when creating campaigns from the template.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public TemplateParameter attribute(Long attribute) { + + this.attribute = attribute; + return this; + } + + /** + * The ID of the attribute linked to this parameter. Omitted when the parameter is not linked to an attribute. + * @return attribute + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "42", value = "The ID of the attribute linked to this parameter. Omitted when the parameter is not linked to an attribute.") + + public Long getAttribute() { + return attribute; + } + + + public void setAttribute(Long attribute) { + this.attribute = attribute; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TemplateParameter templateParameter = (TemplateParameter) o; + return Objects.equals(this.name, templateParameter.name) && + Objects.equals(this.value, templateParameter.value) && + Objects.equals(this.valueType, templateParameter.valueType) && + Objects.equals(this.minValue, templateParameter.minValue) && + Objects.equals(this.maxValue, templateParameter.maxValue) && + Objects.equals(this.description, templateParameter.description) && + Objects.equals(this.attribute, templateParameter.attribute); + } + + @Override + public int hashCode() { + return Objects.hash(name, value, valueType, minValue, maxValue, description, attribute); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TemplateParameter {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" valueType: ").append(toIndentedString(valueType)).append("\n"); + sb.append(" minValue: ").append(toIndentedString(minValue)).append("\n"); + sb.append(" maxValue: ").append(toIndentedString(maxValue)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerCustomEffectBlock.java b/src/main/java/one/talon/model/TriggerCustomEffectBlock.java new file mode 100644 index 00000000..b32a7002 --- /dev/null +++ b/src/main/java/one/talon/model/TriggerCustomEffectBlock.java @@ -0,0 +1,267 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.TriggerCustomEffectBlockCustomEffect; +import one.talon.model.TriggerCustomEffectBlockTarget; + +/** + * A block that triggers a configured custom effect and passes its required parameters. + */ +@ApiModel(description = "A block that triggers a configured custom effect and passes its required parameters.") + +public class TriggerCustomEffectBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_CUSTOM_EFFECT = "customEffect"; + @SerializedName(SERIALIZED_NAME_CUSTOM_EFFECT) + private TriggerCustomEffectBlockCustomEffect customEffect; + + public static final String SERIALIZED_NAME_PARAMS = "params"; + @SerializedName(SERIALIZED_NAME_PARAMS) + private Object params; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private TriggerCustomEffectBlockTarget target; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public TriggerCustomEffectBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public TriggerCustomEffectBlock customEffect(TriggerCustomEffectBlockCustomEffect customEffect) { + + this.customEffect = customEffect; + return this; + } + + /** + * Get customEffect + * @return customEffect + **/ + @ApiModelProperty(required = true, value = "") + + public TriggerCustomEffectBlockCustomEffect getCustomEffect() { + return customEffect; + } + + + public void setCustomEffect(TriggerCustomEffectBlockCustomEffect customEffect) { + this.customEffect = customEffect; + } + + + public TriggerCustomEffectBlock params(Object params) { + + this.params = params; + return this; + } + + /** + * The custom effect's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another. + * @return params + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "{\"template_id\":\"TPL-10293\"}", value = "The custom effect's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another.") + + public Object getParams() { + return params; + } + + + public void setParams(Object params) { + this.params = params; + } + + + public TriggerCustomEffectBlock target(TriggerCustomEffectBlockTarget target) { + + this.target = target; + return this; + } + + /** + * Get target + * @return target + **/ + @ApiModelProperty(required = true, value = "") + + public TriggerCustomEffectBlockTarget getTarget() { + return target; + } + + + public void setTarget(TriggerCustomEffectBlockTarget target) { + this.target = target; + } + + + public TriggerCustomEffectBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public TriggerCustomEffectBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TriggerCustomEffectBlock triggerCustomEffectBlock = (TriggerCustomEffectBlock) o; + return Objects.equals(this.id, triggerCustomEffectBlock.id) && + Objects.equals(this.type, triggerCustomEffectBlock.type) && + Objects.equals(this.tags, triggerCustomEffectBlock.tags) && + Objects.equals(this.customEffect, triggerCustomEffectBlock.customEffect) && + Objects.equals(this.params, triggerCustomEffectBlock.params) && + Objects.equals(this.target, triggerCustomEffectBlock.target) && + Objects.equals(this.onError, triggerCustomEffectBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, customEffect, params, target, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TriggerCustomEffectBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" customEffect: ").append(toIndentedString(customEffect)).append("\n"); + sb.append(" params: ").append(toIndentedString(params)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerCustomEffectBlockCustomEffect.java b/src/main/java/one/talon/model/TriggerCustomEffectBlockCustomEffect.java new file mode 100644 index 00000000..7285eca0 --- /dev/null +++ b/src/main/java/one/talon/model/TriggerCustomEffectBlockCustomEffect.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The custom effect to trigger. + */ +@ApiModel(description = "The custom effect to trigger.") + +public class TriggerCustomEffectBlockCustomEffect { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + + public TriggerCustomEffectBlockCustomEffect id(Long id) { + + this.id = id; + return this; + } + + /** + * The unique identifier of the custom effect. + * @return id + **/ + @ApiModelProperty(example = "1", required = true, value = "The unique identifier of the custom effect.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public TriggerCustomEffectBlockCustomEffect name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the custom effect, as used in API requests. + * @return name + **/ + @ApiModelProperty(example = "sendEmail", required = true, value = "The name of the custom effect, as used in API requests.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public TriggerCustomEffectBlockCustomEffect title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the custom effect. + * @return title + **/ + @ApiModelProperty(example = "Send email", required = true, value = "The display name of the custom effect.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TriggerCustomEffectBlockCustomEffect triggerCustomEffectBlockCustomEffect = (TriggerCustomEffectBlockCustomEffect) o; + return Objects.equals(this.id, triggerCustomEffectBlockCustomEffect.id) && + Objects.equals(this.name, triggerCustomEffectBlockCustomEffect.name) && + Objects.equals(this.title, triggerCustomEffectBlockCustomEffect.title); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TriggerCustomEffectBlockCustomEffect {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerCustomEffectBlockTarget.java b/src/main/java/one/talon/model/TriggerCustomEffectBlockTarget.java new file mode 100644 index 00000000..1738e1b7 --- /dev/null +++ b/src/main/java/one/talon/model/TriggerCustomEffectBlockTarget.java @@ -0,0 +1,181 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The target scope of this effect. + */ +@ApiModel(description = "The target scope of this effect.") + +public class TriggerCustomEffectBlockTarget { + /** + * The scope the custom effect applies to: - `cart` applies once to the whole cart. - `allItems` applies once per cart item. - `selector` applies once per item matched by the named selector. - `globalFilter` applies once per item matched by the named global item filter. - `bundle` applies once per item in the named bundle. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + CART("cart"), + + ALLITEMS("allItems"), + + SELECTOR("selector"), + + GLOBALFILTER("globalFilter"), + + BUNDLE("bundle"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + + public TriggerCustomEffectBlockTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * The scope the custom effect applies to: - `cart` applies once to the whole cart. - `allItems` applies once per cart item. - `selector` applies once per item matched by the named selector. - `globalFilter` applies once per item matched by the named global item filter. - `bundle` applies once per item in the named bundle. + * @return type + **/ + @ApiModelProperty(example = "cart", required = true, value = "The scope the custom effect applies to: - `cart` applies once to the whole cart. - `allItems` applies once per cart item. - `selector` applies once per item matched by the named selector. - `globalFilter` applies once per item matched by the named global item filter. - `bundle` applies once per item in the named bundle.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public TriggerCustomEffectBlockTarget name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the targeted selector or bundle. Only set when `type` is `selector`, `globalFilter`, or `bundle`. + * @return name + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "giftBundle", value = "The name of the targeted selector or bundle. Only set when `type` is `selector`, `globalFilter`, or `bundle`.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TriggerCustomEffectBlockTarget triggerCustomEffectBlockTarget = (TriggerCustomEffectBlockTarget) o; + return Objects.equals(this.type, triggerCustomEffectBlockTarget.type) && + Objects.equals(this.name, triggerCustomEffectBlockTarget.name); + } + + @Override + public int hashCode() { + return Objects.hash(type, name); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TriggerCustomEffectBlockTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerWebhookBlock.java b/src/main/java/one/talon/model/TriggerWebhookBlock.java new file mode 100644 index 00000000..37d7b29a --- /dev/null +++ b/src/main/java/one/talon/model/TriggerWebhookBlock.java @@ -0,0 +1,238 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.TriggerWebhookBlockWebhook; + +/** + * A block that triggers a configured webhook and passes its required parameters. + */ +@ApiModel(description = "A block that triggers a configured webhook and passes its required parameters.") + +public class TriggerWebhookBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + public static final String SERIALIZED_NAME_WEBHOOK = "webhook"; + @SerializedName(SERIALIZED_NAME_WEBHOOK) + private TriggerWebhookBlockWebhook webhook; + + public static final String SERIALIZED_NAME_PARAMS = "params"; + @SerializedName(SERIALIZED_NAME_PARAMS) + private Object params; + + public static final String SERIALIZED_NAME_ON_ERROR = "onError"; + @SerializedName(SERIALIZED_NAME_ON_ERROR) + private Map> onError = null; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public TriggerWebhookBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public TriggerWebhookBlock webhook(TriggerWebhookBlockWebhook webhook) { + + this.webhook = webhook; + return this; + } + + /** + * Get webhook + * @return webhook + **/ + @ApiModelProperty(required = true, value = "") + + public TriggerWebhookBlockWebhook getWebhook() { + return webhook; + } + + + public void setWebhook(TriggerWebhookBlockWebhook webhook) { + this.webhook = webhook; + } + + + public TriggerWebhookBlock params(Object params) { + + this.params = params; + return this; + } + + /** + * The webhook's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another. + * @return params + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "{\"order_id\":\"ORD-10293\"}", value = "The webhook's parameters, in configured order. Each property name is the parameter's title, lowercased with spaces replaced by underscores (for example, `Order ID` becomes `order_id`); falls back to `param_0`, `param_1`, and so on if a title is blank or collides with another.") + + public Object getParams() { + return params; + } + + + public void setParams(Object params) { + this.params = params; + } + + + public TriggerWebhookBlock onError(Map> onError) { + + this.onError = onError; + return this; + } + + public TriggerWebhookBlock putOnErrorItem(String key, List onErrorItem) { + if (this.onError == null) { + this.onError = new HashMap>(); + } + this.onError.put(key, onErrorItem); + return this; + } + + /** + * Named error handlers evaluated when a specific error occurs. + * @return onError + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Named error handlers evaluated when a specific error occurs.") + + public Map> getOnError() { + return onError; + } + + + public void setOnError(Map> onError) { + this.onError = onError; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TriggerWebhookBlock triggerWebhookBlock = (TriggerWebhookBlock) o; + return Objects.equals(this.id, triggerWebhookBlock.id) && + Objects.equals(this.type, triggerWebhookBlock.type) && + Objects.equals(this.tags, triggerWebhookBlock.tags) && + Objects.equals(this.webhook, triggerWebhookBlock.webhook) && + Objects.equals(this.params, triggerWebhookBlock.params) && + Objects.equals(this.onError, triggerWebhookBlock.onError); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, webhook, params, onError); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TriggerWebhookBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" webhook: ").append(toIndentedString(webhook)).append("\n"); + sb.append(" params: ").append(toIndentedString(params)).append("\n"); + sb.append(" onError: ").append(toIndentedString(onError)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerWebhookBlockWebhook.java b/src/main/java/one/talon/model/TriggerWebhookBlockWebhook.java new file mode 100644 index 00000000..908d98c6 --- /dev/null +++ b/src/main/java/one/talon/model/TriggerWebhookBlockWebhook.java @@ -0,0 +1,127 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The webhook to trigger. + */ +@ApiModel(description = "The webhook to trigger.") + +public class TriggerWebhookBlockWebhook { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + + public TriggerWebhookBlockWebhook id(Long id) { + + this.id = id; + return this; + } + + /** + * The unique identifier of the webhook. + * @return id + **/ + @ApiModelProperty(example = "1", required = true, value = "The unique identifier of the webhook.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public TriggerWebhookBlockWebhook title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the webhook. + * @return title + **/ + @ApiModelProperty(example = "Thank you for your order.", required = true, value = "The display name of the webhook.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + TriggerWebhookBlockWebhook triggerWebhookBlockWebhook = (TriggerWebhookBlockWebhook) o; + return Objects.equals(this.id, triggerWebhookBlockWebhook.id) && + Objects.equals(this.title, triggerWebhookBlockWebhook.title); + } + + @Override + public int hashCode() { + return Objects.hash(id, title); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class TriggerWebhookBlockWebhook {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/TriggerWebhookEffectProps.java b/src/main/java/one/talon/model/TriggerWebhookEffectProps.java index 0a654267..7cad2766 100644 --- a/src/main/java/one/talon/model/TriggerWebhookEffectProps.java +++ b/src/main/java/one/talon/model/TriggerWebhookEffectProps.java @@ -26,9 +26,9 @@ import java.math.BigDecimal; /** - * The properties specific to the \"triggerWebhook\" effect. This gets triggered whenever a validated rule contained a \"trigger webhook\" effect. This is communicated as an FYI and should usually not require action on your side. + * This effect is triggered when a rule containing a [webhook effect](https://docs.talon.one/docs/product/rules/effects/available-effects#webhooks) is validated. The details are shared with you for your information only. It usually doesn't require an action on your side. */ -@ApiModel(description = "The properties specific to the \"triggerWebhook\" effect. This gets triggered whenever a validated rule contained a \"trigger webhook\" effect. This is communicated as an FYI and should usually not require action on your side.") +@ApiModel(description = "This effect is triggered when a rule containing a [webhook effect](https://docs.talon.one/docs/product/rules/effects/available-effects#webhooks) is validated. The details are shared with you for your information only. It usually doesn't require an action on your side.") public class TriggerWebhookEffectProps { public static final String SERIALIZED_NAME_WEBHOOK_ID = "webhookId"; @@ -47,10 +47,10 @@ public TriggerWebhookEffectProps webhookId(BigDecimal webhookId) { } /** - * The ID of the webhook that was triggered. + * The internal ID of the webhook. * @return webhookId **/ - @ApiModelProperty(required = true, value = "The ID of the webhook that was triggered.") + @ApiModelProperty(required = true, value = "The internal ID of the webhook.") public BigDecimal getWebhookId() { return webhookId; @@ -69,10 +69,10 @@ public TriggerWebhookEffectProps webhookName(String webhookName) { } /** - * The name of the webhook that was triggered. + * The name of the webhook. * @return webhookName **/ - @ApiModelProperty(required = true, value = "The name of the webhook that was triggered.") + @ApiModelProperty(required = true, value = "The name of the webhook.") public String getWebhookName() { return webhookName; diff --git a/src/main/java/one/talon/model/UnaryCheckAttributeBlock.java b/src/main/java/one/talon/model/UnaryCheckAttributeBlock.java new file mode 100644 index 00000000..5c2bf97a --- /dev/null +++ b/src/main/java/one/talon/model/UnaryCheckAttributeBlock.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for operators that test a property of the attribute itself with no comparison value. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for operators that test a property of the attribute itself with no comparison value.") + +public class UnaryCheckAttributeBlock { + /** + * The unary operator applied to the attribute. These operators require no comparison value. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + EMPTY("empty"), + + NOT_EMPTY_("not(empty)"), + + EXISTS("exists"), + + NOT_EXISTS_("not(exists)"), + + ISTRUE("isTrue"), + + ISFALSE("isFalse"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + + public UnaryCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The unary operator applied to the attribute. These operators require no comparison value. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The unary operator applied to the attribute. These operators require no comparison value.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UnaryCheckAttributeBlock unaryCheckAttributeBlock = (UnaryCheckAttributeBlock) o; + return Objects.equals(this.operator, unaryCheckAttributeBlock.operator); + } + + @Override + public int hashCode() { + return Objects.hash(operator); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UnaryCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UnlockRewardEffectProps.java b/src/main/java/one/talon/model/UnlockRewardEffectProps.java new file mode 100644 index 00000000..3e5f2e24 --- /dev/null +++ b/src/main/java/one/talon/model/UnlockRewardEffectProps.java @@ -0,0 +1,241 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; + +/** + * The properties specific to the \"unlockReward\" effect. This gets triggered whenever a validated rule unlocks a reward for a customer profile. + */ +@ApiModel(description = "The properties specific to the \"unlockReward\" effect. This gets triggered whenever a validated rule unlocks a reward for a customer profile.") + +public class UnlockRewardEffectProps { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + public static final String SERIALIZED_NAME_PROFILE_INTEGRATION_ID = "profileIntegrationId"; + @SerializedName(SERIALIZED_NAME_PROFILE_INTEGRATION_ID) + private String profileIntegrationId; + + public static final String SERIALIZED_NAME_UNLOCKED_AT = "unlockedAt"; + @SerializedName(SERIALIZED_NAME_UNLOCKED_AT) + private OffsetDateTime unlockedAt; + + public static final String SERIALIZED_NAME_CARD_IDENTIFIER = "cardIdentifier"; + @SerializedName(SERIALIZED_NAME_CARD_IDENTIFIER) + private String cardIdentifier; + + + public UnlockRewardEffectProps integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID assigned to the customer reward unlock. + * @return integrationId + **/ + @ApiModelProperty(example = "reward-unlock-123", required = true, value = "The integration ID assigned to the customer reward unlock.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public UnlockRewardEffectProps rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The internal ID of the reward that was unlocked. + * @return rewardId + **/ + @ApiModelProperty(example = "5", required = true, value = "The internal ID of the reward that was unlocked.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + + public UnlockRewardEffectProps applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The internal ID of the application the reward belongs to. + * @return applicationId + **/ + @ApiModelProperty(example = "1", required = true, value = "The internal ID of the application the reward belongs to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + public UnlockRewardEffectProps profileIntegrationId(String profileIntegrationId) { + + this.profileIntegrationId = profileIntegrationId; + return this; + } + + /** + * The integration ID of the customer profile that unlocked the reward. + * @return profileIntegrationId + **/ + @ApiModelProperty(example = "customer1", required = true, value = "The integration ID of the customer profile that unlocked the reward.") + + public String getProfileIntegrationId() { + return profileIntegrationId; + } + + + public void setProfileIntegrationId(String profileIntegrationId) { + this.profileIntegrationId = profileIntegrationId; + } + + + public UnlockRewardEffectProps unlockedAt(OffsetDateTime unlockedAt) { + + this.unlockedAt = unlockedAt; + return this; + } + + /** + * The time the reward was unlocked. + * @return unlockedAt + **/ + @ApiModelProperty(example = "2024-05-29T15:04:05Z", required = true, value = "The time the reward was unlocked.") + + public OffsetDateTime getUnlockedAt() { + return unlockedAt; + } + + + public void setUnlockedAt(OffsetDateTime unlockedAt) { + this.unlockedAt = unlockedAt; + } + + + public UnlockRewardEffectProps cardIdentifier(String cardIdentifier) { + + this.cardIdentifier = cardIdentifier; + return this; + } + + /** + * The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. + * @return cardIdentifier + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "summer-loyalty-card-0543", value = "The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. ") + + public String getCardIdentifier() { + return cardIdentifier; + } + + + public void setCardIdentifier(String cardIdentifier) { + this.cardIdentifier = cardIdentifier; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UnlockRewardEffectProps unlockRewardEffectProps = (UnlockRewardEffectProps) o; + return Objects.equals(this.integrationId, unlockRewardEffectProps.integrationId) && + Objects.equals(this.rewardId, unlockRewardEffectProps.rewardId) && + Objects.equals(this.applicationId, unlockRewardEffectProps.applicationId) && + Objects.equals(this.profileIntegrationId, unlockRewardEffectProps.profileIntegrationId) && + Objects.equals(this.unlockedAt, unlockRewardEffectProps.unlockedAt) && + Objects.equals(this.cardIdentifier, unlockRewardEffectProps.cardIdentifier); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId, rewardId, applicationId, profileIntegrationId, unlockedAt, cardIdentifier); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UnlockRewardEffectProps {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append(" profileIntegrationId: ").append(toIndentedString(profileIntegrationId)).append("\n"); + sb.append(" unlockedAt: ").append(toIndentedString(unlockedAt)).append("\n"); + sb.append(" cardIdentifier: ").append(toIndentedString(cardIdentifier)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAchievementProgressBlock.java b/src/main/java/one/talon/model/UpdateAchievementProgressBlock.java new file mode 100644 index 00000000..6675845f --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAchievementProgressBlock.java @@ -0,0 +1,271 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAchievementProgressBlockAchievement; + +/** + * A block that updates the progress of a customer in an achievement. + */ +@ApiModel(description = "A block that updates the progress of a customer in an achievement.") + +public class UpdateAchievementProgressBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * Gets or Sets operator + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + INCREASEBY("increaseBy"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private String value; + + public static final String SERIALIZED_NAME_ACHIEVEMENT = "achievement"; + @SerializedName(SERIALIZED_NAME_ACHIEVEMENT) + private UpdateAchievementProgressBlockAchievement achievement; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public UpdateAchievementProgressBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public UpdateAchievementProgressBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * Get operator + * @return operator + **/ + @ApiModelProperty(example = "increaseBy", required = true, value = "") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public UpdateAchievementProgressBlock value(String value) { + + this.value = value; + return this; + } + + /** + * The value to update the progress by. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities. + * @return value + **/ + @ApiModelProperty(example = "10", required = true, value = "The value to update the progress by. Supports template placeholders (e.g. \"{{$Session.Total / 2}}\") for dynamic quantities.") + + public String getValue() { + return value; + } + + + public void setValue(String value) { + this.value = value; + } + + + public UpdateAchievementProgressBlock achievement(UpdateAchievementProgressBlockAchievement achievement) { + + this.achievement = achievement; + return this; + } + + /** + * Get achievement + * @return achievement + **/ + @ApiModelProperty(required = true, value = "") + + public UpdateAchievementProgressBlockAchievement getAchievement() { + return achievement; + } + + + public void setAchievement(UpdateAchievementProgressBlockAchievement achievement) { + this.achievement = achievement; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAchievementProgressBlock updateAchievementProgressBlock = (UpdateAchievementProgressBlock) o; + return Objects.equals(this.id, updateAchievementProgressBlock.id) && + Objects.equals(this.type, updateAchievementProgressBlock.type) && + Objects.equals(this.tags, updateAchievementProgressBlock.tags) && + Objects.equals(this.operator, updateAchievementProgressBlock.operator) && + Objects.equals(this.value, updateAchievementProgressBlock.value) && + Objects.equals(this.achievement, updateAchievementProgressBlock.achievement); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, value, achievement); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAchievementProgressBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" achievement: ").append(toIndentedString(achievement)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAchievementProgressBlockAchievement.java b/src/main/java/one/talon/model/UpdateAchievementProgressBlockAchievement.java new file mode 100644 index 00000000..62327fe5 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAchievementProgressBlockAchievement.java @@ -0,0 +1,184 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * The achievement to update. + */ +@ApiModel(description = "The achievement to update.") + +public class UpdateAchievementProgressBlockAchievement { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private BigDecimal target; + + + public UpdateAchievementProgressBlockAchievement id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the achievement. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the achievement.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public UpdateAchievementProgressBlockAchievement name(String name) { + + this.name = name; + return this; + } + + /** + * The internal name of the achievement used in API requests. + * @return name + **/ + @ApiModelProperty(example = "Order50Discount", required = true, value = "The internal name of the achievement used in API requests.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public UpdateAchievementProgressBlockAchievement title(String title) { + + this.title = title; + return this; + } + + /** + * The display name of the achievement in the Campaign Manager. + * @return title + **/ + @ApiModelProperty(example = "50% off on 50th purchase.", required = true, value = "The display name of the achievement in the Campaign Manager.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public UpdateAchievementProgressBlockAchievement target(BigDecimal target) { + + this.target = target; + return this; + } + + /** + * The required number of actions or the transactional milestone to complete the achievement. + * @return target + **/ + @ApiModelProperty(example = "50.0", required = true, value = "The required number of actions or the transactional milestone to complete the achievement.") + + public BigDecimal getTarget() { + return target; + } + + + public void setTarget(BigDecimal target) { + this.target = target; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAchievementProgressBlockAchievement updateAchievementProgressBlockAchievement = (UpdateAchievementProgressBlockAchievement) o; + return Objects.equals(this.id, updateAchievementProgressBlockAchievement.id) && + Objects.equals(this.name, updateAchievementProgressBlockAchievement.name) && + Objects.equals(this.title, updateAchievementProgressBlockAchievement.title) && + Objects.equals(this.target, updateAchievementProgressBlockAchievement.target); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, title, target); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAchievementProgressBlockAchievement {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAchievementV2.java b/src/main/java/one/talon/model/UpdateAchievementV2.java index b8f18a7b..be82ca75 100644 --- a/src/main/java/one/talon/model/UpdateAchievementV2.java +++ b/src/main/java/one/talon/model/UpdateAchievementV2.java @@ -169,17 +169,9 @@ public ActivationPolicyEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_ALLOW_ROLLBACK_AFTER_COMPLETION) private Boolean allowRollbackAfterCompletion; - public static final String SERIALIZED_NAME_SANDBOX = "sandbox"; - @SerializedName(SERIALIZED_NAME_SANDBOX) - private Boolean sandbox; - public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS = "subscribedApplications"; @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS) - private List subscribedApplications = null; - - public static final String SERIALIZED_NAME_TIMEZONE = "timezone"; - @SerializedName(SERIALIZED_NAME_TIMEZONE) - private String timezone; + private List subscribedApplications = new ArrayList(); public UpdateAchievementV2 name(String name) { @@ -192,8 +184,7 @@ public UpdateAchievementV2 name(String name) { * The internal name of the achievement used in API requests. **Note**: The name should start with a letter. This cannot be changed after the achievement has been created. * @return name **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Order50Discount", value = "The internal name of the achievement used in API requests. **Note**: The name should start with a letter. This cannot be changed after the achievement has been created. ") + @ApiModelProperty(example = "Order50Discount", required = true, value = "The internal name of the achievement used in API requests. **Note**: The name should start with a letter. This cannot be changed after the achievement has been created. ") public String getName() { return name; @@ -215,8 +206,7 @@ public UpdateAchievementV2 title(String title) { * The display name for the achievement in the Campaign Manager. * @return title **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "50% off on 50th purchase.", value = "The display name for the achievement in the Campaign Manager.") + @ApiModelProperty(example = "50% off on 50th purchase.", required = true, value = "The display name for the achievement in the Campaign Manager.") public String getTitle() { return title; @@ -238,8 +228,7 @@ public UpdateAchievementV2 description(String description) { * A description of the achievement. * @return description **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "50% off for every 50th purchase in a year.", value = "A description of the achievement.") + @ApiModelProperty(example = "50% off for every 50th purchase in a year.", required = true, value = "A description of the achievement.") public String getDescription() { return description; @@ -261,8 +250,7 @@ public UpdateAchievementV2 target(BigDecimal target) { * The required number of actions or the transactional milestone to complete the achievement. * @return target **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "50.0", value = "The required number of actions or the transactional milestone to complete the achievement.") + @ApiModelProperty(example = "50.0", required = true, value = "The required number of actions or the transactional milestone to complete the achievement.") public BigDecimal getTarget() { return target; @@ -412,29 +400,6 @@ public void setAllowRollbackAfterCompletion(Boolean allowRollbackAfterCompletion } - public UpdateAchievementV2 sandbox(Boolean sandbox) { - - this.sandbox = sandbox; - return this; - } - - /** - * Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type. - * @return sandbox - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "true", value = "Indicates if this achievement is a live or sandbox achievement. Achievements of a given type can only be connected to Applications of the same type.") - - public Boolean getSandbox() { - return sandbox; - } - - - public void setSandbox(Boolean sandbox) { - this.sandbox = sandbox; - } - - public UpdateAchievementV2 subscribedApplications(List subscribedApplications) { this.subscribedApplications = subscribedApplications; @@ -442,9 +407,6 @@ public UpdateAchievementV2 subscribedApplications(List subscribedApplicati } public UpdateAchievementV2 addSubscribedApplicationsItem(Long subscribedApplicationsItem) { - if (this.subscribedApplications == null) { - this.subscribedApplications = new ArrayList(); - } this.subscribedApplications.add(subscribedApplicationsItem); return this; } @@ -453,8 +415,7 @@ public UpdateAchievementV2 addSubscribedApplicationsItem(Long subscribedApplicat * A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement. * @return subscribedApplications **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "[132, 97]", value = "A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement.") + @ApiModelProperty(example = "[132, 97]", required = true, value = "A list containing the IDs of all applications that are subscribed to A list containing the IDs of all Applications that are connected to this achievement.") public List getSubscribedApplications() { return subscribedApplications; @@ -466,29 +427,6 @@ public void setSubscribedApplications(List subscribedApplications) { } - public UpdateAchievementV2 timezone(String timezone) { - - this.timezone = timezone; - return this; - } - - /** - * A string containing an IANA timezone descriptor. - * @return timezone - **/ - @javax.annotation.Nullable - @ApiModelProperty(example = "Europe/Berlin", value = "A string containing an IANA timezone descriptor.") - - public String getTimezone() { - return timezone; - } - - - public void setTimezone(String timezone) { - this.timezone = timezone; - } - - @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -508,14 +446,12 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.fixedStartDate, updateAchievementV2.fixedStartDate) && Objects.equals(this.endDate, updateAchievementV2.endDate) && Objects.equals(this.allowRollbackAfterCompletion, updateAchievementV2.allowRollbackAfterCompletion) && - Objects.equals(this.sandbox, updateAchievementV2.sandbox) && - Objects.equals(this.subscribedApplications, updateAchievementV2.subscribedApplications) && - Objects.equals(this.timezone, updateAchievementV2.timezone); + Objects.equals(this.subscribedApplications, updateAchievementV2.subscribedApplications); } @Override public int hashCode() { - return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, sandbox, subscribedApplications, timezone); + return Objects.hash(name, title, description, target, period, recurrencePolicy, activationPolicy, fixedStartDate, endDate, allowRollbackAfterCompletion, subscribedApplications); } @@ -533,9 +469,7 @@ public String toString() { sb.append(" fixedStartDate: ").append(toIndentedString(fixedStartDate)).append("\n"); sb.append(" endDate: ").append(toIndentedString(endDate)).append("\n"); sb.append(" allowRollbackAfterCompletion: ").append(toIndentedString(allowRollbackAfterCompletion)).append("\n"); - sb.append(" sandbox: ").append(toIndentedString(sandbox)).append("\n"); sb.append(" subscribedApplications: ").append(toIndentedString(subscribedApplications)).append("\n"); - sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/UpdateApplication.java b/src/main/java/one/talon/model/UpdateApplication.java index 45173bf4..715cd625 100644 --- a/src/main/java/one/talon/model/UpdateApplication.java +++ b/src/main/java/one/talon/model/UpdateApplication.java @@ -26,6 +26,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; /** @@ -248,6 +249,10 @@ public DefaultDiscountAdditionalCostPerItemScopeEnum read(final JsonReader jsonR @SerializedName(SERIALIZED_NAME_ENABLE_CAMPAIGN_STATE_MANAGEMENT) private Boolean enableCampaignStateManagement; + public static final String SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS = "bestPriorPriceSettings"; + @SerializedName(SERIALIZED_NAME_BEST_PRIOR_PRICE_SETTINGS) + private BestPriorPriceSettings bestPriorPriceSettings; + public UpdateApplication name(String name) { @@ -645,6 +650,29 @@ public void setEnableCampaignStateManagement(Boolean enableCampaignStateManageme } + public UpdateApplication bestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + + this.bestPriorPriceSettings = bestPriorPriceSettings; + return this; + } + + /** + * Get bestPriorPriceSettings + * @return bestPriorPriceSettings + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public BestPriorPriceSettings getBestPriorPriceSettings() { + return bestPriorPriceSettings; + } + + + public void setBestPriorPriceSettings(BestPriorPriceSettings bestPriorPriceSettings) { + this.bestPriorPriceSettings = bestPriorPriceSettings; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -670,12 +698,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.defaultDiscountAdditionalCostPerItemScope, updateApplication.defaultDiscountAdditionalCostPerItemScope) && Objects.equals(this.defaultEvaluationGroupId, updateApplication.defaultEvaluationGroupId) && Objects.equals(this.defaultCartItemFilterId, updateApplication.defaultCartItemFilterId) && - Objects.equals(this.enableCampaignStateManagement, updateApplication.enableCampaignStateManagement); + Objects.equals(this.enableCampaignStateManagement, updateApplication.enableCampaignStateManagement) && + Objects.equals(this.bestPriorPriceSettings, updateApplication.bestPriorPriceSettings); } @Override public int hashCode() { - return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, defaultEvaluationGroupId, defaultCartItemFilterId, enableCampaignStateManagement); + return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, defaultDiscountScope, enableCascadingDiscounts, enableFlattenedCartItems, attributesSettings, sandbox, enablePartialDiscounts, defaultDiscountAdditionalCostPerItemScope, defaultEvaluationGroupId, defaultCartItemFilterId, enableCampaignStateManagement, bestPriorPriceSettings); } @@ -700,6 +729,7 @@ public String toString() { sb.append(" defaultEvaluationGroupId: ").append(toIndentedString(defaultEvaluationGroupId)).append("\n"); sb.append(" defaultCartItemFilterId: ").append(toIndentedString(defaultCartItemFilterId)).append("\n"); sb.append(" enableCampaignStateManagement: ").append(toIndentedString(enableCampaignStateManagement)).append("\n"); + sb.append(" bestPriorPriceSettings: ").append(toIndentedString(bestPriorPriceSettings)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/UpdateAttributeEffectProps.java b/src/main/java/one/talon/model/UpdateAttributeEffectProps.java index 8b31c9bf..3024060f 100644 --- a/src/main/java/one/talon/model/UpdateAttributeEffectProps.java +++ b/src/main/java/one/talon/model/UpdateAttributeEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"updateAttribute\" effect. This gets triggered whenever a validated rule contained an \"update an attribute\" effect. + * This effect indicates that a rule containing an [Update attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) or [Update cart item attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) was validated. You should update the value of the attribute in your system based on the content of the returned effect. */ -@ApiModel(description = "The properties specific to the \"updateAttribute\" effect. This gets triggered whenever a validated rule contained an \"update an attribute\" effect.") +@ApiModel(description = "This effect indicates that a rule containing an [Update attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) or [Update cart item attribute value](https://docs.talon.one/docs/product/rules/effects/available-effects#update-effects) was validated. You should update the value of the attribute in your system based on the content of the returned effect.") public class UpdateAttributeEffectProps { public static final String SERIALIZED_NAME_PATH = "path"; @@ -46,10 +46,10 @@ public UpdateAttributeEffectProps path(String path) { } /** - * The exact path of the attribute that was updated. + * The entity type and the attribute name. * @return path **/ - @ApiModelProperty(required = true, value = "The exact path of the attribute that was updated.") + @ApiModelProperty(required = true, value = "The entity type and the attribute name.") public String getPath() { return path; @@ -68,10 +68,10 @@ public UpdateAttributeEffectProps value(Object value) { } /** - * The new value of this attribute. The value can be of the following types: - boolean - location - number - string - time - list of any of those types + * The new value of the attribute. * @return value **/ - @ApiModelProperty(required = true, value = "The new value of this attribute. The value can be of the following types: - boolean - location - number - string - time - list of any of those types ") + @ApiModelProperty(required = true, value = "The new value of the attribute.") public Object getValue() { return value; diff --git a/src/main/java/one/talon/model/UpdateAttributeValueBlock.java b/src/main/java/one/talon/model/UpdateAttributeValueBlock.java new file mode 100644 index 00000000..078a4fb6 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAttributeValueBlock.java @@ -0,0 +1,315 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAttributeValueBlockAttribute; +import one.talon.model.UpdateAttributeValueBlockTarget; + +/** + * A block that sets or updates an attribute. The `type` may be empty for [built-in attributes](https://docs.talon.one/docs/dev/concepts/attributes). + */ +@ApiModel(description = "A block that sets or updates an attribute. The `type` may be empty for [built-in attributes](https://docs.talon.one/docs/dev/concepts/attributes).") + +public class UpdateAttributeValueBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The update operation applied to the attribute. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + SETTO("setTo"), + + INCREASEBY("increaseBy"), + + DECREASEBY("decreaseBy"), + + MULTIPLYBY("multiplyBy"), + + DIVIDEBY("divideBy"), + + TOGGLE("toggle"), + + LATERBY("laterBy"), + + EARLIERBY("earlierBy"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_ATTRIBUTE = "attribute"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTE) + private UpdateAttributeValueBlockAttribute attribute; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private Object value; + + public static final String SERIALIZED_NAME_TARGET = "target"; + @SerializedName(SERIALIZED_NAME_TARGET) + private UpdateAttributeValueBlockTarget target; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public UpdateAttributeValueBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public UpdateAttributeValueBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The update operation applied to the attribute. + * @return operator + **/ + @ApiModelProperty(example = "setTo", required = true, value = "The update operation applied to the attribute.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public UpdateAttributeValueBlock attribute(UpdateAttributeValueBlockAttribute attribute) { + + this.attribute = attribute; + return this; + } + + /** + * Get attribute + * @return attribute + **/ + @ApiModelProperty(required = true, value = "") + + public UpdateAttributeValueBlockAttribute getAttribute() { + return attribute; + } + + + public void setAttribute(UpdateAttributeValueBlockAttribute attribute) { + this.attribute = attribute; + } + + + public UpdateAttributeValueBlock value(Object value) { + + this.value = value; + return this; + } + + /** + * The value of the attribute. Omitted when operator is set to `toggle`. + * @return value + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "10", value = "The value of the attribute. Omitted when operator is set to `toggle`.") + + public Object getValue() { + return value; + } + + + public void setValue(Object value) { + this.value = value; + } + + + public UpdateAttributeValueBlock target(UpdateAttributeValueBlockTarget target) { + + this.target = target; + return this; + } + + /** + * Get target + * @return target + **/ + @ApiModelProperty(required = true, value = "") + + public UpdateAttributeValueBlockTarget getTarget() { + return target; + } + + + public void setTarget(UpdateAttributeValueBlockTarget target) { + this.target = target; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAttributeValueBlock updateAttributeValueBlock = (UpdateAttributeValueBlock) o; + return Objects.equals(this.id, updateAttributeValueBlock.id) && + Objects.equals(this.type, updateAttributeValueBlock.type) && + Objects.equals(this.tags, updateAttributeValueBlock.tags) && + Objects.equals(this.operator, updateAttributeValueBlock.operator) && + Objects.equals(this.attribute, updateAttributeValueBlock.attribute) && + Objects.equals(this.value, updateAttributeValueBlock.value) && + Objects.equals(this.target, updateAttributeValueBlock.target); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, attribute, value, target); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAttributeValueBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" attribute: ").append(toIndentedString(attribute)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" target: ").append(toIndentedString(target)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAttributeValueBlockAttribute.java b/src/main/java/one/talon/model/UpdateAttributeValueBlockAttribute.java new file mode 100644 index 00000000..610f3f58 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAttributeValueBlockAttribute.java @@ -0,0 +1,211 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The attribute being updated. + */ +@ApiModel(description = "The attribute being updated.") + +public class UpdateAttributeValueBlockAttribute { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private String entity; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_TITLE = "title"; + @SerializedName(SERIALIZED_NAME_TITLE) + private String title; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + + public UpdateAttributeValueBlockAttribute id(Long id) { + + this.id = id; + return this; + } + + /** + * The internal ID of the attribute. Reverts to `0` when the attribute is deleted or does not exist. + * @return id + **/ + @ApiModelProperty(example = "100", required = true, value = "The internal ID of the attribute. Reverts to `0` when the attribute is deleted or does not exist.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public UpdateAttributeValueBlockAttribute entity(String entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type that owns the attribute. Reverts to an empty string when the attribute is deleted or does not exist. + * @return entity + **/ + @ApiModelProperty(example = "profile", required = true, value = "The entity type that owns the attribute. Reverts to an empty string when the attribute is deleted or does not exist.") + + public String getEntity() { + return entity; + } + + + public void setEntity(String entity) { + this.entity = entity; + } + + + public UpdateAttributeValueBlockAttribute name(String name) { + + this.name = name; + return this; + } + + /** + * The attribute name as used in API requests. + * @return name + **/ + @ApiModelProperty(example = "City", required = true, value = "The attribute name as used in API requests.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public UpdateAttributeValueBlockAttribute title(String title) { + + this.title = title; + return this; + } + + /** + * The human-readable name of the attribute. + * @return title + **/ + @ApiModelProperty(example = "City", required = true, value = "The human-readable name of the attribute.") + + public String getTitle() { + return title; + } + + + public void setTitle(String title) { + this.title = title; + } + + + public UpdateAttributeValueBlockAttribute type(String type) { + + this.type = type; + return this; + } + + /** + * The data type of the attribute. + * @return type + **/ + @ApiModelProperty(example = "string", required = true, value = "The data type of the attribute.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAttributeValueBlockAttribute updateAttributeValueBlockAttribute = (UpdateAttributeValueBlockAttribute) o; + return Objects.equals(this.id, updateAttributeValueBlockAttribute.id) && + Objects.equals(this.entity, updateAttributeValueBlockAttribute.entity) && + Objects.equals(this.name, updateAttributeValueBlockAttribute.name) && + Objects.equals(this.title, updateAttributeValueBlockAttribute.title) && + Objects.equals(this.type, updateAttributeValueBlockAttribute.type); + } + + @Override + public int hashCode() { + return Objects.hash(id, entity, name, title, type); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAttributeValueBlockAttribute {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAttributeValueBlockTarget.java b/src/main/java/one/talon/model/UpdateAttributeValueBlockTarget.java new file mode 100644 index 00000000..b51c0b90 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAttributeValueBlockTarget.java @@ -0,0 +1,191 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The entity or item scope that this effect operates on. + */ +@ApiModel(description = "The entity or item scope that this effect operates on.") + +public class UpdateAttributeValueBlockTarget { + /** + * Identifies the target scope of the attribute update. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + SESSION("session"), + + PROFILE("profile"), + + ADVOCATEPROFILE("advocateProfile"), + + COUPON("coupon"), + + REFERRAL("referral"), + + EVENT("event"), + + LOYALTYCARD("loyaltyCard"), + + ALLITEMS("allItems"), + + SELECTOR("selector"), + + GLOBALFILTER("globalFilter"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + + public UpdateAttributeValueBlockTarget type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * Identifies the target scope of the attribute update. + * @return type + **/ + @ApiModelProperty(example = "profile", required = true, value = "Identifies the target scope of the attribute update.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public UpdateAttributeValueBlockTarget name(String name) { + + this.name = name; + return this; + } + + /** + * Identifies the name of the target when its type is set to `selector` or `globalFilter`. + * @return name + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Filter items by product", value = "Identifies the name of the target when its type is set to `selector` or `globalFilter`.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAttributeValueBlockTarget updateAttributeValueBlockTarget = (UpdateAttributeValueBlockTarget) o; + return Objects.equals(this.type, updateAttributeValueBlockTarget.type) && + Objects.equals(this.name, updateAttributeValueBlockTarget.name); + } + + @Override + public int hashCode() { + return Objects.hash(type, name); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAttributeValueBlockTarget {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAudience.java b/src/main/java/one/talon/model/UpdateAudience.java index 9789dfe0..8dc23e96 100644 --- a/src/main/java/one/talon/model/UpdateAudience.java +++ b/src/main/java/one/talon/model/UpdateAudience.java @@ -23,6 +23,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; /** * UpdateAudience @@ -33,6 +35,10 @@ public class UpdateAudience { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public static final String SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS = "subscribedApplicationsIds"; + @SerializedName(SERIALIZED_NAME_SUBSCRIBED_APPLICATIONS_IDS) + private List subscribedApplicationsIds = null; + public UpdateAudience name(String name) { @@ -56,6 +62,37 @@ public void setName(String name) { } + public UpdateAudience subscribedApplicationsIds(List subscribedApplicationsIds) { + + this.subscribedApplicationsIds = subscribedApplicationsIds; + return this; + } + + public UpdateAudience addSubscribedApplicationsIdsItem(Long subscribedApplicationsIdsItem) { + if (this.subscribedApplicationsIds == null) { + this.subscribedApplicationsIds = new ArrayList(); + } + this.subscribedApplicationsIds.add(subscribedApplicationsIdsItem); + return this; + } + + /** + * A list of the IDs of the Applications that are connected to this audience. + * @return subscribedApplicationsIds + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[3, 13]", value = "A list of the IDs of the Applications that are connected to this audience.") + + public List getSubscribedApplicationsIds() { + return subscribedApplicationsIds; + } + + + public void setSubscribedApplicationsIds(List subscribedApplicationsIds) { + this.subscribedApplicationsIds = subscribedApplicationsIds; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -65,12 +102,13 @@ public boolean equals(java.lang.Object o) { return false; } UpdateAudience updateAudience = (UpdateAudience) o; - return Objects.equals(this.name, updateAudience.name); + return Objects.equals(this.name, updateAudience.name) && + Objects.equals(this.subscribedApplicationsIds, updateAudience.subscribedApplicationsIds); } @Override public int hashCode() { - return Objects.hash(name); + return Objects.hash(name, subscribedApplicationsIds); } @@ -79,6 +117,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class UpdateAudience {\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" subscribedApplicationsIds: ").append(toIndentedString(subscribedApplicationsIds)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/UpdateAudienceMembershipBlock.java b/src/main/java/one/talon/model/UpdateAudienceMembershipBlock.java new file mode 100644 index 00000000..76c8f7e7 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAudienceMembershipBlock.java @@ -0,0 +1,320 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAudienceMembershipBlockAudience; + +/** + * A block that adds a customer to or removes them from an audience. + */ +@ApiModel(description = "A block that adds a customer to or removes them from an audience.") + +public class UpdateAudienceMembershipBlock { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private String id; + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private String type; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + + /** + * The action to perform. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + ADD("add"), + + REMOVE("remove"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + /** + * The customer profile to add or remove from the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + */ + @JsonAdapter(ProfileEnum.Adapter.class) + public enum ProfileEnum { + CURRENT("Current"), + + ADVOCATE("Advocate"); + + private String value; + + ProfileEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ProfileEnum fromValue(String value) { + for (ProfileEnum b : ProfileEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ProfileEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ProfileEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ProfileEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_PROFILE = "profile"; + @SerializedName(SERIALIZED_NAME_PROFILE) + private ProfileEnum profile; + + public static final String SERIALIZED_NAME_AUDIENCE = "audience"; + @SerializedName(SERIALIZED_NAME_AUDIENCE) + private UpdateAudienceMembershipBlockAudience audience; + + + /** + * Unique identifier for this block. + * @return id + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "a1b2c3d4-e5f6-7890-abcd-ef1234567890", value = "Unique identifier for this block.") + + public String getId() { + return id; + } + + + + + public UpdateAudienceMembershipBlock type(String type) { + + this.type = type; + return this; + } + + /** + * Identifies the block variant and determines which additional properties are present in it. + * @return type + **/ + @ApiModelProperty(required = true, value = "Identifies the block variant and determines which additional properties are present in it.") + + public String getType() { + return type; + } + + + public void setType(String type) { + this.type = type; + } + + + /** + * Semantic labels attached to this block. + * @return tags + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Semantic labels attached to this block.") + + public List getTags() { + return tags; + } + + + + + public UpdateAudienceMembershipBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The action to perform. + * @return operator + **/ + @ApiModelProperty(example = "add", required = true, value = "The action to perform.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public UpdateAudienceMembershipBlock profile(ProfileEnum profile) { + + this.profile = profile; + return this; + } + + /** + * The customer profile to add or remove from the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program. + * @return profile + **/ + @ApiModelProperty(example = "Current", required = true, value = "The customer profile to add or remove from the audience. `Current` targets the customer in the current session; `Advocate` targets the person who invited their friend via referral program.") + + public ProfileEnum getProfile() { + return profile; + } + + + public void setProfile(ProfileEnum profile) { + this.profile = profile; + } + + + public UpdateAudienceMembershipBlock audience(UpdateAudienceMembershipBlockAudience audience) { + + this.audience = audience; + return this; + } + + /** + * Get audience + * @return audience + **/ + @ApiModelProperty(required = true, value = "") + + public UpdateAudienceMembershipBlockAudience getAudience() { + return audience; + } + + + public void setAudience(UpdateAudienceMembershipBlockAudience audience) { + this.audience = audience; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAudienceMembershipBlock updateAudienceMembershipBlock = (UpdateAudienceMembershipBlock) o; + return Objects.equals(this.id, updateAudienceMembershipBlock.id) && + Objects.equals(this.type, updateAudienceMembershipBlock.type) && + Objects.equals(this.tags, updateAudienceMembershipBlock.tags) && + Objects.equals(this.operator, updateAudienceMembershipBlock.operator) && + Objects.equals(this.profile, updateAudienceMembershipBlock.profile) && + Objects.equals(this.audience, updateAudienceMembershipBlock.audience); + } + + @Override + public int hashCode() { + return Objects.hash(id, type, tags, operator, profile, audience); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAudienceMembershipBlock {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" profile: ").append(toIndentedString(profile)).append("\n"); + sb.append(" audience: ").append(toIndentedString(audience)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateAudienceMembershipBlockAudience.java b/src/main/java/one/talon/model/UpdateAudienceMembershipBlockAudience.java new file mode 100644 index 00000000..65c2d00a --- /dev/null +++ b/src/main/java/one/talon/model/UpdateAudienceMembershipBlockAudience.java @@ -0,0 +1,185 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * The audience to add the customer to or remove them from. + */ +@ApiModel(description = "The audience to add the customer to or remove them from.") + +public class UpdateAudienceMembershipBlockAudience { + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Long id; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_INTEGRATION = "integration"; + @SerializedName(SERIALIZED_NAME_INTEGRATION) + private String integration; + + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + + public UpdateAudienceMembershipBlockAudience id(Long id) { + + this.id = id; + return this; + } + + /** + * The ID of the audience. + * @return id + **/ + @ApiModelProperty(example = "42", required = true, value = "The ID of the audience.") + + public Long getId() { + return id; + } + + + public void setId(Long id) { + this.id = id; + } + + + public UpdateAudienceMembershipBlockAudience name(String name) { + + this.name = name; + return this; + } + + /** + * The display name of the audience. + * @return name + **/ + @ApiModelProperty(example = "Travel audience", required = true, value = "The display name of the audience.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public UpdateAudienceMembershipBlockAudience integration(String integration) { + + this.integration = integration; + return this; + } + + /** + * The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. + * @return integration + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "mparticle", value = "The Talon.One-supported [3rd-party platform](https://docs.talon.one/docs/dev/technology-partners/overview) that this audience was created in. For example, `mParticle`, `Segment`, `Shopify`, `Braze`, or `Iterable`. **Note:** If you do not integrate with any of these platforms, do not use this property. ") + + public String getIntegration() { + return integration; + } + + + public void setIntegration(String integration) { + this.integration = integration; + } + + + public UpdateAudienceMembershipBlockAudience integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. + * @return integrationId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "382370BKDB946", value = "The ID of this audience in the third-party integration. **Note:** To create an audience that doesn't come from a 3rd party platform, do not use this property. ") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateAudienceMembershipBlockAudience updateAudienceMembershipBlockAudience = (UpdateAudienceMembershipBlockAudience) o; + return Objects.equals(this.id, updateAudienceMembershipBlockAudience.id) && + Objects.equals(this.name, updateAudienceMembershipBlockAudience.name) && + Objects.equals(this.integration, updateAudienceMembershipBlockAudience.integration) && + Objects.equals(this.integrationId, updateAudienceMembershipBlockAudience.integrationId); + } + + @Override + public int hashCode() { + return Objects.hash(id, name, integration, integrationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateAudienceMembershipBlockAudience {\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" integration: ").append(toIndentedString(integration)).append("\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateCampaign.java b/src/main/java/one/talon/model/UpdateCampaign.java index 468163fe..e2e656fb 100644 --- a/src/main/java/one/talon/model/UpdateCampaign.java +++ b/src/main/java/one/talon/model/UpdateCampaign.java @@ -134,7 +134,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/UpdateCampaignTemplate.java b/src/main/java/one/talon/model/UpdateCampaignTemplate.java index b720946c..0d23ea81 100644 --- a/src/main/java/one/talon/model/UpdateCampaignTemplate.java +++ b/src/main/java/one/talon/model/UpdateCampaignTemplate.java @@ -136,7 +136,9 @@ public enum FeaturesEnum { STRIKETHROUGH("strikethrough"), - ACHIEVEMENTS("achievements"); + ACHIEVEMENTS("achievements"), + + ADVANCEDEVENTS("advancedEvents"); private String value; diff --git a/src/main/java/one/talon/model/UpdateExperiment.java b/src/main/java/one/talon/model/UpdateExperiment.java index 33d82334..768324ed 100644 --- a/src/main/java/one/talon/model/UpdateExperiment.java +++ b/src/main/java/one/talon/model/UpdateExperiment.java @@ -38,6 +38,65 @@ public class UpdateExperiment { @SerializedName(SERIALIZED_NAME_CAMPAIGN) private UpdateCampaign campaign; + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the current value is preserved. + */ + @JsonAdapter(GoalTypeEnum.Adapter.class) + public enum GoalTypeEnum { + OTHER("other"), + + MAXIMIZE_REVENUE("maximize_revenue"), + + MAXIMIZE_ITEMS_SOLD("maximize_items_sold"), + + OPTIMIZE_DISCOUNT_EFFICIENCY("optimize_discount_efficiency"); + + private String value; + + GoalTypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static GoalTypeEnum fromValue(String value) { + for (GoalTypeEnum b : GoalTypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final GoalTypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public GoalTypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return GoalTypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_GOAL_TYPE = "goalType"; + @SerializedName(SERIALIZED_NAME_GOAL_TYPE) + private GoalTypeEnum goalType; + + public static final String SERIALIZED_NAME_GOAL_DESCRIPTION = "goalDescription"; + @SerializedName(SERIALIZED_NAME_GOAL_DESCRIPTION) + private String goalDescription; + public UpdateExperiment isVariantAssignmentExternal(Boolean isVariantAssignmentExternal) { @@ -83,6 +142,52 @@ public void setCampaign(UpdateCampaign campaign) { } + public UpdateExperiment goalType(GoalTypeEnum goalType) { + + this.goalType = goalType; + return this; + } + + /** + * The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the current value is preserved. + * @return goalType + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The goal of the experiment. Determines which single metric is used to decide the winning variant. When set to `other`, multiple metrics are used. If omitted, the current value is preserved. ") + + public GoalTypeEnum getGoalType() { + return goalType; + } + + + public void setGoalType(GoalTypeEnum goalType) { + this.goalType = goalType; + } + + + public UpdateExperiment goalDescription(String goalDescription) { + + this.goalDescription = goalDescription; + return this; + } + + /** + * A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the current value is preserved. + * @return goalDescription + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Offering free shipping will increase average order revenue more than a 10% discount", value = "A description of the experiment goal. Provides context for the AI summary and helps it interpret the outcome of the experiment against the stated goal. If omitted, the current value is preserved. ") + + public String getGoalDescription() { + return goalDescription; + } + + + public void setGoalDescription(String goalDescription) { + this.goalDescription = goalDescription; + } + + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -93,12 +198,14 @@ public boolean equals(java.lang.Object o) { } UpdateExperiment updateExperiment = (UpdateExperiment) o; return Objects.equals(this.isVariantAssignmentExternal, updateExperiment.isVariantAssignmentExternal) && - Objects.equals(this.campaign, updateExperiment.campaign); + Objects.equals(this.campaign, updateExperiment.campaign) && + Objects.equals(this.goalType, updateExperiment.goalType) && + Objects.equals(this.goalDescription, updateExperiment.goalDescription); } @Override public int hashCode() { - return Objects.hash(isVariantAssignmentExternal, campaign); + return Objects.hash(isVariantAssignmentExternal, campaign, goalType, goalDescription); } @@ -108,6 +215,8 @@ public String toString() { sb.append("class UpdateExperiment {\n"); sb.append(" isVariantAssignmentExternal: ").append(toIndentedString(isVariantAssignmentExternal)).append("\n"); sb.append(" campaign: ").append(toIndentedString(campaign)).append("\n"); + sb.append(" goalType: ").append(toIndentedString(goalType)).append("\n"); + sb.append(" goalDescription: ").append(toIndentedString(goalDescription)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/UpdateReward.java b/src/main/java/one/talon/model/UpdateReward.java new file mode 100644 index 00000000..51e3c7d1 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateReward.java @@ -0,0 +1,339 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; + +/** + * UpdateReward + */ + +public class UpdateReward { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + /** + * The status of the reward. + */ + @JsonAdapter(StatusEnum.Adapter.class) + public enum StatusEnum { + ACTIVE("active"), + + INACTIVE("inactive"); + + private String value; + + StatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static StatusEnum fromValue(String value) { + for (StatusEnum b : StatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public StatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return StatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private StatusEnum status; + + public static final String SERIALIZED_NAME_ELIGIBILITY_CONDITIONS = "eligibilityConditions"; + @SerializedName(SERIALIZED_NAME_ELIGIBILITY_CONDITIONS) + private Rule eligibilityConditions; + + public static final String SERIALIZED_NAME_RULE = "rule"; + @SerializedName(SERIALIZED_NAME_RULE) + private Rule rule; + + public static final String SERIALIZED_NAME_BINDINGS = "bindings"; + @SerializedName(SERIALIZED_NAME_BINDINGS) + private List bindings = null; + + public static final String SERIALIZED_NAME_POINTS_REQUIRED = "pointsRequired"; + @SerializedName(SERIALIZED_NAME_POINTS_REQUIRED) + private List pointsRequired = null; + + + public UpdateReward name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the reward. + * @return name + **/ + @ApiModelProperty(example = "Free Coffee", required = true, value = "The name of the reward.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public UpdateReward description(String description) { + + this.description = description; + return this; + } + + /** + * A description of the reward. + * @return description + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "This reward gets you one free coffee.", value = "A description of the reward.") + + public String getDescription() { + return description; + } + + + public void setDescription(String description) { + this.description = description; + } + + + public UpdateReward status(StatusEnum status) { + + this.status = status; + return this; + } + + /** + * The status of the reward. + * @return status + **/ + @ApiModelProperty(example = "active", required = true, value = "The status of the reward.") + + public StatusEnum getStatus() { + return status; + } + + + public void setStatus(StatusEnum status) { + this.status = status; + } + + + public UpdateReward eligibilityConditions(Rule eligibilityConditions) { + + this.eligibilityConditions = eligibilityConditions; + return this; + } + + /** + * Get eligibilityConditions + * @return eligibilityConditions + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getEligibilityConditions() { + return eligibilityConditions; + } + + + public void setEligibilityConditions(Rule eligibilityConditions) { + this.eligibilityConditions = eligibilityConditions; + } + + + public UpdateReward rule(Rule rule) { + + this.rule = rule; + return this; + } + + /** + * Get rule + * @return rule + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + + public Rule getRule() { + return rule; + } + + + public void setRule(Rule rule) { + this.rule = rule; + } + + + public UpdateReward bindings(List bindings) { + + this.bindings = bindings; + return this; + } + + public UpdateReward addBindingsItem(Binding bindingsItem) { + if (this.bindings == null) { + this.bindings = new ArrayList(); + } + this.bindings.add(bindingsItem); + return this; + } + + /** + * A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules. + * @return bindings + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "[]", value = "A list of named variables created before the reward's rules are evaluated. Each binding pairs a name with a talang expression. The expression is evaluated once and its result is available by name in any rule condition or effect. Bindings must be defined outside of individual rules.") + + public List getBindings() { + return bindings; + } + + + public void setBindings(List bindings) { + this.bindings = bindings; + } + + + public UpdateReward pointsRequired(List pointsRequired) { + + this.pointsRequired = pointsRequired; + return this; + } + + public UpdateReward addPointsRequiredItem(RewardPointsRequired pointsRequiredItem) { + if (this.pointsRequired == null) { + this.pointsRequired = new ArrayList(); + } + this.pointsRequired.add(pointsRequiredItem); + return this; + } + + /** + * The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** - Objects with an `id` are updated. - Objects without an `id` are created. - Existing objects omitted from the payload are deleted. + * @return pointsRequired + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The loyalty points required to activate the reward. Each object defines the specific loyalty program and subledger from which points are deducted when activating the reward. **Note:** - Objects with an `id` are updated. - Objects without an `id` are created. - Existing objects omitted from the payload are deleted. ") + + public List getPointsRequired() { + return pointsRequired; + } + + + public void setPointsRequired(List pointsRequired) { + this.pointsRequired = pointsRequired; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateReward updateReward = (UpdateReward) o; + return Objects.equals(this.name, updateReward.name) && + Objects.equals(this.description, updateReward.description) && + Objects.equals(this.status, updateReward.status) && + Objects.equals(this.eligibilityConditions, updateReward.eligibilityConditions) && + Objects.equals(this.rule, updateReward.rule) && + Objects.equals(this.bindings, updateReward.bindings) && + Objects.equals(this.pointsRequired, updateReward.pointsRequired); + } + + @Override + public int hashCode() { + return Objects.hash(name, description, status, eligibilityConditions, rule, bindings, pointsRequired); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateReward {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" eligibilityConditions: ").append(toIndentedString(eligibilityConditions)).append("\n"); + sb.append(" rule: ").append(toIndentedString(rule)).append("\n"); + sb.append(" bindings: ").append(toIndentedString(bindings)).append("\n"); + sb.append(" pointsRequired: ").append(toIndentedString(pointsRequired)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateRiskNotification.java b/src/main/java/one/talon/model/UpdateRiskNotification.java new file mode 100644 index 00000000..ae35efb8 --- /dev/null +++ b/src/main/java/one/talon/model/UpdateRiskNotification.java @@ -0,0 +1,330 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Data for updating a risk notification. + */ +@ApiModel(description = "Data for updating a risk notification.") + +public class UpdateRiskNotification { + /** + * The entity type to analyze within the given time frame. + */ + @JsonAdapter(EntityEnum.Adapter.class) + public enum EntityEnum { + PROFILE("customer_profile"), + + SESSION("customer_session"); + + private String value; + + EntityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static EntityEnum fromValue(String value) { + for (EntityEnum b : EntityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final EntityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public EntityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return EntityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ENTITY = "entity"; + @SerializedName(SERIALIZED_NAME_ENTITY) + private EntityEnum entity; + + /** + * The activity metric to analyze within the given entity. + */ + @JsonAdapter(ActivityEnum.Adapter.class) + public enum ActivityEnum { + LOYALTY_POINTS_EARNED("loyalty_points_earned"), + + DISCOUNTED_AMOUNT("discounted_amount"), + + COMPLETED_ORDERS("completed_orders"), + + COUPON_ATTEMPTS("coupon_attempts"); + + private String value; + + ActivityEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActivityEnum fromValue(String value) { + for (ActivityEnum b : ActivityEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActivityEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActivityEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActivityEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_ACTIVITY = "activity"; + @SerializedName(SERIALIZED_NAME_ACTIVITY) + private ActivityEnum activity; + + /** + * The rolling time window for risk evaluation. + */ + @JsonAdapter(TimeFrameEnum.Adapter.class) + public enum TimeFrameEnum { + _1D("1D"), + + _7D("7D"), + + _30D("30D"); + + private String value; + + TimeFrameEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TimeFrameEnum fromValue(String value) { + for (TimeFrameEnum b : TimeFrameEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TimeFrameEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TimeFrameEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TimeFrameEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TIME_FRAME = "timeFrame"; + @SerializedName(SERIALIZED_NAME_TIME_FRAME) + private TimeFrameEnum timeFrame; + + public static final String SERIALIZED_NAME_ACTIVE = "active"; + @SerializedName(SERIALIZED_NAME_ACTIVE) + private Boolean active; + + + public UpdateRiskNotification entity(EntityEnum entity) { + + this.entity = entity; + return this; + } + + /** + * The entity type to analyze within the given time frame. + * @return entity + **/ + @ApiModelProperty(example = "customer_profile", required = true, value = "The entity type to analyze within the given time frame.") + + public EntityEnum getEntity() { + return entity; + } + + + public void setEntity(EntityEnum entity) { + this.entity = entity; + } + + + public UpdateRiskNotification activity(ActivityEnum activity) { + + this.activity = activity; + return this; + } + + /** + * The activity metric to analyze within the given entity. + * @return activity + **/ + @ApiModelProperty(example = "loyalty_points_earned", required = true, value = "The activity metric to analyze within the given entity.") + + public ActivityEnum getActivity() { + return activity; + } + + + public void setActivity(ActivityEnum activity) { + this.activity = activity; + } + + + public UpdateRiskNotification timeFrame(TimeFrameEnum timeFrame) { + + this.timeFrame = timeFrame; + return this; + } + + /** + * The rolling time window for risk evaluation. + * @return timeFrame + **/ + @ApiModelProperty(example = "7D", required = true, value = "The rolling time window for risk evaluation.") + + public TimeFrameEnum getTimeFrame() { + return timeFrame; + } + + + public void setTimeFrame(TimeFrameEnum timeFrame) { + this.timeFrame = timeFrame; + } + + + public UpdateRiskNotification active(Boolean active) { + + this.active = active; + return this; + } + + /** + * Indicates whether this risk notification is active. + * @return active + **/ + @ApiModelProperty(example = "true", required = true, value = "Indicates whether this risk notification is active.") + + public Boolean getActive() { + return active; + } + + + public void setActive(Boolean active) { + this.active = active; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateRiskNotification updateRiskNotification = (UpdateRiskNotification) o; + return Objects.equals(this.entity, updateRiskNotification.entity) && + Objects.equals(this.activity, updateRiskNotification.activity) && + Objects.equals(this.timeFrame, updateRiskNotification.timeFrame) && + Objects.equals(this.active, updateRiskNotification.active); + } + + @Override + public int hashCode() { + return Objects.hash(entity, activity, timeFrame, active); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateRiskNotification {\n"); + sb.append(" entity: ").append(toIndentedString(entity)).append("\n"); + sb.append(" activity: ").append(toIndentedString(activity)).append("\n"); + sb.append(" timeFrame: ").append(toIndentedString(timeFrame)).append("\n"); + sb.append(" active: ").append(toIndentedString(active)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateSupportRequest.java b/src/main/java/one/talon/model/UpdateSupportRequest.java new file mode 100644 index 00000000..ad7d166e --- /dev/null +++ b/src/main/java/one/talon/model/UpdateSupportRequest.java @@ -0,0 +1,176 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * UpdateSupportRequest + */ + +public class UpdateSupportRequest { + /** + * Current status of the support request. + */ + @JsonAdapter(RequestStatusEnum.Adapter.class) + public enum RequestStatusEnum { + APPROVED("approved"), + + REJECTED("rejected"), + + EXPIRED("expired"); + + private String value; + + RequestStatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RequestStatusEnum fromValue(String value) { + for (RequestStatusEnum b : RequestStatusEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RequestStatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RequestStatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RequestStatusEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_REQUEST_STATUS = "requestStatus"; + @SerializedName(SERIALIZED_NAME_REQUEST_STATUS) + private RequestStatusEnum requestStatus; + + public static final String SERIALIZED_NAME_PROCESSING_NOTE = "processingNote"; + @SerializedName(SERIALIZED_NAME_PROCESSING_NOTE) + private String processingNote; + + + public UpdateSupportRequest requestStatus(RequestStatusEnum requestStatus) { + + this.requestStatus = requestStatus; + return this; + } + + /** + * Current status of the support request. + * @return requestStatus + **/ + @ApiModelProperty(example = "approved", required = true, value = "Current status of the support request.") + + public RequestStatusEnum getRequestStatus() { + return requestStatus; + } + + + public void setRequestStatus(RequestStatusEnum requestStatus) { + this.requestStatus = requestStatus; + } + + + public UpdateSupportRequest processingNote(String processingNote) { + + this.processingNote = processingNote; + return this; + } + + /** + * Notes attached by the admin when rejecting or approving a request. + * @return processingNote + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "Rejected as the customer was awarded points already.", value = "Notes attached by the admin when rejecting or approving a request.") + + public String getProcessingNote() { + return processingNote; + } + + + public void setProcessingNote(String processingNote) { + this.processingNote = processingNote; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateSupportRequest updateSupportRequest = (UpdateSupportRequest) o; + return Objects.equals(this.requestStatus, updateSupportRequest.requestStatus) && + Objects.equals(this.processingNote, updateSupportRequest.processingNote); + } + + @Override + public int hashCode() { + return Objects.hash(requestStatus, processingNote); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateSupportRequest {\n"); + sb.append(" requestStatus: ").append(toIndentedString(requestStatus)).append("\n"); + sb.append(" processingNote: ").append(toIndentedString(processingNote)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UseRewardEffectProps.java b/src/main/java/one/talon/model/UseRewardEffectProps.java new file mode 100644 index 00000000..33f24664 --- /dev/null +++ b/src/main/java/one/talon/model/UseRewardEffectProps.java @@ -0,0 +1,155 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * This effect is triggered when a rule that uses a customer's unlocked reward is validated during session evaluation. + */ +@ApiModel(description = "This effect is triggered when a rule that uses a customer's unlocked reward is validated during session evaluation.") + +public class UseRewardEffectProps { + public static final String SERIALIZED_NAME_INTEGRATION_ID = "integrationId"; + @SerializedName(SERIALIZED_NAME_INTEGRATION_ID) + private String integrationId; + + public static final String SERIALIZED_NAME_REWARD_ID = "rewardId"; + @SerializedName(SERIALIZED_NAME_REWARD_ID) + private Long rewardId; + + public static final String SERIALIZED_NAME_APPLICATION_ID = "applicationId"; + @SerializedName(SERIALIZED_NAME_APPLICATION_ID) + private Long applicationId; + + + public UseRewardEffectProps integrationId(String integrationId) { + + this.integrationId = integrationId; + return this; + } + + /** + * The integration ID of the customer reward that was used. + * @return integrationId + **/ + @ApiModelProperty(example = "5c0b5e6d-3f8a-4c2b-9f1e-2a7d6b4c8e90", required = true, value = "The integration ID of the customer reward that was used.") + + public String getIntegrationId() { + return integrationId; + } + + + public void setIntegrationId(String integrationId) { + this.integrationId = integrationId; + } + + + public UseRewardEffectProps rewardId(Long rewardId) { + + this.rewardId = rewardId; + return this; + } + + /** + * The ID of the reward that was used. + * @return rewardId + **/ + @ApiModelProperty(example = "5", required = true, value = "The ID of the reward that was used.") + + public Long getRewardId() { + return rewardId; + } + + + public void setRewardId(Long rewardId) { + this.rewardId = rewardId; + } + + + public UseRewardEffectProps applicationId(Long applicationId) { + + this.applicationId = applicationId; + return this; + } + + /** + * The ID of the Application the reward belongs to. + * @return applicationId + **/ + @ApiModelProperty(example = "1", required = true, value = "The ID of the Application the reward belongs to.") + + public Long getApplicationId() { + return applicationId; + } + + + public void setApplicationId(Long applicationId) { + this.applicationId = applicationId; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UseRewardEffectProps useRewardEffectProps = (UseRewardEffectProps) o; + return Objects.equals(this.integrationId, useRewardEffectProps.integrationId) && + Objects.equals(this.rewardId, useRewardEffectProps.rewardId) && + Objects.equals(this.applicationId, useRewardEffectProps.applicationId); + } + + @Override + public int hashCode() { + return Objects.hash(integrationId, rewardId, applicationId); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UseRewardEffectProps {\n"); + sb.append(" integrationId: ").append(toIndentedString(integrationId)).append("\n"); + sb.append(" rewardId: ").append(toIndentedString(rewardId)).append("\n"); + sb.append(" applicationId: ").append(toIndentedString(applicationId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/WebhookAuthenticationBaseBasic.java b/src/main/java/one/talon/model/WebhookAuthenticationBaseBasic.java new file mode 100644 index 00000000..7846a8f7 --- /dev/null +++ b/src/main/java/one/talon/model/WebhookAuthenticationBaseBasic.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.WebhookAuthenticationDataBasic; + +/** + * Authenticates the webhook with Basic HTTP authentication. + */ +@ApiModel(description = "Authenticates the webhook with Basic HTTP authentication.") + +public class WebhookAuthenticationBaseBasic { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + /** + * A webhook authentication discriminator of type `basic`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + BASIC("basic"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private WebhookAuthenticationDataBasic data; + + + public WebhookAuthenticationBaseBasic name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the webhook authentication. + * @return name + **/ + @ApiModelProperty(example = "My basic auth", required = true, value = "The name of the webhook authentication.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public WebhookAuthenticationBaseBasic type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A webhook authentication discriminator of type `basic`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A webhook authentication discriminator of type `basic`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public WebhookAuthenticationBaseBasic data(WebhookAuthenticationDataBasic data) { + + this.data = data; + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + + public WebhookAuthenticationDataBasic getData() { + return data; + } + + + public void setData(WebhookAuthenticationDataBasic data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + WebhookAuthenticationBaseBasic webhookAuthenticationBaseBasic = (WebhookAuthenticationBaseBasic) o; + return Objects.equals(this.name, webhookAuthenticationBaseBasic.name) && + Objects.equals(this.type, webhookAuthenticationBaseBasic.type) && + Objects.equals(this.data, webhookAuthenticationBaseBasic.data); + } + + @Override + public int hashCode() { + return Objects.hash(name, type, data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class WebhookAuthenticationBaseBasic {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/WebhookAuthenticationBaseCustom.java b/src/main/java/one/talon/model/WebhookAuthenticationBaseCustom.java new file mode 100644 index 00000000..2d8c81e5 --- /dev/null +++ b/src/main/java/one/talon/model/WebhookAuthenticationBaseCustom.java @@ -0,0 +1,201 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.WebhookAuthenticationDataCustom; + +/** + * Authenticates the webhook with a custom set of HTTP headers. + */ +@ApiModel(description = "Authenticates the webhook with a custom set of HTTP headers.") + +public class WebhookAuthenticationBaseCustom { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + /** + * A webhook authentication discriminator of type `custom`. + */ + @JsonAdapter(TypeEnum.Adapter.class) + public enum TypeEnum { + CUSTOM("custom"); + + private String value; + + TypeEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static TypeEnum fromValue(String value) { + for (TypeEnum b : TypeEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public TypeEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return TypeEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_TYPE = "type"; + @SerializedName(SERIALIZED_NAME_TYPE) + private TypeEnum type; + + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private WebhookAuthenticationDataCustom data; + + + public WebhookAuthenticationBaseCustom name(String name) { + + this.name = name; + return this; + } + + /** + * The name of the webhook authentication. + * @return name + **/ + @ApiModelProperty(example = "My custom auth", required = true, value = "The name of the webhook authentication.") + + public String getName() { + return name; + } + + + public void setName(String name) { + this.name = name; + } + + + public WebhookAuthenticationBaseCustom type(TypeEnum type) { + + this.type = type; + return this; + } + + /** + * A webhook authentication discriminator of type `custom`. + * @return type + **/ + @ApiModelProperty(required = true, value = "A webhook authentication discriminator of type `custom`.") + + public TypeEnum getType() { + return type; + } + + + public void setType(TypeEnum type) { + this.type = type; + } + + + public WebhookAuthenticationBaseCustom data(WebhookAuthenticationDataCustom data) { + + this.data = data; + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + + public WebhookAuthenticationDataCustom getData() { + return data; + } + + + public void setData(WebhookAuthenticationDataCustom data) { + this.data = data; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + WebhookAuthenticationBaseCustom webhookAuthenticationBaseCustom = (WebhookAuthenticationBaseCustom) o; + return Objects.equals(this.name, webhookAuthenticationBaseCustom.name) && + Objects.equals(this.type, webhookAuthenticationBaseCustom.type) && + Objects.equals(this.data, webhookAuthenticationBaseCustom.data); + } + + @Override + public int hashCode() { + return Objects.hash(name, type, data); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class WebhookAuthenticationBaseCustom {\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/WillAwardGiveawayEffectProps.java b/src/main/java/one/talon/model/WillAwardGiveawayEffectProps.java index 7df4fd73..3f3a65b0 100644 --- a/src/main/java/one/talon/model/WillAwardGiveawayEffectProps.java +++ b/src/main/java/one/talon/model/WillAwardGiveawayEffectProps.java @@ -25,9 +25,9 @@ import java.io.IOException; /** - * The properties specific to the \"awardGiveaway\" effect when the session is not closed yet. This effect replaces \"awardGiveaway\" only when updating a session with any state other than \"closed\". This is to ensure no giveaway codes are leaked when they are still not guaranteed to be awarded. + * The equivalent of the `awardGiveaway` effect but returned when updating a session with any state other than `closed`. This ensures no giveaway codes are leaked when they are still not guaranteed to be awarded. For more information about session states, see [Manage the session's state](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state). */ -@ApiModel(description = "The properties specific to the \"awardGiveaway\" effect when the session is not closed yet. This effect replaces \"awardGiveaway\" only when updating a session with any state other than \"closed\". This is to ensure no giveaway codes are leaked when they are still not guaranteed to be awarded.") +@ApiModel(description = "The equivalent of the `awardGiveaway` effect but returned when updating a session with any state other than `closed`. This ensures no giveaway codes are leaked when they are still not guaranteed to be awarded. For more information about session states, see [Manage the session's state](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#manage-the-sessions-state).") public class WillAwardGiveawayEffectProps { public static final String SERIALIZED_NAME_POOL_ID = "poolId"; @@ -50,10 +50,10 @@ public WillAwardGiveawayEffectProps poolId(Long poolId) { } /** - * The ID of the giveaways pool the code will be taken from. + * The internal ID of the giveaway pool. * @return poolId **/ - @ApiModelProperty(example = "2", required = true, value = "The ID of the giveaways pool the code will be taken from.") + @ApiModelProperty(example = "2", required = true, value = "The internal ID of the giveaway pool.") public Long getPoolId() { return poolId; @@ -72,10 +72,10 @@ public WillAwardGiveawayEffectProps poolName(String poolName) { } /** - * The name of the giveaways pool the code will be taken from. + * The name of the giveaway pool. * @return poolName **/ - @ApiModelProperty(example = "My pool", required = true, value = "The name of the giveaways pool the code will be taken from.") + @ApiModelProperty(example = "My pool", required = true, value = "The name of the giveaway pool.") public String getPoolName() { return poolName; @@ -94,10 +94,10 @@ public WillAwardGiveawayEffectProps recipientIntegrationId(String recipientInteg } /** - * The integration ID of the profile that will be awarded the giveaway. + * The integration ID of the customer that receives the giveaway. * @return recipientIntegrationId **/ - @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The integration ID of the profile that will be awarded the giveaway.") + @ApiModelProperty(example = "URNGV8294NV", required = true, value = "The integration ID of the customer that receives the giveaway.") public String getRecipientIntegrationId() { return recipientIntegrationId; diff --git a/src/main/java/one/talon/model/WithinCheckAttributeBlock.java b/src/main/java/one/talon/model/WithinCheckAttributeBlock.java new file mode 100644 index 00000000..db37bf9e --- /dev/null +++ b/src/main/java/one/talon/model/WithinCheckAttributeBlock.java @@ -0,0 +1,290 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * Variant of `CheckAttributeBlock` for the `within` and `not(within)` operators, which require both a start and end value. + */ +@ApiModel(description = "Variant of `CheckAttributeBlock` for the `within` and `not(within)` operators, which require both a start and end value.") + +public class WithinCheckAttributeBlock { + /** + * The range comparison operator. Must be `within` or `not(within)`. + */ + @JsonAdapter(OperatorEnum.Adapter.class) + public enum OperatorEnum { + WITHIN("within"), + + NOT_WITHIN_("not(within)"); + + private String value; + + OperatorEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static OperatorEnum fromValue(String value) { + for (OperatorEnum b : OperatorEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final OperatorEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public OperatorEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return OperatorEnum.fromValue(value); + } + } + } + + public static final String SERIALIZED_NAME_OPERATOR = "operator"; + @SerializedName(SERIALIZED_NAME_OPERATOR) + private OperatorEnum operator; + + public static final String SERIALIZED_NAME_START = "start"; + @SerializedName(SERIALIZED_NAME_START) + private Object start; + + public static final String SERIALIZED_NAME_END = "end"; + @SerializedName(SERIALIZED_NAME_END) + private Object end; + + public static final String SERIALIZED_NAME_START_INCLUSIVE = "startInclusive"; + @SerializedName(SERIALIZED_NAME_START_INCLUSIVE) + private Boolean startInclusive; + + public static final String SERIALIZED_NAME_END_INCLUSIVE = "endInclusive"; + @SerializedName(SERIALIZED_NAME_END_INCLUSIVE) + private Boolean endInclusive; + + public static final String SERIALIZED_NAME_TIMEZONE_INSENSITIVE = "timezoneInsensitive"; + @SerializedName(SERIALIZED_NAME_TIMEZONE_INSENSITIVE) + private Boolean timezoneInsensitive; + + + public WithinCheckAttributeBlock operator(OperatorEnum operator) { + + this.operator = operator; + return this; + } + + /** + * The range comparison operator. Must be `within` or `not(within)`. + * @return operator + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "The range comparison operator. Must be `within` or `not(within)`.") + + public OperatorEnum getOperator() { + return operator; + } + + + public void setOperator(OperatorEnum operator) { + this.operator = operator; + } + + + public WithinCheckAttributeBlock start(Object start) { + + this.start = start; + return this; + } + + /** + * The start value for the `within` operator. + * @return start + **/ + @ApiModelProperty(example = "2021-09-22T22:00:00Z", required = true, value = "The start value for the `within` operator.") + + public Object getStart() { + return start; + } + + + public void setStart(Object start) { + this.start = start; + } + + + public WithinCheckAttributeBlock end(Object end) { + + this.end = end; + return this; + } + + /** + * The end value for the `within` operator. + * @return end + **/ + @ApiModelProperty(example = "2021-09-22T22:00:00Z", required = true, value = "The end value for the `within` operator.") + + public Object getEnd() { + return end; + } + + + public void setEnd(Object end) { + this.end = end; + } + + + public WithinCheckAttributeBlock startInclusive(Boolean startInclusive) { + + this.startInclusive = startInclusive; + return this; + } + + /** + * When `true`, the `start` value is included in the range for the `within` operator. + * @return startInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `start` value is included in the range for the `within` operator.") + + public Boolean getStartInclusive() { + return startInclusive; + } + + + public void setStartInclusive(Boolean startInclusive) { + this.startInclusive = startInclusive; + } + + + public WithinCheckAttributeBlock endInclusive(Boolean endInclusive) { + + this.endInclusive = endInclusive; + return this; + } + + /** + * When `true`, the `end` value is included in the range for the `within` operator. + * @return endInclusive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "true", value = "When `true`, the `end` value is included in the range for the `within` operator.") + + public Boolean getEndInclusive() { + return endInclusive; + } + + + public void setEndInclusive(Boolean endInclusive) { + this.endInclusive = endInclusive; + } + + + public WithinCheckAttributeBlock timezoneInsensitive(Boolean timezoneInsensitive) { + + this.timezoneInsensitive = timezoneInsensitive; + return this; + } + + /** + * Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account. + * @return timezoneInsensitive + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "false", value = "Indicates whether the `within` operator ignores time zones and compares the wall-clock time only. When `false`, time zones are taken into account.") + + public Boolean getTimezoneInsensitive() { + return timezoneInsensitive; + } + + + public void setTimezoneInsensitive(Boolean timezoneInsensitive) { + this.timezoneInsensitive = timezoneInsensitive; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + WithinCheckAttributeBlock withinCheckAttributeBlock = (WithinCheckAttributeBlock) o; + return Objects.equals(this.operator, withinCheckAttributeBlock.operator) && + Objects.equals(this.start, withinCheckAttributeBlock.start) && + Objects.equals(this.end, withinCheckAttributeBlock.end) && + Objects.equals(this.startInclusive, withinCheckAttributeBlock.startInclusive) && + Objects.equals(this.endInclusive, withinCheckAttributeBlock.endInclusive) && + Objects.equals(this.timezoneInsensitive, withinCheckAttributeBlock.timezoneInsensitive); + } + + @Override + public int hashCode() { + return Objects.hash(operator, start, end, startInclusive, endInclusive, timezoneInsensitive); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class WithinCheckAttributeBlock {\n"); + sb.append(" operator: ").append(toIndentedString(operator)).append("\n"); + sb.append(" start: ").append(toIndentedString(start)).append("\n"); + sb.append(" end: ").append(toIndentedString(end)).append("\n"); + sb.append(" startInclusive: ").append(toIndentedString(startInclusive)).append("\n"); + sb.append(" endInclusive: ").append(toIndentedString(endInclusive)).append("\n"); + sb.append(" timezoneInsensitive: ").append(toIndentedString(timezoneInsensitive)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/test/java/one/talon/api/IntegrationApiTest.java b/src/test/java/one/talon/api/IntegrationApiTest.java index f43bdf71..05a8c2a6 100644 --- a/src/test/java/one/talon/api/IntegrationApiTest.java +++ b/src/test/java/one/talon/api/IntegrationApiTest.java @@ -19,6 +19,7 @@ import one.talon.model.Audience; import one.talon.model.BestPriorPrice; import one.talon.model.BestPriorPriceRequest; +import java.math.BigDecimal; import one.talon.model.Catalog; import one.talon.model.CatalogSyncRequest; import one.talon.model.Coupon; @@ -30,6 +31,7 @@ import one.talon.model.DeleteLoyaltyTransactionsRequest; import one.talon.model.ErrorResponse; import one.talon.model.ErrorResponseWithStatus; +import one.talon.model.EventV3; import one.talon.model.GenerateLoyaltyCard; import one.talon.model.InlineResponse200; import one.talon.model.InlineResponse2001; @@ -37,14 +39,18 @@ import one.talon.model.InlineResponse2003; import one.talon.model.InlineResponse2004; import one.talon.model.InlineResponse2005; +import one.talon.model.InlineResponse20056; import one.talon.model.InlineResponse2006; import one.talon.model.InlineResponse2007; import one.talon.model.InlineResponse201; import one.talon.model.IntegrationCustomerSessionResponse; import one.talon.model.IntegrationEventV2Request; import one.talon.model.IntegrationEventV2Response; +import one.talon.model.IntegrationEventV3Request; +import one.talon.model.IntegrationEventV3Response; import one.talon.model.IntegrationRequest; import one.talon.model.IntegrationStateV2; +import one.talon.model.IntegrationUnlockRewardRequest; import one.talon.model.LoyaltyBalancesWithTiers; import one.talon.model.LoyaltyCard; import one.talon.model.LoyaltyCardBalances; @@ -58,6 +64,7 @@ import one.talon.model.Referral; import one.talon.model.ReopenSessionResponse; import one.talon.model.ReturnIntegrationRequest; +import one.talon.model.RewardUnlockRejection; import one.talon.model.UpdateAudience; import org.junit.Test; import org.junit.Ignore; @@ -194,7 +201,7 @@ public void deleteAudienceMembershipsV2Test() throws ApiException { /** * Delete audience * - * Delete an audience created by a third-party integration. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). + * Delete an audience. > [!warning] This endpoint also removes any associations recorded between a customer profile and this audience. > [!note] Audiences can also be deleted via the Campaign Manager. See the [docs](https://docs.talon.one/docs/product/audiences/managing-audiences#deleting-an-audience). The audience isn't deleted if any experiment variant uses it. The response identifies each blocking experiment by its Campaign Manager path. * * @throws ApiException * if the Api call fails @@ -336,7 +343,8 @@ public void getCustomerInventoryTest() throws ApiException { Boolean loyalty = null; Boolean giveaways = null; Boolean achievements = null; - CustomerInventory response = api.getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements); + Boolean unlockedRewards = null; + CustomerInventory response = api.getCustomerInventory(integrationId, profile, referrals, coupons, loyalty, giveaways, achievements, unlockedRewards); // TODO: test validations } @@ -357,6 +365,22 @@ public void getCustomerSessionTest() throws ApiException { // TODO: test validations } + /** + * Get advanced event + * + * Retrieve an advanced event by its identifier. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getEventV3Test() throws ApiException { + String integrationId = null; + EventV3 response = api.getEventV3(integrationId); + + // TODO: test validations + } + /** * Get customer's loyalty balances * @@ -460,7 +484,7 @@ public void getLoyaltyProgramProfilePointsTest() throws ApiException { Long loyaltyProgramId = null; String integrationId = null; String status = null; - String subledgerId = null; + List subledgerId = null; List customerSessionIDs = null; List transactionUUIDs = null; Long pageSize = null; @@ -485,7 +509,7 @@ public void getLoyaltyProgramProfileTransactionsTest() throws ApiException { String integrationId = null; List customerSessionIDs = null; List transactionUUIDs = null; - String subledgerId = null; + List subledgerId = null; String loyaltyTransactionType = null; OffsetDateTime startDate = null; OffsetDateTime endDate = null; @@ -530,7 +554,50 @@ public void integrationGetAllCampaignsTest() throws ApiException { OffsetDateTime startBefore = null; OffsetDateTime endAfter = null; OffsetDateTime endBefore = null; - InlineResponse200 response = api.integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore); + Long storeId = null; + Long audienceId = null; + InlineResponse200 response = api.integrationGetAllCampaigns(pageSize, skip, campaignIds, startAfter, startBefore, endAfter, endBefore, storeId, audienceId); + + // TODO: test validations + } + + /** + * List rewards in the catalog + * + * Retrieve the rewards catalog for the Application. Returns a paginated list of rewards. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void integrationRewardsCatalogTest() throws ApiException { + Long pageSize = null; + Long skip = null; + BigDecimal pointsFrom = null; + BigDecimal pointsTo = null; + Boolean includeFree = null; + Long loyaltyProgramId = null; + String subledgerId = null; + String profileIntegrationId = null; + String loyaltyCardId = null; + InlineResponse20056 response = api.integrationRewardsCatalog(pageSize, skip, pointsFrom, pointsTo, includeFree, loyaltyProgramId, subledgerId, profileIntegrationId, loyaltyCardId); + + // TODO: test validations + } + + /** + * Join customer profile to loyalty program + * + * 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. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void joinLoyaltyProgramTest() throws ApiException { + Long loyaltyProgramId = null; + String integrationId = null; + api.joinLoyaltyProgram(loyaltyProgramId, integrationId); // TODO: test validations } @@ -572,7 +639,7 @@ public void reopenCustomerSessionTest() throws ApiException { /** * Return cart items * - * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). > [!note] To make request processing idempotent for this endpoint, include the `Idempotency-Key` header with an idempotency key in requests. Also: > - Requests with the `Idempotency-Key` header are logged in the Talon.One access logs. > - Responses for idempotent requests are stored in the database and expire 24 hours after the request is sent. > - Idempotency keys are typically UUID keys and should not exceed 255 characters in length. + * Create a new return request for the specified cart items. This endpoint automatically changes the session state from `closed` to `partially_returned`. > [!note] This will roll back any effects associated with these cart items. > For more information, see [our documentation on session > states](https://docs.talon.one/docs/dev/concepts/entities/customer-sessions#customer-session-states) > and [this tutorial](https://docs.talon.one/docs/dev/tutorials/partially-returning-a-session). * * @throws ApiException * if the Api call fails @@ -591,7 +658,7 @@ public void returnCartItemsTest() throws ApiException { /** * Sync cart item catalog * - * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. ### Payload examples Synchronization actions are sent as `PUT` requests. See the structure for each action: <details> <summary><strong>Adding an item to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Adding multiple items to the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241027\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" }, { \"payload\": { \"attributes\": { \"color\": \"Navy blue\", \"type\": \"shoes\" }, \"replaceIfExists\": true, \"sku\": \"SKU1241028\", \"price\": 100, \"product\": { \"name\": \"sneakers\" } }, \"type\": \"ADD\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of an item in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"age\": 11, \"origin\": \"germany\" }, \"createIfNotExists\": false, \"sku\": \"SKU1241028\", \"product\": { \"name\": \"sneakers\" } }, \"type\": \"PATCH\" } ] } ``` </div> </details> <details> <summary><strong>Updating the attributes of multiple items in the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"attributes\": { \"color\": \"red\" }, \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"PATCH_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing an item from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"sku\": \"SKU1241028\" }, \"type\": \"REMOVE\" } ] } ``` </div> </details> <details> <summary><strong>Removing multiple items from the catalog</strong></summary> <div> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"color\", \"op\": \"EQ\", \"value\": \"blue\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> <details> <summary><strong>Removing shoes of sizes above 45 from the catalog</strong></summary> <div> <p> Let's imagine that we have a shoe store and we have decided to stop selling shoes larger than size 45. We can remove from the catalog all the shoes of sizes above 45 with a single action:</p> ```json { \"actions\": [ { \"payload\": { \"filters\": [ { \"attr\": \"size\", \"op\": \"GT\", \"value\": \"45\" } ] }, \"type\": \"REMOVE_MANY\" } ] } ``` </div> </details> + * Perform the following actions for a given cart item catalog: - Add an item to the catalog. - Add multiple items to the catalog. - Update the attributes of an item in the catalog. - Update the attributes of multiple items in the catalog. - Remove an item from the catalog. - Remove multiple items from the catalog. You can either add, update, or delete up to 1000 cart items in a single request. Each item synced to a catalog must have a unique `SKU`. > [!important] You can perform only one type of action in a single sync request. Syncing items with duplicate `SKU` values in a single request returns an error message with a `400` status code. For more information, read [managing cart item catalogs](https://docs.talon.one/docs/product/account/dev-tools/managing-cart-item-catalogs). ### Filtering cart items Use [cart item attributes](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) to filter items and select the ones you want to edit or delete when editing or deleting more than one item at a time. The `filters` array contains an object with the following properties: - `attr`: A [cart item attribute](https://docs.talon.one/docs/product/account/dev-tools/managing-attributes) connected to the catalog. It is applied to all items in the catalog. - `op`: The filtering operator indicating the relationship between the value of each cart item in the catalog and the value of the `value` property for the attribute selected in `attr`. The value of `op` can be one of the following: - `EQ`: Equal to `value` - `LT`: Less than `value` - `LE`: Less than or equal to `value` - `GT`: Greater than `value` - `GE`: Greater than or equal to `value` - `IN`: One of the comma-separated values that `value` is set to. **Note:** `GE`, `LE`, `GT`, `LT` are for numeric values only. - `value`: The value of the attribute selected in `attr`. For request examples of each action, see the **Request Body** examples. * * @throws ApiException * if the Api call fails @@ -608,7 +675,7 @@ public void syncCatalogTest() throws ApiException { /** * Track event * - * Triggers a custom event. To use this endpoint: 1. Define a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#creating-a-custom-event) in the Campaign Manager. 1. Update or create a rule to check for this event. 1. Trigger the event with this endpoint. After you have successfully sent an event to Talon.One, you can list the received events in the **Events** view in the Campaign Manager. Talon.One also offers a set of [built-in events](https://docs.talon.one/docs/dev/concepts/entities/events). Ensure you do not create a custom event when you can use a built-in event. For example, use this endpoint to trigger an event when a customer shares a link to a product. See the [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation. + * Trigger a [custom event](https://docs.talon.one/docs/dev/concepts/entities/events#custom-events). To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to trigger an event when a customer shares a link to a product. See our [tutorial](https://docs.talon.one/docs/product/tutorials/referrals/incentivizing-product-link-sharing). > [!note] **Note** > - `profileId` is required even though the schema does not specify it. > - If the customer profile ID is new, a new profile is automatically created but the `customer_profile_created` [built-in event ](https://docs.talon.one/docs/dev/concepts/entities/events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. * * @throws ApiException * if the Api call fails @@ -624,6 +691,25 @@ public void trackEventV2Test() throws ApiException { // TODO: test validations } + /** + * Track advanced event + * + * Trigger an [advanced event](https://docs.talon.one/docs/dev/concepts/entities/events#advanced-events). Advanced events are idempotent, uniquely identifiable events. They can also reference a previously closed session to add more context for rule evaluation. To use this endpoint: 1. [Create](https://docs.talon.one/docs/dev/concepts/entities/events#create-an-event) an event in the Campaign Manager. 1. In a rule, add the **Check for event types** [condition](https://docs.talon.one/docs/dev/concepts/entities/events#use-an-event-in-a-rule) and select the event you created. 1. Trigger the event with this endpoint. You can [list](https://docs.talon.one/docs/product/applications/display-events#list-events) the received events in the **Events** view of the Campaign Manager. For example, you can use this endpoint to award loyalty points after an order is delivered. See our [tutorial](https://docs.talon.one/docs/dev/tutorials/award-loyalty-points-after-delivery). > [!note] **Note** > - If the customer profile does not exist, it will be created. However, the `customer_profile_created` [built-in event](https://docs.talon.one/docs/dev/concepts/entities/events#built-in-events) is **not** triggered. > - We recommend sending requests sequentially. See [Manage parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#manage-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archive-a-campaign) are not considered in rule evaluation. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void trackEventV3Test() throws ApiException { + IntegrationEventV3Request body = null; + String silent = null; + Boolean dry = null; + Boolean forceCompleteEvaluation = null; + IntegrationEventV3Response response = api.trackEventV3(body, silent, dry, forceCompleteEvaluation); + + // TODO: test validations + } + /** * Unlink customer profile from a loyalty card * @@ -642,6 +728,24 @@ public void unlinkLoyaltyCardFromProfileTest() throws ApiException { // TODO: test validations } + /** + * Unlock a reward + * + * Unlock a reward for a customer. If the reward has `pointsRequired` configured, the corresponding loyalty points are deducted from the customer's balance. To unlock a reward with the points of a loyalty card, provide the card in `cardIdentifier`. The points are then deducted from the card, and the unlocked reward belongs to the card, which makes it available to all customer profiles linked to that card. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void unlockRewardTest() throws ApiException { + Long rewardId = null; + IntegrationUnlockRewardRequest body = null; + Boolean dry = null; + IntegrationStateV2 response = api.unlockReward(rewardId, body, dry); + + // TODO: test validations + } + /** * Update profile attributes for all customers in audience * @@ -695,7 +799,7 @@ public void updateCustomerProfileAudiencesTest() throws ApiException { /** * Update customer profile * - * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. + * Update or create a [Customer Profile](https://docs.talon.one/docs/dev/concepts/entities/customer-profiles). This endpoint triggers the Rule Builder. You can use this endpoint to: - Set attributes on the given customer profile. Ensure you create the attributes in the Campaign Manager, first. - Modify the audience the customer profile is a member of. > [!note] **Note** > - Updating a customer profile returns a response with the requested integration state. > - The [Has joined an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) and > [Has left an audience](https://docs.talon.one/docs/product/rules/conditions/available-conditions#audience-conditions) conditions > only trigger through this endpoint. > - You can use the `responseContent` property to save yourself extra API calls. For example, you can get > the customer profile details directly without extra requests. > - We recommend sending requests sequentially. > See [Managing parallel requests](https://docs.talon.one/docs/dev/getting-started/integration-tutorial#managing-parallel-requests). > - [Archived campaigns](https://docs.talon.one/docs/product/campaigns/managing-campaigns#archiving-a-campaign) are not considered in rule evaluation when `runRuleEngine` is `true`. * * @throws ApiException * if the Api call fails diff --git a/src/test/java/one/talon/api/ManagementApiTest.java b/src/test/java/one/talon/api/ManagementApiTest.java index 94c82c2c..aa185baa 100644 --- a/src/test/java/one/talon/api/ManagementApiTest.java +++ b/src/test/java/one/talon/api/ManagementApiTest.java @@ -18,6 +18,7 @@ import one.talon.model.AccountAdditionalCost; import one.talon.model.AccountAnalytics; import one.talon.model.Achievement; +import one.talon.model.AchievementV2; import one.talon.model.AddLoyaltyPoints; import one.talon.model.Application; import one.talon.model.ApplicationApiHealth; @@ -35,6 +36,7 @@ import one.talon.model.Collection; import one.talon.model.Coupon; import one.talon.model.CreateAchievement; +import one.talon.model.CreateAchievementV2; import one.talon.model.CreateTemplateCampaign; import one.talon.model.CreateTemplateCampaignResponse; import one.talon.model.CustomerActivityReport; @@ -45,6 +47,7 @@ import one.talon.model.DeleteUserRequest; import one.talon.model.ErrorResponse; import one.talon.model.ErrorResponseWithStatus; +import one.talon.model.ExcludePriceObservationsRequest; import one.talon.model.Experiment; import one.talon.model.InlineResponse20010; import one.talon.model.InlineResponse20011; @@ -91,6 +94,8 @@ import one.talon.model.InlineResponse20051; import one.talon.model.InlineResponse20052; import one.talon.model.InlineResponse20053; +import one.talon.model.InlineResponse20054; +import one.talon.model.InlineResponse20055; import one.talon.model.InlineResponse2008; import one.talon.model.InlineResponse2009; import one.talon.model.LoginParams; @@ -125,6 +130,7 @@ import one.talon.model.RoleV2; import one.talon.model.RoleV2Base; import one.talon.model.Ruleset; +import one.talon.model.RulesetV2; import one.talon.model.ScimBaseGroup; import one.talon.model.ScimGroup; import one.talon.model.ScimGroupsListResponse; @@ -139,6 +145,7 @@ import one.talon.model.Store; import one.talon.model.TransferLoyaltyCard; import one.talon.model.UpdateAchievement; +import one.talon.model.UpdateAchievementV2; import one.talon.model.UpdateCampaign; import one.talon.model.UpdateCampaignCollection; import one.talon.model.UpdateCollection; @@ -270,6 +277,22 @@ public void createAchievementTest() throws ApiException { // TODO: test validations } + /** + * Create achievement + * + * Create a new account-level achievement. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void createAchievementV2Test() throws ApiException { + CreateAchievementV2 body = null; + AchievementV2 response = api.createAchievementV2(body); + + // TODO: test validations + } + /** * Create additional cost * @@ -494,6 +517,24 @@ public void createPasswordRecoveryEmailTest() throws ApiException { // TODO: test validations } + /** + * Create ruleset (V2) + * + * Create a ruleset from promotion and strikethrough rules in the V2 JSON block format. A ruleset is a revision of all the rules of a campaign. Only `group` and `passthrough` blocks are currently writable, with optional `onFailure` blocks. A payload containing any other block type is rejected. Each rule's `blocks` array may contain at most one block. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void createRulesetV2Test() throws ApiException { + Long applicationId = null; + Long campaignId = null; + RulesetV2 body = null; + RulesetV2 response = api.createRulesetV2(applicationId, campaignId, body); + + // TODO: test validations + } + /** * Create session * @@ -595,6 +636,22 @@ public void deleteAchievementTest() throws ApiException { // TODO: test validations } + /** + * Delete achievement + * + * Delete a specific achievement. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void deleteAchievementV2Test() throws ApiException { + Long achievementId = null; + api.deleteAchievementV2(achievementId); + + // TODO: test validations + } + /** * Delete campaign * @@ -813,6 +870,23 @@ public void disconnectCampaignStoresTest() throws ApiException { // TODO: test validations } + /** + * Exclude price records from price history + * + * Select a batch of historical price IDs to exclude from [best prior price calculation](https://docs.talon.one/integration-api#tag/Catalogs/operation/bestPriorPrice). All IDs in the batch must be valid `id` values obtained from the [Get summary of price history](https://docs.talon.one/management-api#tag/Catalogs/operation/priceHistory.responses.200.history) endpoint, must belong to the specified Application, must not already be excluded from best prior price calculation, and must not be associated with a scheduled strikethrough pricing notification. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void excludePriceHistoryTest() throws ApiException { + Long applicationId = null; + ExcludePriceObservationsRequest body = null; + api.excludePriceHistory(applicationId, body); + + // TODO: test validations + } + /** * Export account-level collection's items * @@ -829,6 +903,22 @@ public void exportAccountCollectionItemsTest() throws ApiException { // TODO: test validations } + /** + * Export achievement customer data + * + * Download a CSV file containing a list of all the customers who have participated in and are currently participating in the given achievement. The CSV file contains the following columns: - `profileIntegrationID`: The integration ID of the customer profile participating in the achievement. - `title`: The display name of the achievement in the Campaign Manager. - `target`: The required number of actions or the transactional milestone to complete the achievement. - `progress`: The current progress of the customer in the achievement. - `status`: The status of the achievement. Can be one of: ['inprogress', 'completed', 'expired']. - `startDate`: The date on which the customer profile started the achievement in RFC3339. - `endDate`: The date on which the achievement ends and resets for the customer profile in RFC3339. - `completionDate`: The date on which the customer profile completed the achievement in RFC3339. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void exportAchievementV2Test() throws ApiException { + Long achievementId = null; + String response = api.exportAchievementV2(achievementId); + + // TODO: test validations + } + /** * Export achievement customer data * @@ -979,7 +1069,9 @@ public void exportCouponsTest() throws ApiException { String dateFormat = null; String campaignState = null; Boolean valuesOnly = null; - String response = api.exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly); + OffsetDateTime deletedBefore = null; + OffsetDateTime deletedAfter = null; + String response = api.exportCoupons(applicationId, campaignId, sort, value, createdBefore, createdAfter, valid, usable, referralId, recipientIntegrationId, batchId, exactMatch, dateFormat, campaignState, valuesOnly, deletedBefore, deletedAfter); // TODO: test validations } @@ -997,10 +1089,12 @@ public void exportCustomerSessionsTest() throws ApiException { Long applicationId = null; OffsetDateTime createdBefore = null; OffsetDateTime createdAfter = null; + OffsetDateTime updatedBefore = null; + OffsetDateTime updatedAfter = null; String profileIntegrationId = null; String dateFormat = null; String customerSessionState = null; - String response = api.exportCustomerSessions(applicationId, createdBefore, createdAfter, profileIntegrationId, dateFormat, customerSessionState); + String response = api.exportCustomerSessions(applicationId, createdBefore, createdAfter, updatedBefore, updatedAfter, profileIntegrationId, dateFormat, customerSessionState); // TODO: test validations } @@ -1055,7 +1149,8 @@ public void exportEffectsTest() throws ApiException { public void exportLoyaltyBalanceTest() throws ApiException { String loyaltyProgramId = null; OffsetDateTime endDate = null; - String response = api.exportLoyaltyBalance(loyaltyProgramId, endDate); + String balances = null; + String response = api.exportLoyaltyBalance(loyaltyProgramId, endDate, balances); // TODO: test validations } @@ -1072,7 +1167,8 @@ public void exportLoyaltyBalanceTest() throws ApiException { public void exportLoyaltyBalancesTest() throws ApiException { String loyaltyProgramId = null; OffsetDateTime endDate = null; - String response = api.exportLoyaltyBalances(loyaltyProgramId, endDate); + String balances = null; + String response = api.exportLoyaltyBalances(loyaltyProgramId, endDate, balances); // TODO: test validations } @@ -1089,7 +1185,8 @@ public void exportLoyaltyBalancesTest() throws ApiException { public void exportLoyaltyCardBalancesTest() throws ApiException { Long loyaltyProgramId = null; OffsetDateTime endDate = null; - String response = api.exportLoyaltyCardBalances(loyaltyProgramId, endDate); + String balances = null; + String response = api.exportLoyaltyCardBalances(loyaltyProgramId, endDate, balances); // TODO: test validations } @@ -1117,7 +1214,7 @@ public void exportLoyaltyCardLedgerTest() throws ApiException { /** * Export loyalty cards * - * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. Currently, this feature is only available upon request. + * Download a CSV file containing the loyalty cards from a specified loyalty program. > [!tip] If the exported CSV file is too large to view, you can > [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files). The CSV file contains the following columns: - `identifier`: The unique identifier of the loyalty card. - `created`: The date and time the loyalty card was created. - `status`: The status of the loyalty card. - `userpercardlimit`: The maximum number of customer profiles that can be linked to the card. - `customerprofileids`: Integration IDs of the customer profiles linked to the card. - `blockreason`: The reason for transferring and blocking the loyalty card. - `generated`: An indicator of whether the loyalty card was generated. - `batchid`: The ID of the batch the loyalty card is in. - `attributes`: The custom attributes of this loyalty card. * * @throws ApiException * if the Api call fails @@ -1225,7 +1322,7 @@ public void generateCouponRejectionsTest() throws ApiException { BigDecimal applicationId = null; String language = null; String couponCode = null; - InlineResponse20053 response = api.generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode); + InlineResponse20055 response = api.generateCouponRejections(sessionIntegrationId, applicationId, language, couponCode); // TODO: test validations } @@ -1320,6 +1417,22 @@ public void getAchievementTest() throws ApiException { // TODO: test validations } + /** + * Get achievement + * + * Retrieve the details of a specific achievement. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getAchievementV2Test() throws ApiException { + Long achievementId = null; + AchievementV2 response = api.getAchievementV2(achievementId); + + // TODO: test validations + } + /** * Get additional cost * @@ -1349,7 +1462,7 @@ public void getAdditionalCostsTest() throws ApiException { Long pageSize = null; Long skip = null; String sort = null; - InlineResponse20040 response = api.getAdditionalCosts(pageSize, skip, sort); + InlineResponse20041 response = api.getAdditionalCosts(pageSize, skip, sort); // TODO: test validations } @@ -1437,7 +1550,7 @@ public void getApplicationCustomerFriendsTest() throws ApiException { Long skip = null; String sort = null; Boolean withTotalResultSize = null; - InlineResponse20037 response = api.getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); + InlineResponse20038 response = api.getApplicationCustomerFriends(applicationId, integrationId, pageSize, skip, sort, withTotalResultSize); // TODO: test validations } @@ -1496,7 +1609,7 @@ public void getApplicationEventTypesTest() throws ApiException { Long pageSize = null; Long skip = null; String sort = null; - InlineResponse20033 response = api.getApplicationEventTypes(applicationId, pageSize, skip, sort); + InlineResponse20034 response = api.getApplicationEventTypes(applicationId, pageSize, skip, sort); // TODO: test validations } @@ -1527,7 +1640,7 @@ public void getApplicationEventsWithoutTotalCountTest() throws ApiException { String ruleQuery = null; String campaignQuery = null; String effectType = null; - InlineResponse20032 response = api.getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); + InlineResponse20033 response = api.getApplicationEventsWithoutTotalCount(applicationId, pageSize, skip, sort, type, createdBefore, createdAfter, session, profile, customerName, customerEmail, couponCode, referralCode, ruleQuery, campaignQuery, effectType); // TODO: test validations } @@ -1577,6 +1690,26 @@ public void getApplicationSessionsTest() throws ApiException { // TODO: test validations } + /** + * List Application sessions matching the given customer attributes + * + * Get a list of the Application sessions matching the provided customer profile attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getApplicationSessionsByCustomerAttributesTest() throws ApiException { + Long applicationId = null; + CustomerProfileSearchQuery body = null; + Long pageSize = null; + Long skip = null; + Boolean withTotalResultSize = null; + InlineResponse20032 response = api.getApplicationSessionsByCustomerAttributes(applicationId, body, pageSize, skip, withTotalResultSize); + + // TODO: test validations + } + /** * List Applications * @@ -1626,10 +1759,11 @@ public void getAttributesTest() throws ApiException { String sort = null; String entity = null; String applicationIds = null; + String loyaltyProgramIds = null; String type = null; String kind = null; String search = null; - InlineResponse20038 response = api.getAttributes(pageSize, skip, sort, entity, applicationIds, type, kind, search); + InlineResponse20039 response = api.getAttributes(pageSize, skip, sort, entity, applicationIds, loyaltyProgramIds, type, kind, search); // TODO: test validations } @@ -1649,7 +1783,7 @@ public void getAudienceMembershipsTest() throws ApiException { Long skip = null; String sort = null; String profileQuery = null; - InlineResponse20036 response = api.getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery); + InlineResponse20037 response = api.getAudienceMemberships(audienceId, pageSize, skip, sort, profileQuery); // TODO: test validations } @@ -1668,7 +1802,7 @@ public void getAudiencesTest() throws ApiException { Long skip = null; String sort = null; Boolean withTotalResultSize = null; - InlineResponse20034 response = api.getAudiences(pageSize, skip, sort, withTotalResultSize); + InlineResponse20035 response = api.getAudiences(pageSize, skip, sort, withTotalResultSize); // TODO: test validations } @@ -1685,7 +1819,7 @@ public void getAudiencesTest() throws ApiException { public void getAudiencesAnalyticsTest() throws ApiException { String audienceIds = null; String sort = null; - InlineResponse20035 response = api.getAudiencesAnalytics(audienceIds, sort); + InlineResponse20036 response = api.getAudiencesAnalytics(audienceIds, sort); // TODO: test validations } @@ -1820,7 +1954,7 @@ public void getCampaignsTest() throws ApiException { String sort = null; String campaignState = null; String name = null; - String tags = null; + List tags = null; OffsetDateTime createdBefore = null; OffsetDateTime createdAfter = null; OffsetDateTime startBefore = null; @@ -1856,7 +1990,7 @@ public void getChangesTest() throws ApiException { Boolean withTotalResultSize = null; Long managementKeyId = null; Boolean includeOld = null; - InlineResponse20044 response = api.getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); + InlineResponse20045 response = api.getChanges(pageSize, skip, sort, applicationId, entityPath, userId, createdBefore, createdAfter, withTotalResultSize, managementKeyId, includeOld); // TODO: test validations } @@ -2030,7 +2164,7 @@ public void getCustomerProfileAchievementProgressTest() throws ApiException { Long skip = null; Long achievementId = null; String title = null; - InlineResponse20052 response = api.getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title); + InlineResponse20054 response = api.getCustomerProfileAchievementProgress(applicationId, integrationId, pageSize, skip, achievementId, title); // TODO: test validations } @@ -2106,7 +2240,7 @@ public void getEventTypesTest() throws ApiException { Long pageSize = null; Long skip = null; String sort = null; - InlineResponse20042 response = api.getEventTypes(name, includeOldVersions, pageSize, skip, sort); + InlineResponse20043 response = api.getEventTypes(name, includeOldVersions, pageSize, skip, sort); // TODO: test validations } @@ -2143,7 +2277,7 @@ public void getExportsTest() throws ApiException { BigDecimal applicationId = null; Long campaignId = null; String entity = null; - InlineResponse20045 response = api.getExports(pageSize, skip, applicationId, campaignId, entity); + InlineResponse20046 response = api.getExports(pageSize, skip, applicationId, campaignId, entity); // TODO: test validations } @@ -2166,9 +2300,9 @@ public void getLoyaltyCardTest() throws ApiException { } /** - * List card's transactions + * List card's transactions (Management API) * - * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. + * Retrieve the transaction logs for the given [loyalty card](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview) within the specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/overview#loyalty-program-types) with filtering options applied. > [!note] For most use cases, especially real-time integrations, use the Integration API endpoint: > [List card's transactions](https://docs.talon.one/integration-api#tag/Loyalty-cards/operation/getLoyaltyCardTransactions). If no filtering options are applied, the last 50 loyalty transactions for the given loyalty card are returned. * * @throws ApiException * if the Api call fails @@ -2212,9 +2346,9 @@ public void getLoyaltyCardsTest() throws ApiException { } /** - * Get customer's loyalty balances + * Get customer's loyalty balances (Management API) * - * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] If no filtering options are applied, you retrieve all loyalty > balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) + * Retrieve loyalty ledger balances for the given Integration ID in the specified loyalty program. You can filter balances by date and subledger ID, and include tier-related information in the response. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: [Get customer's loyalty balances](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyBalances). > - If no filtering options are applied, you retrieve all loyalty balances on the current date for the given integration ID. Loyalty balances are calculated when Talon.One receives your request using the points stored in our database, so retrieving a large number of balances at once can impact performance. For more information, see: - [Managing card-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/card-based/managing-loyalty-cards) - [Managing profile-based loyalty program data](https://docs.talon.one/docs/product/loyalty-programs/profile-based/managing-pb-lp-data) * * @throws ApiException * if the Api call fails @@ -2266,9 +2400,9 @@ public void getLoyaltyProgramTest() throws ApiException { } /** - * List customer's loyalty transactions + * List customer's loyalty transactions (Management API) * - * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] To retrieve all loyalty program transaction logs in a given > loyalty program, use the [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) > endpoint. + * Retrieve paginated results of loyalty transaction logs for the given Integration ID in the specified loyalty program. You can filter transactions by date or by ledger (subledger or main ledger). If no filters are applied, the last 50 loyalty transactions for the given integration ID are returned. > [!note] **Note** > - For most use cases, especially real-time integrations, use the Integration API endpoint: > [List customer's loyalty transactions](https://docs.talon.one/integration-api#tag/Loyalty/operation/getLoyaltyProgramProfileTransactions). > - To retrieve all loyalty program transaction logs in a given loyalty program, use the > [List loyalty program transactions](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgramTransactions) endpoint. * * @throws ApiException * if the Api call fails @@ -2334,7 +2468,7 @@ public void getLoyaltyProgramsTest() throws ApiException { /** * Get loyalty program statistics * - * > [warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. + * > [!warning] This endpoint is deprecated. To retrieve statistics for a loyalty program, use the [Get statistics for loyalty dashboard](/management-api#tag/Loyalty/operation/getDashboardStatistics) endpoint. Retrieve the statistics of the specified loyalty program, such as the total active points, pending points, spent points, and expired points. * * @throws ApiException * if the Api call fails @@ -2364,6 +2498,7 @@ public void getMessageLogsTest() throws ApiException { OffsetDateTime createdBefore = null; OffsetDateTime createdAfter = null; byte[] cursor = null; + Long pageSize = null; String period = null; Boolean isSuccessful = null; BigDecimal applicationId = null; @@ -2371,7 +2506,7 @@ public void getMessageLogsTest() throws ApiException { Long loyaltyProgramId = null; Long responseCode = null; String webhookIDs = null; - MessageLogEntries response = api.getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); + MessageLogEntries response = api.getMessageLogs(entityType, messageID, changeType, notificationIDs, createdBefore, createdAfter, cursor, pageSize, period, isSuccessful, applicationId, campaignId, loyaltyProgramId, responseCode, webhookIDs); // TODO: test validations } @@ -2436,6 +2571,24 @@ public void getRulesetTest() throws ApiException { // TODO: test validations } + /** + * Get ruleset (V2) + * + * Retrieve the specified ruleset as a JSON object. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getRulesetV2Test() throws ApiException { + Long applicationId = null; + Long campaignId = null; + Long rulesetId = null; + RulesetV2 response = api.getRulesetV2(applicationId, campaignId, rulesetId); + + // TODO: test validations + } + /** * List campaign rulesets * @@ -2502,7 +2655,7 @@ public void getUsersTest() throws ApiException { Long pageSize = null; Long skip = null; String sort = null; - InlineResponse20043 response = api.getUsers(pageSize, skip, sort); + InlineResponse20044 response = api.getUsers(pageSize, skip, sort); // TODO: test validations } @@ -2541,7 +2694,7 @@ public void getWebhooksTest() throws ApiException { String visibility = null; Long outgoingIntegrationsTypeId = null; String title = null; - InlineResponse20041 response = api.getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); + InlineResponse20042 response = api.getWebhooks(applicationIds, sort, pageSize, skip, creationType, visibility, outgoingIntegrationsTypeId, title); // TODO: test validations } @@ -2676,7 +2829,7 @@ public void importCouponsTest() throws ApiException { /** * Import loyalty cards * - * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). > [!note] We recommend limiting your file size to 500MB. ## Example ```csv identifier,state,customerprofileids 123-456-789AT,active,Alexa001;UserA ``` + * Upload a CSV file containing the loyalty cards that you want to use in your card-based loyalty program. Send the file as multipart data. It contains the following columns for each card: - `identifier` (required): The identifier of the loyalty card, which must match the regular expression `^[A-Za-z0-9._%+@-]+$`. - `state` (required): The state of the loyalty card. It can be `active` or `inactive`. - `customerprofileids` (optional): An array of strings representing the identifiers of the customer profiles linked to the loyalty card. The identifiers should be separated with a semicolon (;). - `attributes` (optional): A JSON object that contains the loyalty card's custom attributes and their values. These attributes must be created and connected to this loyalty program before they can be assigned to the cards through this endpoint. > [!note] Your CSV file must contain less than 500,000 rows. Requests time out after 30 seconds. ## Example ```csv identifier,state,customerprofileids,attributes 123-456-789AT,active,Alexa001;UserA,'{\"\"my_attributes\"\": \"\"10_off\"\"}\" ``` * * @throws ApiException * if the Api call fails @@ -2693,7 +2846,7 @@ public void importLoyaltyCardsTest() throws ApiException { /** * Import customers into loyalty tiers * - * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiration date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiration date is updated. > [!note] We recommend not using this endpoint to update the tier of a customer. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` + * Upload a CSV file containing existing customers to be assigned to existing tiers. Send the file as multipart data. > [!important] This endpoint only works with loyalty programs with advanced > tiers (with expiration and downgrade policy) feature enabled. The CSV file should contain the following columns: - `subledgerid` (optional): The ID of the subledger. If this field is empty, the main ledger will be used. - `customerprofileid`: The integration ID of the customer profile to whom the tier should be assigned. - `tiername`: The name of an existing tier to assign to the customer. - `expirydate`: The expiry date of the tier when the tier is reevaluated. It should be a future date. About customer assignment to a tier: - If the customer isn't already in a tier, the customer is assigned to the specified tier during the tier import. - If the customer is already in the tier that's specified in the CSV file, only the expiry date is updated. > [!note] We recommend importing customers into the tier that matches their > current balance. If a customer is imported into a lower tier, any session > or points update automatically upgrades them to the tier they qualify for. To update a customer's tier, you can [add](/management-api#tag/Loyalty/operation/addLoyaltyPoints) or [deduct](/management-api#tag/Loyalty/operation/removeLoyaltyPoints) their loyalty points. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv subledgerid,customerprofileid,tiername,expirydate SUB1,alexa,Gold,2024-03-21T07:32:14Z ,george,Silver,2025-04-16T21:12:37Z SUB2,avocado,Bronze,2026-05-03T11:47:01Z ``` * * @throws ApiException * if the Api call fails @@ -2707,6 +2860,23 @@ public void importLoyaltyCustomersTiersTest() throws ApiException { // TODO: test validations } + /** + * Import join dates for a loyalty program + * + * Upload a CSV file containing customer profile IDs and their join dates for the specified loyalty program. Send the file as multipart data. > [!important] This endpoint only works with profile-based loyalty programs. The CSV file **must** contain the following columns: - `customerprofileid`: The integration ID of the customer profile whose join date you want to update. - `newjoindate`: The new join date for the customer in RFC3339 format. You can use the time zone of your choice. It is converted to UTC internally by Talon.One. **Note**: - Customer profiles must already exist. If a referenced profile does not exist, the import fails with a `400` error. - If a join date already exists for a profile, the uploaded date replaces it. > [!note] We recommend limiting your file size to 500 MB. ## Example ```csv customerprofileid,newjoindate customer1,2024-03-21T07:32:14Z customer2,2025-04-16T21:12:37Z customer3,2026-05-03T11:47:01Z ``` + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void importLoyaltyJoinDatesTest() throws ApiException { + Long loyaltyProgramId = null; + String upFile = null; + ModelImport response = api.importLoyaltyJoinDates(loyaltyProgramId, upFile); + + // TODO: test validations + } + /** * Import loyalty points * @@ -2811,7 +2981,27 @@ public void listAchievementsTest() throws ApiException { Long pageSize = null; Long skip = null; String title = null; - InlineResponse20051 response = api.listAchievements(applicationId, campaignId, pageSize, skip, title); + InlineResponse20052 response = api.listAchievements(applicationId, campaignId, pageSize, skip, title); + + // TODO: test validations + } + + /** + * List achievements + * + * List all achievements. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void listAchievementsV2Test() throws ApiException { + Long pageSize = null; + Long skip = null; + String sort = null; + String title = null; + Long applicationId = null; + InlineResponse20053 response = api.listAchievementsV2(pageSize, skip, sort, title, applicationId); // TODO: test validations } @@ -2826,7 +3016,7 @@ public void listAchievementsTest() throws ApiException { */ @Test public void listAllRolesV2Test() throws ApiException { - InlineResponse20046 response = api.listAllRolesV2(); + InlineResponse20047 response = api.listAllRolesV2(); // TODO: test validations } @@ -2844,8 +3034,8 @@ public void listApplicationCartItemFiltersTest() throws ApiException { Long applicationId = null; Long pageSize = null; Long skip = null; - String title = null; - InlineResponse20048 response = api.listApplicationCartItemFilters(applicationId, pageSize, skip, title); + String name = null; + InlineResponse20049 response = api.listApplicationCartItemFilters(applicationId, pageSize, skip, name); // TODO: test validations } @@ -2864,7 +3054,7 @@ public void listCampaignStoreBudgetLimitsTest() throws ApiException { Long campaignId = null; String action = null; String period = null; - InlineResponse20049 response = api.listCampaignStoreBudgetLimits(applicationId, campaignId, action, period); + InlineResponse20050 response = api.listCampaignStoreBudgetLimits(applicationId, campaignId, action, period); // TODO: test validations } @@ -2885,7 +3075,7 @@ public void listCatalogItemsTest() throws ApiException { Boolean withTotalResultSize = null; List sku = null; List productNames = null; - InlineResponse20039 response = api.listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); + InlineResponse20040 response = api.listCatalogItems(catalogId, pageSize, skip, withTotalResultSize, sku, productNames); // TODO: test validations } @@ -2971,7 +3161,7 @@ public void listStoresTest() throws ApiException { String name = null; String integrationId = null; String query = null; - InlineResponse20047 response = api.listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); + InlineResponse20048 response = api.listStores(applicationId, pageSize, skip, sort, withTotalResultSize, campaignId, name, integrationId, query); // TODO: test validations } @@ -3353,7 +3543,7 @@ public void searchCouponsAdvancedWithoutTotalCountTest() throws ApiException { public void summarizeCampaignStoreBudgetTest() throws ApiException { Long applicationId = null; Long campaignId = null; - InlineResponse20050 response = api.summarizeCampaignStoreBudget(applicationId, campaignId); + InlineResponse20051 response = api.summarizeCampaignStoreBudget(applicationId, campaignId); // TODO: test validations } @@ -3412,6 +3602,23 @@ public void updateAchievementTest() throws ApiException { // TODO: test validations } + /** + * Update achievement + * + * Update the details of a specific achievement. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void updateAchievementV2Test() throws ApiException { + Long achievementId = null; + UpdateAchievementV2 body = null; + AchievementV2 response = api.updateAchievementV2(achievementId, body); + + // TODO: test validations + } + /** * Update additional cost * diff --git a/src/test/java/one/talon/model/AchievementAdditionalPropertiesV2Test.java b/src/test/java/one/talon/model/AchievementAdditionalPropertiesV2Test.java index 8c217e32..2b75ffd3 100644 --- a/src/test/java/one/talon/model/AchievementAdditionalPropertiesV2Test.java +++ b/src/test/java/one/talon/model/AchievementAdditionalPropertiesV2Test.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.TimePoint; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -56,6 +57,14 @@ public void createdByTest() { // TODO: test createdBy } + /** + * Test the property 'periodEndOverride' + */ + @Test + public void periodEndOverrideTest() { + // TODO: test periodEndOverride + } + /** * Test the property 'hasProgress' */ diff --git a/src/test/java/one/talon/model/AchievementBaseV2Test.java b/src/test/java/one/talon/model/AchievementBaseV2Test.java index ec160965..6975c00b 100644 --- a/src/test/java/one/talon/model/AchievementBaseV2Test.java +++ b/src/test/java/one/talon/model/AchievementBaseV2Test.java @@ -124,14 +124,6 @@ public void allowRollbackAfterCompletionTest() { // TODO: test allowRollbackAfterCompletion } - /** - * Test the property 'sandbox' - */ - @Test - public void sandboxTest() { - // TODO: test sandbox - } - /** * Test the property 'subscribedApplications' */ @@ -140,12 +132,4 @@ public void subscribedApplicationsTest() { // TODO: test subscribedApplications } - /** - * Test the property 'timezone' - */ - @Test - public void timezoneTest() { - // TODO: test timezone - } - } diff --git a/src/test/java/one/talon/model/AchievementProgressWithDefinitionTest.java b/src/test/java/one/talon/model/AchievementProgressWithDefinitionTest.java index 9ac12c57..f796f723 100644 --- a/src/test/java/one/talon/model/AchievementProgressWithDefinitionTest.java +++ b/src/test/java/one/talon/model/AchievementProgressWithDefinitionTest.java @@ -22,6 +22,9 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CampaignReference; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -122,6 +125,22 @@ public void campaignIdTest() { // TODO: test campaignId } + /** + * Test the property 'campaignIds' + */ + @Test + public void campaignIdsTest() { + // TODO: test campaignIds + } + + /** + * Test the property 'referencedByCampaigns' + */ + @Test + public void referencedByCampaignsTest() { + // TODO: test referencedByCampaigns + } + /** * Test the property 'target' */ diff --git a/src/test/java/one/talon/model/AchievementReferenceTest.java b/src/test/java/one/talon/model/AchievementReferenceTest.java index 52c1b494..b16fd96a 100644 --- a/src/test/java/one/talon/model/AchievementReferenceTest.java +++ b/src/test/java/one/talon/model/AchievementReferenceTest.java @@ -72,4 +72,20 @@ public void campaignIdTest() { // TODO: test campaignId } + /** + * Test the property 'campaignName' + */ + @Test + public void campaignNameTest() { + // TODO: test campaignName + } + + /** + * Test the property 'campaignState' + */ + @Test + public void campaignStateTest() { + // TODO: test campaignState + } + } diff --git a/src/test/java/one/talon/model/AchievementStatusEntryTest.java b/src/test/java/one/talon/model/AchievementStatusEntryTest.java index a8a79b6f..68049f3e 100644 --- a/src/test/java/one/talon/model/AchievementStatusEntryTest.java +++ b/src/test/java/one/talon/model/AchievementStatusEntryTest.java @@ -22,6 +22,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.AchievementProgress; import one.talon.model.TimePoint; import org.threeten.bp.OffsetDateTime; @@ -156,6 +158,14 @@ public void campaignIdTest() { // TODO: test campaignId } + /** + * Test the property 'campaignIds' + */ + @Test + public void campaignIdsTest() { + // TODO: test campaignIds + } + /** * Test the property 'status' */ diff --git a/src/test/java/one/talon/model/AchievementV2Test.java b/src/test/java/one/talon/model/AchievementV2Test.java index 36111c8f..664a6a75 100644 --- a/src/test/java/one/talon/model/AchievementV2Test.java +++ b/src/test/java/one/talon/model/AchievementV2Test.java @@ -24,6 +24,8 @@ import java.math.BigDecimal; import java.util.ArrayList; import java.util.List; +import one.talon.model.CampaignReference; +import one.talon.model.TimePoint; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -140,14 +142,6 @@ public void allowRollbackAfterCompletionTest() { // TODO: test allowRollbackAfterCompletion } - /** - * Test the property 'sandbox' - */ - @Test - public void sandboxTest() { - // TODO: test sandbox - } - /** * Test the property 'subscribedApplications' */ @@ -156,14 +150,6 @@ public void subscribedApplicationsTest() { // TODO: test subscribedApplications } - /** - * Test the property 'timezone' - */ - @Test - public void timezoneTest() { - // TODO: test timezone - } - /** * Test the property 'userId' */ @@ -180,6 +166,14 @@ public void createdByTest() { // TODO: test createdBy } + /** + * Test the property 'periodEndOverride' + */ + @Test + public void periodEndOverrideTest() { + // TODO: test periodEndOverride + } + /** * Test the property 'hasProgress' */ @@ -196,4 +190,36 @@ public void statusTest() { // TODO: test status } + /** + * Test the property 'sandbox' + */ + @Test + public void sandboxTest() { + // TODO: test sandbox + } + + /** + * Test the property 'timezone' + */ + @Test + public void timezoneTest() { + // TODO: test timezone + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'referencedByCampaigns' + */ + @Test + public void referencedByCampaignsTest() { + // TODO: test referencedByCampaigns + } + } diff --git a/src/test/java/one/talon/model/AddLoyaltyPointsSupportTest.java b/src/test/java/one/talon/model/AddLoyaltyPointsSupportTest.java new file mode 100644 index 00000000..3200a71e --- /dev/null +++ b/src/test/java/one/talon/model/AddLoyaltyPointsSupportTest.java @@ -0,0 +1,125 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AddLoyaltyPointsSupport + */ +public class AddLoyaltyPointsSupportTest { + private final AddLoyaltyPointsSupport model = new AddLoyaltyPointsSupport(); + + /** + * Model tests for AddLoyaltyPointsSupport + */ + @Test + public void testAddLoyaltyPointsSupport() { + // TODO: test AddLoyaltyPointsSupport + } + + /** + * Test the property 'points' + */ + @Test + public void pointsTest() { + // TODO: test points + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'validityDuration' + */ + @Test + public void validityDurationTest() { + // TODO: test validityDuration + } + + /** + * Test the property 'validUntil' + */ + @Test + public void validUntilTest() { + // TODO: test validUntil + } + + /** + * Test the property 'pendingDuration' + */ + @Test + public void pendingDurationTest() { + // TODO: test pendingDuration + } + + /** + * Test the property 'pendingUntil' + */ + @Test + public void pendingUntilTest() { + // TODO: test pendingUntil + } + + /** + * Test the property 'subledgerId' + */ + @Test + public void subledgerIdTest() { + // TODO: test subledgerId + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'supportRequestId' + */ + @Test + public void supportRequestIdTest() { + // TODO: test supportRequestId + } + + /** + * Test the property 'processingNote' + */ + @Test + public void processingNoteTest() { + // TODO: test processingNote + } + +} diff --git a/src/test/java/one/talon/model/AdditionalCostReferenceTest.java b/src/test/java/one/talon/model/AdditionalCostReferenceTest.java new file mode 100644 index 00000000..d1659d90 --- /dev/null +++ b/src/test/java/one/talon/model/AdditionalCostReferenceTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AdditionalCostReference + */ +public class AdditionalCostReferenceTest { + private final AdditionalCostReference model = new AdditionalCostReference(); + + /** + * Model tests for AdditionalCostReference + */ + @Test + public void testAdditionalCostReference() { + // TODO: test AdditionalCostReference + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + +} diff --git a/src/test/java/one/talon/model/ApplicationEventTest.java b/src/test/java/one/talon/model/ApplicationEventTest.java index 7298887c..d974518f 100644 --- a/src/test/java/one/talon/model/ApplicationEventTest.java +++ b/src/test/java/one/talon/model/ApplicationEventTest.java @@ -93,6 +93,14 @@ public void storeIntegrationIdTest() { // TODO: test storeIntegrationId } + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + /** * Test the property 'sessionId' */ diff --git a/src/test/java/one/talon/model/ApplicationMembershipTest.java b/src/test/java/one/talon/model/ApplicationMembershipTest.java new file mode 100644 index 00000000..f8d7043c --- /dev/null +++ b/src/test/java/one/talon/model/ApplicationMembershipTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ApplicationMembership + */ +public class ApplicationMembershipTest { + private final ApplicationMembership model = new ApplicationMembership(); + + /** + * Model tests for ApplicationMembership + */ + @Test + public void testApplicationMembership() { + // TODO: test ApplicationMembership + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'applicationName' + */ + @Test + public void applicationNameTest() { + // TODO: test applicationName + } + +} diff --git a/src/test/java/one/talon/model/ApplicationRefereeTest.java b/src/test/java/one/talon/model/ApplicationRefereeTest.java index ad9731a7..91712112 100644 --- a/src/test/java/one/talon/model/ApplicationRefereeTest.java +++ b/src/test/java/one/talon/model/ApplicationRefereeTest.java @@ -57,6 +57,14 @@ public void sessionIdTest() { // TODO: test sessionId } + /** + * Test the property 'advancedEventIntegrationId' + */ + @Test + public void advancedEventIntegrationIdTest() { + // TODO: test advancedEventIntegrationId + } + /** * Test the property 'advocateIntegrationId' */ diff --git a/src/test/java/one/talon/model/ApplicationTest.java b/src/test/java/one/talon/model/ApplicationTest.java index dc9a5b6f..8d2eda8e 100644 --- a/src/test/java/one/talon/model/ApplicationTest.java +++ b/src/test/java/one/talon/model/ApplicationTest.java @@ -24,6 +24,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; import one.talon.model.LoyaltyProgram; import org.threeten.bp.OffsetDateTime; @@ -214,6 +215,14 @@ public void enableCampaignStateManagementTest() { // TODO: test enableCampaignStateManagement } + /** + * Test the property 'bestPriorPriceSettings' + */ + @Test + public void bestPriorPriceSettingsTest() { + // TODO: test bestPriorPriceSettings + } + /** * Test the property 'loyaltyPrograms' */ diff --git a/src/test/java/one/talon/model/AudienceTest.java b/src/test/java/one/talon/model/AudienceTest.java index 70a5224e..1e89201f 100644 --- a/src/test/java/one/talon/model/AudienceTest.java +++ b/src/test/java/one/talon/model/AudienceTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -89,6 +91,14 @@ public void descriptionTest() { // TODO: test description } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + /** * Test the property 'integration' */ diff --git a/src/test/java/one/talon/model/AwardDiscountAdditionalCostTargetTest.java b/src/test/java/one/talon/model/AwardDiscountAdditionalCostTargetTest.java new file mode 100644 index 00000000..ef36439a --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountAdditionalCostTargetTest.java @@ -0,0 +1,68 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AdditionalCostReference; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountAdditionalCostTarget + */ +public class AwardDiscountAdditionalCostTargetTest { + private final AwardDiscountAdditionalCostTarget model = new AwardDiscountAdditionalCostTarget(); + + /** + * Model tests for AwardDiscountAdditionalCostTarget + */ + @Test + public void testAwardDiscountAdditionalCostTarget() { + // TODO: test AwardDiscountAdditionalCostTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'additionalCost' + */ + @Test + public void additionalCostTest() { + // TODO: test additionalCost + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountAllItemsTargetTest.java b/src/test/java/one/talon/model/AwardDiscountAllItemsTargetTest.java new file mode 100644 index 00000000..38685f8c --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountAllItemsTargetTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountAllItemsTarget + */ +public class AwardDiscountAllItemsTargetTest { + private final AwardDiscountAllItemsTarget model = new AwardDiscountAllItemsTarget(); + + /** + * Model tests for AwardDiscountAllItemsTarget + */ + @Test + public void testAwardDiscountAllItemsTarget() { + // TODO: test AwardDiscountAllItemsTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'prorated' + */ + @Test + public void proratedTest() { + // TODO: test prorated + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountBlockTest.java b/src/test/java/one/talon/model/AwardDiscountBlockTest.java new file mode 100644 index 00000000..1f0d31c0 --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountBlockTest.java @@ -0,0 +1,101 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountBlock + */ +public class AwardDiscountBlockTest { + private final AwardDiscountBlock model = new AwardDiscountBlock(); + + /** + * Model tests for AwardDiscountBlock + */ + @Test + public void testAwardDiscountBlock() { + // TODO: test AwardDiscountBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'partial' + */ + @Test + public void partialTest() { + // TODO: test partial + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountBundleItemByAttributeTest.java b/src/test/java/one/talon/model/AwardDiscountBundleItemByAttributeTest.java new file mode 100644 index 00000000..d2752b0b --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountBundleItemByAttributeTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountBundleItemByAttribute + */ +public class AwardDiscountBundleItemByAttributeTest { + private final AwardDiscountBundleItemByAttribute model = new AwardDiscountBundleItemByAttribute(); + + /** + * Model tests for AwardDiscountBundleItemByAttribute + */ + @Test + public void testAwardDiscountBundleItemByAttribute() { + // TODO: test AwardDiscountBundleItemByAttribute + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'attribute' + */ + @Test + public void attributeTest() { + // TODO: test attribute + } + + /** + * Test the property 'direction' + */ + @Test + public void directionTest() { + // TODO: test direction + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountBundleItemByIndexTest.java b/src/test/java/one/talon/model/AwardDiscountBundleItemByIndexTest.java new file mode 100644 index 00000000..06d4ec02 --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountBundleItemByIndexTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountBundleItemByIndex + */ +public class AwardDiscountBundleItemByIndexTest { + private final AwardDiscountBundleItemByIndex model = new AwardDiscountBundleItemByIndex(); + + /** + * Model tests for AwardDiscountBundleItemByIndex + */ + @Test + public void testAwardDiscountBundleItemByIndex() { + // TODO: test AwardDiscountBundleItemByIndex + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountBundleTargetTest.java b/src/test/java/one/talon/model/AwardDiscountBundleTargetTest.java new file mode 100644 index 00000000..55e7df1b --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountBundleTargetTest.java @@ -0,0 +1,75 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountBundleTarget + */ +public class AwardDiscountBundleTargetTest { + private final AwardDiscountBundleTarget model = new AwardDiscountBundleTarget(); + + /** + * Model tests for AwardDiscountBundleTarget + */ + @Test + public void testAwardDiscountBundleTarget() { + // TODO: test AwardDiscountBundleTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'item' + */ + @Test + public void itemTest() { + // TODO: test item + } + + /** + * Test the property 'prorated' + */ + @Test + public void proratedTest() { + // TODO: test prorated + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountCartTargetTest.java b/src/test/java/one/talon/model/AwardDiscountCartTargetTest.java new file mode 100644 index 00000000..ca37f473 --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountCartTargetTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountCartTarget + */ +public class AwardDiscountCartTargetTest { + private final AwardDiscountCartTarget model = new AwardDiscountCartTarget(); + + /** + * Model tests for AwardDiscountCartTarget + */ + @Test + public void testAwardDiscountCartTarget() { + // TODO: test AwardDiscountCartTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountGlobalFilterTargetTest.java b/src/test/java/one/talon/model/AwardDiscountGlobalFilterTargetTest.java new file mode 100644 index 00000000..7e0a4642 --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountGlobalFilterTargetTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountGlobalFilterTarget + */ +public class AwardDiscountGlobalFilterTargetTest { + private final AwardDiscountGlobalFilterTarget model = new AwardDiscountGlobalFilterTarget(); + + /** + * Model tests for AwardDiscountGlobalFilterTarget + */ + @Test + public void testAwardDiscountGlobalFilterTarget() { + // TODO: test AwardDiscountGlobalFilterTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'prorated' + */ + @Test + public void proratedTest() { + // TODO: test prorated + } + +} diff --git a/src/test/java/one/talon/model/AwardDiscountSelectorTargetTest.java b/src/test/java/one/talon/model/AwardDiscountSelectorTargetTest.java new file mode 100644 index 00000000..d99c4fd1 --- /dev/null +++ b/src/test/java/one/talon/model/AwardDiscountSelectorTargetTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardDiscountSelectorTarget + */ +public class AwardDiscountSelectorTargetTest { + private final AwardDiscountSelectorTarget model = new AwardDiscountSelectorTarget(); + + /** + * Model tests for AwardDiscountSelectorTarget + */ + @Test + public void testAwardDiscountSelectorTarget() { + // TODO: test AwardDiscountSelectorTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'prorated' + */ + @Test + public void proratedTest() { + // TODO: test prorated + } + +} diff --git a/src/test/java/one/talon/model/AwardGiveawayBlockTest.java b/src/test/java/one/talon/model/AwardGiveawayBlockTest.java new file mode 100644 index 00000000..9d28d238 --- /dev/null +++ b/src/test/java/one/talon/model/AwardGiveawayBlockTest.java @@ -0,0 +1,104 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.GiveawayPoolReference; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardGiveawayBlock + */ +public class AwardGiveawayBlockTest { + private final AwardGiveawayBlock model = new AwardGiveawayBlock(); + + /** + * Model tests for AwardGiveawayBlock + */ + @Test + public void testAwardGiveawayBlock() { + // TODO: test AwardGiveawayBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'giveawayPool' + */ + @Test + public void giveawayPoolTest() { + // TODO: test giveawayPool + } + + /** + * Test the property 'profile' + */ + @Test + public void profileTest() { + // TODO: test profile + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/AwardItemBlockTest.java b/src/test/java/one/talon/model/AwardItemBlockTest.java new file mode 100644 index 00000000..599afadb --- /dev/null +++ b/src/test/java/one/talon/model/AwardItemBlockTest.java @@ -0,0 +1,119 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for AwardItemBlock + */ +public class AwardItemBlockTest { + private final AwardItemBlock model = new AwardItemBlock(); + + /** + * Model tests for AwardItemBlock + */ + @Test + public void testAwardItemBlock() { + // TODO: test AwardItemBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'sku' + */ + @Test + public void skuTest() { + // TODO: test sku + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'quantity' + */ + @Test + public void quantityTest() { + // TODO: test quantity + } + + /** + * Test the property 'partial' + */ + @Test + public void partialTest() { + // TODO: test partial + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/BaseBlockTest.java b/src/test/java/one/talon/model/BaseBlockTest.java new file mode 100644 index 00000000..8fed0034 --- /dev/null +++ b/src/test/java/one/talon/model/BaseBlockTest.java @@ -0,0 +1,69 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for BaseBlock + */ +public class BaseBlockTest { + private final BaseBlock model = new BaseBlock(); + + /** + * Model tests for BaseBlock + */ + @Test + public void testBaseBlock() { + // TODO: test BaseBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + +} diff --git a/src/test/java/one/talon/model/BestPriorPriceSettingsTest.java b/src/test/java/one/talon/model/BestPriorPriceSettingsTest.java new file mode 100644 index 00000000..8dfa4144 --- /dev/null +++ b/src/test/java/one/talon/model/BestPriorPriceSettingsTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for BestPriorPriceSettings + */ +public class BestPriorPriceSettingsTest { + private final BestPriorPriceSettings model = new BestPriorPriceSettings(); + + /** + * Model tests for BestPriorPriceSettings + */ + @Test + public void testBestPriorPriceSettings() { + // TODO: test BestPriorPriceSettings + } + + /** + * Test the property 'enableBestPriorPrice' + */ + @Test + public void enableBestPriorPriceTest() { + // TODO: test enableBestPriorPrice + } + +} diff --git a/src/test/java/one/talon/model/BestPriorPriceTest.java b/src/test/java/one/talon/model/BestPriorPriceTest.java index fef980e5..6920f5b1 100644 --- a/src/test/java/one/talon/model/BestPriorPriceTest.java +++ b/src/test/java/one/talon/model/BestPriorPriceTest.java @@ -22,6 +22,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.BestPriorPriceMetadata; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; @@ -68,11 +70,11 @@ public void observedAtTest() { } /** - * Test the property 'contextId' + * Test the property 'contextIds' */ @Test - public void contextIdTest() { - // TODO: test contextId + public void contextIdsTest() { + // TODO: test contextIds } /** diff --git a/src/test/java/one/talon/model/BetweenCheckAttributeBlockTest.java b/src/test/java/one/talon/model/BetweenCheckAttributeBlockTest.java new file mode 100644 index 00000000..e005b932 --- /dev/null +++ b/src/test/java/one/talon/model/BetweenCheckAttributeBlockTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for BetweenCheckAttributeBlock + */ +public class BetweenCheckAttributeBlockTest { + private final BetweenCheckAttributeBlock model = new BetweenCheckAttributeBlock(); + + /** + * Model tests for BetweenCheckAttributeBlock + */ + @Test + public void testBetweenCheckAttributeBlock() { + // TODO: test BetweenCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'min' + */ + @Test + public void minTest() { + // TODO: test min + } + + /** + * Test the property 'max' + */ + @Test + public void maxTest() { + // TODO: test max + } + +} diff --git a/src/test/java/one/talon/model/BundleTest.java b/src/test/java/one/talon/model/BundleTest.java new file mode 100644 index 00000000..b2a793e7 --- /dev/null +++ b/src/test/java/one/talon/model/BundleTest.java @@ -0,0 +1,93 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for Bundle + */ +public class BundleTest { + private final Bundle model = new Bundle(); + + /** + * Model tests for Bundle + */ + @Test + public void testBundle() { + // TODO: test Bundle + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'sources' + */ + @Test + public void sourcesTest() { + // TODO: test sources + } + + /** + * Test the property 'counts' + */ + @Test + public void countsTest() { + // TODO: test counts + } + + /** + * Test the property 'matchers' + */ + @Test + public void matchersTest() { + // TODO: test matchers + } + +} diff --git a/src/test/java/one/talon/model/CampaignEligibilityDetailsTest.java b/src/test/java/one/talon/model/CampaignEligibilityDetailsTest.java new file mode 100644 index 00000000..e93649b9 --- /dev/null +++ b/src/test/java/one/talon/model/CampaignEligibilityDetailsTest.java @@ -0,0 +1,68 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.CampaignEligibilityFailureDetails; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignEligibilityDetails + */ +public class CampaignEligibilityDetailsTest { + private final CampaignEligibilityDetails model = new CampaignEligibilityDetails(); + + /** + * Model tests for CampaignEligibilityDetails + */ + @Test + public void testCampaignEligibilityDetails() { + // TODO: test CampaignEligibilityDetails + } + + /** + * Test the property 'passed' + */ + @Test + public void passedTest() { + // TODO: test passed + } + + /** + * Test the property 'couponCode' + */ + @Test + public void couponCodeTest() { + // TODO: test couponCode + } + + /** + * Test the property 'details' + */ + @Test + public void detailsTest() { + // TODO: test details + } + +} diff --git a/src/test/java/one/talon/model/CampaignEligibilityExperimentTest.java b/src/test/java/one/talon/model/CampaignEligibilityExperimentTest.java new file mode 100644 index 00000000..933bb8c5 --- /dev/null +++ b/src/test/java/one/talon/model/CampaignEligibilityExperimentTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignEligibilityExperiment + */ +public class CampaignEligibilityExperimentTest { + private final CampaignEligibilityExperiment model = new CampaignEligibilityExperiment(); + + /** + * Model tests for CampaignEligibilityExperiment + */ + @Test + public void testCampaignEligibilityExperiment() { + // TODO: test CampaignEligibilityExperiment + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'variantId' + */ + @Test + public void variantIdTest() { + // TODO: test variantId + } + +} diff --git a/src/test/java/one/talon/model/CampaignEligibilityFailureDetailsTest.java b/src/test/java/one/talon/model/CampaignEligibilityFailureDetailsTest.java new file mode 100644 index 00000000..f8c314ea --- /dev/null +++ b/src/test/java/one/talon/model/CampaignEligibilityFailureDetailsTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignEligibilityFailureDetails + */ +public class CampaignEligibilityFailureDetailsTest { + private final CampaignEligibilityFailureDetails model = new CampaignEligibilityFailureDetails(); + + /** + * Model tests for CampaignEligibilityFailureDetails + */ + @Test + public void testCampaignEligibilityFailureDetails() { + // TODO: test CampaignEligibilityFailureDetails + } + + /** + * Test the property 'failureCode' + */ + @Test + public void failureCodeTest() { + // TODO: test failureCode + } + +} diff --git a/src/test/java/one/talon/model/CampaignEligibilityTest.java b/src/test/java/one/talon/model/CampaignEligibilityTest.java new file mode 100644 index 00000000..398e882b --- /dev/null +++ b/src/test/java/one/talon/model/CampaignEligibilityTest.java @@ -0,0 +1,153 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CampaignEligibilityDetails; +import one.talon.model.CampaignEligibilityExperiment; +import one.talon.model.RuleMetadataEligibility; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignEligibility + */ +public class CampaignEligibilityTest { + private final CampaignEligibility model = new CampaignEligibility(); + + /** + * Model tests for CampaignEligibility + */ + @Test + public void testCampaignEligibility() { + // TODO: test CampaignEligibility + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'startTime' + */ + @Test + public void startTimeTest() { + // TODO: test startTime + } + + /** + * Test the property 'endTime' + */ + @Test + public void endTimeTest() { + // TODO: test endTime + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'state' + */ + @Test + public void stateTest() { + // TODO: test state + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'features' + */ + @Test + public void featuresTest() { + // TODO: test features + } + + /** + * Test the property 'eligibility' + */ + @Test + public void eligibilityTest() { + // TODO: test eligibility + } + + /** + * Test the property 'rules' + */ + @Test + public void rulesTest() { + // TODO: test rules + } + + /** + * Test the property 'experiment' + */ + @Test + public void experimentTest() { + // TODO: test experiment + } + +} diff --git a/src/test/java/one/talon/model/CampaignLoyaltyProgramTest.java b/src/test/java/one/talon/model/CampaignLoyaltyProgramTest.java new file mode 100644 index 00000000..d30f3153 --- /dev/null +++ b/src/test/java/one/talon/model/CampaignLoyaltyProgramTest.java @@ -0,0 +1,77 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignLoyaltyProgram + */ +public class CampaignLoyaltyProgramTest { + private final CampaignLoyaltyProgram model = new CampaignLoyaltyProgram(); + + /** + * Model tests for CampaignLoyaltyProgram + */ + @Test + public void testCampaignLoyaltyProgram() { + // TODO: test CampaignLoyaltyProgram + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'tiers' + */ + @Test + public void tiersTest() { + // TODO: test tiers + } + + /** + * Test the property 'cardBased' + */ + @Test + public void cardBasedTest() { + // TODO: test cardBased + } + +} diff --git a/src/test/java/one/talon/model/CampaignReferenceTest.java b/src/test/java/one/talon/model/CampaignReferenceTest.java new file mode 100644 index 00000000..2779aeca --- /dev/null +++ b/src/test/java/one/talon/model/CampaignReferenceTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CampaignReference + */ +public class CampaignReferenceTest { + private final CampaignReference model = new CampaignReference(); + + /** + * Model tests for CampaignReference + */ + @Test + public void testCampaignReference() { + // TODO: test CampaignReference + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionAddPriceAdjustmentTest.java b/src/test/java/one/talon/model/CatalogActionAddPriceAdjustmentTest.java new file mode 100644 index 00000000..a4915a95 --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionAddPriceAdjustmentTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AddPriceAdjustmentCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionAddPriceAdjustment + */ +public class CatalogActionAddPriceAdjustmentTest { + private final CatalogActionAddPriceAdjustment model = new CatalogActionAddPriceAdjustment(); + + /** + * Model tests for CatalogActionAddPriceAdjustment + */ + @Test + public void testCatalogActionAddPriceAdjustment() { + // TODO: test CatalogActionAddPriceAdjustment + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionAddTest.java b/src/test/java/one/talon/model/CatalogActionAddTest.java new file mode 100644 index 00000000..a0a3173f --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionAddTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AddItemCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionAdd + */ +public class CatalogActionAddTest { + private final CatalogActionAdd model = new CatalogActionAdd(); + + /** + * Model tests for CatalogActionAdd + */ + @Test + public void testCatalogActionAdd() { + // TODO: test CatalogActionAdd + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionPatchManyTest.java b/src/test/java/one/talon/model/CatalogActionPatchManyTest.java new file mode 100644 index 00000000..de11ce7c --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionPatchManyTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.PatchManyItemsCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionPatchMany + */ +public class CatalogActionPatchManyTest { + private final CatalogActionPatchMany model = new CatalogActionPatchMany(); + + /** + * Model tests for CatalogActionPatchMany + */ + @Test + public void testCatalogActionPatchMany() { + // TODO: test CatalogActionPatchMany + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionPatchTest.java b/src/test/java/one/talon/model/CatalogActionPatchTest.java new file mode 100644 index 00000000..e2a90ca8 --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionPatchTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.PatchItemCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionPatch + */ +public class CatalogActionPatchTest { + private final CatalogActionPatch model = new CatalogActionPatch(); + + /** + * Model tests for CatalogActionPatch + */ + @Test + public void testCatalogActionPatch() { + // TODO: test CatalogActionPatch + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionRemoveManyTest.java b/src/test/java/one/talon/model/CatalogActionRemoveManyTest.java new file mode 100644 index 00000000..eeba1aed --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionRemoveManyTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RemoveManyItemsCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionRemoveMany + */ +public class CatalogActionRemoveManyTest { + private final CatalogActionRemoveMany model = new CatalogActionRemoveMany(); + + /** + * Model tests for CatalogActionRemoveMany + */ + @Test + public void testCatalogActionRemoveMany() { + // TODO: test CatalogActionRemoveMany + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CatalogActionRemoveTest.java b/src/test/java/one/talon/model/CatalogActionRemoveTest.java new file mode 100644 index 00000000..9b8a3eb6 --- /dev/null +++ b/src/test/java/one/talon/model/CatalogActionRemoveTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RemoveItemCatalogAction; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CatalogActionRemove + */ +public class CatalogActionRemoveTest { + private final CatalogActionRemove model = new CatalogActionRemove(); + + /** + * Model tests for CatalogActionRemove + */ + @Test + public void testCatalogActionRemove() { + // TODO: test CatalogActionRemove + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + +} diff --git a/src/test/java/one/talon/model/CheckAchievementBlockAchievementTest.java b/src/test/java/one/talon/model/CheckAchievementBlockAchievementTest.java new file mode 100644 index 00000000..210bd09e --- /dev/null +++ b/src/test/java/one/talon/model/CheckAchievementBlockAchievementTest.java @@ -0,0 +1,76 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAchievementBlockAchievement + */ +public class CheckAchievementBlockAchievementTest { + private final CheckAchievementBlockAchievement model = new CheckAchievementBlockAchievement(); + + /** + * Model tests for CheckAchievementBlockAchievement + */ + @Test + public void testCheckAchievementBlockAchievement() { + // TODO: test CheckAchievementBlockAchievement + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + +} diff --git a/src/test/java/one/talon/model/CheckAchievementBlockTest.java b/src/test/java/one/talon/model/CheckAchievementBlockTest.java new file mode 100644 index 00000000..d7cad518 --- /dev/null +++ b/src/test/java/one/talon/model/CheckAchievementBlockTest.java @@ -0,0 +1,94 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckAchievementBlockAchievement; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAchievementBlock + */ +public class CheckAchievementBlockTest { + private final CheckAchievementBlock model = new CheckAchievementBlock(); + + /** + * Model tests for CheckAchievementBlock + */ + @Test + public void testCheckAchievementBlock() { + // TODO: test CheckAchievementBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'achievement' + */ + @Test + public void achievementTest() { + // TODO: test achievement + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckAttributeBlockBaseTest.java b/src/test/java/one/talon/model/CheckAttributeBlockBaseTest.java new file mode 100644 index 00000000..cddb438c --- /dev/null +++ b/src/test/java/one/talon/model/CheckAttributeBlockBaseTest.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAttributeBlockBase + */ +public class CheckAttributeBlockBaseTest { + private final CheckAttributeBlockBase model = new CheckAttributeBlockBase(); + + /** + * Model tests for CheckAttributeBlockBase + */ + @Test + public void testCheckAttributeBlockBase() { + // TODO: test CheckAttributeBlockBase + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'attribute' + */ + @Test + public void attributeTest() { + // TODO: test attribute + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'min' + */ + @Test + public void minTest() { + // TODO: test min + } + + /** + * Test the property 'max' + */ + @Test + public void maxTest() { + // TODO: test max + } + + /** + * Test the property 'start' + */ + @Test + public void startTest() { + // TODO: test start + } + + /** + * Test the property 'end' + */ + @Test + public void endTest() { + // TODO: test end + } + + /** + * Test the property 'startInclusive' + */ + @Test + public void startInclusiveTest() { + // TODO: test startInclusive + } + + /** + * Test the property 'endInclusive' + */ + @Test + public void endInclusiveTest() { + // TODO: test endInclusive + } + + /** + * Test the property 'timezoneInsensitive' + */ + @Test + public void timezoneInsensitiveTest() { + // TODO: test timezoneInsensitive + } + + /** + * Test the property 'values' + */ + @Test + public void valuesTest() { + // TODO: test values + } + + /** + * Test the property 'count' + */ + @Test + public void countTest() { + // TODO: test count + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckAttributeBlockTest.java b/src/test/java/one/talon/model/CheckAttributeBlockTest.java new file mode 100644 index 00000000..868c100b --- /dev/null +++ b/src/test/java/one/talon/model/CheckAttributeBlockTest.java @@ -0,0 +1,173 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAttributeBlock + */ +public class CheckAttributeBlockTest { + private final CheckAttributeBlock model = new CheckAttributeBlock(); + + /** + * Model tests for CheckAttributeBlock + */ + @Test + public void testCheckAttributeBlock() { + // TODO: test CheckAttributeBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'attribute' + */ + @Test + public void attributeTest() { + // TODO: test attribute + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'min' + */ + @Test + public void minTest() { + // TODO: test min + } + + /** + * Test the property 'max' + */ + @Test + public void maxTest() { + // TODO: test max + } + + /** + * Test the property 'start' + */ + @Test + public void startTest() { + // TODO: test start + } + + /** + * Test the property 'end' + */ + @Test + public void endTest() { + // TODO: test end + } + + /** + * Test the property 'startInclusive' + */ + @Test + public void startInclusiveTest() { + // TODO: test startInclusive + } + + /** + * Test the property 'endInclusive' + */ + @Test + public void endInclusiveTest() { + // TODO: test endInclusive + } + + /** + * Test the property 'timezoneInsensitive' + */ + @Test + public void timezoneInsensitiveTest() { + // TODO: test timezoneInsensitive + } + + /** + * Test the property 'values' + */ + @Test + public void valuesTest() { + // TODO: test values + } + + /** + * Test the property 'count' + */ + @Test + public void countTest() { + // TODO: test count + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckAudienceBlockAudienceTest.java b/src/test/java/one/talon/model/CheckAudienceBlockAudienceTest.java new file mode 100644 index 00000000..1c35436f --- /dev/null +++ b/src/test/java/one/talon/model/CheckAudienceBlockAudienceTest.java @@ -0,0 +1,75 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAudienceBlockAudience + */ +public class CheckAudienceBlockAudienceTest { + private final CheckAudienceBlockAudience model = new CheckAudienceBlockAudience(); + + /** + * Model tests for CheckAudienceBlockAudience + */ + @Test + public void testCheckAudienceBlockAudience() { + // TODO: test CheckAudienceBlockAudience + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'integration' + */ + @Test + public void integrationTest() { + // TODO: test integration + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + +} diff --git a/src/test/java/one/talon/model/CheckAudienceBlockTest.java b/src/test/java/one/talon/model/CheckAudienceBlockTest.java new file mode 100644 index 00000000..4792cff8 --- /dev/null +++ b/src/test/java/one/talon/model/CheckAudienceBlockTest.java @@ -0,0 +1,102 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckAudienceBlockAudience; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckAudienceBlock + */ +public class CheckAudienceBlockTest { + private final CheckAudienceBlock model = new CheckAudienceBlock(); + + /** + * Model tests for CheckAudienceBlock + */ + @Test + public void testCheckAudienceBlock() { + // TODO: test CheckAudienceBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'profile' + */ + @Test + public void profileTest() { + // TODO: test profile + } + + /** + * Test the property 'audience' + */ + @Test + public void audienceTest() { + // TODO: test audience + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckBudgetBlockTest.java b/src/test/java/one/talon/model/CheckBudgetBlockTest.java new file mode 100644 index 00000000..8eba67c8 --- /dev/null +++ b/src/test/java/one/talon/model/CheckBudgetBlockTest.java @@ -0,0 +1,102 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckBudgetBlock + */ +public class CheckBudgetBlockTest { + private final CheckBudgetBlock model = new CheckBudgetBlock(); + + /** + * Model tests for CheckBudgetBlock + */ + @Test + public void testCheckBudgetBlock() { + // TODO: test CheckBudgetBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'action' + */ + @Test + public void actionTest() { + // TODO: test action + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckCouponBlockTest.java b/src/test/java/one/talon/model/CheckCouponBlockTest.java new file mode 100644 index 00000000..03f95338 --- /dev/null +++ b/src/test/java/one/talon/model/CheckCouponBlockTest.java @@ -0,0 +1,85 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckCouponBlock + */ +public class CheckCouponBlockTest { + private final CheckCouponBlock model = new CheckCouponBlock(); + + /** + * Model tests for CheckCouponBlock + */ + @Test + public void testCheckCouponBlock() { + // TODO: test CheckCouponBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'redeem' + */ + @Test + public void redeemTest() { + // TODO: test redeem + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckEventBlockTest.java b/src/test/java/one/talon/model/CheckEventBlockTest.java new file mode 100644 index 00000000..13222953 --- /dev/null +++ b/src/test/java/one/talon/model/CheckEventBlockTest.java @@ -0,0 +1,93 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckEventBlock + */ +public class CheckEventBlockTest { + private final CheckEventBlock model = new CheckEventBlock(); + + /** + * Model tests for CheckEventBlock + */ + @Test + public void testCheckEventBlock() { + // TODO: test CheckEventBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'eventType' + */ + @Test + public void eventTypeTest() { + // TODO: test eventType + } + + /** + * Test the property 'matchers' + */ + @Test + public void matchersTest() { + // TODO: test matchers + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockProgramTest.java b/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockProgramTest.java new file mode 100644 index 00000000..4114b2e3 --- /dev/null +++ b/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockProgramTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckLoyaltyBalanceBlockProgram + */ +public class CheckLoyaltyBalanceBlockProgramTest { + private final CheckLoyaltyBalanceBlockProgram model = new CheckLoyaltyBalanceBlockProgram(); + + /** + * Model tests for CheckLoyaltyBalanceBlockProgram + */ + @Test + public void testCheckLoyaltyBalanceBlockProgram() { + // TODO: test CheckLoyaltyBalanceBlockProgram + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + +} diff --git a/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockTest.java b/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockTest.java new file mode 100644 index 00000000..13ce04dd --- /dev/null +++ b/src/test/java/one/talon/model/CheckLoyaltyBalanceBlockTest.java @@ -0,0 +1,119 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckLoyaltyBalanceBlockProgram; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckLoyaltyBalanceBlock + */ +public class CheckLoyaltyBalanceBlockTest { + private final CheckLoyaltyBalanceBlock model = new CheckLoyaltyBalanceBlock(); + + /** + * Model tests for CheckLoyaltyBalanceBlock + */ + @Test + public void testCheckLoyaltyBalanceBlock() { + // TODO: test CheckLoyaltyBalanceBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'program' + */ + @Test + public void programTest() { + // TODO: test program + } + + /** + * Test the property 'subledger' + */ + @Test + public void subledgerTest() { + // TODO: test subledger + } + + /** + * Test the property 'balance' + */ + @Test + public void balanceTest() { + // TODO: test balance + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckLoyaltyCardBlockTest.java b/src/test/java/one/talon/model/CheckLoyaltyCardBlockTest.java new file mode 100644 index 00000000..7337273b --- /dev/null +++ b/src/test/java/one/talon/model/CheckLoyaltyCardBlockTest.java @@ -0,0 +1,85 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckLoyaltyCardBlock + */ +public class CheckLoyaltyCardBlockTest { + private final CheckLoyaltyCardBlock model = new CheckLoyaltyCardBlock(); + + /** + * Model tests for CheckLoyaltyCardBlock + */ + @Test + public void testCheckLoyaltyCardBlock() { + // TODO: test CheckLoyaltyCardBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckReferralBlockTest.java b/src/test/java/one/talon/model/CheckReferralBlockTest.java new file mode 100644 index 00000000..c42223ee --- /dev/null +++ b/src/test/java/one/talon/model/CheckReferralBlockTest.java @@ -0,0 +1,85 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckReferralBlock + */ +public class CheckReferralBlockTest { + private final CheckReferralBlock model = new CheckReferralBlock(); + + /** + * Model tests for CheckReferralBlock + */ + @Test + public void testCheckReferralBlock() { + // TODO: test CheckReferralBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'redeem' + */ + @Test + public void redeemTest() { + // TODO: test redeem + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckTierBlockTest.java b/src/test/java/one/talon/model/CheckTierBlockTest.java new file mode 100644 index 00000000..6830eb2d --- /dev/null +++ b/src/test/java/one/talon/model/CheckTierBlockTest.java @@ -0,0 +1,102 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CheckTierBlockTier; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckTierBlock + */ +public class CheckTierBlockTest { + private final CheckTierBlock model = new CheckTierBlock(); + + /** + * Model tests for CheckTierBlock + */ + @Test + public void testCheckTierBlock() { + // TODO: test CheckTierBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'subledger' + */ + @Test + public void subledgerTest() { + // TODO: test subledger + } + + /** + * Test the property 'tier' + */ + @Test + public void tierTest() { + // TODO: test tier + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/CheckTierBlockTierTest.java b/src/test/java/one/talon/model/CheckTierBlockTierTest.java new file mode 100644 index 00000000..d83cc336 --- /dev/null +++ b/src/test/java/one/talon/model/CheckTierBlockTierTest.java @@ -0,0 +1,76 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CheckTierBlockTier + */ +public class CheckTierBlockTierTest { + private final CheckTierBlockTier model = new CheckTierBlockTier(); + + /** + * Model tests for CheckTierBlockTier + */ + @Test + public void testCheckTierBlockTier() { + // TODO: test CheckTierBlockTier + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'minPoints' + */ + @Test + public void minPointsTest() { + // TODO: test minPoints + } + + /** + * Test the property 'upperLimit' + */ + @Test + public void upperLimitTest() { + // TODO: test upperLimit + } + +} diff --git a/src/test/java/one/talon/model/ConfirmRisksRequestTest.java b/src/test/java/one/talon/model/ConfirmRisksRequestTest.java new file mode 100644 index 00000000..5a1b12e7 --- /dev/null +++ b/src/test/java/one/talon/model/ConfirmRisksRequestTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ConfirmRisksRequest + */ +public class ConfirmRisksRequestTest { + private final ConfirmRisksRequest model = new ConfirmRisksRequest(); + + /** + * Model tests for ConfirmRisksRequest + */ + @Test + public void testConfirmRisksRequest() { + // TODO: test ConfirmRisksRequest + } + + /** + * Test the property 'riskIds' + */ + @Test + public void riskIdsTest() { + // TODO: test riskIds + } + + /** + * Test the property 'comment' + */ + @Test + public void commentTest() { + // TODO: test comment + } + +} diff --git a/src/test/java/one/talon/model/CouponEligibilityInfoTest.java b/src/test/java/one/talon/model/CouponEligibilityInfoTest.java new file mode 100644 index 00000000..15c2865f --- /dev/null +++ b/src/test/java/one/talon/model/CouponEligibilityInfoTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CouponEligibilityInfo + */ +public class CouponEligibilityInfoTest { + private final CouponEligibilityInfo model = new CouponEligibilityInfo(); + + /** + * Model tests for CouponEligibilityInfo + */ + @Test + public void testCouponEligibilityInfo() { + // TODO: test CouponEligibilityInfo + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'campaignName' + */ + @Test + public void campaignNameTest() { + // TODO: test campaignName + } + + /** + * Test the property 'failureReason' + */ + @Test + public void failureReasonTest() { + // TODO: test failureReason + } + +} diff --git a/src/test/java/one/talon/model/CreateAchievementV2Test.java b/src/test/java/one/talon/model/CreateAchievementV2Test.java index 99001d71..f1528d2a 100644 --- a/src/test/java/one/talon/model/CreateAchievementV2Test.java +++ b/src/test/java/one/talon/model/CreateAchievementV2Test.java @@ -125,19 +125,19 @@ public void allowRollbackAfterCompletionTest() { } /** - * Test the property 'sandbox' + * Test the property 'subscribedApplications' */ @Test - public void sandboxTest() { - // TODO: test sandbox + public void subscribedApplicationsTest() { + // TODO: test subscribedApplications } /** - * Test the property 'subscribedApplications' + * Test the property 'sandbox' */ @Test - public void subscribedApplicationsTest() { - // TODO: test subscribedApplications + public void sandboxTest() { + // TODO: test sandbox } /** diff --git a/src/test/java/one/talon/model/CreateCouponBlockTest.java b/src/test/java/one/talon/model/CreateCouponBlockTest.java new file mode 100644 index 00000000..460f877b --- /dev/null +++ b/src/test/java/one/talon/model/CreateCouponBlockTest.java @@ -0,0 +1,149 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CreateCouponBlock + */ +public class CreateCouponBlockTest { + private final CreateCouponBlock model = new CreateCouponBlock(); + + /** + * Model tests for CreateCouponBlock + */ + @Test + public void testCreateCouponBlock() { + // TODO: test CreateCouponBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'recipientId' + */ + @Test + public void recipientIdTest() { + // TODO: test recipientId + } + + /** + * Test the property 'storeInSession' + */ + @Test + public void storeInSessionTest() { + // TODO: test storeInSession + } + + /** + * Test the property 'usageLimit' + */ + @Test + public void usageLimitTest() { + // TODO: test usageLimit + } + + /** + * Test the property 'discountLimit' + */ + @Test + public void discountLimitTest() { + // TODO: test discountLimit + } + + /** + * Test the property 'startDate' + */ + @Test + public void startDateTest() { + // TODO: test startDate + } + + /** + * Test the property 'expiryDate' + */ + @Test + public void expiryDateTest() { + // TODO: test expiryDate + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'validCharacters' + */ + @Test + public void validCharactersTest() { + // TODO: test validCharacters + } + + /** + * Test the property 'pattern' + */ + @Test + public void patternTest() { + // TODO: test pattern + } + +} diff --git a/src/test/java/one/talon/model/CreateReferralBlockTest.java b/src/test/java/one/talon/model/CreateReferralBlockTest.java new file mode 100644 index 00000000..a981295c --- /dev/null +++ b/src/test/java/one/talon/model/CreateReferralBlockTest.java @@ -0,0 +1,141 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CreateReferralBlock + */ +public class CreateReferralBlockTest { + private final CreateReferralBlock model = new CreateReferralBlock(); + + /** + * Model tests for CreateReferralBlock + */ + @Test + public void testCreateReferralBlock() { + // TODO: test CreateReferralBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'friendId' + */ + @Test + public void friendIdTest() { + // TODO: test friendId + } + + /** + * Test the property 'storeInSession' + */ + @Test + public void storeInSessionTest() { + // TODO: test storeInSession + } + + /** + * Test the property 'usageLimit' + */ + @Test + public void usageLimitTest() { + // TODO: test usageLimit + } + + /** + * Test the property 'startDate' + */ + @Test + public void startDateTest() { + // TODO: test startDate + } + + /** + * Test the property 'expiryDate' + */ + @Test + public void expiryDateTest() { + // TODO: test expiryDate + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'validCharacters' + */ + @Test + public void validCharactersTest() { + // TODO: test validCharacters + } + + /** + * Test the property 'pattern' + */ + @Test + public void patternTest() { + // TODO: test pattern + } + +} diff --git a/src/test/java/one/talon/model/CustomerAchievementTest.java b/src/test/java/one/talon/model/CustomerAchievementTest.java new file mode 100644 index 00000000..f32f180d --- /dev/null +++ b/src/test/java/one/talon/model/CustomerAchievementTest.java @@ -0,0 +1,161 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.AchievementProgress; +import one.talon.model.CampaignReference; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CustomerAchievement + */ +public class CustomerAchievementTest { + private final CustomerAchievement model = new CustomerAchievement(); + + /** + * Model tests for CustomerAchievement + */ + @Test + public void testCustomerAchievement() { + // TODO: test CustomerAchievement + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + + /** + * Test the property 'recurrencePolicy' + */ + @Test + public void recurrencePolicyTest() { + // TODO: test recurrencePolicy + } + + /** + * Test the property 'activationPolicy' + */ + @Test + public void activationPolicyTest() { + // TODO: test activationPolicy + } + + /** + * Test the property 'fixedStartDate' + */ + @Test + public void fixedStartDateTest() { + // TODO: test fixedStartDate + } + + /** + * Test the property 'endDate' + */ + @Test + public void endDateTest() { + // TODO: test endDate + } + + /** + * Test the property 'allowRollbackAfterCompletion' + */ + @Test + public void allowRollbackAfterCompletionTest() { + // TODO: test allowRollbackAfterCompletion + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'campaignIds' + */ + @Test + public void campaignIdsTest() { + // TODO: test campaignIds + } + + /** + * Test the property 'referencedByCampaigns' + */ + @Test + public void referencedByCampaignsTest() { + // TODO: test referencedByCampaigns + } + + /** + * Test the property 'currentProgress' + */ + @Test + public void currentProgressTest() { + // TODO: test currentProgress + } + +} diff --git a/src/test/java/one/talon/model/CustomerInventoryTest.java b/src/test/java/one/talon/model/CustomerInventoryTest.java index 9c6e70b0..73cd4f7c 100644 --- a/src/test/java/one/talon/model/CustomerInventoryTest.java +++ b/src/test/java/one/talon/model/CustomerInventoryTest.java @@ -29,6 +29,7 @@ import one.talon.model.InventoryCoupon; import one.talon.model.InventoryReferral; import one.talon.model.Loyalty; +import one.talon.model.RewardWithUnlocks; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -96,4 +97,12 @@ public void achievementsTest() { // TODO: test achievements } + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + } diff --git a/src/test/java/one/talon/model/CustomerProfileIntegrationResponseV2Test.java b/src/test/java/one/talon/model/CustomerProfileIntegrationResponseV2Test.java index 538b925c..0c7ec44d 100644 --- a/src/test/java/one/talon/model/CustomerProfileIntegrationResponseV2Test.java +++ b/src/test/java/one/talon/model/CustomerProfileIntegrationResponseV2Test.java @@ -24,6 +24,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; import one.talon.model.CustomerProfile; import one.talon.model.Effect; @@ -31,6 +32,7 @@ import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; import org.junit.Assert; import org.junit.Ignore; @@ -91,6 +93,14 @@ public void ruleFailureReasonsTest() { // TODO: test ruleFailureReasons } + /** + * Test the property 'campaignEligibility' + */ + @Test + public void campaignEligibilityTest() { + // TODO: test campaignEligibility + } + /** * Test the property 'awardedGiveaways' */ @@ -99,6 +109,14 @@ public void awardedGiveawaysTest() { // TODO: test awardedGiveaways } + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + /** * Test the property 'effects' */ diff --git a/src/test/java/one/talon/model/CustomerProfileRewardTest.java b/src/test/java/one/talon/model/CustomerProfileRewardTest.java new file mode 100644 index 00000000..8b9da5c1 --- /dev/null +++ b/src/test/java/one/talon/model/CustomerProfileRewardTest.java @@ -0,0 +1,157 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RuleMetadata; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CustomerProfileReward + */ +public class CustomerProfileRewardTest { + private final CustomerProfileReward model = new CustomerProfileReward(); + + /** + * Model tests for CustomerProfileReward + */ + @Test + public void testCustomerProfileReward() { + // TODO: test CustomerProfileReward + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + + /** + * Test the property 'rewardIntegrationId' + */ + @Test + public void rewardIntegrationIdTest() { + // TODO: test rewardIntegrationId + } + + /** + * Test the property 'rewardName' + */ + @Test + public void rewardNameTest() { + // TODO: test rewardName + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + + /** + * Test the property 'unlockedAt' + */ + @Test + public void unlockedAtTest() { + // TODO: test unlockedAt + } + + /** + * Test the property 'unlockedByProfileIntegrationId' + */ + @Test + public void unlockedByProfileIntegrationIdTest() { + // TODO: test unlockedByProfileIntegrationId + } + + /** + * Test the property 'usedAt' + */ + @Test + public void usedAtTest() { + // TODO: test usedAt + } + + /** + * Test the property 'usedByProfileIntegrationId' + */ + @Test + public void usedByProfileIntegrationIdTest() { + // TODO: test usedByProfileIntegrationId + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'loyaltyCardIdentifier' + */ + @Test + public void loyaltyCardIdentifierTest() { + // TODO: test loyaltyCardIdentifier + } + +} diff --git a/src/test/java/one/talon/model/CustomerRewardTest.java b/src/test/java/one/talon/model/CustomerRewardTest.java new file mode 100644 index 00000000..8dc83634 --- /dev/null +++ b/src/test/java/one/talon/model/CustomerRewardTest.java @@ -0,0 +1,84 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for CustomerReward + */ +public class CustomerRewardTest { + private final CustomerReward model = new CustomerReward(); + + /** + * Model tests for CustomerReward + */ + @Test + public void testCustomerReward() { + // TODO: test CustomerReward + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'profileIntegrationId' + */ + @Test + public void profileIntegrationIdTest() { + // TODO: test profileIntegrationId + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'unlockedAt' + */ + @Test + public void unlockedAtTest() { + // TODO: test unlockedAt + } + + /** + * Test the property 'usedAt' + */ + @Test + public void usedAtTest() { + // TODO: test usedAt + } + +} diff --git a/src/test/java/one/talon/model/CustomerSessionV2Test.java b/src/test/java/one/talon/model/CustomerSessionV2Test.java index 3ea2a2e5..27a4ee53 100644 --- a/src/test/java/one/talon/model/CustomerSessionV2Test.java +++ b/src/test/java/one/talon/model/CustomerSessionV2Test.java @@ -129,6 +129,14 @@ public void loyaltyCardsTest() { // TODO: test loyaltyCards } + /** + * Test the property 'rewardIntegrationIds' + */ + @Test + public void rewardIntegrationIdsTest() { + // TODO: test rewardIntegrationIds + } + /** * Test the property 'state' */ @@ -217,6 +225,14 @@ public void additionalCostTotalTest() { // TODO: test additionalCostTotal } + /** + * Test the property 'cartItemAdditionalCostTotal' + */ + @Test + public void cartItemAdditionalCostTotalTest() { + // TODO: test cartItemAdditionalCostTotal + } + /** * Test the property 'updated' */ diff --git a/src/test/java/one/talon/model/DigitalPassTest.java b/src/test/java/one/talon/model/DigitalPassTest.java new file mode 100644 index 00000000..b2331ebb --- /dev/null +++ b/src/test/java/one/talon/model/DigitalPassTest.java @@ -0,0 +1,76 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.net.URI; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for DigitalPass + */ +public class DigitalPassTest { + private final DigitalPass model = new DigitalPass(); + + /** + * Model tests for DigitalPass + */ + @Test + public void testDigitalPass() { + // TODO: test DigitalPass + } + + /** + * Test the property 'passId' + */ + @Test + public void passIdTest() { + // TODO: test passId + } + + /** + * Test the property 'passTemplateId' + */ + @Test + public void passTemplateIdTest() { + // TODO: test passTemplateId + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + + /** + * Test the property 'passUrl' + */ + @Test + public void passUrlTest() { + // TODO: test passUrl + } + +} diff --git a/src/test/java/one/talon/model/DiscardRisksRequestTest.java b/src/test/java/one/talon/model/DiscardRisksRequestTest.java new file mode 100644 index 00000000..55cad9a9 --- /dev/null +++ b/src/test/java/one/talon/model/DiscardRisksRequestTest.java @@ -0,0 +1,69 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for DiscardRisksRequest + */ +public class DiscardRisksRequestTest { + private final DiscardRisksRequest model = new DiscardRisksRequest(); + + /** + * Model tests for DiscardRisksRequest + */ + @Test + public void testDiscardRisksRequest() { + // TODO: test DiscardRisksRequest + } + + /** + * Test the property 'riskIds' + */ + @Test + public void riskIdsTest() { + // TODO: test riskIds + } + + /** + * Test the property 'reason' + */ + @Test + public void reasonTest() { + // TODO: test reason + } + + /** + * Test the property 'comment' + */ + @Test + public void commentTest() { + // TODO: test comment + } + +} diff --git a/src/test/java/one/talon/model/EffectEntityTest.java b/src/test/java/one/talon/model/EffectEntityTest.java index c384c1b6..dea969b2 100644 --- a/src/test/java/one/talon/model/EffectEntityTest.java +++ b/src/test/java/one/talon/model/EffectEntityTest.java @@ -170,4 +170,12 @@ public void adjustmentReferenceIdTest() { // TODO: test adjustmentReferenceId } + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + } diff --git a/src/test/java/one/talon/model/EffectTest.java b/src/test/java/one/talon/model/EffectTest.java index c80968b6..05f8de7d 100644 --- a/src/test/java/one/talon/model/EffectTest.java +++ b/src/test/java/one/talon/model/EffectTest.java @@ -170,6 +170,14 @@ public void adjustmentReferenceIdTest() { // TODO: test adjustmentReferenceId } + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + /** * Test the property 'props' */ diff --git a/src/test/java/one/talon/model/EventTest.java b/src/test/java/one/talon/model/EventTest.java index 3cbd8b46..1e4324e6 100644 --- a/src/test/java/one/talon/model/EventTest.java +++ b/src/test/java/one/talon/model/EventTest.java @@ -101,6 +101,14 @@ public void attributesTest() { // TODO: test attributes } + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + /** * Test the property 'sessionId' */ diff --git a/src/test/java/one/talon/model/EventV3ConnectionsTest.java b/src/test/java/one/talon/model/EventV3ConnectionsTest.java new file mode 100644 index 00000000..da0ff9b8 --- /dev/null +++ b/src/test/java/one/talon/model/EventV3ConnectionsTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for EventV3Connections + */ +public class EventV3ConnectionsTest { + private final EventV3Connections model = new EventV3Connections(); + + /** + * Model tests for EventV3Connections + */ + @Test + public void testEventV3Connections() { + // TODO: test EventV3Connections + } + + /** + * Test the property 'connectedSessionId' + */ + @Test + public void connectedSessionIdTest() { + // TODO: test connectedSessionId + } + +} diff --git a/src/test/java/one/talon/model/EventV3EntityTest.java b/src/test/java/one/talon/model/EventV3EntityTest.java new file mode 100644 index 00000000..da017ad5 --- /dev/null +++ b/src/test/java/one/talon/model/EventV3EntityTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for EventV3Entity + */ +public class EventV3EntityTest { + private final EventV3Entity model = new EventV3Entity(); + + /** + * Model tests for EventV3Entity + */ + @Test + public void testEventV3Entity() { + // TODO: test EventV3Entity + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + +} diff --git a/src/test/java/one/talon/model/EventV3ReferralEntityTest.java b/src/test/java/one/talon/model/EventV3ReferralEntityTest.java new file mode 100644 index 00000000..c477ae05 --- /dev/null +++ b/src/test/java/one/talon/model/EventV3ReferralEntityTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for EventV3ReferralEntity + */ +public class EventV3ReferralEntityTest { + private final EventV3ReferralEntity model = new EventV3ReferralEntity(); + + /** + * Model tests for EventV3ReferralEntity + */ + @Test + public void testEventV3ReferralEntity() { + // TODO: test EventV3ReferralEntity + } + + /** + * Test the property 'referralCode' + */ + @Test + public void referralCodeTest() { + // TODO: test referralCode + } + +} diff --git a/src/test/java/one/talon/model/EventV3RequestEntityTest.java b/src/test/java/one/talon/model/EventV3RequestEntityTest.java new file mode 100644 index 00000000..3a3adb7d --- /dev/null +++ b/src/test/java/one/talon/model/EventV3RequestEntityTest.java @@ -0,0 +1,109 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for EventV3RequestEntity + */ +public class EventV3RequestEntityTest { + private final EventV3RequestEntity model = new EventV3RequestEntity(); + + /** + * Model tests for EventV3RequestEntity + */ + @Test + public void testEventV3RequestEntity() { + // TODO: test EventV3RequestEntity + } + + /** + * Test the property 'profileId' + */ + @Test + public void profileIdTest() { + // TODO: test profileId + } + + /** + * Test the property 'storeIntegrationId' + */ + @Test + public void storeIntegrationIdTest() { + // TODO: test storeIntegrationId + } + + /** + * Test the property 'evaluableCampaignIds' + */ + @Test + public void evaluableCampaignIdsTest() { + // TODO: test evaluableCampaignIds + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'connectedSessionId' + */ + @Test + public void connectedSessionIdTest() { + // TODO: test connectedSessionId + } + + /** + * Test the property 'referralCode' + */ + @Test + public void referralCodeTest() { + // TODO: test referralCode + } + +} diff --git a/src/test/java/one/talon/model/EventV3Test.java b/src/test/java/one/talon/model/EventV3Test.java index 2561d4bc..5c12823d 100644 --- a/src/test/java/one/talon/model/EventV3Test.java +++ b/src/test/java/one/talon/model/EventV3Test.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,35 +44,51 @@ public void testEventV3() { } /** - * Test the property 'profileId' + * Test the property 'connectedSessionId' */ @Test - public void profileIdTest() { - // TODO: test profileId + public void connectedSessionIdTest() { + // TODO: test connectedSessionId } /** - * Test the property 'storeIntegrationId' + * Test the property 'id' */ @Test - public void storeIntegrationIdTest() { - // TODO: test storeIntegrationId + public void idTest() { + // TODO: test id } /** - * Test the property 'evaluableCampaignIds' + * Test the property 'created' */ @Test - public void evaluableCampaignIdsTest() { - // TODO: test evaluableCampaignIds + public void createdTest() { + // TODO: test created } /** - * Test the property 'integrationId' + * Test the property 'applicationId' */ @Test - public void integrationIdTest() { - // TODO: test integrationId + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'profileId' + */ + @Test + public void profileIdTest() { + // TODO: test profileId + } + + /** + * Test the property 'storeIntegrationId' + */ + @Test + public void storeIntegrationIdTest() { + // TODO: test storeIntegrationId } /** @@ -91,19 +108,27 @@ public void attributesTest() { } /** - * Test the property 'connectedSessionID' + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'referralCode' */ @Test - public void connectedSessionIDTest() { - // TODO: test connectedSessionID + public void referralCodeTest() { + // TODO: test referralCode } /** - * Test the property 'previousEventID' + * Test the property 'effects' */ @Test - public void previousEventIDTest() { - // TODO: test previousEventID + public void effectsTest() { + // TODO: test effects } } diff --git a/src/test/java/one/talon/model/ExcludePriceObservationsRequestTest.java b/src/test/java/one/talon/model/ExcludePriceObservationsRequestTest.java new file mode 100644 index 00000000..534b5a6a --- /dev/null +++ b/src/test/java/one/talon/model/ExcludePriceObservationsRequestTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ExcludePriceObservationsRequest + */ +public class ExcludePriceObservationsRequestTest { + private final ExcludePriceObservationsRequest model = new ExcludePriceObservationsRequest(); + + /** + * Model tests for ExcludePriceObservationsRequest + */ + @Test + public void testExcludePriceObservationsRequest() { + // TODO: test ExcludePriceObservationsRequest + } + + /** + * Test the property 'ids' + */ + @Test + public void idsTest() { + // TODO: test ids + } + + /** + * Test the property 'reason' + */ + @Test + public void reasonTest() { + // TODO: test reason + } + +} diff --git a/src/test/java/one/talon/model/ExperimentConfidenceTimelineDataPointTest.java b/src/test/java/one/talon/model/ExperimentConfidenceTimelineDataPointTest.java new file mode 100644 index 00000000..e2c377f8 --- /dev/null +++ b/src/test/java/one/talon/model/ExperimentConfidenceTimelineDataPointTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.ExperimentVariantResultConfidence; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ExperimentConfidenceTimelineDataPoint + */ +public class ExperimentConfidenceTimelineDataPointTest { + private final ExperimentConfidenceTimelineDataPoint model = new ExperimentConfidenceTimelineDataPoint(); + + /** + * Model tests for ExperimentConfidenceTimelineDataPoint + */ + @Test + public void testExperimentConfidenceTimelineDataPoint() { + // TODO: test ExperimentConfidenceTimelineDataPoint + } + + /** + * Test the property 'date' + */ + @Test + public void dateTest() { + // TODO: test date + } + + /** + * Test the property 'confidence' + */ + @Test + public void confidenceTest() { + // TODO: test confidence + } + +} diff --git a/src/test/java/one/talon/model/ExperimentConfidenceTimelineTest.java b/src/test/java/one/talon/model/ExperimentConfidenceTimelineTest.java new file mode 100644 index 00000000..f1e177f0 --- /dev/null +++ b/src/test/java/one/talon/model/ExperimentConfidenceTimelineTest.java @@ -0,0 +1,54 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.ExperimentConfidenceTimelineDataPoint; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ExperimentConfidenceTimeline + */ +public class ExperimentConfidenceTimelineTest { + private final ExperimentConfidenceTimeline model = new ExperimentConfidenceTimeline(); + + /** + * Model tests for ExperimentConfidenceTimeline + */ + @Test + public void testExperimentConfidenceTimeline() { + // TODO: test ExperimentConfidenceTimeline + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/ExperimentCopyExperimentTest.java b/src/test/java/one/talon/model/ExperimentCopyExperimentTest.java index a343d708..c154724a 100644 --- a/src/test/java/one/talon/model/ExperimentCopyExperimentTest.java +++ b/src/test/java/one/talon/model/ExperimentCopyExperimentTest.java @@ -57,4 +57,20 @@ public void campaignTest() { // TODO: test campaign } + /** + * Test the property 'goalType' + */ + @Test + public void goalTypeTest() { + // TODO: test goalType + } + + /** + * Test the property 'goalDescription' + */ + @Test + public void goalDescriptionTest() { + // TODO: test goalDescription + } + } diff --git a/src/test/java/one/talon/model/ExperimentTest.java b/src/test/java/one/talon/model/ExperimentTest.java index 7540b891..2f63d733 100644 --- a/src/test/java/one/talon/model/ExperimentTest.java +++ b/src/test/java/one/talon/model/ExperimentTest.java @@ -109,6 +109,22 @@ public void variantsTest() { // TODO: test variants } + /** + * Test the property 'goalType' + */ + @Test + public void goalTypeTest() { + // TODO: test goalType + } + + /** + * Test the property 'goalDescription' + */ + @Test + public void goalDescriptionTest() { + // TODO: test goalDescription + } + /** * Test the property 'deletedat' */ diff --git a/src/test/java/one/talon/model/FeatureFlagUpdateTest.java b/src/test/java/one/talon/model/FeatureFlagUpdateTest.java new file mode 100644 index 00000000..e23eb605 --- /dev/null +++ b/src/test/java/one/talon/model/FeatureFlagUpdateTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for FeatureFlagUpdate + */ +public class FeatureFlagUpdateTest { + private final FeatureFlagUpdate model = new FeatureFlagUpdate(); + + /** + * Model tests for FeatureFlagUpdate + */ + @Test + public void testFeatureFlagUpdate() { + // TODO: test FeatureFlagUpdate + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + +} diff --git a/src/test/java/one/talon/model/FilterAndMapValuesSelectorStepTest.java b/src/test/java/one/talon/model/FilterAndMapValuesSelectorStepTest.java new file mode 100644 index 00000000..217f056d --- /dev/null +++ b/src/test/java/one/talon/model/FilterAndMapValuesSelectorStepTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.SelectorValueMapRef; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for FilterAndMapValuesSelectorStep + */ +public class FilterAndMapValuesSelectorStepTest { + private final FilterAndMapValuesSelectorStep model = new FilterAndMapValuesSelectorStep(); + + /** + * Model tests for FilterAndMapValuesSelectorStep + */ + @Test + public void testFilterAndMapValuesSelectorStep() { + // TODO: test FilterAndMapValuesSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'valueMap' + */ + @Test + public void valueMapTest() { + // TODO: test valueMap + } + +} diff --git a/src/test/java/one/talon/model/FilterSelectorStepTest.java b/src/test/java/one/talon/model/FilterSelectorStepTest.java new file mode 100644 index 00000000..e351e49b --- /dev/null +++ b/src/test/java/one/talon/model/FilterSelectorStepTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for FilterSelectorStep + */ +public class FilterSelectorStepTest { + private final FilterSelectorStep model = new FilterSelectorStep(); + + /** + * Model tests for FilterSelectorStep + */ + @Test + public void testFilterSelectorStep() { + // TODO: test FilterSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'predicate' + */ + @Test + public void predicateTest() { + // TODO: test predicate + } + +} diff --git a/src/test/java/one/talon/model/GeoJSONGeometryCollectionTest.java b/src/test/java/one/talon/model/GeoJSONGeometryCollectionTest.java new file mode 100644 index 00000000..b386496c --- /dev/null +++ b/src/test/java/one/talon/model/GeoJSONGeometryCollectionTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GeoJSONGeometryCollection + */ +public class GeoJSONGeometryCollectionTest { + private final GeoJSONGeometryCollection model = new GeoJSONGeometryCollection(); + + /** + * Model tests for GeoJSONGeometryCollection + */ + @Test + public void testGeoJSONGeometryCollection() { + // TODO: test GeoJSONGeometryCollection + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'geometries' + */ + @Test + public void geometriesTest() { + // TODO: test geometries + } + +} diff --git a/src/test/java/one/talon/model/GeoJSONMultiPolygonTest.java b/src/test/java/one/talon/model/GeoJSONMultiPolygonTest.java new file mode 100644 index 00000000..f1d7f752 --- /dev/null +++ b/src/test/java/one/talon/model/GeoJSONMultiPolygonTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GeoJSONMultiPolygon + */ +public class GeoJSONMultiPolygonTest { + private final GeoJSONMultiPolygon model = new GeoJSONMultiPolygon(); + + /** + * Model tests for GeoJSONMultiPolygon + */ + @Test + public void testGeoJSONMultiPolygon() { + // TODO: test GeoJSONMultiPolygon + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'coordinates' + */ + @Test + public void coordinatesTest() { + // TODO: test coordinates + } + +} diff --git a/src/test/java/one/talon/model/GeoJSONPointTest.java b/src/test/java/one/talon/model/GeoJSONPointTest.java new file mode 100644 index 00000000..629e85a4 --- /dev/null +++ b/src/test/java/one/talon/model/GeoJSONPointTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GeoJSONPoint + */ +public class GeoJSONPointTest { + private final GeoJSONPoint model = new GeoJSONPoint(); + + /** + * Model tests for GeoJSONPoint + */ + @Test + public void testGeoJSONPoint() { + // TODO: test GeoJSONPoint + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'coordinates' + */ + @Test + public void coordinatesTest() { + // TODO: test coordinates + } + +} diff --git a/src/test/java/one/talon/model/GeoJSONPolygonTest.java b/src/test/java/one/talon/model/GeoJSONPolygonTest.java new file mode 100644 index 00000000..04c60170 --- /dev/null +++ b/src/test/java/one/talon/model/GeoJSONPolygonTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GeoJSONPolygon + */ +public class GeoJSONPolygonTest { + private final GeoJSONPolygon model = new GeoJSONPolygon(); + + /** + * Model tests for GeoJSONPolygon + */ + @Test + public void testGeoJSONPolygon() { + // TODO: test GeoJSONPolygon + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'coordinates' + */ + @Test + public void coordinatesTest() { + // TODO: test coordinates + } + +} diff --git a/src/test/java/one/talon/model/GiveawayPoolReferenceTest.java b/src/test/java/one/talon/model/GiveawayPoolReferenceTest.java new file mode 100644 index 00000000..f1f20204 --- /dev/null +++ b/src/test/java/one/talon/model/GiveawayPoolReferenceTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GiveawayPoolReference + */ +public class GiveawayPoolReferenceTest { + private final GiveawayPoolReference model = new GiveawayPoolReference(); + + /** + * Model tests for GiveawayPoolReference + */ + @Test + public void testGiveawayPoolReference() { + // TODO: test GiveawayPoolReference + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + +} diff --git a/src/test/java/one/talon/model/GroupBlockTest.java b/src/test/java/one/talon/model/GroupBlockTest.java new file mode 100644 index 00000000..9c58d51b --- /dev/null +++ b/src/test/java/one/talon/model/GroupBlockTest.java @@ -0,0 +1,103 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for GroupBlock + */ +public class GroupBlockTest { + private final GroupBlock model = new GroupBlock(); + + /** + * Model tests for GroupBlock + */ + @Test + public void testGroupBlock() { + // TODO: test GroupBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'blocks' + */ + @Test + public void blocksTest() { + // TODO: test blocks + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/HistoryTest.java b/src/test/java/one/talon/model/HistoryTest.java index 985b3eb7..1abb0d77 100644 --- a/src/test/java/one/talon/model/HistoryTest.java +++ b/src/test/java/one/talon/model/HistoryTest.java @@ -22,6 +22,8 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; import one.talon.model.BestPriorPriceMetadata; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; @@ -60,11 +62,11 @@ public void observedAtTest() { } /** - * Test the property 'contextId' + * Test the property 'contextIds' */ @Test - public void contextIdTest() { - // TODO: test contextId + public void contextIdsTest() { + // TODO: test contextIds } /** @@ -91,4 +93,20 @@ public void targetTest() { // TODO: test target } + /** + * Test the property 'excludedAt' + */ + @Test + public void excludedAtTest() { + // TODO: test excludedAt + } + + /** + * Test the property 'exclusionReason' + */ + @Test + public void exclusionReasonTest() { + // TODO: test exclusionReason + } + } diff --git a/src/test/java/one/talon/model/InlineResponse20032Test.java b/src/test/java/one/talon/model/InlineResponse20032Test.java index 5806470b..62673923 100644 --- a/src/test/java/one/talon/model/InlineResponse20032Test.java +++ b/src/test/java/one/talon/model/InlineResponse20032Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationEvent; +import one.talon.model.ApplicationSession; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,6 +51,14 @@ public void hasMoreTest() { // TODO: test hasMore } + /** + * Test the property 'totalResultSize' + */ + @Test + public void totalResultSizeTest() { + // TODO: test totalResultSize + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20033Test.java b/src/test/java/one/talon/model/InlineResponse20033Test.java index c3d1f7e9..426702c8 100644 --- a/src/test/java/one/talon/model/InlineResponse20033Test.java +++ b/src/test/java/one/talon/model/InlineResponse20033Test.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.ApplicationEvent; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,11 +44,11 @@ public void testInlineResponse20033() { } /** - * Test the property 'totalResultSize' + * Test the property 'hasMore' */ @Test - public void totalResultSizeTest() { - // TODO: test totalResultSize + public void hasMoreTest() { + // TODO: test hasMore } /** diff --git a/src/test/java/one/talon/model/InlineResponse20034Test.java b/src/test/java/one/talon/model/InlineResponse20034Test.java index e2f77d15..c58d75fb 100644 --- a/src/test/java/one/talon/model/InlineResponse20034Test.java +++ b/src/test/java/one/talon/model/InlineResponse20034Test.java @@ -23,7 +23,6 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Audience; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,14 +42,6 @@ public void testInlineResponse20034() { // TODO: test InlineResponse20034 } - /** - * Test the property 'hasMore' - */ - @Test - public void hasMoreTest() { - // TODO: test hasMore - } - /** * Test the property 'totalResultSize' */ diff --git a/src/test/java/one/talon/model/InlineResponse20035Test.java b/src/test/java/one/talon/model/InlineResponse20035Test.java index 8d160b67..e01a1595 100644 --- a/src/test/java/one/talon/model/InlineResponse20035Test.java +++ b/src/test/java/one/talon/model/InlineResponse20035Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AudienceAnalytics; +import one.talon.model.Audience; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,6 +51,14 @@ public void hasMoreTest() { // TODO: test hasMore } + /** + * Test the property 'totalResultSize' + */ + @Test + public void totalResultSizeTest() { + // TODO: test totalResultSize + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20036Test.java b/src/test/java/one/talon/model/InlineResponse20036Test.java index be1e6f17..938acadf 100644 --- a/src/test/java/one/talon/model/InlineResponse20036Test.java +++ b/src/test/java/one/talon/model/InlineResponse20036Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CustomerProfile; +import one.talon.model.AudienceAnalytics; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20037Test.java b/src/test/java/one/talon/model/InlineResponse20037Test.java index 3a173e21..a7402b5b 100644 --- a/src/test/java/one/talon/model/InlineResponse20037Test.java +++ b/src/test/java/one/talon/model/InlineResponse20037Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationReferee; +import one.talon.model.CustomerProfile; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,14 +51,6 @@ public void hasMoreTest() { // TODO: test hasMore } - /** - * Test the property 'totalResultSize' - */ - @Test - public void totalResultSizeTest() { - // TODO: test totalResultSize - } - /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20038Test.java b/src/test/java/one/talon/model/InlineResponse20038Test.java index 9a999925..bf236e70 100644 --- a/src/test/java/one/talon/model/InlineResponse20038Test.java +++ b/src/test/java/one/talon/model/InlineResponse20038Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Attribute; +import one.talon.model.ApplicationReferee; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,6 +43,14 @@ public void testInlineResponse20038() { // TODO: test InlineResponse20038 } + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + /** * Test the property 'totalResultSize' */ diff --git a/src/test/java/one/talon/model/InlineResponse20039Test.java b/src/test/java/one/talon/model/InlineResponse20039Test.java index 294c64e0..6a096401 100644 --- a/src/test/java/one/talon/model/InlineResponse20039Test.java +++ b/src/test/java/one/talon/model/InlineResponse20039Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CatalogItem; +import one.talon.model.Attribute; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,14 +43,6 @@ public void testInlineResponse20039() { // TODO: test InlineResponse20039 } - /** - * Test the property 'hasMore' - */ - @Test - public void hasMoreTest() { - // TODO: test hasMore - } - /** * Test the property 'totalResultSize' */ diff --git a/src/test/java/one/talon/model/InlineResponse20040Test.java b/src/test/java/one/talon/model/InlineResponse20040Test.java index bebab563..6a35c33d 100644 --- a/src/test/java/one/talon/model/InlineResponse20040Test.java +++ b/src/test/java/one/talon/model/InlineResponse20040Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AccountAdditionalCost; +import one.talon.model.CatalogItem; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,6 +43,14 @@ public void testInlineResponse20040() { // TODO: test InlineResponse20040 } + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + /** * Test the property 'totalResultSize' */ diff --git a/src/test/java/one/talon/model/InlineResponse20041Test.java b/src/test/java/one/talon/model/InlineResponse20041Test.java index 5e3f9ba7..2290ba27 100644 --- a/src/test/java/one/talon/model/InlineResponse20041Test.java +++ b/src/test/java/one/talon/model/InlineResponse20041Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.WebhookWithOutgoingIntegrationDetails; +import one.talon.model.AccountAdditionalCost; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20042Test.java b/src/test/java/one/talon/model/InlineResponse20042Test.java index e3b2c0c5..bcb714e5 100644 --- a/src/test/java/one/talon/model/InlineResponse20042Test.java +++ b/src/test/java/one/talon/model/InlineResponse20042Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.EventType; +import one.talon.model.WebhookWithOutgoingIntegrationDetails; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20043Test.java b/src/test/java/one/talon/model/InlineResponse20043Test.java index 1a5d34bf..36db31ae 100644 --- a/src/test/java/one/talon/model/InlineResponse20043Test.java +++ b/src/test/java/one/talon/model/InlineResponse20043Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.User; +import one.talon.model.EventType; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20044Test.java b/src/test/java/one/talon/model/InlineResponse20044Test.java index 915a8b4c..bd6d62b3 100644 --- a/src/test/java/one/talon/model/InlineResponse20044Test.java +++ b/src/test/java/one/talon/model/InlineResponse20044Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Change; +import one.talon.model.User; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,14 +51,6 @@ public void totalResultSizeTest() { // TODO: test totalResultSize } - /** - * Test the property 'hasMore' - */ - @Test - public void hasMoreTest() { - // TODO: test hasMore - } - /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20045Test.java b/src/test/java/one/talon/model/InlineResponse20045Test.java index 959495cb..ec5443b4 100644 --- a/src/test/java/one/talon/model/InlineResponse20045Test.java +++ b/src/test/java/one/talon/model/InlineResponse20045Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Export; +import one.talon.model.Change; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,6 +51,14 @@ public void totalResultSizeTest() { // TODO: test totalResultSize } + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20046Test.java b/src/test/java/one/talon/model/InlineResponse20046Test.java index aa1d2dca..6b24dcad 100644 --- a/src/test/java/one/talon/model/InlineResponse20046Test.java +++ b/src/test/java/one/talon/model/InlineResponse20046Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.RoleV2; +import one.talon.model.Export; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20047Test.java b/src/test/java/one/talon/model/InlineResponse20047Test.java index 9edfe286..7120961b 100644 --- a/src/test/java/one/talon/model/InlineResponse20047Test.java +++ b/src/test/java/one/talon/model/InlineResponse20047Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Store; +import one.talon.model.RoleV2; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,14 +43,6 @@ public void testInlineResponse20047() { // TODO: test InlineResponse20047 } - /** - * Test the property 'hasMore' - */ - @Test - public void hasMoreTest() { - // TODO: test hasMore - } - /** * Test the property 'totalResultSize' */ diff --git a/src/test/java/one/talon/model/InlineResponse20048Test.java b/src/test/java/one/talon/model/InlineResponse20048Test.java index 3408d0cd..5ce48035 100644 --- a/src/test/java/one/talon/model/InlineResponse20048Test.java +++ b/src/test/java/one/talon/model/InlineResponse20048Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ApplicationCIF; +import one.talon.model.Store; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -51,6 +51,14 @@ public void hasMoreTest() { // TODO: test hasMore } + /** + * Test the property 'totalResultSize' + */ + @Test + public void totalResultSizeTest() { + // TODO: test totalResultSize + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20049Test.java b/src/test/java/one/talon/model/InlineResponse20049Test.java index 93c87b5a..69f6d445 100644 --- a/src/test/java/one/talon/model/InlineResponse20049Test.java +++ b/src/test/java/one/talon/model/InlineResponse20049Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ListCampaignStoreBudgets; +import one.talon.model.ApplicationCIF; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,6 +43,14 @@ public void testInlineResponse20049() { // TODO: test InlineResponse20049 } + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20050Test.java b/src/test/java/one/talon/model/InlineResponse20050Test.java index f67b8ead..6eacca13 100644 --- a/src/test/java/one/talon/model/InlineResponse20050Test.java +++ b/src/test/java/one/talon/model/InlineResponse20050Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.SummaryCampaignStoreBudget; +import one.talon.model.ListCampaignStoreBudgets; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20051Test.java b/src/test/java/one/talon/model/InlineResponse20051Test.java index 989a24ba..614f512d 100644 --- a/src/test/java/one/talon/model/InlineResponse20051Test.java +++ b/src/test/java/one/talon/model/InlineResponse20051Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Achievement; +import one.talon.model.SummaryCampaignStoreBudget; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,14 +43,6 @@ public void testInlineResponse20051() { // TODO: test InlineResponse20051 } - /** - * Test the property 'hasMore' - */ - @Test - public void hasMoreTest() { - // TODO: test hasMore - } - /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20052Test.java b/src/test/java/one/talon/model/InlineResponse20052Test.java index 24c2745a..d1db9459 100644 --- a/src/test/java/one/talon/model/InlineResponse20052Test.java +++ b/src/test/java/one/talon/model/InlineResponse20052Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.AchievementProgressWithDefinition; +import one.talon.model.Achievement; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/src/test/java/one/talon/model/InlineResponse20053Test.java b/src/test/java/one/talon/model/InlineResponse20053Test.java index 4dcdd850..3f02ed8d 100644 --- a/src/test/java/one/talon/model/InlineResponse20053Test.java +++ b/src/test/java/one/talon/model/InlineResponse20053Test.java @@ -23,7 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.CouponFailureSummary; +import one.talon.model.AchievementV2; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -43,6 +43,14 @@ public void testInlineResponse20053() { // TODO: test InlineResponse20053 } + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + /** * Test the property 'data' */ diff --git a/src/test/java/one/talon/model/InlineResponse20054Test.java b/src/test/java/one/talon/model/InlineResponse20054Test.java new file mode 100644 index 00000000..882f4f30 --- /dev/null +++ b/src/test/java/one/talon/model/InlineResponse20054Test.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.AchievementProgressWithDefinition; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for InlineResponse20054 + */ +public class InlineResponse20054Test { + private final InlineResponse20054 model = new InlineResponse20054(); + + /** + * Model tests for InlineResponse20054 + */ + @Test + public void testInlineResponse20054() { + // TODO: test InlineResponse20054 + } + + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/InlineResponse20055Test.java b/src/test/java/one/talon/model/InlineResponse20055Test.java new file mode 100644 index 00000000..c8c83b09 --- /dev/null +++ b/src/test/java/one/talon/model/InlineResponse20055Test.java @@ -0,0 +1,54 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CouponFailureSummary; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for InlineResponse20055 + */ +public class InlineResponse20055Test { + private final InlineResponse20055 model = new InlineResponse20055(); + + /** + * Model tests for InlineResponse20055 + */ + @Test + public void testInlineResponse20055() { + // TODO: test InlineResponse20055 + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/InlineResponse20056CatalogTest.java b/src/test/java/one/talon/model/InlineResponse20056CatalogTest.java new file mode 100644 index 00000000..9c7f80e2 --- /dev/null +++ b/src/test/java/one/talon/model/InlineResponse20056CatalogTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardCatalogItem; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for InlineResponse20056Catalog + */ +public class InlineResponse20056CatalogTest { + private final InlineResponse20056Catalog model = new InlineResponse20056Catalog(); + + /** + * Model tests for InlineResponse20056Catalog + */ + @Test + public void testInlineResponse20056Catalog() { + // TODO: test InlineResponse20056Catalog + } + + /** + * Test the property 'hasMore' + */ + @Test + public void hasMoreTest() { + // TODO: test hasMore + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/InlineResponse20056Test.java b/src/test/java/one/talon/model/InlineResponse20056Test.java new file mode 100644 index 00000000..c80ad647 --- /dev/null +++ b/src/test/java/one/talon/model/InlineResponse20056Test.java @@ -0,0 +1,64 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.InlineResponse20056Catalog; +import one.talon.model.LoyaltyBalances; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for InlineResponse20056 + */ +public class InlineResponse20056Test { + private final InlineResponse20056 model = new InlineResponse20056(); + + /** + * Model tests for InlineResponse20056 + */ + @Test + public void testInlineResponse20056() { + // TODO: test InlineResponse20056 + } + + /** + * Test the property 'catalog' + */ + @Test + public void catalogTest() { + // TODO: test catalog + } + + /** + * Test the property 'loyalty' + */ + @Test + public void loyaltyTest() { + // TODO: test loyalty + } + +} diff --git a/src/test/java/one/talon/model/IntegrationCampaignBaseTest.java b/src/test/java/one/talon/model/IntegrationCampaignBaseTest.java new file mode 100644 index 00000000..95e3c695 --- /dev/null +++ b/src/test/java/one/talon/model/IntegrationCampaignBaseTest.java @@ -0,0 +1,126 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for IntegrationCampaignBase + */ +public class IntegrationCampaignBaseTest { + private final IntegrationCampaignBase model = new IntegrationCampaignBase(); + + /** + * Model tests for IntegrationCampaignBase + */ + @Test + public void testIntegrationCampaignBase() { + // TODO: test IntegrationCampaignBase + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'startTime' + */ + @Test + public void startTimeTest() { + // TODO: test startTime + } + + /** + * Test the property 'endTime' + */ + @Test + public void endTimeTest() { + // TODO: test endTime + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'state' + */ + @Test + public void stateTest() { + // TODO: test state + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'features' + */ + @Test + public void featuresTest() { + // TODO: test features + } + +} diff --git a/src/test/java/one/talon/model/IntegrationCampaignTest.java b/src/test/java/one/talon/model/IntegrationCampaignTest.java index 73760978..e77bef0c 100644 --- a/src/test/java/one/talon/model/IntegrationCampaignTest.java +++ b/src/test/java/one/talon/model/IntegrationCampaignTest.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.RuleMetadata; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -44,19 +45,19 @@ public void testIntegrationCampaign() { } /** - * Test the property 'id' + * Test the property 'applicationId' */ @Test - public void idTest() { - // TODO: test id + public void applicationIdTest() { + // TODO: test applicationId } /** - * Test the property 'applicationId' + * Test the property 'id' */ @Test - public void applicationIdTest() { - // TODO: test applicationId + public void idTest() { + // TODO: test id } /** @@ -123,4 +124,28 @@ public void featuresTest() { // TODO: test features } + /** + * Test the property 'rules' + */ + @Test + public void rulesTest() { + // TODO: test rules + } + + /** + * Test the property 'linkedStoreIds' + */ + @Test + public void linkedStoreIdsTest() { + // TODO: test linkedStoreIds + } + + /** + * Test the property 'linkedAudienceIds' + */ + @Test + public void linkedAudienceIdsTest() { + // TODO: test linkedAudienceIds + } + } diff --git a/src/test/java/one/talon/model/IntegrationEventV2ResponseTest.java b/src/test/java/one/talon/model/IntegrationEventV2ResponseTest.java index 2ef88383..612d3249 100644 --- a/src/test/java/one/talon/model/IntegrationEventV2ResponseTest.java +++ b/src/test/java/one/talon/model/IntegrationEventV2ResponseTest.java @@ -24,13 +24,16 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.Event; import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; import org.junit.Assert; import org.junit.Ignore; @@ -75,6 +78,14 @@ public void triggeredCampaignsTest() { // TODO: test triggeredCampaigns } + /** + * Test the property 'campaignEligibility' + */ + @Test + public void campaignEligibilityTest() { + // TODO: test campaignEligibility + } + /** * Test the property 'effects' */ @@ -115,6 +126,22 @@ public void awardedGiveawaysTest() { // TODO: test awardedGiveaways } + /** + * Test the property 'achievements' + */ + @Test + public void achievementsTest() { + // TODO: test achievements + } + + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + /** * Test the property 'event' */ diff --git a/src/test/java/one/talon/model/IntegrationEventV3RequestTest.java b/src/test/java/one/talon/model/IntegrationEventV3RequestTest.java index 59cdfc7f..d4b4c01d 100644 --- a/src/test/java/one/talon/model/IntegrationEventV3RequestTest.java +++ b/src/test/java/one/talon/model/IntegrationEventV3RequestTest.java @@ -66,14 +66,6 @@ public void evaluableCampaignIdsTest() { // TODO: test evaluableCampaignIds } - /** - * Test the property 'integrationId' - */ - @Test - public void integrationIdTest() { - // TODO: test integrationId - } - /** * Test the property 'type' */ @@ -91,19 +83,27 @@ public void attributesTest() { } /** - * Test the property 'connectedSessionID' + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'connectedSessionId' */ @Test - public void connectedSessionIDTest() { - // TODO: test connectedSessionID + public void connectedSessionIdTest() { + // TODO: test connectedSessionId } /** - * Test the property 'previousEventID' + * Test the property 'referralCode' */ @Test - public void previousEventIDTest() { - // TODO: test previousEventID + public void referralCodeTest() { + // TODO: test referralCode } /** diff --git a/src/test/java/one/talon/model/IntegrationEventV3ResponseTest.java b/src/test/java/one/talon/model/IntegrationEventV3ResponseTest.java index 77dc71b2..167881fe 100644 --- a/src/test/java/one/talon/model/IntegrationEventV3ResponseTest.java +++ b/src/test/java/one/talon/model/IntegrationEventV3ResponseTest.java @@ -24,13 +24,17 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.EventV3; import one.talon.model.Giveaway; +import one.talon.model.InventoryReferral; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; import org.junit.Assert; import org.junit.Ignore; @@ -75,6 +79,14 @@ public void triggeredCampaignsTest() { // TODO: test triggeredCampaigns } + /** + * Test the property 'campaignEligibility' + */ + @Test + public void campaignEligibilityTest() { + // TODO: test campaignEligibility + } + /** * Test the property 'effects' */ @@ -115,6 +127,22 @@ public void awardedGiveawaysTest() { // TODO: test awardedGiveaways } + /** + * Test the property 'achievements' + */ + @Test + public void achievementsTest() { + // TODO: test achievements + } + + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + /** * Test the property 'advancedEvent' */ @@ -123,4 +151,12 @@ public void advancedEventTest() { // TODO: test advancedEvent } + /** + * Test the property 'referral' + */ + @Test + public void referralTest() { + // TODO: test referral + } + } diff --git a/src/test/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotificationsTest.java b/src/test/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotificationsTest.java index ad15f513..c7e7973a 100644 --- a/src/test/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotificationsTest.java +++ b/src/test/java/one/talon/model/IntegrationHubEventPayloadCouponBasedNotificationsTest.java @@ -44,6 +44,14 @@ public void testIntegrationHubEventPayloadCouponBasedNotifications() { // TODO: test IntegrationHubEventPayloadCouponBasedNotifications } + /** + * Test the property 'eventId' + */ + @Test + public void eventIdTest() { + // TODO: test eventId + } + /** * Test the property 'id' */ diff --git a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationTest.java b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationTest.java index d89f21a7..f93c6c6f 100644 --- a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationTest.java +++ b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotificationTest.java @@ -44,6 +44,14 @@ public void testIntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotifi // TODO: test IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification } + /** + * Test the property 'eventId' + */ + @Test + public void eventIdTest() { + // TODO: test eventId + } + /** * Test the property 'profileIntegrationID' */ @@ -60,6 +68,14 @@ public void loyaltyProgramIDTest() { // TODO: test loyaltyProgramID } + /** + * Test the property 'loyaltyProgramName' + */ + @Test + public void loyaltyProgramNameTest() { + // TODO: test loyaltyProgramName + } + /** * Test the property 'subledgerID' */ @@ -76,6 +92,22 @@ public void sourceOfEventTest() { // TODO: test sourceOfEvent } + /** + * Test the property 'currentTier' + */ + @Test + public void currentTierTest() { + // TODO: test currentTier + } + + /** + * Test the property 'sessionIntegrationID' + */ + @Test + public void sessionIntegrationIDTest() { + // TODO: test sessionIntegrationID + } + /** * Test the property 'employeeName' */ diff --git a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificationTest.java b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificationTest.java index 20ed8504..004e21ca 100644 --- a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificationTest.java +++ b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotificationTest.java @@ -41,6 +41,14 @@ public void testIntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotifi // TODO: test IntegrationHubEventPayloadLoyaltyProfileBasedTierDowngradeNotification } + /** + * Test the property 'eventId' + */ + @Test + public void eventIdTest() { + // TODO: test eventId + } + /** * Test the property 'profileIntegrationID' */ @@ -57,6 +65,14 @@ public void loyaltyProgramIDTest() { // TODO: test loyaltyProgramID } + /** + * Test the property 'loyaltyProgramName' + */ + @Test + public void loyaltyProgramNameTest() { + // TODO: test loyaltyProgramName + } + /** * Test the property 'subledgerID' */ diff --git a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificationTest.java b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificationTest.java index a9e844de..4ee459b6 100644 --- a/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificationTest.java +++ b/src/test/java/one/talon/model/IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotificationTest.java @@ -41,6 +41,14 @@ public void testIntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotifica // TODO: test IntegrationHubEventPayloadLoyaltyProfileBasedTierUpgradeNotification } + /** + * Test the property 'eventId' + */ + @Test + public void eventIdTest() { + // TODO: test eventId + } + /** * Test the property 'profileIntegrationID' */ @@ -57,6 +65,14 @@ public void loyaltyProgramIDTest() { // TODO: test loyaltyProgramID } + /** + * Test the property 'loyaltyProgramName' + */ + @Test + public void loyaltyProgramNameTest() { + // TODO: test loyaltyProgramName + } + /** * Test the property 'subledgerID' */ diff --git a/src/test/java/one/talon/model/IntegrationHubEventRecordTest.java b/src/test/java/one/talon/model/IntegrationHubEventRecordTest.java index f6d70aa7..28050084 100644 --- a/src/test/java/one/talon/model/IntegrationHubEventRecordTest.java +++ b/src/test/java/one/talon/model/IntegrationHubEventRecordTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -58,19 +59,27 @@ public void flowIdTest() { } /** - * Test the property 'eventType' + * Test the property 'integrationName' */ @Test - public void eventTypeTest() { - // TODO: test eventType + public void integrationNameTest() { + // TODO: test integrationName } /** - * Test the property 'eventData' + * Test the property 'instanceName' */ @Test - public void eventDataTest() { - // TODO: test eventData + public void instanceNameTest() { + // TODO: test instanceName + } + + /** + * Test the property 'eventType' + */ + @Test + public void eventTypeTest() { + // TODO: test eventType } /** @@ -90,11 +99,19 @@ public void processedAtTest() { } /** - * Test the property 'processAfter' + * Test the property 'deliveredAt' */ @Test - public void processAfterTest() { - // TODO: test processAfter + public void deliveredAtTest() { + // TODO: test deliveredAt + } + + /** + * Test the property 'scheduledTo' + */ + @Test + public void scheduledToTest() { + // TODO: test scheduledTo } /** @@ -105,4 +122,12 @@ public void retryTest() { // TODO: test retry } + /** + * Test the property 'payload' + */ + @Test + public void payloadTest() { + // TODO: test payload + } + } diff --git a/src/test/java/one/talon/model/IntegrationHubEventStatusUpdateTest.java b/src/test/java/one/talon/model/IntegrationHubEventStatusUpdateTest.java new file mode 100644 index 00000000..a2c0816b --- /dev/null +++ b/src/test/java/one/talon/model/IntegrationHubEventStatusUpdateTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for IntegrationHubEventStatusUpdate + */ +public class IntegrationHubEventStatusUpdateTest { + private final IntegrationHubEventStatusUpdate model = new IntegrationHubEventStatusUpdate(); + + /** + * Model tests for IntegrationHubEventStatusUpdate + */ + @Test + public void testIntegrationHubEventStatusUpdate() { + // TODO: test IntegrationHubEventStatusUpdate + } + + /** + * Test the property 'eventId' + */ + @Test + public void eventIdTest() { + // TODO: test eventId + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + +} diff --git a/src/test/java/one/talon/model/IntegrationHubEventTypeTest.java b/src/test/java/one/talon/model/IntegrationHubEventTypeTest.java new file mode 100644 index 00000000..845a6302 --- /dev/null +++ b/src/test/java/one/talon/model/IntegrationHubEventTypeTest.java @@ -0,0 +1,35 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import io.swagger.annotations.ApiModel; +import com.google.gson.annotations.SerializedName; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for IntegrationHubEventType + */ +public class IntegrationHubEventTypeTest { + /** + * Model tests for IntegrationHubEventType + */ + @Test + public void testIntegrationHubEventType() { + // TODO: test IntegrationHubEventType + } + +} diff --git a/src/test/java/one/talon/model/IntegrationHubFlowConfigTest.java b/src/test/java/one/talon/model/IntegrationHubFlowConfigTest.java index 1f33c9ef..c1643207 100644 --- a/src/test/java/one/talon/model/IntegrationHubFlowConfigTest.java +++ b/src/test/java/one/talon/model/IntegrationHubFlowConfigTest.java @@ -72,4 +72,20 @@ public void maxRetriesTest() { // TODO: test maxRetries } + /** + * Test the property 'instanceName' + */ + @Test + public void instanceNameTest() { + // TODO: test instanceName + } + + /** + * Test the property 'integrationName' + */ + @Test + public void integrationNameTest() { + // TODO: test integrationName + } + } diff --git a/src/test/java/one/talon/model/IntegrationHubFlowResponseTest.java b/src/test/java/one/talon/model/IntegrationHubFlowResponseTest.java index fda43f44..8dffae04 100644 --- a/src/test/java/one/talon/model/IntegrationHubFlowResponseTest.java +++ b/src/test/java/one/talon/model/IntegrationHubFlowResponseTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import one.talon.model.IntegrationHubFlowConfigResponse; +import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -50,27 +51,59 @@ public void idTest() { } /** - * Test the property 'applicationID' + * Test the property 'integrationName' */ @Test - public void applicationIDTest() { - // TODO: test applicationID + public void integrationNameTest() { + // TODO: test integrationName } /** - * Test the property 'eventType' + * Test the property 'instanceName' */ @Test - public void eventTypeTest() { - // TODO: test eventType + public void instanceNameTest() { + // TODO: test instanceName + } + + /** + * Test the property 'createdAt' + */ + @Test + public void createdAtTest() { + // TODO: test createdAt + } + + /** + * Test the property 'disabledUntil' + */ + @Test + public void disabledUntilTest() { + // TODO: test disabledUntil } /** - * Test the property 'integrationHubFlowUrl' + * Test the property 'applicationId' */ @Test - public void integrationHubFlowUrlTest() { - // TODO: test integrationHubFlowUrl + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'eventType' + */ + @Test + public void eventTypeTest() { + // TODO: test eventType } /** diff --git a/src/test/java/one/talon/model/IntegrationHubFlowTest.java b/src/test/java/one/talon/model/IntegrationHubFlowTest.java index 64ce3b30..67dc6814 100644 --- a/src/test/java/one/talon/model/IntegrationHubFlowTest.java +++ b/src/test/java/one/talon/model/IntegrationHubFlowTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -48,6 +49,14 @@ public void applicationIDTest() { // TODO: test applicationID } + /** + * Test the property 'loyaltyProgramID' + */ + @Test + public void loyaltyProgramIDTest() { + // TODO: test loyaltyProgramID + } + /** * Test the property 'eventType' */ diff --git a/src/test/java/one/talon/model/IntegrationHubFlowWithConfigTest.java b/src/test/java/one/talon/model/IntegrationHubFlowWithConfigTest.java index 485cf568..fa833650 100644 --- a/src/test/java/one/talon/model/IntegrationHubFlowWithConfigTest.java +++ b/src/test/java/one/talon/model/IntegrationHubFlowWithConfigTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import one.talon.model.IntegrationHubEventType; import one.talon.model.IntegrationHubFlowConfig; import org.junit.Assert; import org.junit.Ignore; @@ -49,6 +50,14 @@ public void applicationIDTest() { // TODO: test applicationID } + /** + * Test the property 'loyaltyProgramID' + */ + @Test + public void loyaltyProgramIDTest() { + // TODO: test loyaltyProgramID + } + /** * Test the property 'eventType' */ diff --git a/src/test/java/one/talon/model/IntegrationHubInstanceTest.java b/src/test/java/one/talon/model/IntegrationHubInstanceTest.java new file mode 100644 index 00000000..08cc2255 --- /dev/null +++ b/src/test/java/one/talon/model/IntegrationHubInstanceTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for IntegrationHubInstance + */ +public class IntegrationHubInstanceTest { + private final IntegrationHubInstance model = new IntegrationHubInstance(); + + /** + * Model tests for IntegrationHubInstance + */ + @Test + public void testIntegrationHubInstance() { + // TODO: test IntegrationHubInstance + } + + /** + * Test the property 'instanceId' + */ + @Test + public void instanceIdTest() { + // TODO: test instanceId + } + + /** + * Test the property 'instanceName' + */ + @Test + public void instanceNameTest() { + // TODO: test instanceName + } + +} diff --git a/src/test/java/one/talon/model/IntegrationHubPaginatedEventPayloadTest.java b/src/test/java/one/talon/model/IntegrationHubPaginatedEventPayloadTest.java index 6eabdde0..71354b54 100644 --- a/src/test/java/one/talon/model/IntegrationHubPaginatedEventPayloadTest.java +++ b/src/test/java/one/talon/model/IntegrationHubPaginatedEventPayloadTest.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.IntegrationHubEventType; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/src/test/java/one/talon/model/IntegrationResponseTest.java b/src/test/java/one/talon/model/IntegrationResponseTest.java index d88eb550..7507567b 100644 --- a/src/test/java/one/talon/model/IntegrationResponseTest.java +++ b/src/test/java/one/talon/model/IntegrationResponseTest.java @@ -24,12 +24,15 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.Effect; import one.talon.model.Giveaway; import one.talon.model.Loyalty; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; import org.junit.Assert; import org.junit.Ignore; @@ -74,6 +77,14 @@ public void triggeredCampaignsTest() { // TODO: test triggeredCampaigns } + /** + * Test the property 'campaignEligibility' + */ + @Test + public void campaignEligibilityTest() { + // TODO: test campaignEligibility + } + /** * Test the property 'effects' */ @@ -114,4 +125,20 @@ public void awardedGiveawaysTest() { // TODO: test awardedGiveaways } + /** + * Test the property 'achievements' + */ + @Test + public void achievementsTest() { + // TODO: test achievements + } + + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + } diff --git a/src/test/java/one/talon/model/IntegrationStateV2Test.java b/src/test/java/one/talon/model/IntegrationStateV2Test.java index 4f01a8b1..143eacb2 100644 --- a/src/test/java/one/talon/model/IntegrationStateV2Test.java +++ b/src/test/java/one/talon/model/IntegrationStateV2Test.java @@ -24,7 +24,9 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.Campaign; +import one.talon.model.CampaignEligibility; import one.talon.model.Coupon; +import one.talon.model.CustomerAchievement; import one.talon.model.CustomerProfile; import one.talon.model.CustomerSessionV2; import one.talon.model.Effect; @@ -36,6 +38,7 @@ import one.talon.model.Loyalty; import one.talon.model.ModelReturn; import one.talon.model.Referral; +import one.talon.model.RewardWithUnlocks; import one.talon.model.RuleFailureReason; import org.junit.Assert; import org.junit.Ignore; @@ -80,6 +83,14 @@ public void triggeredCampaignsTest() { // TODO: test triggeredCampaigns } + /** + * Test the property 'campaignEligibility' + */ + @Test + public void campaignEligibilityTest() { + // TODO: test campaignEligibility + } + /** * Test the property 'effects' */ @@ -120,6 +131,22 @@ public void awardedGiveawaysTest() { // TODO: test awardedGiveaways } + /** + * Test the property 'achievements' + */ + @Test + public void achievementsTest() { + // TODO: test achievements + } + + /** + * Test the property 'rewards' + */ + @Test + public void rewardsTest() { + // TODO: test rewards + } + /** * Test the property 'referral' */ diff --git a/src/test/java/one/talon/model/IntegrationUnlockRewardRequestTest.java b/src/test/java/one/talon/model/IntegrationUnlockRewardRequestTest.java new file mode 100644 index 00000000..df80a61e --- /dev/null +++ b/src/test/java/one/talon/model/IntegrationUnlockRewardRequestTest.java @@ -0,0 +1,93 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for IntegrationUnlockRewardRequest + */ +public class IntegrationUnlockRewardRequestTest { + private final IntegrationUnlockRewardRequest model = new IntegrationUnlockRewardRequest(); + + /** + * Model tests for IntegrationUnlockRewardRequest + */ + @Test + public void testIntegrationUnlockRewardRequest() { + // TODO: test IntegrationUnlockRewardRequest + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'profileIntegrationId' + */ + @Test + public void profileIntegrationIdTest() { + // TODO: test profileIntegrationId + } + + /** + * Test the property 'cardIdentifier' + */ + @Test + public void cardIdentifierTest() { + // TODO: test cardIdentifier + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'subledgerId' + */ + @Test + public void subledgerIdTest() { + // TODO: test subledgerId + } + + /** + * Test the property 'responseContent' + */ + @Test + public void responseContentTest() { + // TODO: test responseContent + } + +} diff --git a/src/test/java/one/talon/model/JoinLoyaltyProgramEffectPropsTest.java b/src/test/java/one/talon/model/JoinLoyaltyProgramEffectPropsTest.java new file mode 100644 index 00000000..3164d667 --- /dev/null +++ b/src/test/java/one/talon/model/JoinLoyaltyProgramEffectPropsTest.java @@ -0,0 +1,60 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for JoinLoyaltyProgramEffectProps + */ +public class JoinLoyaltyProgramEffectPropsTest { + private final JoinLoyaltyProgramEffectProps model = new JoinLoyaltyProgramEffectProps(); + + /** + * Model tests for JoinLoyaltyProgramEffectProps + */ + @Test + public void testJoinLoyaltyProgramEffectProps() { + // TODO: test JoinLoyaltyProgramEffectProps + } + + /** + * Test the property 'programId' + */ + @Test + public void programIdTest() { + // TODO: test programId + } + + /** + * Test the property 'joinDate' + */ + @Test + public void joinDateTest() { + // TODO: test joinDate + } + +} diff --git a/src/test/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPITest.java b/src/test/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPITest.java index bbe35a9e..da7b5cf0 100644 --- a/src/test/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPITest.java +++ b/src/test/java/one/talon/model/LedgerTransactionLogEntryIntegrationAPITest.java @@ -75,6 +75,14 @@ public void customerSessionIdTest() { // TODO: test customerSessionId } + /** + * Test the property 'storeIntegrationId' + */ + @Test + public void storeIntegrationIdTest() { + // TODO: test storeIntegrationId + } + /** * Test the property 'type' */ diff --git a/src/test/java/one/talon/model/ListCheckAttributeBlockTest.java b/src/test/java/one/talon/model/ListCheckAttributeBlockTest.java new file mode 100644 index 00000000..141fa1a8 --- /dev/null +++ b/src/test/java/one/talon/model/ListCheckAttributeBlockTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ListCheckAttributeBlock + */ +public class ListCheckAttributeBlockTest { + private final ListCheckAttributeBlock model = new ListCheckAttributeBlock(); + + /** + * Model tests for ListCheckAttributeBlock + */ + @Test + public void testListCheckAttributeBlock() { + // TODO: test ListCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'values' + */ + @Test + public void valuesTest() { + // TODO: test values + } + +} diff --git a/src/test/java/one/talon/model/ListWithCountCheckAttributeBlockTest.java b/src/test/java/one/talon/model/ListWithCountCheckAttributeBlockTest.java new file mode 100644 index 00000000..185a2fdb --- /dev/null +++ b/src/test/java/one/talon/model/ListWithCountCheckAttributeBlockTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ListWithCountCheckAttributeBlock + */ +public class ListWithCountCheckAttributeBlockTest { + private final ListWithCountCheckAttributeBlock model = new ListWithCountCheckAttributeBlock(); + + /** + * Model tests for ListWithCountCheckAttributeBlock + */ + @Test + public void testListWithCountCheckAttributeBlock() { + // TODO: test ListWithCountCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'values' + */ + @Test + public void valuesTest() { + // TODO: test values + } + + /** + * Test the property 'count' + */ + @Test + public void countTest() { + // TODO: test count + } + +} diff --git a/src/test/java/one/talon/model/LocationCheckAttributeBlockTest.java b/src/test/java/one/talon/model/LocationCheckAttributeBlockTest.java new file mode 100644 index 00000000..386197f0 --- /dev/null +++ b/src/test/java/one/talon/model/LocationCheckAttributeBlockTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for LocationCheckAttributeBlock + */ +public class LocationCheckAttributeBlockTest { + private final LocationCheckAttributeBlock model = new LocationCheckAttributeBlock(); + + /** + * Model tests for LocationCheckAttributeBlock + */ + @Test + public void testLocationCheckAttributeBlock() { + // TODO: test LocationCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'values' + */ + @Test + public void valuesTest() { + // TODO: test values + } + +} diff --git a/src/test/java/one/talon/model/MCPCompleteOAuthSessionTest.java b/src/test/java/one/talon/model/MCPCompleteOAuthSessionTest.java new file mode 100644 index 00000000..5e809dc3 --- /dev/null +++ b/src/test/java/one/talon/model/MCPCompleteOAuthSessionTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPCompleteOAuthSession + */ +public class MCPCompleteOAuthSessionTest { + private final MCPCompleteOAuthSession model = new MCPCompleteOAuthSession(); + + /** + * Model tests for MCPCompleteOAuthSession + */ + @Test + public void testMCPCompleteOAuthSession() { + // TODO: test MCPCompleteOAuthSession + } + + /** + * Test the property 'sessionId' + */ + @Test + public void sessionIdTest() { + // TODO: test sessionId + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthClientTest.java b/src/test/java/one/talon/model/MCPOAuthClientTest.java new file mode 100644 index 00000000..c857e0e2 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthClientTest.java @@ -0,0 +1,78 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthClient + */ +public class MCPOAuthClientTest { + private final MCPOAuthClient model = new MCPOAuthClient(); + + /** + * Model tests for MCPOAuthClient + */ + @Test + public void testMCPOAuthClient() { + // TODO: test MCPOAuthClient + } + + /** + * Test the property 'clientId' + */ + @Test + public void clientIdTest() { + // TODO: test clientId + } + + /** + * Test the property 'clientName' + */ + @Test + public void clientNameTest() { + // TODO: test clientName + } + + /** + * Test the property 'redirectUris' + */ + @Test + public void redirectUrisTest() { + // TODO: test redirectUris + } + + /** + * Test the property 'createdAt' + */ + @Test + public void createdAtTest() { + // TODO: test createdAt + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthCompleteResultTest.java b/src/test/java/one/talon/model/MCPOAuthCompleteResultTest.java new file mode 100644 index 00000000..e63a7802 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthCompleteResultTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthCompleteResult + */ +public class MCPOAuthCompleteResultTest { + private final MCPOAuthCompleteResult model = new MCPOAuthCompleteResult(); + + /** + * Model tests for MCPOAuthCompleteResult + */ + @Test + public void testMCPOAuthCompleteResult() { + // TODO: test MCPOAuthCompleteResult + } + + /** + * Test the property 'redirectUrl' + */ + @Test + public void redirectUrlTest() { + // TODO: test redirectUrl + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthProtectedResourceTest.java b/src/test/java/one/talon/model/MCPOAuthProtectedResourceTest.java new file mode 100644 index 00000000..aedb15e5 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthProtectedResourceTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthProtectedResource + */ +public class MCPOAuthProtectedResourceTest { + private final MCPOAuthProtectedResource model = new MCPOAuthProtectedResource(); + + /** + * Model tests for MCPOAuthProtectedResource + */ + @Test + public void testMCPOAuthProtectedResource() { + // TODO: test MCPOAuthProtectedResource + } + + /** + * Test the property 'resource' + */ + @Test + public void resourceTest() { + // TODO: test resource + } + + /** + * Test the property 'authorizationServers' + */ + @Test + public void authorizationServersTest() { + // TODO: test authorizationServers + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthServerMetadataTest.java b/src/test/java/one/talon/model/MCPOAuthServerMetadataTest.java new file mode 100644 index 00000000..c5e5e2d7 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthServerMetadataTest.java @@ -0,0 +1,101 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthServerMetadata + */ +public class MCPOAuthServerMetadataTest { + private final MCPOAuthServerMetadata model = new MCPOAuthServerMetadata(); + + /** + * Model tests for MCPOAuthServerMetadata + */ + @Test + public void testMCPOAuthServerMetadata() { + // TODO: test MCPOAuthServerMetadata + } + + /** + * Test the property 'issuer' + */ + @Test + public void issuerTest() { + // TODO: test issuer + } + + /** + * Test the property 'authorizationEndpoint' + */ + @Test + public void authorizationEndpointTest() { + // TODO: test authorizationEndpoint + } + + /** + * Test the property 'tokenEndpoint' + */ + @Test + public void tokenEndpointTest() { + // TODO: test tokenEndpoint + } + + /** + * Test the property 'registrationEndpoint' + */ + @Test + public void registrationEndpointTest() { + // TODO: test registrationEndpoint + } + + /** + * Test the property 'responseTypesSupported' + */ + @Test + public void responseTypesSupportedTest() { + // TODO: test responseTypesSupported + } + + /** + * Test the property 'grantTypesSupported' + */ + @Test + public void grantTypesSupportedTest() { + // TODO: test grantTypesSupported + } + + /** + * Test the property 'codeChallengeMethodsSupported' + */ + @Test + public void codeChallengeMethodsSupportedTest() { + // TODO: test codeChallengeMethodsSupported + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthSessionInfoTest.java b/src/test/java/one/talon/model/MCPOAuthSessionInfoTest.java new file mode 100644 index 00000000..33c694f0 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthSessionInfoTest.java @@ -0,0 +1,69 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.MCPOAuthClient; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthSessionInfo + */ +public class MCPOAuthSessionInfoTest { + private final MCPOAuthSessionInfo model = new MCPOAuthSessionInfo(); + + /** + * Model tests for MCPOAuthSessionInfo + */ + @Test + public void testMCPOAuthSessionInfo() { + // TODO: test MCPOAuthSessionInfo + } + + /** + * Test the property 'sessionId' + */ + @Test + public void sessionIdTest() { + // TODO: test sessionId + } + + /** + * Test the property 'expiresAt' + */ + @Test + public void expiresAtTest() { + // TODO: test expiresAt + } + + /** + * Test the property 'client' + */ + @Test + public void clientTest() { + // TODO: test client + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthTokenErrorTest.java b/src/test/java/one/talon/model/MCPOAuthTokenErrorTest.java new file mode 100644 index 00000000..f88583f4 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthTokenErrorTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthTokenError + */ +public class MCPOAuthTokenErrorTest { + private final MCPOAuthTokenError model = new MCPOAuthTokenError(); + + /** + * Model tests for MCPOAuthTokenError + */ + @Test + public void testMCPOAuthTokenError() { + // TODO: test MCPOAuthTokenError + } + + /** + * Test the property 'error' + */ + @Test + public void errorTest() { + // TODO: test error + } + + /** + * Test the property 'errorDescription' + */ + @Test + public void errorDescriptionTest() { + // TODO: test errorDescription + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthTokenRequestTest.java b/src/test/java/one/talon/model/MCPOAuthTokenRequestTest.java new file mode 100644 index 00000000..1cebf4b6 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthTokenRequestTest.java @@ -0,0 +1,91 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthTokenRequest + */ +public class MCPOAuthTokenRequestTest { + private final MCPOAuthTokenRequest model = new MCPOAuthTokenRequest(); + + /** + * Model tests for MCPOAuthTokenRequest + */ + @Test + public void testMCPOAuthTokenRequest() { + // TODO: test MCPOAuthTokenRequest + } + + /** + * Test the property 'grantType' + */ + @Test + public void grantTypeTest() { + // TODO: test grantType + } + + /** + * Test the property 'code' + */ + @Test + public void codeTest() { + // TODO: test code + } + + /** + * Test the property 'clientId' + */ + @Test + public void clientIdTest() { + // TODO: test clientId + } + + /** + * Test the property 'redirectUri' + */ + @Test + public void redirectUriTest() { + // TODO: test redirectUri + } + + /** + * Test the property 'codeVerifier' + */ + @Test + public void codeVerifierTest() { + // TODO: test codeVerifier + } + + /** + * Test the property 'refreshToken' + */ + @Test + public void refreshTokenTest() { + // TODO: test refreshToken + } + +} diff --git a/src/test/java/one/talon/model/MCPOAuthTokenTest.java b/src/test/java/one/talon/model/MCPOAuthTokenTest.java new file mode 100644 index 00000000..31ed3ee6 --- /dev/null +++ b/src/test/java/one/talon/model/MCPOAuthTokenTest.java @@ -0,0 +1,83 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MCPOAuthToken + */ +public class MCPOAuthTokenTest { + private final MCPOAuthToken model = new MCPOAuthToken(); + + /** + * Model tests for MCPOAuthToken + */ + @Test + public void testMCPOAuthToken() { + // TODO: test MCPOAuthToken + } + + /** + * Test the property 'accessToken' + */ + @Test + public void accessTokenTest() { + // TODO: test accessToken + } + + /** + * Test the property 'tokenType' + */ + @Test + public void tokenTypeTest() { + // TODO: test tokenType + } + + /** + * Test the property 'expiresIn' + */ + @Test + public void expiresInTest() { + // TODO: test expiresIn + } + + /** + * Test the property 'refreshToken' + */ + @Test + public void refreshTokenTest() { + // TODO: test refreshToken + } + + /** + * Test the property 'refreshTokenExpiresIn' + */ + @Test + public void refreshTokenExpiresInTest() { + // TODO: test refreshTokenExpiresIn + } + +} diff --git a/src/test/java/one/talon/model/MapSelectorStepTest.java b/src/test/java/one/talon/model/MapSelectorStepTest.java new file mode 100644 index 00000000..f38b0f5e --- /dev/null +++ b/src/test/java/one/talon/model/MapSelectorStepTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for MapSelectorStep + */ +public class MapSelectorStepTest { + private final MapSelectorStep model = new MapSelectorStep(); + + /** + * Model tests for MapSelectorStep + */ + @Test + public void testMapSelectorStep() { + // TODO: test MapSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'expression' + */ + @Test + public void expressionTest() { + // TODO: test expression + } + +} diff --git a/src/test/java/one/talon/model/MultipleAudiencesItemTest.java b/src/test/java/one/talon/model/MultipleAudiencesItemTest.java index 18376627..4203c297 100644 --- a/src/test/java/one/talon/model/MultipleAudiencesItemTest.java +++ b/src/test/java/one/talon/model/MultipleAudiencesItemTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -65,6 +67,14 @@ public void nameTest() { // TODO: test name } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + /** * Test the property 'integrationId' */ diff --git a/src/test/java/one/talon/model/NewApplicationTest.java b/src/test/java/one/talon/model/NewApplicationTest.java index 8ec6275f..dc22ce6c 100644 --- a/src/test/java/one/talon/model/NewApplicationTest.java +++ b/src/test/java/one/talon/model/NewApplicationTest.java @@ -24,6 +24,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; import org.junit.Assert; import org.junit.Ignore; @@ -172,4 +173,12 @@ public void enableCampaignStateManagementTest() { // TODO: test enableCampaignStateManagement } + /** + * Test the property 'bestPriorPriceSettings' + */ + @Test + public void bestPriorPriceSettingsTest() { + // TODO: test bestPriorPriceSettings + } + } diff --git a/src/test/java/one/talon/model/NewAudienceTest.java b/src/test/java/one/talon/model/NewAudienceTest.java index 67b124d3..0dffc626 100644 --- a/src/test/java/one/talon/model/NewAudienceTest.java +++ b/src/test/java/one/talon/model/NewAudienceTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -65,6 +67,14 @@ public void descriptionTest() { // TODO: test description } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + /** * Test the property 'integration' */ diff --git a/src/test/java/one/talon/model/NewCouponsForMultipleRecipientsTest.java b/src/test/java/one/talon/model/NewCouponsForMultipleRecipientsTest.java index 82d678c0..cfc90d89 100644 --- a/src/test/java/one/talon/model/NewCouponsForMultipleRecipientsTest.java +++ b/src/test/java/one/talon/model/NewCouponsForMultipleRecipientsTest.java @@ -84,6 +84,14 @@ public void expiryDateTest() { // TODO: test expiryDate } + /** + * Test the property 'batchId' + */ + @Test + public void batchIdTest() { + // TODO: test batchId + } + /** * Test the property 'attributes' */ diff --git a/src/test/java/one/talon/model/NewCouponsTest.java b/src/test/java/one/talon/model/NewCouponsTest.java index 66e50d68..e729afaf 100644 --- a/src/test/java/one/talon/model/NewCouponsTest.java +++ b/src/test/java/one/talon/model/NewCouponsTest.java @@ -101,6 +101,14 @@ public void numberOfCouponsTest() { // TODO: test numberOfCoupons } + /** + * Test the property 'batchId' + */ + @Test + public void batchIdTest() { + // TODO: test batchId + } + /** * Test the property 'uniquePrefix' */ @@ -157,4 +165,20 @@ public void implicitlyReservedTest() { // TODO: test implicitlyReserved } + /** + * Test the property 'supportRequestId' + */ + @Test + public void supportRequestIdTest() { + // TODO: test supportRequestId + } + + /** + * Test the property 'supportRequestNote' + */ + @Test + public void supportRequestNoteTest() { + // TODO: test supportRequestNote + } + } diff --git a/src/test/java/one/talon/model/NewCustomerSessionV2Test.java b/src/test/java/one/talon/model/NewCustomerSessionV2Test.java index 2138a92c..0ba0fadf 100644 --- a/src/test/java/one/talon/model/NewCustomerSessionV2Test.java +++ b/src/test/java/one/talon/model/NewCustomerSessionV2Test.java @@ -95,6 +95,14 @@ public void loyaltyCardsTest() { // TODO: test loyaltyCards } + /** + * Test the property 'rewardIntegrationIds' + */ + @Test + public void rewardIntegrationIdsTest() { + // TODO: test rewardIntegrationIds + } + /** * Test the property 'state' */ diff --git a/src/test/java/one/talon/model/NewDigitalPassTest.java b/src/test/java/one/talon/model/NewDigitalPassTest.java new file mode 100644 index 00000000..9cd49854 --- /dev/null +++ b/src/test/java/one/talon/model/NewDigitalPassTest.java @@ -0,0 +1,94 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for NewDigitalPass + */ +public class NewDigitalPassTest { + private final NewDigitalPass model = new NewDigitalPass(); + + /** + * Model tests for NewDigitalPass + */ + @Test + public void testNewDigitalPass() { + // TODO: test NewDigitalPass + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'passTemplateId' + */ + @Test + public void passTemplateIdTest() { + // TODO: test passTemplateId + } + + /** + * Test the property 'profileId' + */ + @Test + public void profileIdTest() { + // TODO: test profileId + } + + /** + * Test the property 'loyaltyCardId' + */ + @Test + public void loyaltyCardIdTest() { + // TODO: test loyaltyCardId + } + + /** + * Test the property 'platform' + */ + @Test + public void platformTest() { + // TODO: test platform + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + +} diff --git a/src/test/java/one/talon/model/NewEventV3EntityTest.java b/src/test/java/one/talon/model/NewEventV3EntityTest.java new file mode 100644 index 00000000..e3d2694a --- /dev/null +++ b/src/test/java/one/talon/model/NewEventV3EntityTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for NewEventV3Entity + */ +public class NewEventV3EntityTest { + private final NewEventV3Entity model = new NewEventV3Entity(); + + /** + * Model tests for NewEventV3Entity + */ + @Test + public void testNewEventV3Entity() { + // TODO: test NewEventV3Entity + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + +} diff --git a/src/test/java/one/talon/model/NewExperimentTest.java b/src/test/java/one/talon/model/NewExperimentTest.java index 99078284..057d8b2c 100644 --- a/src/test/java/one/talon/model/NewExperimentTest.java +++ b/src/test/java/one/talon/model/NewExperimentTest.java @@ -57,4 +57,20 @@ public void campaignTest() { // TODO: test campaign } + /** + * Test the property 'goalType' + */ + @Test + public void goalTypeTest() { + // TODO: test goalType + } + + /** + * Test the property 'goalDescription' + */ + @Test + public void goalDescriptionTest() { + // TODO: test goalDescription + } + } diff --git a/src/test/java/one/talon/model/NewIntegrationHubCouponsTest.java b/src/test/java/one/talon/model/NewIntegrationHubCouponsTest.java new file mode 100644 index 00000000..b1558056 --- /dev/null +++ b/src/test/java/one/talon/model/NewIntegrationHubCouponsTest.java @@ -0,0 +1,192 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.LimitConfig; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for NewIntegrationHubCoupons + */ +public class NewIntegrationHubCouponsTest { + private final NewIntegrationHubCoupons model = new NewIntegrationHubCoupons(); + + /** + * Model tests for NewIntegrationHubCoupons + */ + @Test + public void testNewIntegrationHubCoupons() { + // TODO: test NewIntegrationHubCoupons + } + + /** + * Test the property 'usageLimit' + */ + @Test + public void usageLimitTest() { + // TODO: test usageLimit + } + + /** + * Test the property 'discountLimit' + */ + @Test + public void discountLimitTest() { + // TODO: test discountLimit + } + + /** + * Test the property 'reservationLimit' + */ + @Test + public void reservationLimitTest() { + // TODO: test reservationLimit + } + + /** + * Test the property 'startDate' + */ + @Test + public void startDateTest() { + // TODO: test startDate + } + + /** + * Test the property 'expiryDate' + */ + @Test + public void expiryDateTest() { + // TODO: test expiryDate + } + + /** + * Test the property 'limits' + */ + @Test + public void limitsTest() { + // TODO: test limits + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'batchId' + */ + @Test + public void batchIdTest() { + // TODO: test batchId + } + + /** + * Test the property 'numberOfCoupons' + */ + @Test + public void numberOfCouponsTest() { + // TODO: test numberOfCoupons + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'validCharacters' + */ + @Test + public void validCharactersTest() { + // TODO: test validCharacters + } + + /** + * Test the property 'couponPattern' + */ + @Test + public void couponPatternTest() { + // TODO: test couponPattern + } + + /** + * Test the property 'isReservationMandatory' + */ + @Test + public void isReservationMandatoryTest() { + // TODO: test isReservationMandatory + } + + /** + * Test the property 'implicitlyReserved' + */ + @Test + public void implicitlyReservedTest() { + // TODO: test implicitlyReserved + } + + /** + * Test the property 'recipientIntegrationId' + */ + @Test + public void recipientIntegrationIdTest() { + // TODO: test recipientIntegrationId + } + + /** + * Test the property 'supportRequestId' + */ + @Test + public void supportRequestIdTest() { + // TODO: test supportRequestId + } + + /** + * Test the property 'supportRequestNote' + */ + @Test + public void supportRequestNoteTest() { + // TODO: test supportRequestNote + } + +} diff --git a/src/test/java/one/talon/model/NewInternalAudienceTest.java b/src/test/java/one/talon/model/NewInternalAudienceTest.java index 2de4f390..e878ecdc 100644 --- a/src/test/java/one/talon/model/NewInternalAudienceTest.java +++ b/src/test/java/one/talon/model/NewInternalAudienceTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -64,4 +66,12 @@ public void descriptionTest() { // TODO: test description } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + } diff --git a/src/test/java/one/talon/model/NewMCPOAuthClientTest.java b/src/test/java/one/talon/model/NewMCPOAuthClientTest.java new file mode 100644 index 00000000..babc3b99 --- /dev/null +++ b/src/test/java/one/talon/model/NewMCPOAuthClientTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for NewMCPOAuthClient + */ +public class NewMCPOAuthClientTest { + private final NewMCPOAuthClient model = new NewMCPOAuthClient(); + + /** + * Model tests for NewMCPOAuthClient + */ + @Test + public void testNewMCPOAuthClient() { + // TODO: test NewMCPOAuthClient + } + + /** + * Test the property 'clientName' + */ + @Test + public void clientNameTest() { + // TODO: test clientName + } + + /** + * Test the property 'redirectUris' + */ + @Test + public void redirectUrisTest() { + // TODO: test redirectUris + } + +} diff --git a/src/test/java/one/talon/model/NewMultipleAudiencesItemTest.java b/src/test/java/one/talon/model/NewMultipleAudiencesItemTest.java index 8fc9c5c5..563919b0 100644 --- a/src/test/java/one/talon/model/NewMultipleAudiencesItemTest.java +++ b/src/test/java/one/talon/model/NewMultipleAudiencesItemTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -48,6 +50,14 @@ public void nameTest() { // TODO: test name } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + /** * Test the property 'integrationId' */ diff --git a/src/test/java/one/talon/model/NewRewardTest.java b/src/test/java/one/talon/model/NewRewardTest.java index af97711f..8c59f840 100644 --- a/src/test/java/one/talon/model/NewRewardTest.java +++ b/src/test/java/one/talon/model/NewRewardTest.java @@ -23,6 +23,9 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -82,4 +85,36 @@ public void sandboxTest() { // TODO: test sandbox } + /** + * Test the property 'eligibilityConditions' + */ + @Test + public void eligibilityConditionsTest() { + // TODO: test eligibilityConditions + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'bindings' + */ + @Test + public void bindingsTest() { + // TODO: test bindings + } + + /** + * Test the property 'pointsRequired' + */ + @Test + public void pointsRequiredTest() { + // TODO: test pointsRequired + } + } diff --git a/src/test/java/one/talon/model/NewRiskNotificationTest.java b/src/test/java/one/talon/model/NewRiskNotificationTest.java new file mode 100644 index 00000000..a73a3c7d --- /dev/null +++ b/src/test/java/one/talon/model/NewRiskNotificationTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for NewRiskNotification + */ +public class NewRiskNotificationTest { + private final NewRiskNotification model = new NewRiskNotification(); + + /** + * Model tests for NewRiskNotification + */ + @Test + public void testNewRiskNotification() { + // TODO: test NewRiskNotification + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'activity' + */ + @Test + public void activityTest() { + // TODO: test activity + } + + /** + * Test the property 'timeFrame' + */ + @Test + public void timeFrameTest() { + // TODO: test timeFrame + } + +} diff --git a/src/test/java/one/talon/model/PassthroughBlockTest.java b/src/test/java/one/talon/model/PassthroughBlockTest.java new file mode 100644 index 00000000..083f2320 --- /dev/null +++ b/src/test/java/one/talon/model/PassthroughBlockTest.java @@ -0,0 +1,69 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for PassthroughBlock + */ +public class PassthroughBlockTest { + private final PassthroughBlock model = new PassthroughBlock(); + + /** + * Model tests for PassthroughBlock + */ + @Test + public void testPassthroughBlock() { + // TODO: test PassthroughBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'expression' + */ + @Test + public void expressionTest() { + // TODO: test expression + } + +} diff --git a/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockProgramTest.java b/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockProgramTest.java new file mode 100644 index 00000000..4abac5ce --- /dev/null +++ b/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockProgramTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RedeemLoyaltyPointsBlockProgram + */ +public class RedeemLoyaltyPointsBlockProgramTest { + private final RedeemLoyaltyPointsBlockProgram model = new RedeemLoyaltyPointsBlockProgram(); + + /** + * Model tests for RedeemLoyaltyPointsBlockProgram + */ + @Test + public void testRedeemLoyaltyPointsBlockProgram() { + // TODO: test RedeemLoyaltyPointsBlockProgram + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + +} diff --git a/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockTest.java b/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockTest.java new file mode 100644 index 00000000..4ebce6aa --- /dev/null +++ b/src/test/java/one/talon/model/RedeemLoyaltyPointsBlockTest.java @@ -0,0 +1,110 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RedeemLoyaltyPointsBlockProgram; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RedeemLoyaltyPointsBlock + */ +public class RedeemLoyaltyPointsBlockTest { + private final RedeemLoyaltyPointsBlock model = new RedeemLoyaltyPointsBlock(); + + /** + * Model tests for RedeemLoyaltyPointsBlock + */ + @Test + public void testRedeemLoyaltyPointsBlock() { + // TODO: test RedeemLoyaltyPointsBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'program' + */ + @Test + public void programTest() { + // TODO: test program + } + + /** + * Test the property 'subledger' + */ + @Test + public void subledgerTest() { + // TODO: test subledger + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + +} diff --git a/src/test/java/one/talon/model/RedeemableCouponTest.java b/src/test/java/one/talon/model/RedeemableCouponTest.java new file mode 100644 index 00000000..94a1fabf --- /dev/null +++ b/src/test/java/one/talon/model/RedeemableCouponTest.java @@ -0,0 +1,83 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RedeemableCoupon + */ +public class RedeemableCouponTest { + private final RedeemableCoupon model = new RedeemableCoupon(); + + /** + * Model tests for RedeemableCoupon + */ + @Test + public void testRedeemableCoupon() { + // TODO: test RedeemableCoupon + } + + /** + * Test the property 'couponId' + */ + @Test + public void couponIdTest() { + // TODO: test couponId + } + + /** + * Test the property 'couponCode' + */ + @Test + public void couponCodeTest() { + // TODO: test couponCode + } + + /** + * Test the property 'usageCounter' + */ + @Test + public void usageCounterTest() { + // TODO: test usageCounter + } + + /** + * Test the property 'usageLimit' + */ + @Test + public void usageLimitTest() { + // TODO: test usageLimit + } + + /** + * Test the property 'campaignName' + */ + @Test + public void campaignNameTest() { + // TODO: test campaignName + } + +} diff --git a/src/test/java/one/talon/model/ReduceSelectorStepTest.java b/src/test/java/one/talon/model/ReduceSelectorStepTest.java new file mode 100644 index 00000000..c3012862 --- /dev/null +++ b/src/test/java/one/talon/model/ReduceSelectorStepTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ReduceSelectorStep + */ +public class ReduceSelectorStepTest { + private final ReduceSelectorStep model = new ReduceSelectorStep(); + + /** + * Model tests for ReduceSelectorStep + */ + @Test + public void testReduceSelectorStep() { + // TODO: test ReduceSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + +} diff --git a/src/test/java/one/talon/model/ReserveCouponBlockTest.java b/src/test/java/one/talon/model/ReserveCouponBlockTest.java new file mode 100644 index 00000000..b67a45b1 --- /dev/null +++ b/src/test/java/one/talon/model/ReserveCouponBlockTest.java @@ -0,0 +1,69 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ReserveCouponBlock + */ +public class ReserveCouponBlockTest { + private final ReserveCouponBlock model = new ReserveCouponBlock(); + + /** + * Model tests for ReserveCouponBlock + */ + @Test + public void testReserveCouponBlock() { + // TODO: test ReserveCouponBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + +} diff --git a/src/test/java/one/talon/model/ReverseSelectorStepTest.java b/src/test/java/one/talon/model/ReverseSelectorStepTest.java new file mode 100644 index 00000000..d1eb9905 --- /dev/null +++ b/src/test/java/one/talon/model/ReverseSelectorStepTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ReverseSelectorStep + */ +public class ReverseSelectorStepTest { + private final ReverseSelectorStep model = new ReverseSelectorStep(); + + /** + * Model tests for ReverseSelectorStep + */ + @Test + public void testReverseSelectorStep() { + // TODO: test ReverseSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + +} diff --git a/src/test/java/one/talon/model/ReviewRisksRequestTest.java b/src/test/java/one/talon/model/ReviewRisksRequestTest.java new file mode 100644 index 00000000..44754a24 --- /dev/null +++ b/src/test/java/one/talon/model/ReviewRisksRequestTest.java @@ -0,0 +1,53 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ReviewRisksRequest + */ +public class ReviewRisksRequestTest { + private final ReviewRisksRequest model = new ReviewRisksRequest(); + + /** + * Model tests for ReviewRisksRequest + */ + @Test + public void testReviewRisksRequest() { + // TODO: test ReviewRisksRequest + } + + /** + * Test the property 'riskIds' + */ + @Test + public void riskIdsTest() { + // TODO: test riskIds + } + +} diff --git a/src/test/java/one/talon/model/RewardCatalogItemTest.java b/src/test/java/one/talon/model/RewardCatalogItemTest.java new file mode 100644 index 00000000..69b8884e --- /dev/null +++ b/src/test/java/one/talon/model/RewardCatalogItemTest.java @@ -0,0 +1,96 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardEligibility; +import one.talon.model.RewardPointsRequired; +import one.talon.model.RuleMetadata; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardCatalogItem + */ +public class RewardCatalogItemTest { + private final RewardCatalogItem model = new RewardCatalogItem(); + + /** + * Model tests for RewardCatalogItem + */ + @Test + public void testRewardCatalogItem() { + // TODO: test RewardCatalogItem + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'pointsRequired' + */ + @Test + public void pointsRequiredTest() { + // TODO: test pointsRequired + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'eligibility' + */ + @Test + public void eligibilityTest() { + // TODO: test eligibility + } + +} diff --git a/src/test/java/one/talon/model/RewardEligibilityFailureDetailsTest.java b/src/test/java/one/talon/model/RewardEligibilityFailureDetailsTest.java new file mode 100644 index 00000000..a9755811 --- /dev/null +++ b/src/test/java/one/talon/model/RewardEligibilityFailureDetailsTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardEligibilityFailureDetails + */ +public class RewardEligibilityFailureDetailsTest { + private final RewardEligibilityFailureDetails model = new RewardEligibilityFailureDetails(); + + /** + * Model tests for RewardEligibilityFailureDetails + */ + @Test + public void testRewardEligibilityFailureDetails() { + // TODO: test RewardEligibilityFailureDetails + } + + /** + * Test the property 'failureCode' + */ + @Test + public void failureCodeTest() { + // TODO: test failureCode + } + + /** + * Test the property 'conditionIndex' + */ + @Test + public void conditionIndexTest() { + // TODO: test conditionIndex + } + +} diff --git a/src/test/java/one/talon/model/RewardEligibilityTest.java b/src/test/java/one/talon/model/RewardEligibilityTest.java new file mode 100644 index 00000000..6c29b56e --- /dev/null +++ b/src/test/java/one/talon/model/RewardEligibilityTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RewardEligibilityFailureDetails; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardEligibility + */ +public class RewardEligibilityTest { + private final RewardEligibility model = new RewardEligibility(); + + /** + * Model tests for RewardEligibility + */ + @Test + public void testRewardEligibility() { + // TODO: test RewardEligibility + } + + /** + * Test the property 'passed' + */ + @Test + public void passedTest() { + // TODO: test passed + } + + /** + * Test the property 'details' + */ + @Test + public void detailsTest() { + // TODO: test details + } + +} diff --git a/src/test/java/one/talon/model/RewardPointsRequiredTest.java b/src/test/java/one/talon/model/RewardPointsRequiredTest.java new file mode 100644 index 00000000..465cc3a8 --- /dev/null +++ b/src/test/java/one/talon/model/RewardPointsRequiredTest.java @@ -0,0 +1,76 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardPointsRequired + */ +public class RewardPointsRequiredTest { + private final RewardPointsRequired model = new RewardPointsRequired(); + + /** + * Model tests for RewardPointsRequired + */ + @Test + public void testRewardPointsRequired() { + // TODO: test RewardPointsRequired + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'amount' + */ + @Test + public void amountTest() { + // TODO: test amount + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'subledgerId' + */ + @Test + public void subledgerIdTest() { + // TODO: test subledgerId + } + +} diff --git a/src/test/java/one/talon/model/RewardTest.java b/src/test/java/one/talon/model/RewardTest.java index 842c1df5..e4176d56 100644 --- a/src/test/java/one/talon/model/RewardTest.java +++ b/src/test/java/one/talon/model/RewardTest.java @@ -23,6 +23,9 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; @@ -107,6 +110,46 @@ public void sandboxTest() { // TODO: test sandbox } + /** + * Test the property 'eligibilityConditions' + */ + @Test + public void eligibilityConditionsTest() { + // TODO: test eligibilityConditions + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'bindings' + */ + @Test + public void bindingsTest() { + // TODO: test bindings + } + + /** + * Test the property 'pointsRequired' + */ + @Test + public void pointsRequiredTest() { + // TODO: test pointsRequired + } + + /** + * Test the property 'modified' + */ + @Test + public void modifiedTest() { + // TODO: test modified + } + /** * Test the property 'status' */ diff --git a/src/test/java/one/talon/model/RewardUnlockRejectionTest.java b/src/test/java/one/talon/model/RewardUnlockRejectionTest.java new file mode 100644 index 00000000..19541a15 --- /dev/null +++ b/src/test/java/one/talon/model/RewardUnlockRejectionTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RuleFailureReason; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardUnlockRejection + */ +public class RewardUnlockRejectionTest { + private final RewardUnlockRejection model = new RewardUnlockRejection(); + + /** + * Model tests for RewardUnlockRejection + */ + @Test + public void testRewardUnlockRejection() { + // TODO: test RewardUnlockRejection + } + + /** + * Test the property 'message' + */ + @Test + public void messageTest() { + // TODO: test message + } + + /** + * Test the property 'ruleFailureReasons' + */ + @Test + public void ruleFailureReasonsTest() { + // TODO: test ruleFailureReasons + } + +} diff --git a/src/test/java/one/talon/model/RewardWithUnlocksTest.java b/src/test/java/one/talon/model/RewardWithUnlocksTest.java new file mode 100644 index 00000000..a00c6998 --- /dev/null +++ b/src/test/java/one/talon/model/RewardWithUnlocksTest.java @@ -0,0 +1,95 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CustomerReward; +import one.talon.model.RuleMetadata; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RewardWithUnlocks + */ +public class RewardWithUnlocksTest { + private final RewardWithUnlocks model = new RewardWithUnlocks(); + + /** + * Model tests for RewardWithUnlocks + */ + @Test + public void testRewardWithUnlocks() { + // TODO: test RewardWithUnlocks + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'unlocked' + */ + @Test + public void unlockedTest() { + // TODO: test unlocked + } + +} diff --git a/src/test/java/one/talon/model/RiskAffectedEntityItemTest.java b/src/test/java/one/talon/model/RiskAffectedEntityItemTest.java new file mode 100644 index 00000000..d02e4282 --- /dev/null +++ b/src/test/java/one/talon/model/RiskAffectedEntityItemTest.java @@ -0,0 +1,83 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RiskAffectedEntityItem + */ +public class RiskAffectedEntityItemTest { + private final RiskAffectedEntityItem model = new RiskAffectedEntityItem(); + + /** + * Model tests for RiskAffectedEntityItem + */ + @Test + public void testRiskAffectedEntityItem() { + // TODO: test RiskAffectedEntityItem + } + + /** + * Test the property 'entityId' + */ + @Test + public void entityIdTest() { + // TODO: test entityId + } + + /** + * Test the property 'activityValue' + */ + @Test + public void activityValueTest() { + // TODO: test activityValue + } + + /** + * Test the property 'threshold' + */ + @Test + public void thresholdTest() { + // TODO: test threshold + } + + /** + * Test the property 'severityRatio' + */ + @Test + public void severityRatioTest() { + // TODO: test severityRatio + } + + /** + * Test the property 'criticality' + */ + @Test + public void criticalityTest() { + // TODO: test criticality + } + +} diff --git a/src/test/java/one/talon/model/RiskCriticalityUpdateTest.java b/src/test/java/one/talon/model/RiskCriticalityUpdateTest.java new file mode 100644 index 00000000..89c6ea84 --- /dev/null +++ b/src/test/java/one/talon/model/RiskCriticalityUpdateTest.java @@ -0,0 +1,61 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RiskCriticalityUpdate + */ +public class RiskCriticalityUpdateTest { + private final RiskCriticalityUpdate model = new RiskCriticalityUpdate(); + + /** + * Model tests for RiskCriticalityUpdate + */ + @Test + public void testRiskCriticalityUpdate() { + // TODO: test RiskCriticalityUpdate + } + + /** + * Test the property 'riskIds' + */ + @Test + public void riskIdsTest() { + // TODO: test riskIds + } + + /** + * Test the property 'criticality' + */ + @Test + public void criticalityTest() { + // TODO: test criticality + } + +} diff --git a/src/test/java/one/talon/model/RiskDetailTest.java b/src/test/java/one/talon/model/RiskDetailTest.java new file mode 100644 index 00000000..993cf2cf --- /dev/null +++ b/src/test/java/one/talon/model/RiskDetailTest.java @@ -0,0 +1,208 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RiskAffectedEntityItem; +import org.threeten.bp.LocalDate; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RiskDetail + */ +public class RiskDetailTest { + private final RiskDetail model = new RiskDetail(); + + /** + * Model tests for RiskDetail + */ + @Test + public void testRiskDetail() { + // TODO: test RiskDetail + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'created' + */ + @Test + public void createdTest() { + // TODO: test created + } + + /** + * Test the property 'notificationId' + */ + @Test + public void notificationIdTest() { + // TODO: test notificationId + } + + /** + * Test the property 'featureDate' + */ + @Test + public void featureDateTest() { + // TODO: test featureDate + } + + /** + * Test the property 'groupKey' + */ + @Test + public void groupKeyTest() { + // TODO: test groupKey + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + + /** + * Test the property 'criticality' + */ + @Test + public void criticalityTest() { + // TODO: test criticality + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'activity' + */ + @Test + public void activityTest() { + // TODO: test activity + } + + /** + * Test the property 'timeFrame' + */ + @Test + public void timeFrameTest() { + // TODO: test timeFrame + } + + /** + * Test the property 'reportedDate' + */ + @Test + public void reportedDateTest() { + // TODO: test reportedDate + } + + /** + * Test the property 'affectedEntityCount' + */ + @Test + public void affectedEntityCountTest() { + // TODO: test affectedEntityCount + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'discardReason' + */ + @Test + public void discardReasonTest() { + // TODO: test discardReason + } + + /** + * Test the property 'statusComment' + */ + @Test + public void statusCommentTest() { + // TODO: test statusComment + } + + /** + * Test the property 'statusChangedBy' + */ + @Test + public void statusChangedByTest() { + // TODO: test statusChangedBy + } + + /** + * Test the property 'statusChangedAt' + */ + @Test + public void statusChangedAtTest() { + // TODO: test statusChangedAt + } + + /** + * Test the property 'modified' + */ + @Test + public void modifiedTest() { + // TODO: test modified + } + + /** + * Test the property 'affectedEntities' + */ + @Test + public void affectedEntitiesTest() { + // TODO: test affectedEntities + } + +} diff --git a/src/test/java/one/talon/model/RiskNotificationTest.java b/src/test/java/one/talon/model/RiskNotificationTest.java new file mode 100644 index 00000000..7409dc51 --- /dev/null +++ b/src/test/java/one/talon/model/RiskNotificationTest.java @@ -0,0 +1,100 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RiskNotification + */ +public class RiskNotificationTest { + private final RiskNotification model = new RiskNotification(); + + /** + * Model tests for RiskNotification + */ + @Test + public void testRiskNotification() { + // TODO: test RiskNotification + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'created' + */ + @Test + public void createdTest() { + // TODO: test created + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'activity' + */ + @Test + public void activityTest() { + // TODO: test activity + } + + /** + * Test the property 'timeFrame' + */ + @Test + public void timeFrameTest() { + // TODO: test timeFrame + } + + /** + * Test the property 'active' + */ + @Test + public void activeTest() { + // TODO: test active + } + + /** + * Test the property 'modified' + */ + @Test + public void modifiedTest() { + // TODO: test modified + } + +} diff --git a/src/test/java/one/talon/model/RiskTest.java b/src/test/java/one/talon/model/RiskTest.java new file mode 100644 index 00000000..ec058cfd --- /dev/null +++ b/src/test/java/one/talon/model/RiskTest.java @@ -0,0 +1,197 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.LocalDate; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for Risk + */ +public class RiskTest { + private final Risk model = new Risk(); + + /** + * Model tests for Risk + */ + @Test + public void testRisk() { + // TODO: test Risk + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'created' + */ + @Test + public void createdTest() { + // TODO: test created + } + + /** + * Test the property 'notificationId' + */ + @Test + public void notificationIdTest() { + // TODO: test notificationId + } + + /** + * Test the property 'featureDate' + */ + @Test + public void featureDateTest() { + // TODO: test featureDate + } + + /** + * Test the property 'groupKey' + */ + @Test + public void groupKeyTest() { + // TODO: test groupKey + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + + /** + * Test the property 'criticality' + */ + @Test + public void criticalityTest() { + // TODO: test criticality + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'activity' + */ + @Test + public void activityTest() { + // TODO: test activity + } + + /** + * Test the property 'timeFrame' + */ + @Test + public void timeFrameTest() { + // TODO: test timeFrame + } + + /** + * Test the property 'reportedDate' + */ + @Test + public void reportedDateTest() { + // TODO: test reportedDate + } + + /** + * Test the property 'affectedEntityCount' + */ + @Test + public void affectedEntityCountTest() { + // TODO: test affectedEntityCount + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'discardReason' + */ + @Test + public void discardReasonTest() { + // TODO: test discardReason + } + + /** + * Test the property 'statusComment' + */ + @Test + public void statusCommentTest() { + // TODO: test statusComment + } + + /** + * Test the property 'statusChangedBy' + */ + @Test + public void statusChangedByTest() { + // TODO: test statusChangedBy + } + + /** + * Test the property 'statusChangedAt' + */ + @Test + public void statusChangedAtTest() { + // TODO: test statusChangedAt + } + + /** + * Test the property 'modified' + */ + @Test + public void modifiedTest() { + // TODO: test modified + } + +} diff --git a/src/test/java/one/talon/model/RoleV2ApplicationDetailsTest.java b/src/test/java/one/talon/model/RoleV2ApplicationDetailsTest.java index a22e077b..01c0eaf9 100644 --- a/src/test/java/one/talon/model/RoleV2ApplicationDetailsTest.java +++ b/src/test/java/one/talon/model/RoleV2ApplicationDetailsTest.java @@ -21,7 +21,6 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; -import one.talon.model.RolesV2Thresholds; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -73,12 +72,4 @@ public void toolsTest() { // TODO: test tools } - /** - * Test the property 'thresholds' - */ - @Test - public void thresholdsTest() { - // TODO: test thresholds - } - } diff --git a/src/test/java/one/talon/model/RoleV2PermissionsTest.java b/src/test/java/one/talon/model/RoleV2PermissionsTest.java index 35a00958..c06595e5 100644 --- a/src/test/java/one/talon/model/RoleV2PermissionsTest.java +++ b/src/test/java/one/talon/model/RoleV2PermissionsTest.java @@ -25,6 +25,7 @@ import java.util.List; import one.talon.model.RoleV2PermissionSet; import one.talon.model.RoleV2RolesGroup; +import one.talon.model.RolesV2Thresholds; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -60,4 +61,12 @@ public void rolesTest() { // TODO: test roles } + /** + * Test the property 'thresholds' + */ + @Test + public void thresholdsTest() { + // TODO: test thresholds + } + } diff --git a/src/test/java/one/talon/model/RolesV2ThresholdsTest.java b/src/test/java/one/talon/model/RolesV2ThresholdsTest.java index 39bef110..8c0d3523 100644 --- a/src/test/java/one/talon/model/RolesV2ThresholdsTest.java +++ b/src/test/java/one/talon/model/RolesV2ThresholdsTest.java @@ -40,6 +40,14 @@ public void testRolesV2Thresholds() { // TODO: test RolesV2Thresholds } + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + /** * Test the property 'loyaltyPointsLimit' */ diff --git a/src/test/java/one/talon/model/RollbackUseRewardEffectPropsTest.java b/src/test/java/one/talon/model/RollbackUseRewardEffectPropsTest.java new file mode 100644 index 00000000..3d08d145 --- /dev/null +++ b/src/test/java/one/talon/model/RollbackUseRewardEffectPropsTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RollbackUseRewardEffectProps + */ +public class RollbackUseRewardEffectPropsTest { + private final RollbackUseRewardEffectProps model = new RollbackUseRewardEffectProps(); + + /** + * Model tests for RollbackUseRewardEffectProps + */ + @Test + public void testRollbackUseRewardEffectProps() { + // TODO: test RollbackUseRewardEffectProps + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + +} diff --git a/src/test/java/one/talon/model/RuleEligibilityFailureDetailsTest.java b/src/test/java/one/talon/model/RuleEligibilityFailureDetailsTest.java new file mode 100644 index 00000000..f7e71065 --- /dev/null +++ b/src/test/java/one/talon/model/RuleEligibilityFailureDetailsTest.java @@ -0,0 +1,107 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RuleEligibilityFailureDetails + */ +public class RuleEligibilityFailureDetailsTest { + private final RuleEligibilityFailureDetails model = new RuleEligibilityFailureDetails(); + + /** + * Model tests for RuleEligibilityFailureDetails + */ + @Test + public void testRuleEligibilityFailureDetails() { + // TODO: test RuleEligibilityFailureDetails + } + + /** + * Test the property 'failureCode' + */ + @Test + public void failureCodeTest() { + // TODO: test failureCode + } + + /** + * Test the property 'couponID' + */ + @Test + public void couponIDTest() { + // TODO: test couponID + } + + /** + * Test the property 'couponValue' + */ + @Test + public void couponValueTest() { + // TODO: test couponValue + } + + /** + * Test the property 'referralID' + */ + @Test + public void referralIDTest() { + // TODO: test referralID + } + + /** + * Test the property 'referralValue' + */ + @Test + public void referralValueTest() { + // TODO: test referralValue + } + + /** + * Test the property 'conditionIndex' + */ + @Test + public void conditionIndexTest() { + // TODO: test conditionIndex + } + + /** + * Test the property 'effectIndex' + */ + @Test + public void effectIndexTest() { + // TODO: test effectIndex + } + + /** + * Test the property 'details' + */ + @Test + public void detailsTest() { + // TODO: test details + } + +} diff --git a/src/test/java/one/talon/model/RuleEligibilityTest.java b/src/test/java/one/talon/model/RuleEligibilityTest.java new file mode 100644 index 00000000..26347f21 --- /dev/null +++ b/src/test/java/one/talon/model/RuleEligibilityTest.java @@ -0,0 +1,68 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.RuleEligibilityFailureDetails; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RuleEligibility + */ +public class RuleEligibilityTest { + private final RuleEligibility model = new RuleEligibility(); + + /** + * Model tests for RuleEligibility + */ + @Test + public void testRuleEligibility() { + // TODO: test RuleEligibility + } + + /** + * Test the property 'passed' + */ + @Test + public void passedTest() { + // TODO: test passed + } + + /** + * Test the property 'couponCode' + */ + @Test + public void couponCodeTest() { + // TODO: test couponCode + } + + /** + * Test the property 'details' + */ + @Test + public void detailsTest() { + // TODO: test details + } + +} diff --git a/src/test/java/one/talon/model/RuleFailureReasonTest.java b/src/test/java/one/talon/model/RuleFailureReasonTest.java index 144be9be..d67406a1 100644 --- a/src/test/java/one/talon/model/RuleFailureReasonTest.java +++ b/src/test/java/one/talon/model/RuleFailureReasonTest.java @@ -96,6 +96,22 @@ public void referralValueTest() { // TODO: test referralValue } + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + + /** + * Test the property 'rewardIntegrationId' + */ + @Test + public void rewardIntegrationIdTest() { + // TODO: test rewardIntegrationId + } + /** * Test the property 'ruleIndex' */ diff --git a/src/test/java/one/talon/model/RuleMetadataEligibilityTest.java b/src/test/java/one/talon/model/RuleMetadataEligibilityTest.java new file mode 100644 index 00000000..a8af288f --- /dev/null +++ b/src/test/java/one/talon/model/RuleMetadataEligibilityTest.java @@ -0,0 +1,86 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.RuleEligibility; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RuleMetadataEligibility + */ +public class RuleMetadataEligibilityTest { + private final RuleMetadataEligibility model = new RuleMetadataEligibility(); + + /** + * Model tests for RuleMetadataEligibility + */ + @Test + public void testRuleMetadataEligibility() { + // TODO: test RuleMetadataEligibility + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'displayName' + */ + @Test + public void displayNameTest() { + // TODO: test displayName + } + + /** + * Test the property 'displayDescription' + */ + @Test + public void displayDescriptionTest() { + // TODO: test displayDescription + } + + /** + * Test the property 'relatedData' + */ + @Test + public void relatedDataTest() { + // TODO: test relatedData + } + + /** + * Test the property 'eligibility' + */ + @Test + public void eligibilityTest() { + // TODO: test eligibility + } + +} diff --git a/src/test/java/one/talon/model/RuleV2Test.java b/src/test/java/one/talon/model/RuleV2Test.java new file mode 100644 index 00000000..da24be05 --- /dev/null +++ b/src/test/java/one/talon/model/RuleV2Test.java @@ -0,0 +1,85 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RuleV2 + */ +public class RuleV2Test { + private final RuleV2 model = new RuleV2(); + + /** + * Model tests for RuleV2 + */ + @Test + public void testRuleV2() { + // TODO: test RuleV2 + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'parentId' + */ + @Test + public void parentIdTest() { + // TODO: test parentId + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'blocks' + */ + @Test + public void blocksTest() { + // TODO: test blocks + } + +} diff --git a/src/test/java/one/talon/model/RulesetV2Test.java b/src/test/java/one/talon/model/RulesetV2Test.java new file mode 100644 index 00000000..d3ef58e9 --- /dev/null +++ b/src/test/java/one/talon/model/RulesetV2Test.java @@ -0,0 +1,138 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.Bundle; +import one.talon.model.RuleV2; +import one.talon.model.Selector; +import one.talon.model.TemplateParameter; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for RulesetV2 + */ +public class RulesetV2Test { + private final RulesetV2 model = new RulesetV2(); + + /** + * Model tests for RulesetV2 + */ + @Test + public void testRulesetV2() { + // TODO: test RulesetV2 + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'created' + */ + @Test + public void createdTest() { + // TODO: test created + } + + /** + * Test the property 'userId' + */ + @Test + public void userIdTest() { + // TODO: test userId + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'templateId' + */ + @Test + public void templateIdTest() { + // TODO: test templateId + } + + /** + * Test the property 'activatedAt' + */ + @Test + public void activatedAtTest() { + // TODO: test activatedAt + } + + /** + * Test the property 'promotionRules' + */ + @Test + public void promotionRulesTest() { + // TODO: test promotionRules + } + + /** + * Test the property 'strikethroughRules' + */ + @Test + public void strikethroughRulesTest() { + // TODO: test strikethroughRules + } + + /** + * Test the property 'selectors' + */ + @Test + public void selectorsTest() { + // TODO: test selectors + } + + /** + * Test the property 'bundles' + */ + @Test + public void bundlesTest() { + // TODO: test bundles + } + + /** + * Test the property 'parameters' + */ + @Test + public void parametersTest() { + // TODO: test parameters + } + +} diff --git a/src/test/java/one/talon/model/SamlConnectionTest.java b/src/test/java/one/talon/model/SamlConnectionTest.java index f2c13e85..0c5282e7 100644 --- a/src/test/java/one/talon/model/SamlConnectionTest.java +++ b/src/test/java/one/talon/model/SamlConnectionTest.java @@ -49,6 +49,14 @@ public void assertionConsumerServiceURLTest() { // TODO: test assertionConsumerServiceURL } + /** + * Test the property 'certificateExpiry' + */ + @Test + public void certificateExpiryTest() { + // TODO: test certificateExpiry + } + /** * Test the property 'accountId' */ diff --git a/src/test/java/one/talon/model/ScalarCheckAttributeBlockTest.java b/src/test/java/one/talon/model/ScalarCheckAttributeBlockTest.java new file mode 100644 index 00000000..cd267ed1 --- /dev/null +++ b/src/test/java/one/talon/model/ScalarCheckAttributeBlockTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ScalarCheckAttributeBlock + */ +public class ScalarCheckAttributeBlockTest { + private final ScalarCheckAttributeBlock model = new ScalarCheckAttributeBlock(); + + /** + * Model tests for ScalarCheckAttributeBlock + */ + @Test + public void testScalarCheckAttributeBlock() { + // TODO: test ScalarCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + +} diff --git a/src/test/java/one/talon/model/SelectSelectorStepTest.java b/src/test/java/one/talon/model/SelectSelectorStepTest.java new file mode 100644 index 00000000..465acabc --- /dev/null +++ b/src/test/java/one/talon/model/SelectSelectorStepTest.java @@ -0,0 +1,99 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SelectSelectorStep + */ +public class SelectSelectorStepTest { + private final SelectSelectorStep model = new SelectSelectorStep(); + + /** + * Model tests for SelectSelectorStep + */ + @Test + public void testSelectSelectorStep() { + // TODO: test SelectSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'from' + */ + @Test + public void fromTest() { + // TODO: test from + } + + /** + * Test the property 'to' + */ + @Test + public void toTest() { + // TODO: test to + } + + /** + * Test the property 'count' + */ + @Test + public void countTest() { + // TODO: test count + } + + /** + * Test the property 'index' + */ + @Test + public void indexTest() { + // TODO: test index + } + + /** + * Test the property 'partial' + */ + @Test + public void partialTest() { + // TODO: test partial + } + +} diff --git a/src/test/java/one/talon/model/SelectorTest.java b/src/test/java/one/talon/model/SelectorTest.java new file mode 100644 index 00000000..b78d597f --- /dev/null +++ b/src/test/java/one/talon/model/SelectorTest.java @@ -0,0 +1,77 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for Selector + */ +public class SelectorTest { + private final Selector model = new Selector(); + + /** + * Model tests for Selector + */ + @Test + public void testSelector() { + // TODO: test Selector + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'source' + */ + @Test + public void sourceTest() { + // TODO: test source + } + + /** + * Test the property 'steps' + */ + @Test + public void stepsTest() { + // TODO: test steps + } + +} diff --git a/src/test/java/one/talon/model/SelectorValueMapRefTest.java b/src/test/java/one/talon/model/SelectorValueMapRefTest.java new file mode 100644 index 00000000..f6395606 --- /dev/null +++ b/src/test/java/one/talon/model/SelectorValueMapRefTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SelectorValueMapRef + */ +public class SelectorValueMapRefTest { + private final SelectorValueMapRef model = new SelectorValueMapRef(); + + /** + * Model tests for SelectorValueMapRef + */ + @Test + public void testSelectorValueMapRef() { + // TODO: test SelectorValueMapRef + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + +} diff --git a/src/test/java/one/talon/model/ShowNotificationBlockTest.java b/src/test/java/one/talon/model/ShowNotificationBlockTest.java new file mode 100644 index 00000000..154f70b6 --- /dev/null +++ b/src/test/java/one/talon/model/ShowNotificationBlockTest.java @@ -0,0 +1,111 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for ShowNotificationBlock + */ +public class ShowNotificationBlockTest { + private final ShowNotificationBlock model = new ShowNotificationBlock(); + + /** + * Model tests for ShowNotificationBlock + */ + @Test + public void testShowNotificationBlock() { + // TODO: test ShowNotificationBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'notificationType' + */ + @Test + public void notificationTypeTest() { + // TODO: test notificationType + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'body' + */ + @Test + public void bodyTest() { + // TODO: test body + } + + /** + * Test the property 'onFailure' + */ + @Test + public void onFailureTest() { + // TODO: test onFailure + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/SortSelectorStepFieldTest.java b/src/test/java/one/talon/model/SortSelectorStepFieldTest.java new file mode 100644 index 00000000..4a4df688 --- /dev/null +++ b/src/test/java/one/talon/model/SortSelectorStepFieldTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SortSelectorStepField + */ +public class SortSelectorStepFieldTest { + private final SortSelectorStepField model = new SortSelectorStepField(); + + /** + * Model tests for SortSelectorStepField + */ + @Test + public void testSortSelectorStepField() { + // TODO: test SortSelectorStepField + } + + /** + * Test the property 'expression' + */ + @Test + public void expressionTest() { + // TODO: test expression + } + + /** + * Test the property 'direction' + */ + @Test + public void directionTest() { + // TODO: test direction + } + +} diff --git a/src/test/java/one/talon/model/SortSelectorStepTest.java b/src/test/java/one/talon/model/SortSelectorStepTest.java new file mode 100644 index 00000000..d4447b05 --- /dev/null +++ b/src/test/java/one/talon/model/SortSelectorStepTest.java @@ -0,0 +1,62 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.SortSelectorStepField; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SortSelectorStep + */ +public class SortSelectorStepTest { + private final SortSelectorStep model = new SortSelectorStep(); + + /** + * Model tests for SortSelectorStep + */ + @Test + public void testSortSelectorStep() { + // TODO: test SortSelectorStep + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'fields' + */ + @Test + public void fieldsTest() { + // TODO: test fields + } + +} diff --git a/src/test/java/one/talon/model/StartAchievementProgressEffectPropsTest.java b/src/test/java/one/talon/model/StartAchievementProgressEffectPropsTest.java new file mode 100644 index 00000000..52c302ab --- /dev/null +++ b/src/test/java/one/talon/model/StartAchievementProgressEffectPropsTest.java @@ -0,0 +1,93 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for StartAchievementProgressEffectProps + */ +public class StartAchievementProgressEffectPropsTest { + private final StartAchievementProgressEffectProps model = new StartAchievementProgressEffectProps(); + + /** + * Model tests for StartAchievementProgressEffectProps + */ + @Test + public void testStartAchievementProgressEffectProps() { + // TODO: test StartAchievementProgressEffectProps + } + + /** + * Test the property 'achievementId' + */ + @Test + public void achievementIdTest() { + // TODO: test achievementId + } + + /** + * Test the property 'achievementName' + */ + @Test + public void achievementNameTest() { + // TODO: test achievementName + } + + /** + * Test the property 'progressTrackerId' + */ + @Test + public void progressTrackerIdTest() { + // TODO: test progressTrackerId + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + + /** + * Test the property 'startDate' + */ + @Test + public void startDateTest() { + // TODO: test startDate + } + + /** + * Test the property 'endDate' + */ + @Test + public void endDateTest() { + // TODO: test endDate + } + +} diff --git a/src/test/java/one/talon/model/SupportCustomerProfileTest.java b/src/test/java/one/talon/model/SupportCustomerProfileTest.java new file mode 100644 index 00000000..d7d1b989 --- /dev/null +++ b/src/test/java/one/talon/model/SupportCustomerProfileTest.java @@ -0,0 +1,87 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.ApplicationMembership; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SupportCustomerProfile + */ +public class SupportCustomerProfileTest { + private final SupportCustomerProfile model = new SupportCustomerProfile(); + + /** + * Model tests for SupportCustomerProfile + */ + @Test + public void testSupportCustomerProfile() { + // TODO: test SupportCustomerProfile + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'created' + */ + @Test + public void createdTest() { + // TODO: test created + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'attributes' + */ + @Test + public void attributesTest() { + // TODO: test attributes + } + + /** + * Test the property 'applicationMemberships' + */ + @Test + public void applicationMembershipsTest() { + // TODO: test applicationMemberships + } + +} diff --git a/src/test/java/one/talon/model/SupportRequestInputTest.java b/src/test/java/one/talon/model/SupportRequestInputTest.java new file mode 100644 index 00000000..b2c9bd2e --- /dev/null +++ b/src/test/java/one/talon/model/SupportRequestInputTest.java @@ -0,0 +1,107 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SupportRequestInput + */ +public class SupportRequestInputTest { + private final SupportRequestInput model = new SupportRequestInput(); + + /** + * Model tests for SupportRequestInput + */ + @Test + public void testSupportRequestInput() { + // TODO: test SupportRequestInput + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'subledgerId' + */ + @Test + public void subledgerIdTest() { + // TODO: test subledgerId + } + + /** + * Test the property 'customerProfileId' + */ + @Test + public void customerProfileIdTest() { + // TODO: test customerProfileId + } + + /** + * Test the property 'requestType' + */ + @Test + public void requestTypeTest() { + // TODO: test requestType + } + + /** + * Test the property 'requestValue' + */ + @Test + public void requestValueTest() { + // TODO: test requestValue + } + + /** + * Test the property 'requestNote' + */ + @Test + public void requestNoteTest() { + // TODO: test requestNote + } + +} diff --git a/src/test/java/one/talon/model/SupportRequestTest.java b/src/test/java/one/talon/model/SupportRequestTest.java new file mode 100644 index 00000000..5a811821 --- /dev/null +++ b/src/test/java/one/talon/model/SupportRequestTest.java @@ -0,0 +1,172 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for SupportRequest + */ +public class SupportRequestTest { + private final SupportRequest model = new SupportRequest(); + + /** + * Model tests for SupportRequest + */ + @Test + public void testSupportRequest() { + // TODO: test SupportRequest + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'campaignId' + */ + @Test + public void campaignIdTest() { + // TODO: test campaignId + } + + /** + * Test the property 'loyaltyProgramId' + */ + @Test + public void loyaltyProgramIdTest() { + // TODO: test loyaltyProgramId + } + + /** + * Test the property 'subledgerId' + */ + @Test + public void subledgerIdTest() { + // TODO: test subledgerId + } + + /** + * Test the property 'createdByUser' + */ + @Test + public void createdByUserTest() { + // TODO: test createdByUser + } + + /** + * Test the property 'createdAt' + */ + @Test + public void createdAtTest() { + // TODO: test createdAt + } + + /** + * Test the property 'customerProfileId' + */ + @Test + public void customerProfileIdTest() { + // TODO: test customerProfileId + } + + /** + * Test the property 'requestType' + */ + @Test + public void requestTypeTest() { + // TODO: test requestType + } + + /** + * Test the property 'requestValue' + */ + @Test + public void requestValueTest() { + // TODO: test requestValue + } + + /** + * Test the property 'requestNote' + */ + @Test + public void requestNoteTest() { + // TODO: test requestNote + } + + /** + * Test the property 'requestStatus' + */ + @Test + public void requestStatusTest() { + // TODO: test requestStatus + } + + /** + * Test the property 'processedAt' + */ + @Test + public void processedAtTest() { + // TODO: test processedAt + } + + /** + * Test the property 'processingNote' + */ + @Test + public void processingNoteTest() { + // TODO: test processingNote + } + + /** + * Test the property 'processedByUser' + */ + @Test + public void processedByUserTest() { + // TODO: test processedByUser + } + + /** + * Test the property 'couponCode' + */ + @Test + public void couponCodeTest() { + // TODO: test couponCode + } + +} diff --git a/src/test/java/one/talon/model/TemplateParameterTest.java b/src/test/java/one/talon/model/TemplateParameterTest.java new file mode 100644 index 00000000..9475f30d --- /dev/null +++ b/src/test/java/one/talon/model/TemplateParameterTest.java @@ -0,0 +1,100 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TemplateParameter + */ +public class TemplateParameterTest { + private final TemplateParameter model = new TemplateParameter(); + + /** + * Model tests for TemplateParameter + */ + @Test + public void testTemplateParameter() { + // TODO: test TemplateParameter + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'valueType' + */ + @Test + public void valueTypeTest() { + // TODO: test valueType + } + + /** + * Test the property 'minValue' + */ + @Test + public void minValueTest() { + // TODO: test minValue + } + + /** + * Test the property 'maxValue' + */ + @Test + public void maxValueTest() { + // TODO: test maxValue + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'attribute' + */ + @Test + public void attributeTest() { + // TODO: test attribute + } + +} diff --git a/src/test/java/one/talon/model/TriggerCustomEffectBlockCustomEffectTest.java b/src/test/java/one/talon/model/TriggerCustomEffectBlockCustomEffectTest.java new file mode 100644 index 00000000..1b28806a --- /dev/null +++ b/src/test/java/one/talon/model/TriggerCustomEffectBlockCustomEffectTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TriggerCustomEffectBlockCustomEffect + */ +public class TriggerCustomEffectBlockCustomEffectTest { + private final TriggerCustomEffectBlockCustomEffect model = new TriggerCustomEffectBlockCustomEffect(); + + /** + * Model tests for TriggerCustomEffectBlockCustomEffect + */ + @Test + public void testTriggerCustomEffectBlockCustomEffect() { + // TODO: test TriggerCustomEffectBlockCustomEffect + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + +} diff --git a/src/test/java/one/talon/model/TriggerCustomEffectBlockTargetTest.java b/src/test/java/one/talon/model/TriggerCustomEffectBlockTargetTest.java new file mode 100644 index 00000000..82793ce2 --- /dev/null +++ b/src/test/java/one/talon/model/TriggerCustomEffectBlockTargetTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TriggerCustomEffectBlockTarget + */ +public class TriggerCustomEffectBlockTargetTest { + private final TriggerCustomEffectBlockTarget model = new TriggerCustomEffectBlockTarget(); + + /** + * Model tests for TriggerCustomEffectBlockTarget + */ + @Test + public void testTriggerCustomEffectBlockTarget() { + // TODO: test TriggerCustomEffectBlockTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + +} diff --git a/src/test/java/one/talon/model/TriggerCustomEffectBlockTest.java b/src/test/java/one/talon/model/TriggerCustomEffectBlockTest.java new file mode 100644 index 00000000..cce3f397 --- /dev/null +++ b/src/test/java/one/talon/model/TriggerCustomEffectBlockTest.java @@ -0,0 +1,105 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.TriggerCustomEffectBlockCustomEffect; +import one.talon.model.TriggerCustomEffectBlockTarget; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TriggerCustomEffectBlock + */ +public class TriggerCustomEffectBlockTest { + private final TriggerCustomEffectBlock model = new TriggerCustomEffectBlock(); + + /** + * Model tests for TriggerCustomEffectBlock + */ + @Test + public void testTriggerCustomEffectBlock() { + // TODO: test TriggerCustomEffectBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'customEffect' + */ + @Test + public void customEffectTest() { + // TODO: test customEffect + } + + /** + * Test the property 'params' + */ + @Test + public void paramsTest() { + // TODO: test params + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/TriggerWebhookBlockTest.java b/src/test/java/one/talon/model/TriggerWebhookBlockTest.java new file mode 100644 index 00000000..8f668c63 --- /dev/null +++ b/src/test/java/one/talon/model/TriggerWebhookBlockTest.java @@ -0,0 +1,96 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import one.talon.model.TriggerWebhookBlockWebhook; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TriggerWebhookBlock + */ +public class TriggerWebhookBlockTest { + private final TriggerWebhookBlock model = new TriggerWebhookBlock(); + + /** + * Model tests for TriggerWebhookBlock + */ + @Test + public void testTriggerWebhookBlock() { + // TODO: test TriggerWebhookBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'webhook' + */ + @Test + public void webhookTest() { + // TODO: test webhook + } + + /** + * Test the property 'params' + */ + @Test + public void paramsTest() { + // TODO: test params + } + + /** + * Test the property 'onError' + */ + @Test + public void onErrorTest() { + // TODO: test onError + } + +} diff --git a/src/test/java/one/talon/model/TriggerWebhookBlockWebhookTest.java b/src/test/java/one/talon/model/TriggerWebhookBlockWebhookTest.java new file mode 100644 index 00000000..1f81a529 --- /dev/null +++ b/src/test/java/one/talon/model/TriggerWebhookBlockWebhookTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for TriggerWebhookBlockWebhook + */ +public class TriggerWebhookBlockWebhookTest { + private final TriggerWebhookBlockWebhook model = new TriggerWebhookBlockWebhook(); + + /** + * Model tests for TriggerWebhookBlockWebhook + */ + @Test + public void testTriggerWebhookBlockWebhook() { + // TODO: test TriggerWebhookBlockWebhook + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + +} diff --git a/src/test/java/one/talon/model/UnaryCheckAttributeBlockTest.java b/src/test/java/one/talon/model/UnaryCheckAttributeBlockTest.java new file mode 100644 index 00000000..b39ccbdb --- /dev/null +++ b/src/test/java/one/talon/model/UnaryCheckAttributeBlockTest.java @@ -0,0 +1,51 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UnaryCheckAttributeBlock + */ +public class UnaryCheckAttributeBlockTest { + private final UnaryCheckAttributeBlock model = new UnaryCheckAttributeBlock(); + + /** + * Model tests for UnaryCheckAttributeBlock + */ + @Test + public void testUnaryCheckAttributeBlock() { + // TODO: test UnaryCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + +} diff --git a/src/test/java/one/talon/model/UnlockRewardEffectPropsTest.java b/src/test/java/one/talon/model/UnlockRewardEffectPropsTest.java new file mode 100644 index 00000000..fc1ea26e --- /dev/null +++ b/src/test/java/one/talon/model/UnlockRewardEffectPropsTest.java @@ -0,0 +1,92 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.threeten.bp.OffsetDateTime; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UnlockRewardEffectProps + */ +public class UnlockRewardEffectPropsTest { + private final UnlockRewardEffectProps model = new UnlockRewardEffectProps(); + + /** + * Model tests for UnlockRewardEffectProps + */ + @Test + public void testUnlockRewardEffectProps() { + // TODO: test UnlockRewardEffectProps + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + + /** + * Test the property 'profileIntegrationId' + */ + @Test + public void profileIntegrationIdTest() { + // TODO: test profileIntegrationId + } + + /** + * Test the property 'unlockedAt' + */ + @Test + public void unlockedAtTest() { + // TODO: test unlockedAt + } + + /** + * Test the property 'cardIdentifier' + */ + @Test + public void cardIdentifierTest() { + // TODO: test cardIdentifier + } + +} diff --git a/src/test/java/one/talon/model/UpdateAchievementProgressBlockAchievementTest.java b/src/test/java/one/talon/model/UpdateAchievementProgressBlockAchievementTest.java new file mode 100644 index 00000000..98bc0af8 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAchievementProgressBlockAchievementTest.java @@ -0,0 +1,76 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAchievementProgressBlockAchievement + */ +public class UpdateAchievementProgressBlockAchievementTest { + private final UpdateAchievementProgressBlockAchievement model = new UpdateAchievementProgressBlockAchievement(); + + /** + * Model tests for UpdateAchievementProgressBlockAchievement + */ + @Test + public void testUpdateAchievementProgressBlockAchievement() { + // TODO: test UpdateAchievementProgressBlockAchievement + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + +} diff --git a/src/test/java/one/talon/model/UpdateAchievementProgressBlockTest.java b/src/test/java/one/talon/model/UpdateAchievementProgressBlockTest.java new file mode 100644 index 00000000..1a2967d0 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAchievementProgressBlockTest.java @@ -0,0 +1,94 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAchievementProgressBlockAchievement; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAchievementProgressBlock + */ +public class UpdateAchievementProgressBlockTest { + private final UpdateAchievementProgressBlock model = new UpdateAchievementProgressBlock(); + + /** + * Model tests for UpdateAchievementProgressBlock + */ + @Test + public void testUpdateAchievementProgressBlock() { + // TODO: test UpdateAchievementProgressBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'achievement' + */ + @Test + public void achievementTest() { + // TODO: test achievement + } + +} diff --git a/src/test/java/one/talon/model/UpdateAchievementV2Test.java b/src/test/java/one/talon/model/UpdateAchievementV2Test.java index 636d2989..7d2dd241 100644 --- a/src/test/java/one/talon/model/UpdateAchievementV2Test.java +++ b/src/test/java/one/talon/model/UpdateAchievementV2Test.java @@ -124,14 +124,6 @@ public void allowRollbackAfterCompletionTest() { // TODO: test allowRollbackAfterCompletion } - /** - * Test the property 'sandbox' - */ - @Test - public void sandboxTest() { - // TODO: test sandbox - } - /** * Test the property 'subscribedApplications' */ @@ -140,12 +132,4 @@ public void subscribedApplicationsTest() { // TODO: test subscribedApplications } - /** - * Test the property 'timezone' - */ - @Test - public void timezoneTest() { - // TODO: test timezone - } - } diff --git a/src/test/java/one/talon/model/UpdateApplicationTest.java b/src/test/java/one/talon/model/UpdateApplicationTest.java index 26e01a48..3f1693ff 100644 --- a/src/test/java/one/talon/model/UpdateApplicationTest.java +++ b/src/test/java/one/talon/model/UpdateApplicationTest.java @@ -24,6 +24,7 @@ import java.util.ArrayList; import java.util.List; import one.talon.model.AttributesSettings; +import one.talon.model.BestPriorPriceSettings; import one.talon.model.LimitConfig; import org.junit.Assert; import org.junit.Ignore; @@ -180,4 +181,12 @@ public void enableCampaignStateManagementTest() { // TODO: test enableCampaignStateManagement } + /** + * Test the property 'bestPriorPriceSettings' + */ + @Test + public void bestPriorPriceSettingsTest() { + // TODO: test bestPriorPriceSettings + } + } diff --git a/src/test/java/one/talon/model/UpdateAttributeValueBlockAttributeTest.java b/src/test/java/one/talon/model/UpdateAttributeValueBlockAttributeTest.java new file mode 100644 index 00000000..bb61effe --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAttributeValueBlockAttributeTest.java @@ -0,0 +1,83 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAttributeValueBlockAttribute + */ +public class UpdateAttributeValueBlockAttributeTest { + private final UpdateAttributeValueBlockAttribute model = new UpdateAttributeValueBlockAttribute(); + + /** + * Model tests for UpdateAttributeValueBlockAttribute + */ + @Test + public void testUpdateAttributeValueBlockAttribute() { + // TODO: test UpdateAttributeValueBlockAttribute + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'title' + */ + @Test + public void titleTest() { + // TODO: test title + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + +} diff --git a/src/test/java/one/talon/model/UpdateAttributeValueBlockTargetTest.java b/src/test/java/one/talon/model/UpdateAttributeValueBlockTargetTest.java new file mode 100644 index 00000000..bfe6ceb3 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAttributeValueBlockTargetTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAttributeValueBlockTarget + */ +public class UpdateAttributeValueBlockTargetTest { + private final UpdateAttributeValueBlockTarget model = new UpdateAttributeValueBlockTarget(); + + /** + * Model tests for UpdateAttributeValueBlockTarget + */ + @Test + public void testUpdateAttributeValueBlockTarget() { + // TODO: test UpdateAttributeValueBlockTarget + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + +} diff --git a/src/test/java/one/talon/model/UpdateAttributeValueBlockTest.java b/src/test/java/one/talon/model/UpdateAttributeValueBlockTest.java new file mode 100644 index 00000000..e44dd543 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAttributeValueBlockTest.java @@ -0,0 +1,103 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAttributeValueBlockAttribute; +import one.talon.model.UpdateAttributeValueBlockTarget; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAttributeValueBlock + */ +public class UpdateAttributeValueBlockTest { + private final UpdateAttributeValueBlock model = new UpdateAttributeValueBlock(); + + /** + * Model tests for UpdateAttributeValueBlock + */ + @Test + public void testUpdateAttributeValueBlock() { + // TODO: test UpdateAttributeValueBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'attribute' + */ + @Test + public void attributeTest() { + // TODO: test attribute + } + + /** + * Test the property 'value' + */ + @Test + public void valueTest() { + // TODO: test value + } + + /** + * Test the property 'target' + */ + @Test + public void targetTest() { + // TODO: test target + } + +} diff --git a/src/test/java/one/talon/model/UpdateAudienceMembershipBlockAudienceTest.java b/src/test/java/one/talon/model/UpdateAudienceMembershipBlockAudienceTest.java new file mode 100644 index 00000000..29cda770 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAudienceMembershipBlockAudienceTest.java @@ -0,0 +1,75 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAudienceMembershipBlockAudience + */ +public class UpdateAudienceMembershipBlockAudienceTest { + private final UpdateAudienceMembershipBlockAudience model = new UpdateAudienceMembershipBlockAudience(); + + /** + * Model tests for UpdateAudienceMembershipBlockAudience + */ + @Test + public void testUpdateAudienceMembershipBlockAudience() { + // TODO: test UpdateAudienceMembershipBlockAudience + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'integration' + */ + @Test + public void integrationTest() { + // TODO: test integration + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + +} diff --git a/src/test/java/one/talon/model/UpdateAudienceMembershipBlockTest.java b/src/test/java/one/talon/model/UpdateAudienceMembershipBlockTest.java new file mode 100644 index 00000000..25e3aef0 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateAudienceMembershipBlockTest.java @@ -0,0 +1,94 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.UpdateAudienceMembershipBlockAudience; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateAudienceMembershipBlock + */ +public class UpdateAudienceMembershipBlockTest { + private final UpdateAudienceMembershipBlock model = new UpdateAudienceMembershipBlock(); + + /** + * Model tests for UpdateAudienceMembershipBlock + */ + @Test + public void testUpdateAudienceMembershipBlock() { + // TODO: test UpdateAudienceMembershipBlock + } + + /** + * Test the property 'id' + */ + @Test + public void idTest() { + // TODO: test id + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'tags' + */ + @Test + public void tagsTest() { + // TODO: test tags + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'profile' + */ + @Test + public void profileTest() { + // TODO: test profile + } + + /** + * Test the property 'audience' + */ + @Test + public void audienceTest() { + // TODO: test audience + } + +} diff --git a/src/test/java/one/talon/model/UpdateAudienceTest.java b/src/test/java/one/talon/model/UpdateAudienceTest.java index ad78f8ec..adcee773 100644 --- a/src/test/java/one/talon/model/UpdateAudienceTest.java +++ b/src/test/java/one/talon/model/UpdateAudienceTest.java @@ -21,6 +21,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import java.util.ArrayList; +import java.util.List; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; @@ -48,4 +50,12 @@ public void nameTest() { // TODO: test name } + /** + * Test the property 'subscribedApplicationsIds' + */ + @Test + public void subscribedApplicationsIdsTest() { + // TODO: test subscribedApplicationsIds + } + } diff --git a/src/test/java/one/talon/model/UpdateExperimentTest.java b/src/test/java/one/talon/model/UpdateExperimentTest.java index cdbff93c..274a2189 100644 --- a/src/test/java/one/talon/model/UpdateExperimentTest.java +++ b/src/test/java/one/talon/model/UpdateExperimentTest.java @@ -57,4 +57,20 @@ public void campaignTest() { // TODO: test campaign } + /** + * Test the property 'goalType' + */ + @Test + public void goalTypeTest() { + // TODO: test goalType + } + + /** + * Test the property 'goalDescription' + */ + @Test + public void goalDescriptionTest() { + // TODO: test goalDescription + } + } diff --git a/src/test/java/one/talon/model/UpdateRewardTest.java b/src/test/java/one/talon/model/UpdateRewardTest.java new file mode 100644 index 00000000..a50aa453 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateRewardTest.java @@ -0,0 +1,104 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.Binding; +import one.talon.model.RewardPointsRequired; +import one.talon.model.Rule; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateReward + */ +public class UpdateRewardTest { + private final UpdateReward model = new UpdateReward(); + + /** + * Model tests for UpdateReward + */ + @Test + public void testUpdateReward() { + // TODO: test UpdateReward + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'description' + */ + @Test + public void descriptionTest() { + // TODO: test description + } + + /** + * Test the property 'status' + */ + @Test + public void statusTest() { + // TODO: test status + } + + /** + * Test the property 'eligibilityConditions' + */ + @Test + public void eligibilityConditionsTest() { + // TODO: test eligibilityConditions + } + + /** + * Test the property 'rule' + */ + @Test + public void ruleTest() { + // TODO: test rule + } + + /** + * Test the property 'bindings' + */ + @Test + public void bindingsTest() { + // TODO: test bindings + } + + /** + * Test the property 'pointsRequired' + */ + @Test + public void pointsRequiredTest() { + // TODO: test pointsRequired + } + +} diff --git a/src/test/java/one/talon/model/UpdateRiskNotificationTest.java b/src/test/java/one/talon/model/UpdateRiskNotificationTest.java new file mode 100644 index 00000000..ea3b39d4 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateRiskNotificationTest.java @@ -0,0 +1,75 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateRiskNotification + */ +public class UpdateRiskNotificationTest { + private final UpdateRiskNotification model = new UpdateRiskNotification(); + + /** + * Model tests for UpdateRiskNotification + */ + @Test + public void testUpdateRiskNotification() { + // TODO: test UpdateRiskNotification + } + + /** + * Test the property 'entity' + */ + @Test + public void entityTest() { + // TODO: test entity + } + + /** + * Test the property 'activity' + */ + @Test + public void activityTest() { + // TODO: test activity + } + + /** + * Test the property 'timeFrame' + */ + @Test + public void timeFrameTest() { + // TODO: test timeFrame + } + + /** + * Test the property 'active' + */ + @Test + public void activeTest() { + // TODO: test active + } + +} diff --git a/src/test/java/one/talon/model/UpdateSupportRequestTest.java b/src/test/java/one/talon/model/UpdateSupportRequestTest.java new file mode 100644 index 00000000..5a42e1a2 --- /dev/null +++ b/src/test/java/one/talon/model/UpdateSupportRequestTest.java @@ -0,0 +1,59 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UpdateSupportRequest + */ +public class UpdateSupportRequestTest { + private final UpdateSupportRequest model = new UpdateSupportRequest(); + + /** + * Model tests for UpdateSupportRequest + */ + @Test + public void testUpdateSupportRequest() { + // TODO: test UpdateSupportRequest + } + + /** + * Test the property 'requestStatus' + */ + @Test + public void requestStatusTest() { + // TODO: test requestStatus + } + + /** + * Test the property 'processingNote' + */ + @Test + public void processingNoteTest() { + // TODO: test processingNote + } + +} diff --git a/src/test/java/one/talon/model/UseRewardEffectPropsTest.java b/src/test/java/one/talon/model/UseRewardEffectPropsTest.java new file mode 100644 index 00000000..bae94724 --- /dev/null +++ b/src/test/java/one/talon/model/UseRewardEffectPropsTest.java @@ -0,0 +1,67 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for UseRewardEffectProps + */ +public class UseRewardEffectPropsTest { + private final UseRewardEffectProps model = new UseRewardEffectProps(); + + /** + * Model tests for UseRewardEffectProps + */ + @Test + public void testUseRewardEffectProps() { + // TODO: test UseRewardEffectProps + } + + /** + * Test the property 'integrationId' + */ + @Test + public void integrationIdTest() { + // TODO: test integrationId + } + + /** + * Test the property 'rewardId' + */ + @Test + public void rewardIdTest() { + // TODO: test rewardId + } + + /** + * Test the property 'applicationId' + */ + @Test + public void applicationIdTest() { + // TODO: test applicationId + } + +} diff --git a/src/test/java/one/talon/model/WebhookAuthenticationBaseBasicTest.java b/src/test/java/one/talon/model/WebhookAuthenticationBaseBasicTest.java new file mode 100644 index 00000000..1f8c44bb --- /dev/null +++ b/src/test/java/one/talon/model/WebhookAuthenticationBaseBasicTest.java @@ -0,0 +1,68 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.WebhookAuthenticationDataBasic; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for WebhookAuthenticationBaseBasic + */ +public class WebhookAuthenticationBaseBasicTest { + private final WebhookAuthenticationBaseBasic model = new WebhookAuthenticationBaseBasic(); + + /** + * Model tests for WebhookAuthenticationBaseBasic + */ + @Test + public void testWebhookAuthenticationBaseBasic() { + // TODO: test WebhookAuthenticationBaseBasic + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/WebhookAuthenticationBaseCustomTest.java b/src/test/java/one/talon/model/WebhookAuthenticationBaseCustomTest.java new file mode 100644 index 00000000..866e3f7d --- /dev/null +++ b/src/test/java/one/talon/model/WebhookAuthenticationBaseCustomTest.java @@ -0,0 +1,68 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.WebhookAuthenticationDataCustom; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for WebhookAuthenticationBaseCustom + */ +public class WebhookAuthenticationBaseCustomTest { + private final WebhookAuthenticationBaseCustom model = new WebhookAuthenticationBaseCustom(); + + /** + * Model tests for WebhookAuthenticationBaseCustom + */ + @Test + public void testWebhookAuthenticationBaseCustom() { + // TODO: test WebhookAuthenticationBaseCustom + } + + /** + * Test the property 'name' + */ + @Test + public void nameTest() { + // TODO: test name + } + + /** + * Test the property 'type' + */ + @Test + public void typeTest() { + // TODO: test type + } + + /** + * Test the property 'data' + */ + @Test + public void dataTest() { + // TODO: test data + } + +} diff --git a/src/test/java/one/talon/model/WithinCheckAttributeBlockTest.java b/src/test/java/one/talon/model/WithinCheckAttributeBlockTest.java new file mode 100644 index 00000000..fd88414f --- /dev/null +++ b/src/test/java/one/talon/model/WithinCheckAttributeBlockTest.java @@ -0,0 +1,91 @@ +/* + * Talon.One API + * Use the Talon.One API to integrate with your application and to manage applications and campaigns: - Use the operations in the [Integration API section](#integration-api) to integrate with our platform. - Use the operation in the [Management API section](#management-api) to manage applications and campaigns. ## Determining the base URL of the endpoints The API is available at the same hostname as your Campaign Manager deployment. For example, if you access the Campaign Manager at `https://yourbaseurl.talon.one/`, the URL for the [updateCustomerSessionV2](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint is `https://yourbaseurl.talon.one/v2/customer_sessions/{Id}`. + * + * The version of the OpenAPI document: + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + + +/** + * Model tests for WithinCheckAttributeBlock + */ +public class WithinCheckAttributeBlockTest { + private final WithinCheckAttributeBlock model = new WithinCheckAttributeBlock(); + + /** + * Model tests for WithinCheckAttributeBlock + */ + @Test + public void testWithinCheckAttributeBlock() { + // TODO: test WithinCheckAttributeBlock + } + + /** + * Test the property 'operator' + */ + @Test + public void operatorTest() { + // TODO: test operator + } + + /** + * Test the property 'start' + */ + @Test + public void startTest() { + // TODO: test start + } + + /** + * Test the property 'end' + */ + @Test + public void endTest() { + // TODO: test end + } + + /** + * Test the property 'startInclusive' + */ + @Test + public void startInclusiveTest() { + // TODO: test startInclusive + } + + /** + * Test the property 'endInclusive' + */ + @Test + public void endInclusiveTest() { + // TODO: test endInclusive + } + + /** + * Test the property 'timezoneInsensitive' + */ + @Test + public void timezoneInsensitiveTest() { + // TODO: test timezoneInsensitive + } + +}