talon_one 5.0.0 → 6.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (327) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +77 -17
  3. data/docs/AchievementProgress.md +2 -0
  4. data/docs/AdditionalCampaignProperties.md +3 -1
  5. data/docs/AnalyticsDataPoint.md +19 -0
  6. data/docs/AnalyticsDataPointWithTrend.md +19 -0
  7. data/docs/AnalyticsDataPointWithTrendAndInfluencedRate.md +21 -0
  8. data/docs/AnalyticsDataPointWithTrendAndUplift.md +21 -0
  9. data/docs/Application.md +4 -0
  10. data/docs/ApplicationAnalyticsDataPoint.md +6 -6
  11. data/docs/ApplicationCIF.md +33 -0
  12. data/docs/ApplicationCIFExpression.md +27 -0
  13. data/docs/ApplicationCampaignAnalytics.md +13 -19
  14. data/docs/ApplicationCampaignStats.md +1 -3
  15. data/docs/AsyncCouponDeletionJobResponse.md +17 -0
  16. data/docs/BaseLoyaltyProgram.md +8 -4
  17. data/docs/BaseNotification.md +1 -1
  18. data/docs/BaseNotificationEntity.md +1 -1
  19. data/docs/Campaign.md +15 -1
  20. data/docs/CampaignCollectionEditedNotification.md +21 -0
  21. data/docs/CampaignNotificationPolicy.md +3 -1
  22. data/docs/CampaignStateChangedNotification.md +2 -2
  23. data/docs/CampaignStoreBudget.md +25 -0
  24. data/docs/CampaignVersions.md +27 -0
  25. data/docs/CardAddedDeductedPointsNotificationPolicy.md +19 -0
  26. data/docs/CartItem.md +1 -1
  27. data/docs/CodeGeneratorSettings.md +1 -1
  28. data/docs/Coupon.md +1 -1
  29. data/docs/CouponConstraints.md +1 -1
  30. data/docs/CouponCreationJob.md +1 -1
  31. data/docs/CouponDeletionFilters.md +43 -0
  32. data/docs/CouponDeletionJob.md +39 -0
  33. data/docs/CustomerSessionV2.md +2 -2
  34. data/docs/Effect.md +8 -0
  35. data/docs/EffectEntity.md +9 -1
  36. data/docs/Environment.md +3 -1
  37. data/docs/Event.md +1 -1
  38. data/docs/GenerateCampaignDescription.md +19 -0
  39. data/docs/GenerateCampaignTags.md +17 -0
  40. data/docs/GenerateItemFilterDescription.md +17 -0
  41. data/docs/GenerateLoyaltyCard.md +19 -0
  42. data/docs/GenerateRuleTitle.md +19 -0
  43. data/docs/GenerateRuleTitleRule.md +19 -0
  44. data/docs/IncreaseAchievementProgressEffectProps.md +1 -1
  45. data/docs/IntegrationApi.md +67 -6
  46. data/docs/IntegrationCoupon.md +1 -1
  47. data/docs/InventoryCoupon.md +1 -1
  48. data/docs/InventoryReferral.md +1 -1
  49. data/docs/LoyaltyBalanceWithTier.md +31 -0
  50. data/docs/LoyaltyBalancesWithTiers.md +19 -0
  51. data/docs/LoyaltyCard.md +6 -2
  52. data/docs/LoyaltyCardBatch.md +21 -0
  53. data/docs/LoyaltyCardBatchResponse.md +19 -0
  54. data/docs/LoyaltyProgram.md +14 -6
  55. data/docs/ManagementApi.md +1044 -69
  56. data/docs/MessageLogResponse.md +3 -3
  57. data/docs/NewAppWideCouponDeletionJob.md +19 -0
  58. data/docs/NewApplication.md +3 -1
  59. data/docs/NewApplicationCIF.md +27 -0
  60. data/docs/NewApplicationCIFExpression.md +21 -0
  61. data/docs/NewBaseNotification.md +1 -1
  62. data/docs/NewCouponCreationJob.md +1 -1
  63. data/docs/NewCouponDeletionJob.md +17 -0
  64. data/docs/NewCoupons.md +1 -1
  65. data/docs/NewCouponsForMultipleRecipients.md +1 -1
  66. data/docs/NewCustomerSessionV2.md +2 -2
  67. data/docs/NewLoyaltyProgram.md +8 -4
  68. data/docs/NewOutgoingIntegrationWebhook.md +2 -0
  69. data/docs/NewReferral.md +1 -1
  70. data/docs/NewReferralsForMultipleAdvocates.md +1 -1
  71. data/docs/NewRevisionVersion.md +37 -0
  72. data/docs/NewWebhook.md +2 -0
  73. data/docs/OktaEvent.md +19 -0
  74. data/docs/OktaEventPayload.md +17 -0
  75. data/docs/OktaEventPayloadData.md +17 -0
  76. data/docs/OktaEventTarget.md +21 -0
  77. data/docs/ProjectedTier.md +21 -0
  78. data/docs/Referral.md +1 -1
  79. data/docs/ReferralConstraints.md +1 -1
  80. data/docs/RejectCouponEffectProps.md +3 -1
  81. data/docs/RejectReferralEffectProps.md +3 -1
  82. data/docs/Revision.md +35 -0
  83. data/docs/RevisionActivation.md +17 -0
  84. data/docs/RevisionVersion.md +53 -0
  85. data/docs/RollbackIncreasedAchievementProgressEffectProps.md +27 -0
  86. data/docs/RuleFailureReason.md +5 -1
  87. data/docs/SSOConfig.md +3 -1
  88. data/docs/ScimBaseUser.md +23 -0
  89. data/docs/ScimBaseUserName.md +17 -0
  90. data/docs/ScimNewUser.md +23 -0
  91. data/docs/ScimPatchOperation.md +21 -0
  92. data/docs/ScimPatchRequest.md +19 -0
  93. data/docs/ScimResource.md +21 -0
  94. data/docs/ScimResourceTypesListResponse.md +17 -0
  95. data/docs/ScimSchemaResource.md +23 -0
  96. data/docs/ScimSchemasListResponse.md +21 -0
  97. data/docs/ScimServiceProviderConfigResponse.md +27 -0
  98. data/docs/ScimServiceProviderConfigResponseBulk.md +21 -0
  99. data/docs/ScimServiceProviderConfigResponseChangePassword.md +17 -0
  100. data/docs/ScimServiceProviderConfigResponseFilter.md +19 -0
  101. data/docs/ScimServiceProviderConfigResponsePatch.md +17 -0
  102. data/docs/ScimUser.md +25 -0
  103. data/docs/ScimUsersListResponse.md +21 -0
  104. data/docs/Tier.md +3 -1
  105. data/docs/TransferLoyaltyCard.md +3 -1
  106. data/docs/UpdateApplication.md +5 -1
  107. data/docs/UpdateApplicationCIF.md +23 -0
  108. data/docs/UpdateCampaign.md +1 -1
  109. data/docs/UpdateCoupon.md +1 -1
  110. data/docs/UpdateCouponBatch.md +1 -1
  111. data/docs/UpdateLoyaltyCard.md +4 -2
  112. data/docs/UpdateLoyaltyProgram.md +8 -4
  113. data/docs/UpdateReferral.md +1 -1
  114. data/docs/UpdateReferralBatch.md +1 -1
  115. data/docs/User.md +3 -1
  116. data/docs/Webhook.md +2 -0
  117. data/docs/WebhookWithOutgoingIntegrationDetails.md +2 -0
  118. data/lib/talon_one/api/integration_api.rb +83 -7
  119. data/lib/talon_one/api/management_api.rb +1127 -78
  120. data/lib/talon_one/models/achievement_progress.rb +16 -1
  121. data/lib/talon_one/models/additional_campaign_properties.rb +21 -6
  122. data/lib/talon_one/models/analytics_data_point.rb +225 -0
  123. data/lib/talon_one/models/analytics_data_point_with_trend.rb +225 -0
  124. data/lib/talon_one/models/analytics_data_point_with_trend_and_influenced_rate.rb +239 -0
  125. data/lib/talon_one/models/analytics_data_point_with_trend_and_uplift.rb +239 -0
  126. data/lib/talon_one/models/application.rb +21 -1
  127. data/lib/talon_one/models/application_analytics_data_point.rb +14 -4
  128. data/lib/talon_one/models/application_campaign_analytics.rb +39 -41
  129. data/lib/talon_one/models/application_campaign_stats.rb +1 -16
  130. data/lib/talon_one/models/application_cif.rb +308 -0
  131. data/lib/talon_one/models/application_cif_expression.rb +275 -0
  132. data/lib/talon_one/models/async_coupon_deletion_job_response.rb +213 -0
  133. data/lib/talon_one/models/attribute.rb +2 -2
  134. data/lib/talon_one/models/base_loyalty_program.rb +44 -25
  135. data/lib/talon_one/models/base_notification.rb +3 -2
  136. data/lib/talon_one/models/base_notification_entity.rb +1 -0
  137. data/lib/talon_one/models/campaign.rb +83 -6
  138. data/lib/talon_one/models/campaign_collection_edited_notification.rb +235 -0
  139. data/lib/talon_one/models/campaign_notification_policy.rb +16 -4
  140. data/lib/talon_one/models/campaign_state_changed_notification.rb +2 -2
  141. data/lib/talon_one/models/campaign_store_budget.rb +275 -0
  142. data/lib/talon_one/models/campaign_versions.rb +259 -0
  143. data/lib/talon_one/models/card_added_deducted_points_notification_policy.rb +269 -0
  144. data/lib/talon_one/models/cart_item.rb +1 -1
  145. data/lib/talon_one/models/code_generator_settings.rb +1 -1
  146. data/lib/talon_one/models/coupon.rb +1 -1
  147. data/lib/talon_one/models/coupon_constraints.rb +1 -1
  148. data/lib/talon_one/models/coupon_creation_job.rb +1 -1
  149. data/lib/talon_one/models/coupon_deletion_filters.rb +375 -0
  150. data/lib/talon_one/models/coupon_deletion_job.rb +370 -0
  151. data/lib/talon_one/models/customer_session_v2.rb +2 -2
  152. data/lib/talon_one/models/effect.rb +41 -1
  153. data/lib/talon_one/models/effect_entity.rb +44 -4
  154. data/lib/talon_one/models/environment.rb +16 -4
  155. data/lib/talon_one/models/event.rb +0 -5
  156. data/lib/talon_one/models/generate_campaign_description.rb +227 -0
  157. data/lib/talon_one/models/generate_campaign_tags.rb +212 -0
  158. data/lib/talon_one/models/generate_item_filter_description.rb +214 -0
  159. data/lib/talon_one/models/generate_loyalty_card.rb +256 -0
  160. data/lib/talon_one/models/generate_rule_title.rb +226 -0
  161. data/lib/talon_one/models/generate_rule_title_rule.rb +221 -0
  162. data/lib/talon_one/models/increase_achievement_progress_effect_props.rb +1 -1
  163. data/lib/talon_one/models/integration_coupon.rb +1 -1
  164. data/lib/talon_one/models/inventory_coupon.rb +1 -1
  165. data/lib/talon_one/models/inventory_referral.rb +1 -1
  166. data/lib/talon_one/models/loyalty_balance_with_tier.rb +276 -0
  167. data/lib/talon_one/models/loyalty_balances_with_tiers.rb +219 -0
  168. data/lib/talon_one/models/loyalty_card.rb +25 -5
  169. data/lib/talon_one/models/loyalty_card_batch.rb +304 -0
  170. data/lib/talon_one/models/loyalty_card_batch_response.rb +227 -0
  171. data/lib/talon_one/models/loyalty_program.rb +70 -29
  172. data/lib/talon_one/models/message_log_response.rb +3 -22
  173. data/lib/talon_one/models/new_app_wide_coupon_deletion_job.rb +227 -0
  174. data/lib/talon_one/models/new_application.rb +14 -4
  175. data/lib/talon_one/models/new_application_cif.rb +262 -0
  176. data/lib/talon_one/models/new_application_cif_expression.rb +229 -0
  177. data/lib/talon_one/models/new_attribute.rb +2 -2
  178. data/lib/talon_one/models/new_base_notification.rb +1 -0
  179. data/lib/talon_one/models/new_coupon_creation_job.rb +1 -1
  180. data/lib/talon_one/models/new_coupon_deletion_job.rb +211 -0
  181. data/lib/talon_one/models/new_coupons.rb +1 -1
  182. data/lib/talon_one/models/new_coupons_for_multiple_recipients.rb +1 -1
  183. data/lib/talon_one/models/new_customer_session_v2.rb +2 -2
  184. data/lib/talon_one/models/new_loyalty_program.rb +44 -25
  185. data/lib/talon_one/models/new_notification_test.rb +2 -2
  186. data/lib/talon_one/models/new_outgoing_integration_webhook.rb +11 -1
  187. data/lib/talon_one/models/new_referral.rb +1 -1
  188. data/lib/talon_one/models/new_referrals_for_multiple_advocates.rb +1 -1
  189. data/lib/talon_one/models/new_revision_version.rb +352 -0
  190. data/lib/talon_one/models/new_webhook.rb +11 -1
  191. data/lib/talon_one/models/okta_event.rb +229 -0
  192. data/lib/talon_one/models/okta_event_payload.rb +212 -0
  193. data/lib/talon_one/models/okta_event_payload_data.rb +214 -0
  194. data/lib/talon_one/models/okta_event_target.rb +243 -0
  195. data/lib/talon_one/models/projected_tier.rb +232 -0
  196. data/lib/talon_one/models/referral.rb +1 -1
  197. data/lib/talon_one/models/referral_constraints.rb +1 -1
  198. data/lib/talon_one/models/reject_coupon_effect_props.rb +14 -4
  199. data/lib/talon_one/models/reject_referral_effect_props.rb +14 -4
  200. data/lib/talon_one/models/revision.rb +319 -0
  201. data/lib/talon_one/models/revision_activation.rb +206 -0
  202. data/lib/talon_one/models/revision_version.rb +466 -0
  203. data/lib/talon_one/models/rollback_increased_achievement_progress_effect_props.rb +288 -0
  204. data/lib/talon_one/models/rule_failure_reason.rb +24 -4
  205. data/lib/talon_one/models/scim_base_user.rb +237 -0
  206. data/lib/talon_one/models/scim_base_user_name.rb +208 -0
  207. data/lib/talon_one/models/scim_new_user.rb +237 -0
  208. data/lib/talon_one/models/scim_patch_operation.rb +267 -0
  209. data/lib/talon_one/models/scim_patch_request.rb +226 -0
  210. data/lib/talon_one/models/scim_resource.rb +228 -0
  211. data/lib/talon_one/models/scim_resource_types_list_response.rb +214 -0
  212. data/lib/talon_one/models/scim_schema_resource.rb +239 -0
  213. data/lib/talon_one/models/scim_schemas_list_response.rb +236 -0
  214. data/lib/talon_one/models/scim_service_provider_config_response.rb +256 -0
  215. data/lib/talon_one/models/scim_service_provider_config_response_bulk.rb +228 -0
  216. data/lib/talon_one/models/scim_service_provider_config_response_change_password.rb +208 -0
  217. data/lib/talon_one/models/scim_service_provider_config_response_filter.rb +218 -0
  218. data/lib/talon_one/models/scim_service_provider_config_response_patch.rb +208 -0
  219. data/lib/talon_one/models/scim_user.rb +252 -0
  220. data/lib/talon_one/models/scim_users_list_response.rb +236 -0
  221. data/lib/talon_one/models/sso_config.rb +14 -4
  222. data/lib/talon_one/models/tier.rb +12 -2
  223. data/lib/talon_one/models/transfer_loyalty_card.rb +14 -4
  224. data/lib/talon_one/models/update_application.rb +24 -4
  225. data/lib/talon_one/models/update_application_cif.rb +237 -0
  226. data/lib/talon_one/models/update_campaign.rb +1 -1
  227. data/lib/talon_one/models/update_coupon.rb +1 -1
  228. data/lib/talon_one/models/update_coupon_batch.rb +1 -1
  229. data/lib/talon_one/models/update_loyalty_card.rb +15 -5
  230. data/lib/talon_one/models/update_loyalty_program.rb +44 -25
  231. data/lib/talon_one/models/update_referral.rb +1 -1
  232. data/lib/talon_one/models/update_referral_batch.rb +1 -1
  233. data/lib/talon_one/models/user.rb +14 -4
  234. data/lib/talon_one/models/webhook.rb +11 -1
  235. data/lib/talon_one/models/webhook_with_outgoing_integration_details.rb +11 -1
  236. data/lib/talon_one/version.rb +1 -1
  237. data/lib/talon_one.rb +54 -11
  238. data/spec/api/integration_api_spec.rb +18 -3
  239. data/spec/api/management_api_spec.rb +227 -23
  240. data/spec/models/achievement_progress_spec.rb +6 -0
  241. data/spec/models/additional_campaign_properties_spec.rb +7 -1
  242. data/spec/models/analytics_data_point_spec.rb +47 -0
  243. data/spec/models/analytics_data_point_with_trend_and_influenced_rate_spec.rb +53 -0
  244. data/spec/models/analytics_data_point_with_trend_and_uplift_spec.rb +53 -0
  245. data/spec/models/analytics_data_point_with_trend_spec.rb +47 -0
  246. data/spec/models/application_campaign_analytics_spec.rb +1 -19
  247. data/spec/models/application_campaign_stats_spec.rb +0 -6
  248. data/spec/models/application_cif_expression_spec.rb +71 -0
  249. data/spec/models/application_cif_spec.rb +89 -0
  250. data/spec/models/application_spec.rb +12 -0
  251. data/spec/models/async_coupon_deletion_job_response_spec.rb +41 -0
  252. data/spec/models/attribute_spec.rb +1 -1
  253. data/spec/models/base_loyalty_program_spec.rb +18 -6
  254. data/spec/models/base_notification_spec.rb +1 -1
  255. data/spec/models/campaign_collection_edited_notification_spec.rb +53 -0
  256. data/spec/models/campaign_notification_policy_spec.rb +6 -0
  257. data/spec/models/campaign_spec.rb +43 -1
  258. data/spec/models/campaign_store_budget_spec.rb +65 -0
  259. data/spec/models/campaign_versions_spec.rb +71 -0
  260. data/spec/models/card_added_deducted_points_notification_policy_spec.rb +51 -0
  261. data/spec/models/coupon_deletion_filters_spec.rb +123 -0
  262. data/spec/models/coupon_deletion_job_spec.rb +107 -0
  263. data/spec/models/effect_entity_spec.rb +24 -0
  264. data/spec/models/effect_spec.rb +24 -0
  265. data/spec/models/environment_spec.rb +6 -0
  266. data/spec/models/generate_campaign_description_spec.rb +47 -0
  267. data/spec/models/generate_campaign_tags_spec.rb +41 -0
  268. data/spec/models/generate_item_filter_description_spec.rb +41 -0
  269. data/spec/models/generate_loyalty_card_spec.rb +51 -0
  270. data/spec/models/generate_rule_title_rule_spec.rb +47 -0
  271. data/spec/models/generate_rule_title_spec.rb +47 -0
  272. data/spec/models/loyalty_balance_with_tier_spec.rb +83 -0
  273. data/spec/models/loyalty_balances_with_tiers_spec.rb +47 -0
  274. data/spec/models/loyalty_card_batch_response_spec.rb +47 -0
  275. data/spec/models/loyalty_card_batch_spec.rb +57 -0
  276. data/spec/models/loyalty_card_spec.rb +12 -0
  277. data/spec/models/loyalty_program_spec.rb +30 -6
  278. data/spec/models/new_app_wide_coupon_deletion_job_spec.rb +47 -0
  279. data/spec/models/new_application_cif_expression_spec.rb +53 -0
  280. data/spec/models/new_application_cif_spec.rb +71 -0
  281. data/spec/models/new_application_spec.rb +6 -0
  282. data/spec/models/new_attribute_spec.rb +1 -1
  283. data/spec/models/new_coupon_deletion_job_spec.rb +41 -0
  284. data/spec/models/new_loyalty_program_spec.rb +18 -6
  285. data/spec/models/new_notification_test_spec.rb +1 -1
  286. data/spec/models/new_outgoing_integration_webhook_spec.rb +6 -0
  287. data/spec/models/new_revision_version_spec.rb +105 -0
  288. data/spec/models/new_webhook_spec.rb +6 -0
  289. data/spec/models/okta_event_payload_data_spec.rb +41 -0
  290. data/spec/models/okta_event_payload_spec.rb +41 -0
  291. data/spec/models/okta_event_spec.rb +47 -0
  292. data/spec/models/okta_event_target_spec.rb +53 -0
  293. data/spec/models/projected_tier_spec.rb +53 -0
  294. data/spec/models/reject_coupon_effect_props_spec.rb +6 -0
  295. data/spec/models/reject_referral_effect_props_spec.rb +6 -0
  296. data/spec/models/revision_activation_spec.rb +41 -0
  297. data/spec/models/revision_spec.rb +95 -0
  298. data/spec/models/revision_version_spec.rb +153 -0
  299. data/spec/models/rollback_increased_achievement_progress_effect_props_spec.rb +71 -0
  300. data/spec/models/rule_failure_reason_spec.rb +12 -0
  301. data/spec/models/scim_base_user_name_spec.rb +41 -0
  302. data/spec/models/scim_base_user_spec.rb +59 -0
  303. data/spec/models/scim_new_user_spec.rb +59 -0
  304. data/spec/models/scim_patch_operation_spec.rb +57 -0
  305. data/spec/models/scim_patch_request_spec.rb +47 -0
  306. data/spec/models/scim_resource_spec.rb +53 -0
  307. data/spec/models/scim_resource_types_list_response_spec.rb +41 -0
  308. data/spec/models/scim_schema_resource_spec.rb +59 -0
  309. data/spec/models/scim_schemas_list_response_spec.rb +53 -0
  310. data/spec/models/scim_service_provider_config_response_bulk_spec.rb +53 -0
  311. data/spec/models/scim_service_provider_config_response_change_password_spec.rb +41 -0
  312. data/spec/models/scim_service_provider_config_response_filter_spec.rb +47 -0
  313. data/spec/models/scim_service_provider_config_response_patch_spec.rb +41 -0
  314. data/spec/models/scim_service_provider_config_response_spec.rb +71 -0
  315. data/spec/models/scim_user_spec.rb +65 -0
  316. data/spec/models/scim_users_list_response_spec.rb +53 -0
  317. data/spec/models/sso_config_spec.rb +6 -0
  318. data/spec/models/tier_spec.rb +6 -0
  319. data/spec/models/transfer_loyalty_card_spec.rb +6 -0
  320. data/spec/models/update_application_cif_spec.rb +59 -0
  321. data/spec/models/update_application_spec.rb +12 -0
  322. data/spec/models/update_loyalty_card_spec.rb +6 -0
  323. data/spec/models/update_loyalty_program_spec.rb +18 -6
  324. data/spec/models/user_spec.rb +6 -0
  325. data/spec/models/webhook_spec.rb +6 -0
  326. data/spec/models/webhook_with_outgoing_integration_details_spec.rb +6 -0
  327. metadata +219 -3
