voucherify 6.0.0 → 7.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Dockerfile +1 -1
- data/ENDPOINTS-COVERAGE.md +94 -95
- data/EXAMPLES.md +3 -3
- data/Gemfile.lock +4 -4
- data/README.md +345 -9
- data/__tests__/lib/stackables.rb +18 -0
- data/__tests__/spec/09_redemptions_spec.rb +5 -0
- data/docs/ApplicableTo.md +7 -7
- data/docs/BinApi.md +132 -0
- data/docs/Campaign.md +40 -0
- data/docs/CampaignBase.md +1 -0
- data/docs/CampaignTemplate.md +14 -0
- data/docs/CampaignsApi.md +3 -1
- data/docs/CampaignsCreateRequestBody.md +1 -2
- data/docs/CampaignsCreateResponseBody.md +1 -0
- data/docs/CampaignsGetResponseBody.md +1 -0
- data/docs/CampaignsUpdateRequestBody.md +1 -4
- data/docs/CampaignsUpdateResponseBody.md +1 -0
- data/docs/CampaignsVouchersCreateCombinedResponseBodyPublish.md +1 -1
- data/docs/CampaignsVouchersCreateCombinedResponseBodyRedemption.md +1 -1
- data/docs/CampaignsVouchersCreateResponseBodyPublish.md +1 -1
- data/docs/CampaignsVouchersCreateResponseBodyRedemption.md +1 -1
- data/docs/CategoriesCreateRequestBody.md +1 -1
- data/docs/CategoriesCreateResponseBody.md +1 -1
- data/docs/CategoriesGetResponseBody.md +1 -2
- data/docs/CategoriesUpdateRequestBody.md +1 -1
- data/docs/CategoriesUpdateResponseBody.md +1 -1
- data/docs/Category.md +1 -2
- data/docs/CategoryWithStackingRulesType.md +14 -0
- data/docs/ClientPromotionsTiersListResponseBody.md +1 -1
- data/docs/ClientValidationsValidateResponseBodyRedeemablesItem.md +1 -1
- data/docs/CustomersActivityListResponseBody.md +1 -1
- data/docs/CustomersApi.md +2 -64
- data/docs/Error.md +1 -1
- data/docs/ExportsApi.md +13 -1
- data/docs/{ParameterFiltersListCustomerRedeemablesCreatedAtConditions.md → FilterConditionsDateTime.md} +1 -1
- data/docs/InapplicableTo.md +7 -7
- data/docs/Location.md +13 -0
- data/docs/LocationShape.md +11 -0
- data/docs/LocationShapeDistance.md +9 -0
- data/docs/LocationShapeGeojson.md +9 -0
- data/docs/LocationsApi.md +133 -0
- data/docs/LocationsGetResponseBody.md +13 -0
- data/docs/LocationsGetResponseBodyShape.md +11 -0
- data/docs/LocationsGetResponseBodyShapeDistance.md +9 -0
- data/docs/LocationsGetResponseBodyShapeGeojson.md +9 -0
- data/docs/LocationsListResponseBody.md +12 -0
- data/docs/LoyaltiesApi.md +9 -3
- data/docs/LoyaltiesCreateCampaignRequestBody.md +1 -1
- data/docs/LoyaltiesCreateCampaignResponseBody.md +1 -0
- data/docs/LoyaltiesGetCampaignResponseBody.md +1 -0
- data/docs/LoyaltiesMemberActivityListResponseBody.md +1 -1
- data/docs/LoyaltiesMembersCreateResponseBodyPublish.md +1 -1
- data/docs/LoyaltiesMembersCreateResponseBodyRedemption.md +1 -1
- data/docs/LoyaltiesMembersGetResponseBodyPublish.md +1 -1
- data/docs/LoyaltiesMembersGetResponseBodyRedemption.md +1 -1
- data/docs/LoyaltiesMembersRedemptionRedeemResponseBody.md +1 -1
- data/docs/LoyaltiesMembersRedemptionRedeemResponseBodyChannel.md +2 -2
- data/docs/LoyaltiesMembersRedemptionRedeemResponseBodyVoucher.md +1 -1
- data/docs/LoyaltiesMembersRedemptionRedeemResponseBodyVoucherPublish.md +1 -1
- data/docs/LoyaltiesMembersRedemptionRedeemResponseBodyVoucherRedemption.md +1 -1
- data/docs/LoyaltiesMembersTransactionsListResponseBody.md +2 -1
- data/docs/LoyaltiesMembersTransfersCreateResponseBodyPublish.md +1 -1
- data/docs/LoyaltiesMembersTransfersCreateResponseBodyRedemption.md +1 -1
- data/docs/LoyaltiesRewardAssignmentsGetResponseBodyParametersLoyalty.md +1 -0
- data/docs/LoyaltiesRewardsCreateAssignmentResponseBodyParametersLoyalty.md +1 -0
- data/docs/LoyaltiesRewardsGetResponseBodyParametersLoyalty.md +1 -0
- data/docs/LoyaltiesRewardsUpdateAssignmentRequestBodyParametersLoyalty.md +1 -0
- data/docs/LoyaltiesRewardsUpdateAssignmentResponseBodyParametersLoyalty.md +1 -0
- data/docs/LoyaltiesUpdateCampaignResponseBody.md +1 -0
- data/docs/LoyaltyCampaign.md +1 -0
- data/docs/LoyaltyMemberPublish.md +1 -1
- data/docs/LoyaltyMemberRedemption.md +1 -1
- data/docs/ManagementApi.md +2348 -0
- data/docs/ManagementProject.md +30 -0
- data/docs/ManagementProjectApiUsageNotifications.md +13 -0
- data/docs/ManagementProjectDefaultCodeConfig.md +8 -0
- data/docs/ManagementProjectLimits.md +9 -0
- data/docs/ManagementProjectLimitsApiCallsItem.md +9 -0
- data/docs/ManagementProjectLimitsBulkApiCallsItem.md +9 -0
- data/docs/ManagementProjectWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsBranding.md +12 -0
- data/docs/ManagementProjectsBrandingAddress.md +12 -0
- data/docs/ManagementProjectsBrandingBrand.md +12 -0
- data/docs/ManagementProjectsBrandingCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingContact.md +9 -0
- data/docs/ManagementProjectsBrandingCreateRequestBody.md +11 -0
- data/docs/ManagementProjectsBrandingCreateRequestBodyAddress.md +12 -0
- data/docs/ManagementProjectsBrandingCreateRequestBodyBrand.md +12 -0
- data/docs/ManagementProjectsBrandingCreateRequestBodyCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingCreateRequestBodyContact.md +9 -0
- data/docs/ManagementProjectsBrandingCreateResponseBody.md +12 -0
- data/docs/ManagementProjectsBrandingCreateResponseBodyAddress.md +12 -0
- data/docs/ManagementProjectsBrandingCreateResponseBodyBrand.md +12 -0
- data/docs/ManagementProjectsBrandingCreateResponseBodyCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingCreateResponseBodyContact.md +9 -0
- data/docs/ManagementProjectsBrandingGetResponseBody.md +12 -0
- data/docs/ManagementProjectsBrandingGetResponseBodyAddress.md +12 -0
- data/docs/ManagementProjectsBrandingGetResponseBodyBrand.md +12 -0
- data/docs/ManagementProjectsBrandingGetResponseBodyCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingGetResponseBodyContact.md +9 -0
- data/docs/ManagementProjectsBrandingListResponseBody.md +11 -0
- data/docs/ManagementProjectsBrandingUpdateRequestBody.md +11 -0
- data/docs/ManagementProjectsBrandingUpdateRequestBodyAddress.md +12 -0
- data/docs/ManagementProjectsBrandingUpdateRequestBodyBrand.md +12 -0
- data/docs/ManagementProjectsBrandingUpdateRequestBodyCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingUpdateRequestBodyContact.md +9 -0
- data/docs/ManagementProjectsBrandingUpdateResponseBody.md +12 -0
- data/docs/ManagementProjectsBrandingUpdateResponseBodyAddress.md +12 -0
- data/docs/ManagementProjectsBrandingUpdateResponseBodyBrand.md +12 -0
- data/docs/ManagementProjectsBrandingUpdateResponseBodyCockpits.md +15 -0
- data/docs/ManagementProjectsBrandingUpdateResponseBodyContact.md +9 -0
- data/docs/ManagementProjectsCreateRequestBody.md +26 -0
- data/docs/ManagementProjectsCreateRequestBodyApiUsageNotifications.md +12 -0
- data/docs/ManagementProjectsCreateRequestBodyUsersItem.md +10 -0
- data/docs/ManagementProjectsCreateRequestBodyWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectsCreateRequestBodyWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectsCreateRequestBodyWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsCreateResponseBody.md +30 -0
- data/docs/ManagementProjectsCreateResponseBodyApiUsageNotifications.md +13 -0
- data/docs/ManagementProjectsCreateResponseBodyClientSideKey.md +9 -0
- data/docs/ManagementProjectsCreateResponseBodyServerSideKey.md +9 -0
- data/docs/ManagementProjectsCreateResponseBodyWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectsCreateResponseBodyWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectsCreateResponseBodyWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsCustomEventSchema.md +13 -0
- data/docs/ManagementProjectsCustomEventSchemaSchema.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasCreateRequestBody.md +9 -0
- data/docs/ManagementProjectsCustomEventSchemasCreateRequestBodySchema.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasCreateRequestBodySchemaPropertiesEntry.md +10 -0
- data/docs/ManagementProjectsCustomEventSchemasCreateResponseBody.md +13 -0
- data/docs/ManagementProjectsCustomEventSchemasCreateResponseBodySchema.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasGetResponseBody.md +13 -0
- data/docs/ManagementProjectsCustomEventSchemasGetResponseBodySchema.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasListResponseBody.md +11 -0
- data/docs/ManagementProjectsCustomEventSchemasUpdateRequestBody.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasUpdateRequestBodySchema.md +8 -0
- data/docs/ManagementProjectsCustomEventSchemasUpdateResponseBody.md +13 -0
- data/docs/ManagementProjectsCustomEventSchemasUpdateResponseBodySchema.md +8 -0
- data/docs/ManagementProjectsGetResponseBody.md +30 -0
- data/docs/ManagementProjectsGetResponseBodyApiUsageNotifications.md +13 -0
- data/docs/ManagementProjectsGetResponseBodyDefaultCodeConfig.md +8 -0
- data/docs/ManagementProjectsGetResponseBodyLimits.md +9 -0
- data/docs/ManagementProjectsGetResponseBodyLimitsApiCallsItem.md +9 -0
- data/docs/ManagementProjectsGetResponseBodyLimitsBulkApiCallsItem.md +9 -0
- data/docs/ManagementProjectsGetResponseBodyWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectsGetResponseBodyWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectsGetResponseBodyWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsListResponseBody.md +11 -0
- data/docs/ManagementProjectsMetadataSchema.md +14 -0
- data/docs/ManagementProjectsMetadataSchemaDefinition.md +21 -0
- data/docs/ManagementProjectsMetadataSchemasCreateRequestBody.md +10 -0
- data/docs/ManagementProjectsMetadataSchemasCreateResponseBody.md +14 -0
- data/docs/ManagementProjectsMetadataSchemasGetResponseBody.md +14 -0
- data/docs/ManagementProjectsMetadataSchemasListResponseBody.md +11 -0
- data/docs/ManagementProjectsMetadataSchemasUpdateRequestBody.md +9 -0
- data/docs/ManagementProjectsMetadataSchemasUpdateResponseBody.md +14 -0
- data/docs/ManagementProjectsStackingRules.md +22 -0
- data/docs/ManagementProjectsStackingRulesCreateRequestBody.md +19 -0
- data/docs/ManagementProjectsStackingRulesCreateResponseBody.md +22 -0
- data/docs/ManagementProjectsStackingRulesGetResponseBody.md +22 -0
- data/docs/ManagementProjectsStackingRulesListResponseBody.md +11 -0
- data/docs/ManagementProjectsStackingRulesUpdateRequestBody.md +19 -0
- data/docs/ManagementProjectsStackingRulesUpdateResponseBody.md +22 -0
- data/docs/ManagementProjectsTemplatesCampaignsCopyCreateRequestBody.md +10 -0
- data/docs/ManagementProjectsTemplatesCampaignsCopyCreateResponseBody.md +13 -0
- data/docs/ManagementProjectsTemplatesCampaignsListResponseBody.md +13 -0
- data/docs/ManagementProjectsUpdateRequestBody.md +23 -0
- data/docs/ManagementProjectsUpdateRequestBodyApiUsageNotifications.md +12 -0
- data/docs/ManagementProjectsUpdateRequestBodyDefaultCodeConfig.md +8 -0
- data/docs/ManagementProjectsUpdateRequestBodyWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectsUpdateRequestBodyWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectsUpdateRequestBodyWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsUpdateResponseBody.md +30 -0
- data/docs/ManagementProjectsUpdateResponseBodyApiUsageNotifications.md +13 -0
- data/docs/ManagementProjectsUpdateResponseBodyDefaultCodeConfig.md +8 -0
- data/docs/ManagementProjectsUpdateResponseBodyLimits.md +9 -0
- data/docs/ManagementProjectsUpdateResponseBodyLimitsApiCallsItem.md +9 -0
- data/docs/ManagementProjectsUpdateResponseBodyLimitsBulkApiCallsItem.md +9 -0
- data/docs/ManagementProjectsUpdateResponseBodyWebhooksCalloutNotifications.md +9 -0
- data/docs/ManagementProjectsUpdateResponseBodyWebhooksCalloutNotificationsDistributions.md +10 -0
- data/docs/ManagementProjectsUpdateResponseBodyWebhooksCalloutNotificationsWebhooks.md +10 -0
- data/docs/ManagementProjectsUsersAssignRequestBody.md +10 -0
- data/docs/ManagementProjectsUsersAssignResponseBody.md +14 -0
- data/docs/ManagementProjectsUsersGetUserResponseBody.md +14 -0
- data/docs/ManagementProjectsUsersInviteCreateRequestBody.md +11 -0
- data/docs/ManagementProjectsUsersListResponseBody.md +11 -0
- data/docs/ManagementProjectsUsersUpdateRoleRequestBody.md +8 -0
- data/docs/ManagementProjectsUsersUpdateRoleResponseBody.md +14 -0
- data/docs/ManagementProjectsWebhook.md +13 -0
- data/docs/ManagementProjectsWebhooksCreateRequestBody.md +10 -0
- data/docs/ManagementProjectsWebhooksCreateResponseBody.md +13 -0
- data/docs/ManagementProjectsWebhooksGetResponseBody.md +13 -0
- data/docs/ManagementProjectsWebhooksListResponseBody.md +11 -0
- data/docs/ManagementProjectsWebhooksUpdateRequestBody.md +10 -0
- data/docs/ManagementProjectsWebhooksUpdateResponseBody.md +13 -0
- data/docs/MetadataSchemaDefinitionDeprecated.md +21 -0
- data/docs/MetadataSchemaDeprecated.md +14 -0
- data/docs/MetadataSchemasApi.md +122 -0
- data/docs/MetadataSchemasGetResponseBody.md +14 -0
- data/docs/MetadataSchemasListResponseBody.md +11 -0
- data/docs/Order.md +1 -1
- data/docs/OrderCalculated.md +1 -1
- data/docs/OrderItemProduct.md +1 -1
- data/docs/OrdersCreateRequestBody.md +1 -1
- data/docs/OrdersCreateResponseBody.md +1 -1
- data/docs/OrdersGetResponseBody.md +1 -1
- data/docs/OrdersImportCreateRequestBodyItem.md +1 -1
- data/docs/OrdersUpdateRequestBody.md +1 -1
- data/docs/OrdersUpdateResponseBody.md +1 -1
- data/docs/ParameterFiltersListBin.md +12 -0
- data/docs/ParameterFiltersListBinId.md +8 -0
- data/docs/ParameterFiltersListBinResourceId.md +8 -0
- data/docs/ParameterFiltersListBinResourceName.md +8 -0
- data/docs/ParameterFiltersListBinResourceType.md +8 -0
- data/docs/ParameterFiltersListBinResourceTypeConditions.md +15 -0
- data/docs/ParameterFiltersListCampaigns.md +14 -0
- data/docs/ParameterFiltersListCampaignsCampaignStatus.md +8 -0
- data/docs/ParameterFiltersListCampaignsCampaignStatusConditions.md +15 -0
- data/docs/ParameterFiltersListCampaignsCategories.md +8 -0
- data/docs/ParameterFiltersListCampaignsCategoryIds.md +8 -0
- data/docs/ParameterFiltersListCampaignsIsReferralCode.md +9 -0
- data/docs/ParameterFiltersListCampaignsValidityTimeframe.md +8 -0
- data/docs/ParameterFiltersListCampaignsVoucherType.md +8 -0
- data/docs/ParameterFiltersListCustomerRedeemables.md +1 -0
- data/docs/ParameterFiltersListCustomerRedeemablesCampaignId.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesCampaignType.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesCreatedAt.md +1 -2
- data/docs/ParameterFiltersListCustomerRedeemablesHolderRole.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesId.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesRedeemableId.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesRedeemableObject.md +0 -1
- data/docs/ParameterFiltersListCustomerRedeemablesVoucherType.md +0 -1
- data/docs/ParameterFiltersListLocations.md +10 -0
- data/docs/ParameterFiltersListLocationsCreatedAt.md +8 -0
- data/docs/ParameterFiltersListLocationsName.md +8 -0
- data/docs/ParameterFiltersListLocationsUpdatedAt.md +8 -0
- data/docs/ParameterFiltersListPublications.md +17 -0
- data/docs/ParameterFiltersListPublicationsCampaignName.md +8 -0
- data/docs/ParameterFiltersListPublicationsCustomerId.md +8 -0
- data/docs/ParameterFiltersListPublicationsFailureCode.md +8 -0
- data/docs/ParameterFiltersListPublicationsIsReferralCode.md +8 -0
- data/docs/ParameterFiltersListPublicationsParentObjectId.md +8 -0
- data/docs/ParameterFiltersListPublicationsRelatedObjectId.md +8 -0
- data/docs/ParameterFiltersListPublicationsResult.md +8 -0
- data/docs/ParameterFiltersListPublicationsSourceId.md +8 -0
- data/docs/ParameterFiltersListPublicationsVoucherType.md +8 -0
- data/docs/ParameterFiltersListRedemptions.md +1 -0
- data/docs/ParameterFiltersListRedemptionsCampaignName.md +0 -1
- data/docs/ParameterFiltersListRedemptionsCustomerId.md +0 -1
- data/docs/ParameterFiltersListRedemptionsFailureCode.md +0 -1
- data/docs/ParameterFiltersListRedemptionsObject.md +0 -1
- data/docs/ParameterFiltersListRedemptionsParentRedemptionId.md +0 -1
- data/docs/ParameterFiltersListRedemptionsRelatedObjectId.md +0 -1
- data/docs/ParameterFiltersListRedemptionsRelatedObjectParentId.md +0 -1
- data/docs/ParameterFiltersListRedemptionsResult.md +0 -1
- data/docs/ParameterFiltersListRedemptionsUserLogin.md +0 -1
- data/docs/ParameterFiltersListRedemptionsVoucherCode.md +0 -1
- data/docs/ParameterFiltersListReferralsRedeemableHolders.md +12 -0
- data/docs/ParameterFiltersListReferralsRedeemableHoldersCreatedAt.md +8 -0
- data/docs/ParameterFiltersListReferralsRedeemableHoldersCustomerId.md +8 -0
- data/docs/ParameterFiltersListReferralsRedeemableHoldersHolderRole.md +8 -0
- data/docs/ParameterFiltersListReferralsRedeemableHoldersHolderRoleConditions.md +15 -0
- data/docs/ParameterFiltersListReferralsRedeemableHoldersId.md +8 -0
- data/docs/ParameterFiltersListTemplates.md +11 -0
- data/docs/ParameterFiltersListTemplatesCampaignType.md +8 -0
- data/docs/ParameterFiltersListTemplatesCampaignTypeConditions.md +15 -0
- data/docs/ParameterFiltersListTemplatesId.md +8 -0
- data/docs/ParameterFiltersListTemplatesName.md +8 -0
- data/docs/ParameterOrderListBin.md +7 -0
- data/docs/ParameterOrderListLocations.md +7 -0
- data/docs/ParameterOrderListTransactions.md +7 -0
- data/docs/ParameterTemplatesList.md +7 -0
- data/docs/ProductCollectionsCreateRequestBody.md +1 -1
- data/docs/ProductCollectionsCreateResponseBody.md +1 -1
- data/docs/ProductCollectionsGetResponseBody.md +1 -1
- data/docs/ProductCollectionsItem.md +1 -1
- data/docs/ProductsApi.md +2 -2
- data/docs/PromotionTiersList.md +1 -1
- data/docs/PromotionsStacksUpdateRequestBodyTiers.md +1 -1
- data/docs/PromotionsTiersCreateRequestBody.md +2 -2
- data/docs/PromotionsTiersListResponseBody.md +1 -1
- data/docs/PublicationsApi.md +2 -2
- data/docs/PublicationsCreateRequestBody.md +1 -1
- data/docs/QualificationsOption.md +1 -1
- data/docs/QualificationsRedeemable.md +1 -1
- data/docs/QualificationsRedeemableBase.md +1 -1
- data/docs/RedeemableHolder.md +18 -0
- data/docs/RedeemableVoucherPublish.md +1 -1
- data/docs/RedeemableVoucherRedemption.md +1 -1
- data/docs/Redemption.md +1 -1
- data/docs/RedemptionChannel.md +2 -2
- data/docs/RedemptionEntry.md +1 -1
- data/docs/RedemptionEntryChannel.md +1 -1
- data/docs/RedemptionEntryOrder.md +1 -1
- data/docs/RedemptionEntryVoucherPublish.md +1 -1
- data/docs/RedemptionEntryVoucherRedemption.md +1 -1
- data/docs/RedemptionVoucher.md +1 -1
- data/docs/RedemptionVoucherPublish.md +1 -1
- data/docs/RedemptionVoucherRedemption.md +1 -1
- data/docs/RedemptionsGetResponseBody.md +1 -1
- data/docs/RedemptionsGetResponseBodyChannel.md +1 -1
- data/docs/RedemptionsGetResponseBodyOrder.md +1 -1
- data/docs/RedemptionsGetResponseBodyVoucherPublish.md +1 -1
- data/docs/RedemptionsGetResponseBodyVoucherRedemption.md +1 -1
- data/docs/RedemptionsListResponseBodyRedemptionsItem.md +1 -1
- data/docs/RedemptionsListResponseBodyRedemptionsItemChannel.md +1 -1
- data/docs/RedemptionsListResponseBodyRedemptionsItemOrder.md +1 -1
- data/docs/RedemptionsListResponseBodyRedemptionsItemVoucherPublish.md +1 -1
- data/docs/RedemptionsListResponseBodyRedemptionsItemVoucherRedemption.md +1 -1
- data/docs/ReferralsApi.md +397 -0
- data/docs/ReferralsMembersHoldersCreateInBulkRequestBody.md +9 -0
- data/docs/ReferralsMembersHoldersCreateInBulkResponseBody.md +8 -0
- data/docs/ReferralsMembersHoldersListResponseBody.md +13 -0
- data/docs/RewardAssignmentParametersLoyalty.md +1 -0
- data/docs/RewardsAssignmentsCreateRequestBodyParametersLoyalty.md +1 -0
- data/docs/RewardsAssignmentsCreateResponseBodyParametersLoyalty.md +1 -0
- data/docs/RewardsAssignmentsGetResponseBodyParametersLoyalty.md +1 -0
- data/docs/RewardsAssignmentsUpdateRequestBodyParametersLoyalty.md +1 -0
- data/docs/RewardsAssignmentsUpdateResponseBodyParametersLoyalty.md +1 -0
- data/docs/TemplatesApi.md +443 -0
- data/docs/TemplatesCampaignsCampaignSetupCreateRequestBody.md +24 -0
- data/docs/TemplatesCampaignsCampaignSetupCreateRequestBodyVoucher.md +9 -0
- data/docs/TemplatesCampaignsCampaignSetupCreateRequestBodyVoucherRedemption.md +8 -0
- data/docs/TemplatesCampaignsCampaignSetupCreateResponseBody.md +10 -0
- data/docs/TemplatesCampaignsCampaignSetupCreateResponseBodyCreatedResourcesItem.md +9 -0
- data/docs/TemplatesCampaignsCreateRequestBody.md +11 -0
- data/docs/TemplatesCampaignsCreateTemplateResponseBody.md +13 -0
- data/docs/TemplatesCampaignsGetResponseBody.md +14 -0
- data/docs/TemplatesCampaignsListResponseBody.md +13 -0
- data/docs/TemplatesCampaignsTierSetupCreateRequestBody.md +20 -0
- data/docs/TemplatesCampaignsTierSetupCreateResponseBody.md +10 -0
- data/docs/TemplatesCampaignsTierSetupCreateResponseBodyCreatedResourcesItem.md +9 -0
- data/docs/TemplatesCampaignsUpdateRequestBody.md +9 -0
- data/docs/TemplatesCampaignsUpdateResponseBody.md +14 -0
- data/docs/TrashBinItem.md +15 -0
- data/docs/TrashBinListResponseBody.md +13 -0
- data/docs/UsageNotifications.md +11 -0
- data/docs/User.md +14 -0
- data/docs/ValidationRule.md +1 -1
- data/docs/ValidationRulesCreateRequestBody.md +1 -1
- data/docs/ValidationRulesCreateResponseBody.md +1 -1
- data/docs/ValidationRulesGetResponseBody.md +1 -1
- data/docs/ValidationRulesUpdateRequestBody.md +1 -1
- data/docs/ValidationRulesUpdateResponseBody.md +1 -1
- data/docs/ValidationsRedeemableInapplicable.md +1 -1
- data/docs/ValidationsRedeemableSkipped.md +1 -1
- data/docs/ValidationsValidateResponseBodyRedeemablesItem.md +1 -1
- data/docs/VoucherPublish.md +1 -1
- data/docs/VoucherRedemption.md +1 -1
- data/docs/VoucherWithCategoriesPublish.md +1 -1
- data/docs/VoucherWithCategoriesRedemption.md +1 -1
- data/docs/VouchersApi.md +4 -2
- data/docs/VouchersCreateResponseBodyPublish.md +1 -1
- data/docs/VouchersCreateResponseBodyRedemption.md +1 -1
- data/docs/VouchersDisableResponseBodyPublish.md +1 -1
- data/docs/VouchersDisableResponseBodyRedemption.md +1 -1
- data/docs/VouchersEnableResponseBodyPublish.md +1 -1
- data/docs/VouchersEnableResponseBodyRedemption.md +1 -1
- data/docs/VouchersGetResponseBodyPublish.md +1 -1
- data/docs/VouchersGetResponseBodyRedemption.md +1 -1
- data/docs/VouchersTransactionsListResponseBody.md +2 -1
- data/docs/VouchersUpdateResponseBodyPublish.md +1 -1
- data/docs/VouchersUpdateResponseBodyRedemption.md +1 -1
- data/lib/VoucherifySdk/api/bin_api.rb +148 -0
- data/lib/VoucherifySdk/api/campaigns_api.rb +3 -0
- data/lib/VoucherifySdk/api/customers_api.rb +4 -68
- data/lib/VoucherifySdk/api/exports_api.rb +1 -1
- data/lib/VoucherifySdk/api/locations_api.rb +150 -0
- data/lib/VoucherifySdk/api/loyalties_api.rb +12 -3
- data/lib/VoucherifySdk/api/management_api.rb +2407 -0
- data/lib/VoucherifySdk/api/metadata_schemas_api.rb +138 -0
- data/lib/VoucherifySdk/api/products_api.rb +4 -4
- data/lib/VoucherifySdk/api/publications_api.rb +2 -2
- data/lib/VoucherifySdk/api/referrals_api.rb +420 -0
- data/lib/VoucherifySdk/api/templates_api.rb +472 -0
- data/lib/VoucherifySdk/api/vouchers_api.rb +6 -3
- data/lib/VoucherifySdk/api_client.rb +22 -1
- data/lib/VoucherifySdk/configuration.rb +14 -0
- data/lib/VoucherifySdk/models/access_settings_campaign_assignments_list.rb +1 -1
- data/lib/VoucherifySdk/models/applicable_to.rb +7 -3
- data/lib/VoucherifySdk/models/applicable_to_effect.rb +6 -4
- data/lib/VoucherifySdk/models/campaign.rb +580 -0
- data/lib/VoucherifySdk/models/campaign_base.rb +13 -2
- data/lib/VoucherifySdk/models/{product_collections_item_filter.rb → campaign_template.rb} +47 -89
- data/lib/VoucherifySdk/models/campaigns_create_request_body.rb +19 -28
- data/lib/VoucherifySdk/models/campaigns_create_response_body.rb +13 -2
- data/lib/VoucherifySdk/models/campaigns_get_response_body.rb +13 -2
- data/lib/VoucherifySdk/models/campaigns_update_request_body.rb +6 -40
- data/lib/VoucherifySdk/models/campaigns_update_response_body.rb +13 -2
- data/lib/VoucherifySdk/models/campaigns_vouchers_create_combined_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/campaigns_vouchers_create_combined_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/campaigns_vouchers_create_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/campaigns_vouchers_create_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/categories_create_request_body.rb +6 -1
- data/lib/VoucherifySdk/models/categories_create_response_body.rb +6 -1
- data/lib/VoucherifySdk/models/categories_get_response_body.rb +11 -19
- data/lib/VoucherifySdk/models/categories_update_request_body.rb +6 -1
- data/lib/VoucherifySdk/models/categories_update_response_body.rb +6 -1
- data/lib/VoucherifySdk/models/category.rb +11 -19
- data/lib/VoucherifySdk/models/category_with_stacking_rules_type.rb +309 -0
- data/lib/VoucherifySdk/models/client_promotions_tiers_list_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/client_validations_validate_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/client_validations_validate_response_body_redeemables_item.rb +1 -1
- data/lib/VoucherifySdk/models/customer_redeemable.rb +2 -2
- data/lib/VoucherifySdk/models/customers_activity_list_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/error.rb +1 -1
- data/lib/VoucherifySdk/models/{parameter_filters_list_customer_redeemables_created_at_conditions.rb → filter_conditions_date_time.rb} +1 -1
- data/lib/VoucherifySdk/models/inapplicable_to.rb +7 -3
- data/lib/VoucherifySdk/models/{product_collections_create_response_body_filter.rb → location.rb} +34 -89
- data/lib/VoucherifySdk/models/location_shape.rb +264 -0
- data/lib/VoucherifySdk/models/location_shape_distance.rb +221 -0
- data/lib/VoucherifySdk/models/{lucky_draw.rb → location_shape_geojson.rb} +42 -30
- data/lib/VoucherifySdk/models/locations_get_response_body.rb +290 -0
- data/lib/VoucherifySdk/models/locations_get_response_body_shape.rb +264 -0
- data/lib/VoucherifySdk/models/locations_get_response_body_shape_distance.rb +221 -0
- data/lib/VoucherifySdk/models/locations_get_response_body_shape_geojson.rb +244 -0
- data/lib/VoucherifySdk/models/locations_list_response_body.rb +260 -0
- data/lib/VoucherifySdk/models/loyalties_create_campaign_request_body.rb +14 -14
- data/lib/VoucherifySdk/models/loyalties_create_campaign_response_body.rb +12 -1
- data/lib/VoucherifySdk/models/loyalties_get_campaign_response_body.rb +12 -1
- data/lib/VoucherifySdk/models/loyalties_member_activity_list_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_create_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_create_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_get_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_get_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_redemption_redeem_response_body.rb +15 -15
- data/lib/VoucherifySdk/models/loyalties_members_redemption_redeem_response_body_channel.rb +3 -3
- data/lib/VoucherifySdk/models/loyalties_members_redemption_redeem_response_body_voucher.rb +2 -2
- data/lib/VoucherifySdk/models/loyalties_members_redemption_redeem_response_body_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_redemption_redeem_response_body_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_transactions_list_response_body.rb +17 -6
- data/lib/VoucherifySdk/models/loyalties_members_transfers_create_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_members_transfers_create_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/loyalties_reward_assignments_get_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/loyalties_rewards_create_assignment_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/loyalties_rewards_get_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/loyalties_rewards_update_assignment_request_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/loyalties_rewards_update_assignment_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/loyalties_update_campaign_response_body.rb +12 -1
- data/lib/VoucherifySdk/models/loyalty_campaign.rb +12 -1
- data/lib/VoucherifySdk/models/loyalty_member_publish.rb +1 -1
- data/lib/VoucherifySdk/models/loyalty_member_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/management_project.rb +479 -0
- data/lib/VoucherifySdk/models/management_project_api_usage_notifications.rb +253 -0
- data/lib/VoucherifySdk/models/management_project_default_code_config.rb +210 -0
- data/lib/VoucherifySdk/models/management_project_limits.rb +223 -0
- data/lib/VoucherifySdk/models/management_project_limits_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_project_limits_bulk_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_project_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_project_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_project_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_branding.rb +250 -0
- data/lib/VoucherifySdk/models/{publications_create_request_body_customer_address.rb → management_projects_branding_address.rb} +32 -42
- data/lib/VoucherifySdk/models/management_projects_branding_brand.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_cockpits.rb +311 -0
- data/lib/VoucherifySdk/models/management_projects_branding_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_request_body.rb +239 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_request_body_address.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_request_body_brand.rb +256 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_request_body_cockpits.rb +325 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_request_body_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_response_body.rb +250 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_response_body_address.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_response_body_brand.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_response_body_cockpits.rb +311 -0
- data/lib/VoucherifySdk/models/management_projects_branding_create_response_body_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_branding_get_response_body.rb +250 -0
- data/lib/VoucherifySdk/models/management_projects_branding_get_response_body_address.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_get_response_body_brand.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_get_response_body_cockpits.rb +311 -0
- data/lib/VoucherifySdk/models/management_projects_branding_get_response_body_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_branding_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_request_body.rb +238 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_request_body_address.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_request_body_brand.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_request_body_cockpits.rb +311 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_request_body_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_response_body.rb +250 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_response_body_address.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_response_body_brand.rb +254 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_response_body_cockpits.rb +311 -0
- data/lib/VoucherifySdk/models/management_projects_branding_update_response_body_contact.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body.rb +440 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body_api_usage_notifications.rb +244 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body_users_item.rb +236 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_create_request_body_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body.rb +480 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_api_usage_notifications.rb +253 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_client_side_key.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_server_side_key.rb +221 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_create_response_body_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schema.rb +290 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schema_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_create_request_body.rb +220 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_create_request_body_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_create_request_body_schema_properties_entry.rb +267 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_create_response_body.rb +290 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_create_response_body_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_get_response_body.rb +290 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_get_response_body_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_update_request_body.rb +209 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_update_request_body_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_update_response_body.rb +290 -0
- data/lib/VoucherifySdk/models/management_projects_custom_event_schemas_update_response_body_schema.rb +212 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body.rb +479 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_api_usage_notifications.rb +253 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_default_code_config.rb +210 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_limits.rb +223 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_limits_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_limits_bulk_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_get_response_body_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schema.rb +280 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schema_definition.rb +380 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_create_request_body.rb +236 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_create_response_body.rb +280 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_get_response_body.rb +280 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_update_request_body.rb +223 -0
- data/lib/VoucherifySdk/models/management_projects_metadata_schemas_update_response_body.rb +280 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules.rb +425 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_create_request_body.rb +392 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_create_response_body.rb +425 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_get_response_body.rb +425 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_update_request_body.rb +392 -0
- data/lib/VoucherifySdk/models/management_projects_stacking_rules_update_response_body.rb +425 -0
- data/lib/VoucherifySdk/models/management_projects_templates_campaigns_copy_create_request_body.rb +232 -0
- data/lib/VoucherifySdk/models/management_projects_templates_campaigns_copy_create_response_body.rb +293 -0
- data/lib/VoucherifySdk/models/management_projects_templates_campaigns_list_response_body.rb +297 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body.rb +400 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body_api_usage_notifications.rb +244 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body_default_code_config.rb +210 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_update_request_body_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body.rb +479 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_api_usage_notifications.rb +253 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_default_code_config.rb +210 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_limits.rb +223 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_limits_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_limits_bulk_api_calls_item.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_webhooks_callout_notifications.rb +219 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_webhooks_callout_notifications_distributions.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_update_response_body_webhooks_callout_notifications_webhooks.rb +234 -0
- data/lib/VoucherifySdk/models/management_projects_users_assign_request_body.rb +231 -0
- data/lib/VoucherifySdk/models/management_projects_users_assign_response_body.rb +278 -0
- data/lib/VoucherifySdk/models/management_projects_users_get_user_response_body.rb +278 -0
- data/lib/VoucherifySdk/models/management_projects_users_invite_create_request_body.rb +245 -0
- data/lib/VoucherifySdk/models/management_projects_users_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_users_update_role_request_body.rb +209 -0
- data/lib/VoucherifySdk/models/management_projects_users_update_role_response_body.rb +278 -0
- data/lib/VoucherifySdk/models/management_projects_webhook.rb +295 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_create_request_body.rb +258 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_create_response_body.rb +295 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_get_response_body.rb +295 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_update_request_body.rb +258 -0
- data/lib/VoucherifySdk/models/management_projects_webhooks_update_response_body.rb +295 -0
- data/lib/VoucherifySdk/models/metadata_schema_definition_deprecated.rb +380 -0
- data/lib/VoucherifySdk/models/metadata_schema_deprecated.rb +280 -0
- data/lib/VoucherifySdk/models/metadata_schemas_get_response_body.rb +280 -0
- data/lib/VoucherifySdk/models/metadata_schemas_list_response_body.rb +275 -0
- data/lib/VoucherifySdk/models/order.rb +1 -1
- data/lib/VoucherifySdk/models/order_calculated.rb +1 -1
- data/lib/VoucherifySdk/models/order_item_product.rb +1 -1
- data/lib/VoucherifySdk/models/orders_create_request_body.rb +1 -1
- data/lib/VoucherifySdk/models/orders_create_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/orders_get_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/orders_import_create_request_body_item.rb +1 -1
- data/lib/VoucherifySdk/models/orders_update_request_body.rb +1 -1
- data/lib/VoucherifySdk/models/orders_update_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/parameter_campaign_type.rb +1 -2
- data/lib/VoucherifySdk/models/parameter_filters_list_bin.rb +269 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_bin_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_bin_resource_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_bin_resource_name.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_bin_resource_type.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_bin_resource_type_conditions.rb +316 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns.rb +289 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_campaign_status.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_campaign_status_conditions.rb +316 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_categories.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_category_ids.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_is_referral_code.rb +247 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_validity_timeframe.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_campaigns_voucher_type.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables.rb +36 -5
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_campaign_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_campaign_type.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_created_at.rb +4 -36
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_holder_role.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_redeemable_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_redeemable_object.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_customer_redeemables_voucher_type.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_locations.rb +228 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_locations_created_at.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_locations_name.rb +207 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_locations_updated_at.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications.rb +319 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_campaign_name.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_customer_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_failure_code.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_is_referral_code.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_parent_object_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_related_object_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_result.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_source_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_publications_voucher_type.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions.rb +36 -5
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_campaign_name.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_customer_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_failure_code.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_object.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_parent_redemption_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_related_object_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_related_object_parent_id.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_result.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_user_login.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_redemptions_voucher_code.rb +4 -35
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders.rb +269 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders_created_at.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders_customer_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders_holder_role.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders_holder_role_conditions.rb +316 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_referrals_redeemable_holders_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_templates.rb +259 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_templates_campaign_type.rb +209 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_templates_campaign_type_conditions.rb +317 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_templates_id.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_filters_list_templates_name.rb +208 -0
- data/lib/VoucherifySdk/models/parameter_order_list_bin.rb +40 -0
- data/lib/VoucherifySdk/models/parameter_order_list_locations.rb +42 -0
- data/lib/VoucherifySdk/models/parameter_order_list_transactions.rb +40 -0
- data/lib/VoucherifySdk/models/parameter_templates_list.rb +40 -0
- data/lib/VoucherifySdk/models/parameter_voucher_type_list_publications.rb +1 -2
- data/lib/VoucherifySdk/models/product_collections_create_request_body.rb +2 -1
- data/lib/VoucherifySdk/models/product_collections_create_response_body.rb +2 -1
- data/lib/VoucherifySdk/models/product_collections_get_response_body.rb +2 -1
- data/lib/VoucherifySdk/models/product_collections_item.rb +2 -1
- data/lib/VoucherifySdk/models/promotion_tiers_list.rb +1 -1
- data/lib/VoucherifySdk/models/promotions_stacks_update_request_body_tiers.rb +1 -1
- data/lib/VoucherifySdk/models/promotions_tiers_create_request_body.rb +24 -24
- data/lib/VoucherifySdk/models/promotions_tiers_list_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/publications_create_request_body.rb +1 -2
- data/lib/VoucherifySdk/models/qualifications_option.rb +1 -1
- data/lib/VoucherifySdk/models/qualifications_redeemable.rb +1 -1
- data/lib/VoucherifySdk/models/qualifications_redeemable_base.rb +1 -1
- data/lib/VoucherifySdk/models/redeemable_holder.rb +354 -0
- data/lib/VoucherifySdk/models/redeemable_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/redeemable_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/redemption.rb +16 -16
- data/lib/VoucherifySdk/models/redemption_channel.rb +3 -3
- data/lib/VoucherifySdk/models/redemption_entry.rb +11 -11
- data/lib/VoucherifySdk/models/redemption_entry_channel.rb +1 -2
- data/lib/VoucherifySdk/models/redemption_entry_order.rb +1 -1
- data/lib/VoucherifySdk/models/redemption_entry_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/redemption_entry_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/redemption_voucher.rb +1 -1
- data/lib/VoucherifySdk/models/redemption_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/redemption_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_get_response_body.rb +11 -11
- data/lib/VoucherifySdk/models/redemptions_get_response_body_channel.rb +1 -2
- data/lib/VoucherifySdk/models/redemptions_get_response_body_order.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_get_response_body_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_get_response_body_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_list_response_body_redemptions_item.rb +10 -10
- data/lib/VoucherifySdk/models/redemptions_list_response_body_redemptions_item_channel.rb +1 -3
- data/lib/VoucherifySdk/models/redemptions_list_response_body_redemptions_item_order.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_list_response_body_redemptions_item_voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_list_response_body_redemptions_item_voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/redemptions_rollbacks_create_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/referral_program_referee_reward.rb +1 -1
- data/lib/VoucherifySdk/models/referrals_members_holders_create_in_bulk_request_body.rb +223 -0
- data/lib/VoucherifySdk/models/referrals_members_holders_create_in_bulk_response_body.rb +212 -0
- data/lib/VoucherifySdk/models/referrals_members_holders_list_response_body.rb +271 -0
- data/lib/VoucherifySdk/models/reward_assignment_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/rewards_assignments_create_request_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/rewards_assignments_create_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/rewards_assignments_create_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/rewards_assignments_get_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/rewards_assignments_update_request_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/rewards_assignments_update_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/rewards_assignments_update_response_body_parameters_loyalty.rb +16 -5
- data/lib/VoucherifySdk/models/stacking_rules.rb +1 -1
- data/lib/VoucherifySdk/models/templates_campaigns_campaign_setup_create_request_body.rb +406 -0
- data/lib/VoucherifySdk/models/templates_campaigns_campaign_setup_create_request_body_voucher.rb +218 -0
- data/lib/VoucherifySdk/models/templates_campaigns_campaign_setup_create_request_body_voucher_redemption.rb +210 -0
- data/lib/VoucherifySdk/models/templates_campaigns_campaign_setup_create_response_body.rb +265 -0
- data/lib/VoucherifySdk/models/templates_campaigns_campaign_setup_create_response_body_created_resources_item.rb +242 -0
- data/lib/VoucherifySdk/models/templates_campaigns_create_request_body.rb +243 -0
- data/lib/VoucherifySdk/models/{publications_create_request_body_customer.rb → templates_campaigns_create_template_response_body.rb} +55 -68
- data/lib/VoucherifySdk/models/{product_collections_get_response_body_filter.rb → templates_campaigns_get_response_body.rb} +48 -89
- data/lib/VoucherifySdk/models/templates_campaigns_list_response_body.rb +297 -0
- data/lib/VoucherifySdk/models/templates_campaigns_tier_setup_create_request_body.rb +361 -0
- data/lib/VoucherifySdk/models/templates_campaigns_tier_setup_create_response_body.rb +258 -0
- data/lib/VoucherifySdk/models/templates_campaigns_tier_setup_create_response_body_created_resources_item.rb +242 -0
- data/lib/VoucherifySdk/models/templates_campaigns_update_request_body.rb +221 -0
- data/lib/VoucherifySdk/models/{product_collections_create_request_body_filter.rb → templates_campaigns_update_response_body.rb} +48 -89
- data/lib/VoucherifySdk/models/trash_bin_item.rb +313 -0
- data/lib/VoucherifySdk/models/trash_bin_list_response_body.rb +297 -0
- data/lib/VoucherifySdk/models/usage_notifications.rb +254 -0
- data/lib/VoucherifySdk/models/user.rb +278 -0
- data/lib/VoucherifySdk/models/validation_rule.rb +2 -2
- data/lib/VoucherifySdk/models/validation_rules_create_request_body.rb +2 -2
- data/lib/VoucherifySdk/models/validation_rules_create_response_body.rb +2 -2
- data/lib/VoucherifySdk/models/validation_rules_get_response_body.rb +2 -2
- data/lib/VoucherifySdk/models/validation_rules_update_request_body.rb +2 -2
- data/lib/VoucherifySdk/models/validation_rules_update_response_body.rb +2 -2
- data/lib/VoucherifySdk/models/validations_redeemable_inapplicable.rb +1 -1
- data/lib/VoucherifySdk/models/validations_redeemable_skipped.rb +1 -1
- data/lib/VoucherifySdk/models/validations_validate_response_body.rb +1 -1
- data/lib/VoucherifySdk/models/validations_validate_response_body_redeemables_item.rb +1 -1
- data/lib/VoucherifySdk/models/voucher_publish.rb +1 -1
- data/lib/VoucherifySdk/models/voucher_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/voucher_with_categories_publish.rb +1 -1
- data/lib/VoucherifySdk/models/voucher_with_categories_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_create_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_create_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_disable_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_disable_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_enable_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_enable_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_get_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_get_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_transactions_list_response_body.rb +43 -6
- data/lib/VoucherifySdk/models/vouchers_update_response_body_publish.rb +1 -1
- data/lib/VoucherifySdk/models/vouchers_update_response_body_redemption.rb +1 -1
- data/lib/VoucherifySdk/version.rb +1 -1
- data/lib/VoucherifySdk.rb +212 -8
- metadata +456 -48
- data/docs/LuckyDraw.md +0 -10
- data/docs/ProductCollectionsCreateRequestBodyFilter.md +0 -20
- data/docs/ProductCollectionsCreateResponseBodyFilter.md +0 -20
- data/docs/ProductCollectionsGetResponseBodyFilter.md +0 -20
- data/docs/ProductCollectionsItemFilter.md +0 -20
- data/docs/PublicationsCreateRequestBodyCustomer.md +0 -17
- data/docs/PublicationsCreateRequestBodyCustomerAddress.md +0 -13
@@ -0,0 +1,472 @@
|
|
1
|
+
=begin
|
2
|
+
#Voucherify API
|
3
|
+
|
4
|
+
#Voucherify promotion engine REST API. Please see https://docs.voucherify.io/docs for more details.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v2018-08-01
|
7
|
+
Contact: support@voucherify.io
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.0.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module VoucherifySdk
|
16
|
+
class TemplatesApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Add Promotion Tier From Template
|
23
|
+
# Creates a promotion tier out of a discount campaign template and adds it to an existing promotion campaign. To add a promotion tier to a campaign, you need to provide the name in the request and the campaign ID. Other fields are optional. If no other fields are sent, the configuration from the template will be used. You can send new values of the fields listed below to replace the settings saved in the template. However, you cannot assign an action or an existing validation rule or create a new one in the request. If the template has a validation rule, a new validation rule is always created for the promotion tier. When the promotion tier has been created, then you can: - Update the validation rule, - Unassign the validation rule, - Assign an existing validation rule. 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign - Promotion tier 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
24
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
25
|
+
# @param [Hash] opts the optional parameters
|
26
|
+
# @option opts [TemplatesCampaignsTierSetupCreateRequestBody] :templates_campaigns_tier_setup_create_request_body Only name and campaign_id are required. The rest of the fields will overwrite the template configuration.
|
27
|
+
# @return [TemplatesCampaignsTierSetupCreateResponseBody]
|
28
|
+
def add_tier_from_template(campaign_template_id, opts = {})
|
29
|
+
data, _status_code, _headers = add_tier_from_template_with_http_info(campaign_template_id, opts)
|
30
|
+
data
|
31
|
+
end
|
32
|
+
|
33
|
+
# Add Promotion Tier From Template
|
34
|
+
# Creates a promotion tier out of a discount campaign template and adds it to an existing promotion campaign. To add a promotion tier to a campaign, you need to provide the name in the request and the campaign ID. Other fields are optional. If no other fields are sent, the configuration from the template will be used. You can send new values of the fields listed below to replace the settings saved in the template. However, you cannot assign an action or an existing validation rule or create a new one in the request. If the template has a validation rule, a new validation rule is always created for the promotion tier. When the promotion tier has been created, then you can: - Update the validation rule, - Unassign the validation rule, - Assign an existing validation rule. 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign - Promotion tier 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
35
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
36
|
+
# @param [Hash] opts the optional parameters
|
37
|
+
# @option opts [TemplatesCampaignsTierSetupCreateRequestBody] :templates_campaigns_tier_setup_create_request_body Only name and campaign_id are required. The rest of the fields will overwrite the template configuration.
|
38
|
+
# @return [Array<(TemplatesCampaignsTierSetupCreateResponseBody, Integer, Hash)>] TemplatesCampaignsTierSetupCreateResponseBody data, response status code and response headers
|
39
|
+
private def add_tier_from_template_with_http_info(campaign_template_id, opts = {})
|
40
|
+
if @api_client.config.debugging
|
41
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.add_tier_from_template ...'
|
42
|
+
end
|
43
|
+
# resource path
|
44
|
+
local_var_path = '/v1/templates/campaigns/{campaignTemplateId}/tier-setup'.sub('{' + 'campaignTemplateId' + '}', CGI.escape(campaign_template_id.to_s))
|
45
|
+
|
46
|
+
# query parameters
|
47
|
+
query_params = opts[:query_params] || {}
|
48
|
+
|
49
|
+
# header parameters
|
50
|
+
header_params = opts[:header_params] || {}
|
51
|
+
# HTTP header 'Accept' (if needed)
|
52
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
53
|
+
# HTTP header 'Content-Type'
|
54
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
55
|
+
if !content_type.nil?
|
56
|
+
header_params['Content-Type'] = content_type
|
57
|
+
end
|
58
|
+
|
59
|
+
# form parameters
|
60
|
+
form_params = opts[:form_params] || {}
|
61
|
+
|
62
|
+
# http body (model)
|
63
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'templates_campaigns_tier_setup_create_request_body'])
|
64
|
+
|
65
|
+
# return_type
|
66
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsTierSetupCreateResponseBody'
|
67
|
+
|
68
|
+
# auth_names
|
69
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
70
|
+
|
71
|
+
new_options = opts.merge(
|
72
|
+
:operation => :"TemplatesApi.add_tier_from_template",
|
73
|
+
:header_params => header_params,
|
74
|
+
:query_params => query_params,
|
75
|
+
:form_params => form_params,
|
76
|
+
:body => post_body,
|
77
|
+
:auth_names => auth_names,
|
78
|
+
:return_type => return_type
|
79
|
+
)
|
80
|
+
|
81
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
82
|
+
if @api_client.config.debugging
|
83
|
+
@api_client.config.logger.debug "API called: TemplatesApi#add_tier_from_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
84
|
+
end
|
85
|
+
return data, status_code, headers
|
86
|
+
end
|
87
|
+
|
88
|
+
# Create Campaign From Template
|
89
|
+
# Creates a campaign out of a campaign template. To create a campaign, you need to provide the name in the request, while other fields are optional. If no other fields are sent, the configuration from the template will be used. You can send new values of the fields listed below to replace the settings saved in the template. However, you cannot assign an existing validation rule or create a new one in the request. If the template has a validation rule, a new validation rule is always created for the campaign. When the campaign has been created, then you can: - Update the validation rule, - Unassign the validation rule, - Assign an existing validation rule. 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign - Promotion tier 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
90
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
91
|
+
# @param [Hash] opts the optional parameters
|
92
|
+
# @option opts [TemplatesCampaignsCampaignSetupCreateRequestBody] :templates_campaigns_campaign_setup_create_request_body Only name is required. The rest of the fields will overwrite the template configuration.
|
93
|
+
# @return [TemplatesCampaignsCampaignSetupCreateResponseBody]
|
94
|
+
def create_campaign_from_template(campaign_template_id, opts = {})
|
95
|
+
data, _status_code, _headers = create_campaign_from_template_with_http_info(campaign_template_id, opts)
|
96
|
+
data
|
97
|
+
end
|
98
|
+
|
99
|
+
# Create Campaign From Template
|
100
|
+
# Creates a campaign out of a campaign template. To create a campaign, you need to provide the name in the request, while other fields are optional. If no other fields are sent, the configuration from the template will be used. You can send new values of the fields listed below to replace the settings saved in the template. However, you cannot assign an existing validation rule or create a new one in the request. If the template has a validation rule, a new validation rule is always created for the campaign. When the campaign has been created, then you can: - Update the validation rule, - Unassign the validation rule, - Assign an existing validation rule. 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign - Promotion tier 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
101
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
102
|
+
# @param [Hash] opts the optional parameters
|
103
|
+
# @option opts [TemplatesCampaignsCampaignSetupCreateRequestBody] :templates_campaigns_campaign_setup_create_request_body Only name is required. The rest of the fields will overwrite the template configuration.
|
104
|
+
# @return [Array<(TemplatesCampaignsCampaignSetupCreateResponseBody, Integer, Hash)>] TemplatesCampaignsCampaignSetupCreateResponseBody data, response status code and response headers
|
105
|
+
private def create_campaign_from_template_with_http_info(campaign_template_id, opts = {})
|
106
|
+
if @api_client.config.debugging
|
107
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.create_campaign_from_template ...'
|
108
|
+
end
|
109
|
+
# resource path
|
110
|
+
local_var_path = '/v1/templates/campaigns/{campaignTemplateId}/campaign-setup'.sub('{' + 'campaignTemplateId' + '}', CGI.escape(campaign_template_id.to_s))
|
111
|
+
|
112
|
+
# query parameters
|
113
|
+
query_params = opts[:query_params] || {}
|
114
|
+
|
115
|
+
# header parameters
|
116
|
+
header_params = opts[:header_params] || {}
|
117
|
+
# HTTP header 'Accept' (if needed)
|
118
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
119
|
+
# HTTP header 'Content-Type'
|
120
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
121
|
+
if !content_type.nil?
|
122
|
+
header_params['Content-Type'] = content_type
|
123
|
+
end
|
124
|
+
|
125
|
+
# form parameters
|
126
|
+
form_params = opts[:form_params] || {}
|
127
|
+
|
128
|
+
# http body (model)
|
129
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'templates_campaigns_campaign_setup_create_request_body'])
|
130
|
+
|
131
|
+
# return_type
|
132
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsCampaignSetupCreateResponseBody'
|
133
|
+
|
134
|
+
# auth_names
|
135
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
136
|
+
|
137
|
+
new_options = opts.merge(
|
138
|
+
:operation => :"TemplatesApi.create_campaign_from_template",
|
139
|
+
:header_params => header_params,
|
140
|
+
:query_params => query_params,
|
141
|
+
:form_params => form_params,
|
142
|
+
:body => post_body,
|
143
|
+
:auth_names => auth_names,
|
144
|
+
:return_type => return_type
|
145
|
+
)
|
146
|
+
|
147
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
148
|
+
if @api_client.config.debugging
|
149
|
+
@api_client.config.logger.debug "API called: TemplatesApi#create_campaign_from_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
150
|
+
end
|
151
|
+
return data, status_code, headers
|
152
|
+
end
|
153
|
+
|
154
|
+
# Create Campaign Template
|
155
|
+
# Creates a template for a discount or gift campaign, or a promotion tier. A template stores campaign configuration **without** the following details: - Campaign name - Category - Code count The following elements are not supported by campaign templates: - Redeeming API keys - Redeeming users - Customer loyalty tier - Static segments 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign, - Promotion tier. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
156
|
+
# @param [Hash] opts the optional parameters
|
157
|
+
# @option opts [TemplatesCampaignsCreateRequestBody] :templates_campaigns_create_request_body Provide details for a campaign template
|
158
|
+
# @return [TemplatesCampaignsCreateTemplateResponseBody]
|
159
|
+
def create_campaign_template(opts = {})
|
160
|
+
data, _status_code, _headers = create_campaign_template_with_http_info(opts)
|
161
|
+
data
|
162
|
+
end
|
163
|
+
|
164
|
+
# Create Campaign Template
|
165
|
+
# Creates a template for a discount or gift campaign, or a promotion tier. A template stores campaign configuration **without** the following details: - Campaign name - Category - Code count The following elements are not supported by campaign templates: - Redeeming API keys - Redeeming users - Customer loyalty tier - Static segments 👍 Promotion Tiers and Campaign Templates You can create a campaign template out of a promotion tier. Promotion tiers are converted to a discount campaign with the DISCOUNT_COUPON type. You can use this template to create: - Discount campaign, - Promotion tier. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
166
|
+
# @param [Hash] opts the optional parameters
|
167
|
+
# @option opts [TemplatesCampaignsCreateRequestBody] :templates_campaigns_create_request_body Provide details for a campaign template
|
168
|
+
# @return [Array<(TemplatesCampaignsCreateTemplateResponseBody, Integer, Hash)>] TemplatesCampaignsCreateTemplateResponseBody data, response status code and response headers
|
169
|
+
private def create_campaign_template_with_http_info(opts = {})
|
170
|
+
if @api_client.config.debugging
|
171
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.create_campaign_template ...'
|
172
|
+
end
|
173
|
+
# resource path
|
174
|
+
local_var_path = '/v1/templates/campaigns'
|
175
|
+
|
176
|
+
# query parameters
|
177
|
+
query_params = opts[:query_params] || {}
|
178
|
+
|
179
|
+
# header parameters
|
180
|
+
header_params = opts[:header_params] || {}
|
181
|
+
# HTTP header 'Accept' (if needed)
|
182
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
183
|
+
# HTTP header 'Content-Type'
|
184
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
185
|
+
if !content_type.nil?
|
186
|
+
header_params['Content-Type'] = content_type
|
187
|
+
end
|
188
|
+
|
189
|
+
# form parameters
|
190
|
+
form_params = opts[:form_params] || {}
|
191
|
+
|
192
|
+
# http body (model)
|
193
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'templates_campaigns_create_request_body'])
|
194
|
+
|
195
|
+
# return_type
|
196
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsCreateTemplateResponseBody'
|
197
|
+
|
198
|
+
# auth_names
|
199
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
200
|
+
|
201
|
+
new_options = opts.merge(
|
202
|
+
:operation => :"TemplatesApi.create_campaign_template",
|
203
|
+
:header_params => header_params,
|
204
|
+
:query_params => query_params,
|
205
|
+
:form_params => form_params,
|
206
|
+
:body => post_body,
|
207
|
+
:auth_names => auth_names,
|
208
|
+
:return_type => return_type
|
209
|
+
)
|
210
|
+
|
211
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
212
|
+
if @api_client.config.debugging
|
213
|
+
@api_client.config.logger.debug "API called: TemplatesApi#create_campaign_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
214
|
+
end
|
215
|
+
return data, status_code, headers
|
216
|
+
end
|
217
|
+
|
218
|
+
# Delete Campaign Template
|
219
|
+
# Deletes the campaign template permanently. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
220
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
221
|
+
# @param [Hash] opts the optional parameters
|
222
|
+
# @return [nil]
|
223
|
+
def delete_campaign_template(campaign_template_id, opts = {})
|
224
|
+
delete_campaign_template_with_http_info(campaign_template_id, opts)
|
225
|
+
nil
|
226
|
+
end
|
227
|
+
|
228
|
+
# Delete Campaign Template
|
229
|
+
# Deletes the campaign template permanently. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
230
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
231
|
+
# @param [Hash] opts the optional parameters
|
232
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
233
|
+
private def delete_campaign_template_with_http_info(campaign_template_id, opts = {})
|
234
|
+
if @api_client.config.debugging
|
235
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.delete_campaign_template ...'
|
236
|
+
end
|
237
|
+
# resource path
|
238
|
+
local_var_path = '/v1/templates/campaigns/{campaignTemplateId}'.sub('{' + 'campaignTemplateId' + '}', CGI.escape(campaign_template_id.to_s))
|
239
|
+
|
240
|
+
# query parameters
|
241
|
+
query_params = opts[:query_params] || {}
|
242
|
+
|
243
|
+
# header parameters
|
244
|
+
header_params = opts[:header_params] || {}
|
245
|
+
|
246
|
+
# form parameters
|
247
|
+
form_params = opts[:form_params] || {}
|
248
|
+
|
249
|
+
# http body (model)
|
250
|
+
post_body = opts[:debug_body]
|
251
|
+
|
252
|
+
# return_type
|
253
|
+
return_type = opts[:debug_return_type]
|
254
|
+
|
255
|
+
# auth_names
|
256
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
257
|
+
|
258
|
+
new_options = opts.merge(
|
259
|
+
:operation => :"TemplatesApi.delete_campaign_template",
|
260
|
+
:header_params => header_params,
|
261
|
+
:query_params => query_params,
|
262
|
+
:form_params => form_params,
|
263
|
+
:body => post_body,
|
264
|
+
:auth_names => auth_names,
|
265
|
+
:return_type => return_type
|
266
|
+
)
|
267
|
+
|
268
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
269
|
+
if @api_client.config.debugging
|
270
|
+
@api_client.config.logger.debug "API called: TemplatesApi#delete_campaign_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
271
|
+
end
|
272
|
+
return data, status_code, headers
|
273
|
+
end
|
274
|
+
|
275
|
+
# Get Campaign Template
|
276
|
+
# Retrieves a campaign template available in the project. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
277
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
278
|
+
# @param [Hash] opts the optional parameters
|
279
|
+
# @return [TemplatesCampaignsGetResponseBody]
|
280
|
+
def get_campaign_template(campaign_template_id, opts = {})
|
281
|
+
data, _status_code, _headers = get_campaign_template_with_http_info(campaign_template_id, opts)
|
282
|
+
data
|
283
|
+
end
|
284
|
+
|
285
|
+
# Get Campaign Template
|
286
|
+
# Retrieves a campaign template available in the project. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
287
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
288
|
+
# @param [Hash] opts the optional parameters
|
289
|
+
# @return [Array<(TemplatesCampaignsGetResponseBody, Integer, Hash)>] TemplatesCampaignsGetResponseBody data, response status code and response headers
|
290
|
+
private def get_campaign_template_with_http_info(campaign_template_id, opts = {})
|
291
|
+
if @api_client.config.debugging
|
292
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.get_campaign_template ...'
|
293
|
+
end
|
294
|
+
# resource path
|
295
|
+
local_var_path = '/v1/templates/campaigns/{campaignTemplateId}'.sub('{' + 'campaignTemplateId' + '}', CGI.escape(campaign_template_id.to_s))
|
296
|
+
|
297
|
+
# query parameters
|
298
|
+
query_params = opts[:query_params] || {}
|
299
|
+
|
300
|
+
# header parameters
|
301
|
+
header_params = opts[:header_params] || {}
|
302
|
+
# HTTP header 'Accept' (if needed)
|
303
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
304
|
+
|
305
|
+
# form parameters
|
306
|
+
form_params = opts[:form_params] || {}
|
307
|
+
|
308
|
+
# http body (model)
|
309
|
+
post_body = opts[:debug_body]
|
310
|
+
|
311
|
+
# return_type
|
312
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsGetResponseBody'
|
313
|
+
|
314
|
+
# auth_names
|
315
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
316
|
+
|
317
|
+
new_options = opts.merge(
|
318
|
+
:operation => :"TemplatesApi.get_campaign_template",
|
319
|
+
:header_params => header_params,
|
320
|
+
:query_params => query_params,
|
321
|
+
:form_params => form_params,
|
322
|
+
:body => post_body,
|
323
|
+
:auth_names => auth_names,
|
324
|
+
:return_type => return_type
|
325
|
+
)
|
326
|
+
|
327
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
328
|
+
if @api_client.config.debugging
|
329
|
+
@api_client.config.logger.debug "API called: TemplatesApi#get_campaign_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
330
|
+
end
|
331
|
+
return data, status_code, headers
|
332
|
+
end
|
333
|
+
|
334
|
+
# List Campaign Templates
|
335
|
+
# Lists all campaign templates available in the project. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
336
|
+
# @param [Hash] opts the optional parameters
|
337
|
+
# @option opts [Integer] :limit Limits the number of objects to be returned. The limit can range between 1 and 100 items. If no limit is set, it returns 10 items.
|
338
|
+
# @option opts [String] :starting_after_id A cursor for pagination. It retrieves the campaign templates created after a template with the given ID.
|
339
|
+
# @option opts [ParameterTemplatesList] :order Sorts the results using one of the filtering options, where the dash - preceding a sorting option means sorting in a descending order.
|
340
|
+
# @option opts [Boolean] :include_total If set to true, the response returns the number of all campaign templates, regardless of the applied filters or limits. Set to false by default.
|
341
|
+
# @option opts [ParameterFiltersListTemplates] :filters Filters for listing templates.
|
342
|
+
# @return [TemplatesCampaignsListResponseBody]
|
343
|
+
def list_campaign_templates(opts = {})
|
344
|
+
data, _status_code, _headers = list_campaign_templates_with_http_info(opts)
|
345
|
+
data
|
346
|
+
end
|
347
|
+
|
348
|
+
# List Campaign Templates
|
349
|
+
# Lists all campaign templates available in the project. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
350
|
+
# @param [Hash] opts the optional parameters
|
351
|
+
# @option opts [Integer] :limit Limits the number of objects to be returned. The limit can range between 1 and 100 items. If no limit is set, it returns 10 items.
|
352
|
+
# @option opts [String] :starting_after_id A cursor for pagination. It retrieves the campaign templates created after a template with the given ID.
|
353
|
+
# @option opts [ParameterTemplatesList] :order Sorts the results using one of the filtering options, where the dash - preceding a sorting option means sorting in a descending order.
|
354
|
+
# @option opts [Boolean] :include_total If set to true, the response returns the number of all campaign templates, regardless of the applied filters or limits. Set to false by default.
|
355
|
+
# @option opts [ParameterFiltersListTemplates] :filters Filters for listing templates.
|
356
|
+
# @return [Array<(TemplatesCampaignsListResponseBody, Integer, Hash)>] TemplatesCampaignsListResponseBody data, response status code and response headers
|
357
|
+
private def list_campaign_templates_with_http_info(opts = {})
|
358
|
+
if @api_client.config.debugging
|
359
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.list_campaign_templates ...'
|
360
|
+
end
|
361
|
+
# resource path
|
362
|
+
local_var_path = '/v1/templates/campaigns'
|
363
|
+
|
364
|
+
# query parameters
|
365
|
+
query_params = opts[:query_params] || {}
|
366
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
367
|
+
query_params[:'starting_after_id'] = opts[:'starting_after_id'] if !opts[:'starting_after_id'].nil?
|
368
|
+
query_params[:'order'] = opts[:'order'] if !opts[:'order'].nil?
|
369
|
+
query_params[:'include_total'] = opts[:'include_total'] if !opts[:'include_total'].nil?
|
370
|
+
query_params[:'filters'] = opts[:'filters'] if !opts[:'filters'].nil?
|
371
|
+
|
372
|
+
# header parameters
|
373
|
+
header_params = opts[:header_params] || {}
|
374
|
+
# HTTP header 'Accept' (if needed)
|
375
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
376
|
+
|
377
|
+
# form parameters
|
378
|
+
form_params = opts[:form_params] || {}
|
379
|
+
|
380
|
+
# http body (model)
|
381
|
+
post_body = opts[:debug_body]
|
382
|
+
|
383
|
+
# return_type
|
384
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsListResponseBody'
|
385
|
+
|
386
|
+
# auth_names
|
387
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
388
|
+
|
389
|
+
new_options = opts.merge(
|
390
|
+
:operation => :"TemplatesApi.list_campaign_templates",
|
391
|
+
:header_params => header_params,
|
392
|
+
:query_params => query_params,
|
393
|
+
:form_params => form_params,
|
394
|
+
:body => post_body,
|
395
|
+
:auth_names => auth_names,
|
396
|
+
:return_type => return_type
|
397
|
+
)
|
398
|
+
|
399
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
400
|
+
if @api_client.config.debugging
|
401
|
+
@api_client.config.logger.debug "API called: TemplatesApi#list_campaign_templates\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
402
|
+
end
|
403
|
+
return data, status_code, headers
|
404
|
+
end
|
405
|
+
|
406
|
+
# Update Campaign Template
|
407
|
+
# Updates the name or description of the campaign template. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
408
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
409
|
+
# @param [Hash] opts the optional parameters
|
410
|
+
# @option opts [TemplatesCampaignsUpdateRequestBody] :templates_campaigns_update_request_body Provide the new name or description for the campaign template
|
411
|
+
# @return [TemplatesCampaignsUpdateResponseBody]
|
412
|
+
def update_campaign_template(campaign_template_id, opts = {})
|
413
|
+
data, _status_code, _headers = update_campaign_template_with_http_info(campaign_template_id, opts)
|
414
|
+
data
|
415
|
+
end
|
416
|
+
|
417
|
+
# Update Campaign Template
|
418
|
+
# Updates the name or description of the campaign template. 📘 Campaign Templates – Documentation Read the [Campaign Templates documentation](https://support.voucherify.io/article/620-campaign-templates) to learn more about this feature.
|
419
|
+
# @param campaign_template_id [String] Pass the campaign template ID that was assigned by Voucherify.
|
420
|
+
# @param [Hash] opts the optional parameters
|
421
|
+
# @option opts [TemplatesCampaignsUpdateRequestBody] :templates_campaigns_update_request_body Provide the new name or description for the campaign template
|
422
|
+
# @return [Array<(TemplatesCampaignsUpdateResponseBody, Integer, Hash)>] TemplatesCampaignsUpdateResponseBody data, response status code and response headers
|
423
|
+
private def update_campaign_template_with_http_info(campaign_template_id, opts = {})
|
424
|
+
if @api_client.config.debugging
|
425
|
+
@api_client.config.logger.debug 'Calling API: TemplatesApi.update_campaign_template ...'
|
426
|
+
end
|
427
|
+
# resource path
|
428
|
+
local_var_path = '/v1/templates/campaigns/{campaignTemplateId}'.sub('{' + 'campaignTemplateId' + '}', CGI.escape(campaign_template_id.to_s))
|
429
|
+
|
430
|
+
# query parameters
|
431
|
+
query_params = opts[:query_params] || {}
|
432
|
+
|
433
|
+
# header parameters
|
434
|
+
header_params = opts[:header_params] || {}
|
435
|
+
# HTTP header 'Accept' (if needed)
|
436
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
437
|
+
# HTTP header 'Content-Type'
|
438
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
439
|
+
if !content_type.nil?
|
440
|
+
header_params['Content-Type'] = content_type
|
441
|
+
end
|
442
|
+
|
443
|
+
# form parameters
|
444
|
+
form_params = opts[:form_params] || {}
|
445
|
+
|
446
|
+
# http body (model)
|
447
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'templates_campaigns_update_request_body'])
|
448
|
+
|
449
|
+
# return_type
|
450
|
+
return_type = opts[:debug_return_type] || 'TemplatesCampaignsUpdateResponseBody'
|
451
|
+
|
452
|
+
# auth_names
|
453
|
+
auth_names = opts[:debug_auth_names] || ['X-App-Id', 'X-App-Token']
|
454
|
+
|
455
|
+
new_options = opts.merge(
|
456
|
+
:operation => :"TemplatesApi.update_campaign_template",
|
457
|
+
:header_params => header_params,
|
458
|
+
:query_params => query_params,
|
459
|
+
:form_params => form_params,
|
460
|
+
:body => post_body,
|
461
|
+
:auth_names => auth_names,
|
462
|
+
:return_type => return_type
|
463
|
+
)
|
464
|
+
|
465
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
466
|
+
if @api_client.config.debugging
|
467
|
+
@api_client.config.logger.debug "API called: TemplatesApi#update_campaign_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
468
|
+
end
|
469
|
+
return data, status_code, headers
|
470
|
+
end
|
471
|
+
end
|
472
|
+
end
|
@@ -586,7 +586,8 @@ module VoucherifySdk
|
|
586
586
|
# @param code [String] A **code** that identifies the voucher or a unique voucher ID assigned by Voucherify, i.e. v_TzD19aeNiqGc9LWciMWknyEZT8IW7u4u.
|
587
587
|
# @param [Hash] opts the optional parameters
|
588
588
|
# @option opts [Integer] :limit Limits the number of objects to be returned. The limit can range between 1 and 100 items. If no limit is set, it returns 10 items.
|
589
|
-
# @option opts [
|
589
|
+
# @option opts [ParameterOrderListTransactions] :order Sorts the results using one of the filtering options, where the dash - preceding a sorting option means sorting in a descending order.
|
590
|
+
# @option opts [String] :starting_after_id A cursor for pagination. It retrieves the transactions starting after a transaction with the given ID.
|
590
591
|
# @return [VouchersTransactionsListResponseBody]
|
591
592
|
def list_voucher_transactions(code, opts = {})
|
592
593
|
data, _status_code, _headers = list_voucher_transactions_with_http_info(code, opts)
|
@@ -598,7 +599,8 @@ module VoucherifySdk
|
|
598
599
|
# @param code [String] A **code** that identifies the voucher or a unique voucher ID assigned by Voucherify, i.e. v_TzD19aeNiqGc9LWciMWknyEZT8IW7u4u.
|
599
600
|
# @param [Hash] opts the optional parameters
|
600
601
|
# @option opts [Integer] :limit Limits the number of objects to be returned. The limit can range between 1 and 100 items. If no limit is set, it returns 10 items.
|
601
|
-
# @option opts [
|
602
|
+
# @option opts [ParameterOrderListTransactions] :order Sorts the results using one of the filtering options, where the dash - preceding a sorting option means sorting in a descending order.
|
603
|
+
# @option opts [String] :starting_after_id A cursor for pagination. It retrieves the transactions starting after a transaction with the given ID.
|
602
604
|
# @return [Array<(VouchersTransactionsListResponseBody, Integer, Hash)>] VouchersTransactionsListResponseBody data, response status code and response headers
|
603
605
|
private def list_voucher_transactions_with_http_info(code, opts = {})
|
604
606
|
if @api_client.config.debugging
|
@@ -610,7 +612,8 @@ module VoucherifySdk
|
|
610
612
|
# query parameters
|
611
613
|
query_params = opts[:query_params] || {}
|
612
614
|
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
613
|
-
query_params[:'
|
615
|
+
query_params[:'order'] = opts[:'order'] if !opts[:'order'].nil?
|
616
|
+
query_params[:'starting_after_id'] = opts[:'starting_after_id'] if !opts[:'starting_after_id'].nil?
|
614
617
|
|
615
618
|
# header parameters
|
616
619
|
header_params = opts[:header_params] || {}
|
@@ -77,6 +77,27 @@ module VoucherifySdk
|
|
77
77
|
return data, response.code, response.headers
|
78
78
|
end
|
79
79
|
|
80
|
+
|
81
|
+
# Serializes the query parameters for the HTTP request
|
82
|
+
#
|
83
|
+
# This method transforms the given parameters, converting any objects
|
84
|
+
# that respond to `to_hash` into a hash representation. This is necessary
|
85
|
+
# to ensure that the query parameters are in the correct format expected
|
86
|
+
# by the API.
|
87
|
+
#
|
88
|
+
# @param [Hash] params A hash of query parameters to serialize
|
89
|
+
# @return [Hash] A new hash with serialized query parameters
|
90
|
+
def serialize_query_params(params)
|
91
|
+
params.transform_values do |value|
|
92
|
+
if value.respond_to?(:to_hash)
|
93
|
+
value.to_hash
|
94
|
+
else
|
95
|
+
value
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
|
80
101
|
# Builds the HTTP request
|
81
102
|
#
|
82
103
|
# @param [String] http_method HTTP method/verb (e.g. POST)
|
@@ -103,7 +124,7 @@ module VoucherifySdk
|
|
103
124
|
req_opts = {
|
104
125
|
:method => http_method,
|
105
126
|
:headers => header_params,
|
106
|
-
:params => query_params,
|
127
|
+
:params => serialize_query_params(query_params),
|
107
128
|
:params_encoding => @config.params_encoding,
|
108
129
|
:timeout => @config.timeout,
|
109
130
|
:ssl_verifypeer => @config.verify_ssl,
|
@@ -262,6 +262,20 @@ module VoucherifySdk
|
|
262
262
|
key: 'X-Client-Application-Id',
|
263
263
|
value: api_key_with_prefix('X-Client-Application-Id')
|
264
264
|
},
|
265
|
+
'X-Management-Id' =>
|
266
|
+
{
|
267
|
+
type: 'api_key',
|
268
|
+
in: 'header',
|
269
|
+
key: 'X-Management-Id',
|
270
|
+
value: api_key_with_prefix('X-Management-Id')
|
271
|
+
},
|
272
|
+
'X-Management-Token' =>
|
273
|
+
{
|
274
|
+
type: 'api_key',
|
275
|
+
in: 'header',
|
276
|
+
key: 'X-Management-Token',
|
277
|
+
value: api_key_with_prefix('X-Management-Token')
|
278
|
+
},
|
265
279
|
}
|
266
280
|
end
|
267
281
|
|
@@ -14,7 +14,7 @@ require 'date'
|
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module VoucherifySdk
|
17
|
-
# Lists all assignments of the campaign to areas and stores if the Areas and Stores feature is enabled (
|
17
|
+
# Lists all assignments of the campaign to areas and stores. **NOTE**: This object is returned only if the Areas and Stores enterprise feature is enabled. Contact [Voucherify Sales](https://www.voucherify.io/contact-sales) to learn more.
|
18
18
|
class AccessSettingsCampaignAssignmentsList
|
19
19
|
# The type of the object represented by JSON. Default is `list`. This object stores information about campaign assignments to areas and stores
|
20
20
|
attr_accessor :object
|
@@ -15,13 +15,13 @@ require 'time'
|
|
15
15
|
|
16
16
|
module VoucherifySdk
|
17
17
|
class ApplicableTo
|
18
|
-
# This object stores information about the
|
18
|
+
# This object stores information about the resource to which the discount is applicable.
|
19
19
|
attr_accessor :object
|
20
20
|
|
21
|
-
# Unique product collection
|
21
|
+
# Unique product collection, product, or SKU identifier assigned by Voucherify.
|
22
22
|
attr_accessor :id
|
23
23
|
|
24
|
-
# The source
|
24
|
+
# The source identifier from your inventory system.
|
25
25
|
attr_accessor :source_id
|
26
26
|
|
27
27
|
# Parent product's unique ID assigned by Voucherify.
|
@@ -52,12 +52,16 @@ module VoucherifySdk
|
|
52
52
|
# Maximum discount amount per order. Value is multiplied by 100 to precisely represent 2 decimal places. For example, a $6 maximum discount on the entire order is written as 600. This value is definable for the following discount effects: - `APPLY_TO_ITEMS` (each item subtotal is discounted equally) - `APPLY_TO_ITEMS_BY_QUANTITY` (each unit of matched products has the same discount value)
|
53
53
|
attr_accessor :aggregated_amount_limit
|
54
54
|
|
55
|
+
# Determines the order in which the discount is applied to the products or SKUs sent in the `order` object in the request. The counting begins from `0`.
|
55
56
|
attr_accessor :order_item_indices
|
56
57
|
|
58
|
+
# Determines the recurrence of the discount, e.g. `\"repeat\": 3` means that the discount is applied to every third item.
|
57
59
|
attr_accessor :repeat
|
58
60
|
|
61
|
+
# Determines how many items are skipped before the discount is applied.
|
59
62
|
attr_accessor :skip_initially
|
60
63
|
|
64
|
+
# Determines to which kinds of objects the discount is applicable. `\"ITEM\"` includes products and SKUs.
|
61
65
|
attr_accessor :target
|
62
66
|
|
63
67
|
class EnumAttributeValidator
|
@@ -15,12 +15,14 @@ require 'time'
|
|
15
15
|
|
16
16
|
module VoucherifySdk
|
17
17
|
class ApplicableToEffect
|
18
|
-
|
19
|
-
|
20
|
-
|
18
|
+
TO_EVERY = "APPLY_TO_EVERY".freeze
|
19
|
+
TO_CHEAPEST = "APPLY_TO_CHEAPEST".freeze
|
20
|
+
FROM_CHEAPEST = "APPLY_FROM_CHEAPEST".freeze
|
21
|
+
TO_MOST_EXPENSIVE = "APPLY_TO_MOST_EXPENSIVE".freeze
|
22
|
+
FROM_MOST_EXPENSIVE = "APPLY_FROM_MOST_EXPENSIVE".freeze
|
21
23
|
|
22
24
|
def self.all_vars
|
23
|
-
@all_vars ||= [
|
25
|
+
@all_vars ||= [TO_EVERY, TO_CHEAPEST, FROM_CHEAPEST, TO_MOST_EXPENSIVE, FROM_MOST_EXPENSIVE].freeze
|
24
26
|
end
|
25
27
|
|
26
28
|
# Builds the enum from string
|