Package io.voucherify.client.model
Class CampaignsGetResponseBody
java.lang.Object
io.voucherify.client.model.CampaignsGetResponseBody
@Generated("org.openapitools.codegen.languages.JavaClientCodegen")
public class CampaignsGetResponseBody
extends Object
Response body schema for **GET** `v1/campaigns/{campaignId}`.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumType of campaign.static enumIndicates the status of the campaign creation.static classstatic enumDefines whether the campaign can be updated with new vouchers after campaign creation or if the campaign consists of standalone vouchers.static enumGets or Sets validityDayOfWeekstatic enumIndicates the status of the campaign's voucher generation. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription_protected(Boolean _protected) accessSettingsAssignments(AccessSettingsCampaignAssignmentsList accessSettingsAssignments) activityDurationAfterPublishing(String activityDurationAfterPublishing) addCategoriesItem(Category categoriesItem) addValidityDayOfWeekItem(CampaignsGetResponseBody.ValidityDayOfWeekEnum validityDayOfWeekItem) campaignType(CampaignsGetResponseBody.CampaignTypeEnum campaignType) categories(List<Category> categories) categoryId(String categoryId) createdAt(OffsetDateTime createdAt) creationStatus(CampaignsGetResponseBody.CreationStatusEnum creationStatus) description(String description) booleanexpirationDate(OffsetDateTime expirationDate) static CampaignsGetResponseBodyCreate an instance of CampaignsGetResponseBody given an JSON stringGet accessSettingsAssignmentsA flag to toggle the campaign on or off.Defines the amount of time the vouchers will be active after publishing.Indicates whether customers will be able to auto-join a loyalty campaign if any earning rule is fulfilled.Type of campaign.Contains details about the category.Unique category name.Unique category ID that this campaign belongs to.Timestamp representing the date and time when the campaign was created.Indicates the status of the campaign creation.An optional field to keep any extra textual information about the campaign such as a campaign description and details.Expiration timestamp defines when the campaign expires in ISO 8601 format.getId()Unique campaign ID, assigned by Voucherify.If this value is set to `true`, customers will be able to join the campaign only once.Get loyaltyTiersExpirationThe metadata object stores all custom attributes assigned to the campaign.getName()Campaign name.The type of the object represented by JSON.Get promotionIndicates whether the resource can be deleted.Indicates whether the campaign can be only read by a restricted user in the Areas and Stores enterprise feature.Get referralProgramActivation timestamp defines when the campaign starts to be active in ISO 8601 format.getType()Defines whether the campaign can be updated with new vouchers after campaign creation or if the campaign consists of standalone vouchers.Timestamp representing the date and time when the campaign was last updated in ISO 8601 format.Flag indicating whether the campaign is to use the voucher's metadata schema instead of the campaign metadata schema.Get validationRulesAssignmentsInteger array corresponding to the particular days of the week in which the voucher is valid.Get validityHoursGet validityTimeframeGet voucherTotal number of unique vouchers in campaign.Indicates the status of the campaign's voucher generation.inthashCode()loyaltyTiersExpiration(LoyaltyTiersExpirationAll loyaltyTiersExpiration) promotion(PromotionTiersList promotion) referralProgram(ReferralProgram referralProgram) voidsetAccessSettingsAssignments(AccessSettingsCampaignAssignmentsList accessSettingsAssignments) voidvoidsetActivityDurationAfterPublishing(String activityDurationAfterPublishing) voidsetAutoJoin(Boolean autoJoin) voidsetCampaignType(CampaignsGetResponseBody.CampaignTypeEnum campaignType) voidsetCategories(List<Category> categories) voidsetCategory(String category) voidsetCategoryId(String categoryId) voidsetCreatedAt(OffsetDateTime createdAt) voidsetCreationStatus(CampaignsGetResponseBody.CreationStatusEnum creationStatus) voidsetDescription(String description) voidsetExpirationDate(OffsetDateTime expirationDate) voidvoidsetJoinOnce(Boolean joinOnce) voidsetLoyaltyTiersExpiration(LoyaltyTiersExpirationAll loyaltyTiersExpiration) voidsetMetadata(Object metadata) voidvoidvoidsetPromotion(PromotionTiersList promotion) voidsetProtected(Boolean _protected) voidsetReadonly(Boolean readonly) voidsetReferralProgram(ReferralProgram referralProgram) voidsetStartDate(OffsetDateTime startDate) voidvoidsetUpdatedAt(OffsetDateTime updatedAt) voidsetUseVoucherMetadataSchema(Boolean useVoucherMetadataSchema) voidsetValidationRulesAssignments(ValidationRulesAssignmentsList validationRulesAssignments) voidsetValidityDayOfWeek(List<CampaignsGetResponseBody.ValidityDayOfWeekEnum> validityDayOfWeek) voidsetValidityHours(ValidityHours validityHours) voidsetValidityTimeframe(ValidityTimeframe validityTimeframe) voidsetVoucher(CampaignVoucher voucher) voidsetVouchersCount(Integer vouchersCount) voidsetVouchersGenerationStatus(CampaignsGetResponseBody.VouchersGenerationStatusEnum vouchersGenerationStatus) startDate(OffsetDateTime startDate) toJson()Convert an instance of CampaignsGetResponseBody to an JSON stringtoString()updatedAt(OffsetDateTime updatedAt) useVoucherMetadataSchema(Boolean useVoucherMetadataSchema) validationRulesAssignments(ValidationRulesAssignmentsList validationRulesAssignments) validityDayOfWeek(List<CampaignsGetResponseBody.ValidityDayOfWeekEnum> validityDayOfWeek) validityHours(ValidityHours validityHours) validityTimeframe(ValidityTimeframe validityTimeframe) voucher(CampaignVoucher voucher) vouchersCount(Integer vouchersCount) vouchersGenerationStatus(CampaignsGetResponseBody.VouchersGenerationStatusEnum vouchersGenerationStatus)
-
Field Details
-
SERIALIZED_NAME_ID
- See Also:
-
SERIALIZED_NAME_NAME
- See Also:
-
SERIALIZED_NAME_DESCRIPTION
- See Also:
-
SERIALIZED_NAME_CAMPAIGN_TYPE
- See Also:
-
SERIALIZED_NAME_TYPE
- See Also:
-
SERIALIZED_NAME_VOUCHER
- See Also:
-
SERIALIZED_NAME_AUTO_JOIN
- See Also:
-
SERIALIZED_NAME_JOIN_ONCE
- See Also:
-
SERIALIZED_NAME_USE_VOUCHER_METADATA_SCHEMA
- See Also:
-
SERIALIZED_NAME_VALIDITY_TIMEFRAME
- See Also:
-
SERIALIZED_NAME_VALIDITY_DAY_OF_WEEK
- See Also:
-
SERIALIZED_NAME_VALIDITY_HOURS
- See Also:
-
SERIALIZED_NAME_ACTIVITY_DURATION_AFTER_PUBLISHING
- See Also:
-
SERIALIZED_NAME_VOUCHERS_COUNT
- See Also:
-
SERIALIZED_NAME_START_DATE
- See Also:
-
SERIALIZED_NAME_EXPIRATION_DATE
- See Also:
-
SERIALIZED_NAME_ACTIVE
- See Also:
-
SERIALIZED_NAME_METADATA
- See Also:
-
SERIALIZED_NAME_CREATED_AT
- See Also:
-
SERIALIZED_NAME_UPDATED_AT
- See Also:
-
SERIALIZED_NAME_CATEGORY
- See Also:
-
SERIALIZED_NAME_CREATION_STATUS
- See Also:
-
SERIALIZED_NAME_VOUCHERS_GENERATION_STATUS
- See Also:
-
SERIALIZED_NAME_READONLY
- See Also:
-
SERIALIZED_NAME_PROTECTED
- See Also:
-
SERIALIZED_NAME_CATEGORY_ID
- See Also:
-
SERIALIZED_NAME_CATEGORIES
- See Also:
-
SERIALIZED_NAME_OBJECT
- See Also:
-
SERIALIZED_NAME_REFERRAL_PROGRAM
- See Also:
-
SERIALIZED_NAME_LOYALTY_TIERS_EXPIRATION
- See Also:
-
SERIALIZED_NAME_PROMOTION
- See Also:
-
SERIALIZED_NAME_VALIDATION_RULES_ASSIGNMENTS
- See Also:
-
SERIALIZED_NAME_ACCESS_SETTINGS_ASSIGNMENTS
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
CampaignsGetResponseBody
public CampaignsGetResponseBody()
-
-
Method Details
-
id
-
getId
Unique campaign ID, assigned by Voucherify.- Returns:
- id
-
setId
-
name
-
getName
Campaign name.- Returns:
- name
-
setName
-
description
-
getDescription
An optional field to keep any extra textual information about the campaign such as a campaign description and details.- Returns:
- description
-
setDescription
-
campaignType
public CampaignsGetResponseBody campaignType(CampaignsGetResponseBody.CampaignTypeEnum campaignType) -
getCampaignType
Type of campaign.- Returns:
- campaignType
-
setCampaignType
-
type
-
getType
Defines whether the campaign can be updated with new vouchers after campaign creation or if the campaign consists of standalone vouchers. - `AUTO_UPDATE`: the campaign is dynamic, i.e. vouchers will generate based on set criteria - `STATIC`: vouchers need to be manually published - `STANDALONE`: campaign for single vouchers- Returns:
- type
-
setType
-
voucher
-
getVoucher
Get voucher- Returns:
- voucher
-
setVoucher
-
autoJoin
-
getAutoJoin
Indicates whether customers will be able to auto-join a loyalty campaign if any earning rule is fulfilled.- Returns:
- autoJoin
-
setAutoJoin
-
joinOnce
-
getJoinOnce
If this value is set to `true`, customers will be able to join the campaign only once. It is always `false` for standalone voucher campaigns and it cannot be changed in them.- Returns:
- joinOnce
-
setJoinOnce
-
useVoucherMetadataSchema
-
getUseVoucherMetadataSchema
Flag indicating whether the campaign is to use the voucher's metadata schema instead of the campaign metadata schema.- Returns:
- useVoucherMetadataSchema
-
setUseVoucherMetadataSchema
-
validityTimeframe
-
getValidityTimeframe
Get validityTimeframe- Returns:
- validityTimeframe
-
setValidityTimeframe
-
validityDayOfWeek
public CampaignsGetResponseBody validityDayOfWeek(List<CampaignsGetResponseBody.ValidityDayOfWeekEnum> validityDayOfWeek) -
addValidityDayOfWeekItem
public CampaignsGetResponseBody addValidityDayOfWeekItem(CampaignsGetResponseBody.ValidityDayOfWeekEnum validityDayOfWeekItem) -
getValidityDayOfWeek
Integer array corresponding to the particular days of the week in which the voucher is valid. - `0` Sunday - `1` Monday - `2` Tuesday - `3` Wednesday - `4` Thursday - `5` Friday - `6` Saturday- Returns:
- validityDayOfWeek
-
setValidityDayOfWeek
public void setValidityDayOfWeek(List<CampaignsGetResponseBody.ValidityDayOfWeekEnum> validityDayOfWeek) -
validityHours
-
getValidityHours
Get validityHours- Returns:
- validityHours
-
setValidityHours
-
activityDurationAfterPublishing
public CampaignsGetResponseBody activityDurationAfterPublishing(String activityDurationAfterPublishing) -
getActivityDurationAfterPublishing
Defines the amount of time the vouchers will be active after publishing. The value is shown in the ISO 8601 format. For example, a voucher with the value of P24D will be valid for a duration of 24 days.- Returns:
- activityDurationAfterPublishing
-
setActivityDurationAfterPublishing
-
vouchersCount
-
getVouchersCount
Total number of unique vouchers in campaign.- Returns:
- vouchersCount
-
setVouchersCount
-
startDate
-
getStartDate
Activation timestamp defines when the campaign starts to be active in ISO 8601 format. Campaign is *inactive before* this date.- Returns:
- startDate
-
setStartDate
-
expirationDate
-
getExpirationDate
Expiration timestamp defines when the campaign expires in ISO 8601 format. Campaign is *inactive after* this date.- Returns:
- expirationDate
-
setExpirationDate
-
active
-
getActive
A flag to toggle the campaign on or off. You can disable a campaign even though it's within the active period defined by the `start_date` and `expiration_date`. - `true` indicates an *active* campaign - `false` indicates an *inactive* campaign- Returns:
- active
-
setActive
-
metadata
-
getMetadata
The metadata object stores all custom attributes assigned to the campaign. A set of key/value pairs that you can attach to a campaign object. It can be useful for storing additional information about the campaign in a structured format.- Returns:
- metadata
-
setMetadata
-
createdAt
-
getCreatedAt
Timestamp representing the date and time when the campaign was created. The value is shown in the ISO 8601 format.- Returns:
- createdAt
-
setCreatedAt
-
updatedAt
-
getUpdatedAt
Timestamp representing the date and time when the campaign was last updated in ISO 8601 format.- Returns:
- updatedAt
-
setUpdatedAt
-
category
-
getCategory
Unique category name.- Returns:
- category
-
setCategory
-
creationStatus
public CampaignsGetResponseBody creationStatus(CampaignsGetResponseBody.CreationStatusEnum creationStatus) -
getCreationStatus
Indicates the status of the campaign creation.- Returns:
- creationStatus
-
setCreationStatus
-
vouchersGenerationStatus
public CampaignsGetResponseBody vouchersGenerationStatus(CampaignsGetResponseBody.VouchersGenerationStatusEnum vouchersGenerationStatus) -
getVouchersGenerationStatus
@Nullable public CampaignsGetResponseBody.VouchersGenerationStatusEnum getVouchersGenerationStatus()Indicates the status of the campaign's voucher generation.- Returns:
- vouchersGenerationStatus
-
setVouchersGenerationStatus
public void setVouchersGenerationStatus(CampaignsGetResponseBody.VouchersGenerationStatusEnum vouchersGenerationStatus) -
readonly
-
getReadonly
Indicates whether the campaign can be only read by a restricted user in the Areas and Stores enterprise feature. It is returned only to restricted users; this field is not returned for users with other roles.- Returns:
- readonly
-
setReadonly
-
_protected
-
getProtected
Indicates whether the resource can be deleted.- Returns:
- _protected
-
setProtected
-
categoryId
-
getCategoryId
Unique category ID that this campaign belongs to.- Returns:
- categoryId
-
setCategoryId
-
categories
-
addCategoriesItem
-
getCategories
Contains details about the category.- Returns:
- categories
-
setCategories
-
_object
-
getObject
The type of the object represented by JSON. This object stores information about the campaign.- Returns:
- _object
-
setObject
-
referralProgram
-
getReferralProgram
Get referralProgram- Returns:
- referralProgram
-
setReferralProgram
-
loyaltyTiersExpiration
public CampaignsGetResponseBody loyaltyTiersExpiration(LoyaltyTiersExpirationAll loyaltyTiersExpiration) -
getLoyaltyTiersExpiration
Get loyaltyTiersExpiration- Returns:
- loyaltyTiersExpiration
-
setLoyaltyTiersExpiration
-
promotion
-
getPromotion
Get promotion- Returns:
- promotion
-
setPromotion
-
validationRulesAssignments
public CampaignsGetResponseBody validationRulesAssignments(ValidationRulesAssignmentsList validationRulesAssignments) -
getValidationRulesAssignments
Get validationRulesAssignments- Returns:
- validationRulesAssignments
-
setValidationRulesAssignments
public void setValidationRulesAssignments(ValidationRulesAssignmentsList validationRulesAssignments) -
accessSettingsAssignments
public CampaignsGetResponseBody accessSettingsAssignments(AccessSettingsCampaignAssignmentsList accessSettingsAssignments) -
getAccessSettingsAssignments
Get accessSettingsAssignments- Returns:
- accessSettingsAssignments
-
setAccessSettingsAssignments
public void setAccessSettingsAssignments(AccessSettingsCampaignAssignmentsList accessSettingsAssignments) -
equals
-
hashCode
public int hashCode() -
toString
-
fromJson
Create an instance of CampaignsGetResponseBody given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of CampaignsGetResponseBody
- Throws:
IOException- if the JSON string is invalid with respect to CampaignsGetResponseBody
-
toJson
Convert an instance of CampaignsGetResponseBody to an JSON string- Returns:
- JSON string
-