@@ -12,6 +12,7 @@ Method | HTTP request | Description
12
12
  [**delete_audience_v2**](IntegrationApi.md#delete_audience_v2) | **DELETE** /v2/audiences/{audienceId} | Delete audience
13
13
  [**delete_coupon_reservation**](IntegrationApi.md#delete_coupon_reservation) | **DELETE** /v1/coupon_reservations/{couponValue} | Delete coupon reservations
14
14
  [**delete_customer_data**](IntegrationApi.md#delete_customer_data) | **DELETE** /v1/customer_data/{integrationId} | Delete customer's personal data
15
+ [**generate_loyalty_card**](IntegrationApi.md#generate_loyalty_card) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/cards | Generate loyalty card
15
16
  [**get_customer_inventory**](IntegrationApi.md#get_customer_inventory) | **GET** /v1/customer_profiles/{integrationId}/inventory | List customer data
16
17
  [**get_customer_session**](IntegrationApi.md#get_customer_session) | **GET** /v2/customer_sessions/{customerSessionId} | Get customer session
17
18
  [**get_loyalty_balances**](IntegrationApi.md#get_loyalty_balances) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/balances | Get customer's loyalty points
@@ -471,6 +472,62 @@ nil (empty response body)
471
472
  - **Accept**: application/json
472
473
 
473
474
 
475
+ ## generate_loyalty_card
476
+
477
+ > LoyaltyCard generate_loyalty_card(loyalty_program_id, body)
478
+
479
+ Generate loyalty card
480
+
481
+ Generate a loyalty card in a specified [card-based loyalty program](https://docs.talon.one/docs/product/loyalty-programs/card-based/card-based-overview). To link the card to one or more customer profiles, use the `customerProfileIds` parameter in the request body. **Note:** - The number of customer profiles linked to the loyalty card cannot exceed the loyalty program's `usersPerCardLimit`. To find the program's limit, use the [Get loyalty program](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyProgram) endpoint. - If the loyalty program has a defined code format, it will be used for the loyalty card identifier.
482
+
483
+ ### Example
484
+
485
+ ```ruby
486
+ # load the gem
487
+ require 'talon_one'
488
+ # setup authorization
489
+ TalonOne.configure do |config|
490
+ # Configure API key authorization: api_key_v1
491
+ config.api_key['Authorization'] = 'YOUR API KEY'
492
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
493
+ #config.api_key_prefix['Authorization'] = 'Bearer'
494
+ end
495
+
496
+ api_instance = TalonOne::IntegrationApi.new
497
+ loyalty_program_id = 56 # Integer | 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.
498
+ body = TalonOne::GenerateLoyaltyCard.new # GenerateLoyaltyCard | body
499
+
500
+ begin
501
+ #Generate loyalty card
502
+ result = api_instance.generate_loyalty_card(loyalty_program_id, body)
503
+ p result
504
+ rescue TalonOne::ApiError => e
505
+ puts "Exception when calling IntegrationApi->generate_loyalty_card: #{e}"
506
+ end
507
+ ```
508
+
509
+ ### Parameters
510
+
511
+
512
+ Name | Type | Description | Notes
513
+ ------------- | ------------- | ------------- | -------------
514
+ **loyalty_program_id** | **Integer**| 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. |
515
+ **body** | [**GenerateLoyaltyCard**](GenerateLoyaltyCard.md)| body |
516
+
517
+ ### Return type
518
+
519
+ [**LoyaltyCard**](LoyaltyCard.md)
520
+
521
+ ### Authorization
522
+
523
+ [api_key_v1](../README.md#api_key_v1)
524
+
525
+ ### HTTP request headers
526
+
527
+ - **Content-Type**: application/json
528
+ - **Accept**: application/json
529
+
530
+
474
531
  ## get_customer_inventory
475
532
 
476
533
  > CustomerInventory get_customer_inventory(integration_id, opts)
@@ -595,7 +652,7 @@ Name | Type | Description | Notes
595
652
 
596
653
  ## get_loyalty_balances
597
654
 
598
- > LoyaltyBalances get_loyalty_balances(loyalty_program_id, integration_id, opts)
655
+ > LoyaltyBalancesWithTiers get_loyalty_balances(loyalty_program_id, integration_id, opts)
599
656
 
600
657
  Get customer's loyalty points
601
658
 
@@ -619,7 +676,9 @@ loyalty_program_id = 56 # Integer | Identifier of the profile-based loyalty prog
619
676
  integration_id = 'integration_id_example' # String | The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier.
620
677
  opts = {
621
678
  end_date: DateTime.parse('2013-10-20T19:20:30+01:00'), # DateTime | Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. **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.
622
- subledger_id: 'subledger_id_example' # String | The ID of the subledger by which we filter the data.
679
+ subledger_id: 'subledger_id_example', # String | The ID of the subledger by which we filter the data.
680
+ include_tiers: false, # Boolean | Indicates whether tier information is included in the response. When set to `true`, the response includes information about the current tier and the number of points required to move to next tier.
681
+ include_projected_tier: false # Boolean | Indicates whether the customer's projected tier information is included in the response. When set to `true`, the response includes information about the customer’s active points and the name of the projected tier. **Note** We recommend filtering by `subledgerId` for better performance.
623
682
  }
624
683
 
625
684
  begin
@@ -640,10 +699,12 @@ Name | Type | Description | Notes
640
699
  **integration_id** | **String**| The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier. |
641
700
  **end_date** | **DateTime**| Used to return expired, active, and pending loyalty balances before this timestamp. You can enter any past, present, or future timestamp value. **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]
642
701
  **subledger_id** | **String**| The ID of the subledger by which we filter the data. | [optional]
702
+ **include_tiers** | **Boolean**| Indicates whether tier information is included in the response. When set to `true`, the response includes information about the current tier and the number of points required to move to next tier. | [optional] [default to false]
703
+ **include_projected_tier** | **Boolean**| Indicates whether the customer's projected tier information is included in the response. When set to `true`, the response includes information about the customer’s active points and the name of the projected tier. **Note** We recommend filtering by `subledgerId` for better performance. | [optional] [default to false]
643
704
 
644
705
  ### Return type
645
706
 
646
- [**LoyaltyBalances**](LoyaltyBalances.md)
707
+ [**LoyaltyBalancesWithTiers**](LoyaltyBalancesWithTiers.md)
647
708
 
648
709
  ### Authorization
649
710
 
@@ -1221,7 +1282,7 @@ Name | Type | Description | Notes
1221
1282
 
1222
1283
  Sync cart item catalog
1223
1284
 
1224
- Perform one or more of the following actions for a given cart item catalog: - Adding an item to the catalog. - Adding several items to the catalog. - Editing the attributes of an item in the catalog. - Editing the attributes of several items in the catalog. - Removing an item from the catalog. - Removing several items from the catalog. You can 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**: 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 several 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>Editing 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>Editing the attributes of several 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 several 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>
1285
+ 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>
1225
1286
 
1226
1287
  ### Example
1227
1288
 
@@ -1640,7 +1701,7 @@ api_instance = TalonOne::IntegrationApi.new
1640
1701
  customer_session_id = 'customer_session_id_example' # String | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#operation/getApplicationSessions) endpoint.
1641
1702
  body = TalonOne::IntegrationRequest.new # IntegrationRequest | body
1642
1703
  opts = {
1643
- dry: true, # Boolean | Indicates whether to persist the changes. Changes are ignored when `dry=true`. When set to `true`: - The endpoint will **only** consider 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).
1704
+ 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).
1644
1705
  now: DateTime.parse('2013-10-20T19:20:30+01:00') # DateTime | 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:** - 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`.
1645
1706
  }
1646
1707
 
@@ -1660,7 +1721,7 @@ Name | Type | Description | Notes
1660
1721
  ------------- | ------------- | ------------- | -------------
1661
1722
  **customer_session_id** | **String**| The &#x60;integration ID&#x60; 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&#39;s **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#operation/getApplicationSessions) endpoint. |
1662
1723
  **body** | [**IntegrationRequest**](IntegrationRequest.md)| body |
1663
- **dry** | **Boolean**| Indicates whether to persist the changes. Changes are ignored when &#x60;dry&#x3D;true&#x60;. When set to &#x60;true&#x60;: - The endpoint will **only** consider the payload that you pass when **closing** the session. When you do not use the &#x60;dry&#x60; parameter, the endpoint behaves as a typical PUT endpoint. Each update builds upon the previous ones. - You can use the &#x60;evaluableCampaignIds&#x60; body property to select specific campaigns to run. [See the docs](https://docs.talon.one/docs/dev/integration-api/dry-requests). | [optional]
1724
+ **dry** | **Boolean**| Indicates whether to persist the changes. Changes are ignored when &#x60;dry&#x3D;true&#x60;. When set to &#x60;true&#x60;: - The endpoint considers **only** the payload that you pass when **closing** the session. When you do not use the &#x60;dry&#x60; parameter, the endpoint behaves as a typical PUT endpoint. Each update builds upon the previous ones. - You can use the &#x60;evaluableCampaignIds&#x60; body property to select specific campaigns to run. [See the docs](https://docs.talon.one/docs/dev/integration-api/dry-requests). | [optional]
1664
1725
  **now** | **DateTime**| 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:** - It must be an RFC3339 timestamp string. - It can **only** be a date in the future. - It can **only** be used if the &#x60;dry&#x60; parameter in the query is set to &#x60;true&#x60;. | [optional]
1665
1726
 
1666
1727
  ### Return type
@@ -12,7 +12,7 @@ Name | Type | Description | Notes
12
12
  **discount_limit** | **Float** | The total discount value that the code can give. Typically used to represent a gift card value. | [optional]
13
13
  **reservation_limit** | **Integer** | The number of reservations that can be made with this coupon code. | [optional]
14
14
  **start_date** | **DateTime** | Timestamp at which point the coupon becomes valid. | [optional]
15
- **expiry_date** | **DateTime** | Expiration date of the coupon. Coupon never expires if this is omitted, zero, or negative. | [optional]
15
+ **expiry_date** | **DateTime** | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional]
16
16
  **limits** | [**Array&lt;LimitConfig&gt;**](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]
17
17
  **usage_counter** | **Integer** | The number of times the coupon has been successfully redeemed. |
18
18
  **discount_counter** | **Float** | The amount of discounts given on rules redeeming this coupon. Only usable if a coupon discount budget was set for this coupon. | [optional]
@@ -12,7 +12,7 @@ Name | Type | Description | Notes
12
12
  **discount_limit** | **Float** | The total discount value that the code can give. Typically used to represent a gift card value. | [optional]
13
13
  **reservation_limit** | **Integer** | The number of reservations that can be made with this coupon code. | [optional]
14
14
  **start_date** | **DateTime** | Timestamp at which point the coupon becomes valid. | [optional]
15
- **expiry_date** | **DateTime** | Expiration date of the coupon. Coupon never expires if this is omitted, zero, or negative. | [optional]
15
+ **expiry_date** | **DateTime** | Expiration date of the coupon. Coupon never expires if this is omitted. | [optional]
16
16
  **limits** | [**Array&lt;LimitConfig&gt;**](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]
17
17
  **usage_counter** | **Integer** | The number of times the coupon has been successfully redeemed. |
18
18
  **discount_counter** | **Float** | The amount of discounts given on rules redeeming this coupon. Only usable if a coupon discount budget was set for this coupon. | [optional]
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
7
7
  **id** | **Integer** | Internal ID of this entity. |
8
8
  **created** | **DateTime** | The time this entity was created. |
9
9
  **start_date** | **DateTime** | Timestamp at which point the referral code becomes valid. | [optional]
10
- **expiry_date** | **DateTime** | Expiration date of the referral code. Referral never expires if this is omitted, zero, or negative. | [optional]
10
+ **expiry_date** | **DateTime** | Expiration date of the referral code. Referral never expires if this is omitted. | [optional]
11
11
  **usage_limit** | **Integer** | The number of times a referral code can be used. &#x60;0&#x60; means no limit but any campaign usage limits will still apply. |
12
12
  **campaign_id** | **Integer** | ID of the campaign from which the referral received the referral code. |
13
13
  **advocate_profile_integration_id** | **String** | The Integration ID of the Advocate&#39;s Profile. |
@@ -0,0 +1,31 @@
1
+ # TalonOne::LoyaltyBalanceWithTier
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **active_points** | **Float** | Total amount of points awarded to this customer and available to spend. | [optional]
8
+ **pending_points** | **Float** | Total amount of points awarded to this customer but not available until their start date. | [optional]
9
+ **spent_points** | **Float** | Total amount of points already spent by this customer. | [optional]
10
+ **expired_points** | **Float** | Total amount of points awarded but never redeemed. They cannot be used anymore. | [optional]
11
+ **current_tier** | [**Tier**](Tier.md) | | [optional]
12
+ **projected_tier** | [**ProjectedTier**](ProjectedTier.md) | | [optional]
13
+ **points_to_next_tier** | **Float** | The number of points required to move up a tier. | [optional]
14
+ **next_tier_name** | **String** | The name of the tier consecutive to the current tier. | [optional]
15
+
16
+ ## Code Sample
17
+
18
+ ```ruby
19
+ require 'TalonOne'
20
+
21
+ instance = TalonOne::LoyaltyBalanceWithTier.new(active_points: 286.0,
22
+ pending_points: 50.0,
23
+ spent_points: 150.0,
24
+ expired_points: 286.0,
25
+ current_tier: null,
26
+ projected_tier: null,
27
+ points_to_next_tier: 20.0,
28
+ next_tier_name: silver)
29
+ ```
30
+
31
+
@@ -0,0 +1,19 @@
1
+ # TalonOne::LoyaltyBalancesWithTiers
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **balance** | [**LoyaltyBalanceWithTier**](LoyaltyBalanceWithTier.md) | | [optional]
8
+ **subledger_balances** | [**Hash&lt;String, LoyaltyBalanceWithTier&gt;**](LoyaltyBalanceWithTier.md) | Map of the loyalty balances of the subledgers of a ledger. | [optional]
9
+
10
+ ## Code Sample
11
+
12
+ ```ruby
13
+ require 'TalonOne'
14
+
15
+ instance = TalonOne::LoyaltyBalancesWithTiers.new(balance: null,
16
+ subledger_balances: {&quot;mysubledger&quot;:{&quot;activePoints&quot;:286,&quot;pendingPoints&quot;:50,&quot;spentPoints&quot;:150,&quot;expiredPoints&quot;:25}})
17
+ ```
18
+
19
+
data/docs/LoyaltyCard.md CHANGED
@@ -7,7 +7,8 @@ Name | Type | Description | Notes
7
7
  **id** | **Integer** | Internal ID of this entity. |
8
8
  **created** | **DateTime** | The time this entity was created. |
9
9
  **program_id** | **Integer** | The ID of the loyalty program that owns this entity. |
10
- **status** | **String** | Status of the loyalty card. Can be one of: [&#39;active&#39;, &#39;inactive&#39;] |
10
+ **status** | **String** | Status of the loyalty card. Can be &#x60;active&#x60; or &#x60;inactive&#x60;. |
11
+ **block_reason** | **String** | Reason for transferring and blocking the loyalty card. | [optional]
11
12
  **identifier** | **String** | The alphanumeric identifier of the loyalty card. |
12
13
  **users_per_card_limit** | **Integer** | The max amount of customer profiles that can be linked to the card. 0 means unlimited. |
13
14
  **profiles** | [**Array&lt;LoyaltyCardProfileRegistration&gt;**](LoyaltyCardProfileRegistration.md) | Integration IDs of the customers profiles linked to the card. | [optional]
@@ -16,6 +17,7 @@ Name | Type | Description | Notes
16
17
  **modified** | **DateTime** | Timestamp of the most recent update of the loyalty card. | [optional]
17
18
  **old_card_identifier** | **String** | The alphanumeric identifier of the loyalty card. | [optional]
18
19
  **new_card_identifier** | **String** | The alphanumeric identifier of the loyalty card. | [optional]
20
+ **batch_id** | **String** | The ID of the batch in which the loyalty card was created. | [optional]
19
21
 
20
22
  ## Code Sample
21
23
 
@@ -26,6 +28,7 @@ instance = TalonOne::LoyaltyCard.new(id: 6,
26
28
  created: 2020-06-10T09:05:27.993483Z,
27
29
  program_id: 125,
28
30
  status: active,
31
+ block_reason: Current card lost. Customer needs a new card.,
29
32
  identifier: summer-loyalty-card-0543,
30
33
  users_per_card_limit: 111,
31
34
  profiles: null,
@@ -33,7 +36,8 @@ instance = TalonOne::LoyaltyCard.new(id: 6,
33
36
  subledgers: null,
34
37
  modified: 2021-09-12T10:12:42Z,
35
38
  old_card_identifier: summer-loyalty-card-0543,
36
- new_card_identifier: summer-loyalty-card-0543)
39
+ new_card_identifier: summer-loyalty-card-0543,
40
+ batch_id: wdefpov)
37
41
  ```
38
42
 
39
43
 
@@ -0,0 +1,21 @@
1
+ # TalonOne::LoyaltyCardBatch
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **number_of_cards** | **Integer** | Number of loyalty cards in the batch. |
8
+ **batch_id** | **String** | ID of the loyalty card batch. | [optional]
9
+ **status** | **String** | Status of the loyalty cards in the batch. | [optional] [default to &#39;active&#39;]
10
+
11
+ ## Code Sample
12
+
13
+ ```ruby
14
+ require 'TalonOne'
15
+
16
+ instance = TalonOne::LoyaltyCardBatch.new(number_of_cards: 5000,
17
+ batch_id: hwernpjz,
18
+ status: active)
19
+ ```
20
+
21
+
@@ -0,0 +1,19 @@
1
+ # TalonOne::LoyaltyCardBatchResponse
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **number_of_cards_generated** | **Integer** | Number of loyalty cards in the batch. |
8
+ **batch_id** | **String** | ID of the loyalty card batch. |
9
+
10
+ ## Code Sample
11
+
12
+ ```ruby
13
+ require 'TalonOne'
14
+
15
+ instance = TalonOne::LoyaltyCardBatchResponse.new(number_of_cards_generated: 5000,
16
+ batch_id: hwernpjz)
17
+ ```
18
+
19
+
@@ -14,18 +14,22 @@ Name | Type | Description | Notes
14
14
  **allow_subledger** | **Boolean** | Indicates if this program supports subledgers inside the program. |
15
15
  **users_per_card_limit** | **Integer** | 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 &#x60;cardBased&#x60; is &#x60;true&#x60;. | [optional]
16
16
  **sandbox** | **Boolean** | 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. |
17
- **tiers_expiration_policy** | **String** | The policy that defines which date is used to calculate the expiration date of a customer&#39;s current tier. - &#x60;tier_start_date&#x60;: The tier expiration date is calculated based on when the customer joined the current tier. - &#x60;program_join_date&#x60;: The tier expiration date is calculated based on when the customer joined the loyalty program. | [optional]
18
- **tiers_expire_in** | **String** | The amount of time after which the tier expires. The time format is an **integer** followed by one letter indicating the time unit. Examples: &#x60;30s&#x60;, &#x60;40m&#x60;, &#x60;1h&#x60;, &#x60;5D&#x60;, &#x60;7W&#x60;, &#x60;10M&#x60;, &#x60;15Y&#x60;. Available units: - &#x60;s&#x60;: seconds - &#x60;m&#x60;: minutes - &#x60;h&#x60;: hours - &#x60;D&#x60;: days - &#x60;W&#x60;: weeks - &#x60;M&#x60;: months - &#x60;Y&#x60;: years You can round certain units up or down: - &#x60;_D&#x60; for rounding down days only. Signifies the start of the day. - &#x60;_U&#x60; for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. | [optional]
19
- **tiers_downgrade_policy** | **String** | Customers&#39;s tier downgrade policy. - &#x60;one_down&#x60;: Once the tier expires and if the user doesn&#39;t have enough points to stay in the tier, the user is downgraded one tier down. - &#x60;balance_based&#x60;: Once the tier expires, the user&#39;s tier is evaluated based on the amount of active points the user has at this instant. | [optional]
20
17
  **program_join_policy** | **String** | The policy that defines when the customer joins the loyalty program. - &#x60;not_join&#x60;: 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. - &#x60;points_activated&#x60;: The customer joins the loyalty program only when their earned loyalty points become active for the first time. - &#x60;points_earned&#x60;: The customer joins the loyalty program when they earn loyalty points for the first time. | [optional]
18
+ **tiers_expiration_policy** | **String** | The policy that defines how tier expiration, used to reevaluate the customer&#39;s current tier, is determined. - &#x60;tier_start_date&#x60;: The tier expiration is relative to when the customer joined the current tier. - &#x60;program_join_date&#x60;: The tier expiration is relative to when the customer joined the loyalty program. - &#x60;customer_attribute&#x60;: The tier expiration is determined by a custom customer attribute. - &#x60;absolute_expiration&#x60;: The tier is reevaluated at the start of each tier cycle. For this policy, it is required to provide a &#x60;tierCycleStartDate&#x60;. | [optional]
19
+ **tier_cycle_start_date** | **DateTime** | 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 &#x60;absolute_expiration&#x60;. | [optional]
20
+ **tiers_expire_in** | **String** | 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: &#x60;30s&#x60;, &#x60;40m&#x60;, &#x60;1h&#x60;, &#x60;5D&#x60;, &#x60;7W&#x60;, &#x60;10M&#x60;, &#x60;15Y&#x60;. Available units: - &#x60;s&#x60;: seconds - &#x60;m&#x60;: minutes - &#x60;h&#x60;: hours - &#x60;D&#x60;: days - &#x60;W&#x60;: weeks - &#x60;M&#x60;: months - &#x60;Y&#x60;: years You can round certain units up or down: - &#x60;_D&#x60; for rounding down days only. Signifies the start of the day. - &#x60;_U&#x60; for rounding up days, weeks, months and years. Signifies the end of the day, week, month or year. | [optional]
21
+ **tiers_downgrade_policy** | **String** | The policy that defines how customer tiers are downgraded in the loyalty program after tier reevaluation. - &#x60;one_down&#x60;: If the customer doesn&#39;t have enough points to stay in the current tier, they are downgraded by one tier. - &#x60;balance_based&#x60;: The customer&#39;s tier is reevaluated based on the amount of active points they have at the moment. | [optional]
22
+ **card_code_settings** | [**CodeGeneratorSettings**](CodeGeneratorSettings.md) | | [optional]
21
23
  **account_id** | **Integer** | The ID of the Talon.One account that owns this program. |
22
24
  **name** | **String** | The internal name for the Loyalty Program. This is an immutable value. |
23
25
  **tiers** | [**Array&lt;LoyaltyTier&gt;**](LoyaltyTier.md) | The tiers in this loyalty program. | [optional]
24
26
  **timezone** | **String** | A string containing an IANA timezone descriptor. |
25
27
  **card_based** | **Boolean** | Defines the type of loyalty program: - &#x60;true&#x60;: the program is a card-based. - &#x60;false&#x60;: the program is profile-based. | [default to false]
26
28
  **can_update_tiers** | **Boolean** | &#x60;True&#x60; if the tier definitions can be updated. | [optional] [default to false]
27
- **can_update_join_policy** | **Boolean** | Indicates whether the program join policy can be updated. The join policy can be updated when this value is set to &#x60;true&#x60;. | [optional]
29
+ **can_update_join_policy** | **Boolean** | &#x60;True&#x60; if the program join policy can be updated. | [optional]
30
+ **can_update_tier_expiration_policy** | **Boolean** | &#x60;True&#x60; if the tier expiration policy can be updated. | [optional]
28
31
  **can_upgrade_to_advanced_tiers** | **Boolean** | &#x60;True&#x60; if the program can be upgraded to use the &#x60;tiersExpireIn&#x60; and &#x60;tiersDowngradePolicy&#x60; properties. | [optional] [default to false]
32
+ **can_update_subledgers** | **Boolean** | &#x60;True&#x60; if the &#x60;allowSubledger&#x60; property can be updated in the loyalty program. | [optional] [default to false]
29
33
 
30
34
  ## Code Sample
31
35
 
@@ -42,10 +46,12 @@ instance = TalonOne::LoyaltyProgram.new(id: null,
42
46
  allow_subledger: false,
43
47
  users_per_card_limit: 111,
44
48
  sandbox: true,
49
+ program_join_policy: null,
45
50
  tiers_expiration_policy: null,
51
+ tier_cycle_start_date: 2021-09-12T10:12:42Z,
46
52
  tiers_expire_in: 27W_U,
47
53
  tiers_downgrade_policy: null,
48
- program_join_policy: null,
54
+ card_code_settings: null,
49
55
  account_id: 1,
50
56
  name: my_program,
51
57
  tiers: [{name&#x3D;Gold, minPoints&#x3D;300, id&#x3D;3, created&#x3D;2021-06-10T09:05:27.993483Z, programID&#x3D;139}, {name&#x3D;Silver, minPoints&#x3D;200, id&#x3D;2, created&#x3D;2021-06-10T09:04:59.355258Z, programId&#x3D;139}, {name&#x3D;Bronze, minPoints&#x3D;100, id&#x3D;1, created&#x3D;2021-06-10T09:04:39.355258Z, programId&#x3D;139}],
@@ -53,7 +59,9 @@ instance = TalonOne::LoyaltyProgram.new(id: null,
53
59
  card_based: true,
54
60
  can_update_tiers: true,
55
61
  can_update_join_policy: true,
56
- can_upgrade_to_advanced_tiers: true)
62
+ can_update_tier_expiration_policy: true,
63
+ can_upgrade_to_advanced_tiers: true,
64
+ can_update_subledgers: true)
57
65
  ```
58
66
 
59
67