Package io.voucherify.client.model
Class ValidationRulesGetResponseBody
java.lang.Object
io.voucherify.client.model.ValidationRulesGetResponseBody
@Generated("org.openapitools.codegen.languages.JavaClientCodegen")
public class ValidationRulesGetResponseBody
extends Object
Response body schema for **GET** `v1/validation-rules/{validationRuleId}`.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumValidation rule context type.static classstatic enumType of validation rule. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapplicableTo(ValidationRulesGetResponseBodyApplicableTo applicableTo) assignmentsCount(Integer assignmentsCount) createdAt(OffsetDateTime createdAt) booleanCreate an instance of ValidationRulesGetResponseBody given an JSON stringGet applicableToThe number of instances the validation rule has been assigned to different types of redeemables.Validation rule context type.Timestamp representing the date and time when the validation rule was created.getError()Get errorgetId()Unique validation rule ID.getName()Custom, unique name for set of validation rules.The type of the object represented by JSON.getRules()Contains all the rule definitions for the validation rule.getType()Type of validation rule.Timestamp representing the date and time when the validation rule was updated.inthashCode()voidsetApplicableTo(ValidationRulesGetResponseBodyApplicableTo applicableTo) voidsetAssignmentsCount(Integer assignmentsCount) voidvoidsetCreatedAt(OffsetDateTime createdAt) voidvoidvoidvoidvoidvoidvoidsetUpdatedAt(OffsetDateTime updatedAt) toJson()Convert an instance of ValidationRulesGetResponseBody to an JSON stringtoString()updatedAt(OffsetDateTime updatedAt)
-
Field Details
-
SERIALIZED_NAME_NAME
- See Also:
-
SERIALIZED_NAME_RULES
- See Also:
-
SERIALIZED_NAME_ERROR
- See Also:
-
SERIALIZED_NAME_APPLICABLE_TO
- See Also:
-
SERIALIZED_NAME_TYPE
- See Also:
-
SERIALIZED_NAME_CONTEXT_TYPE
- See Also:
-
SERIALIZED_NAME_ID
- See Also:
-
SERIALIZED_NAME_CREATED_AT
- See Also:
-
SERIALIZED_NAME_UPDATED_AT
- See Also:
-
SERIALIZED_NAME_ASSIGNMENTS_COUNT
- See Also:
-
SERIALIZED_NAME_OBJECT
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
ValidationRulesGetResponseBody
public ValidationRulesGetResponseBody()
-
-
Method Details
-
name
-
getName
Custom, unique name for set of validation rules.- Returns:
- name
-
setName
-
rules
-
getRules
Contains all the rule definitions for the validation rule. It is a set of key value pairs representing the rules and logic between the rules. The keys are numbered consecutively beginning from `1`. The values are objects containing the rule conditions.- Returns:
- rules
-
setRules
-
error
-
getError
Get error- Returns:
- error
-
setError
-
applicableTo
public ValidationRulesGetResponseBody applicableTo(ValidationRulesGetResponseBodyApplicableTo applicableTo) -
getApplicableTo
Get applicableTo- Returns:
- applicableTo
-
setApplicableTo
-
type
-
getType
Type of validation rule.- Returns:
- type
-
setType
-
contextType
public ValidationRulesGetResponseBody contextType(ValidationRulesGetResponseBody.ContextTypeEnum contextType) -
getContextType
Validation rule context type. | **Context Type** | **Definition** | |:---|:---| | earning_rule.order.paid | | | earning_rule.custom_event | | | earning_rule.customer.segment.entered | | | campaign.discount_coupons | | | campaign.discount_coupons.discount.apply_to_order | | | campaign.discount_coupons.discount.apply_to_items | | | campaign.discount_coupons.discount.apply_to_items_proportionally | | | campaign.discount_coupons.discount.apply_to_items_proportionally_by_quantity | | | campaign.discount_coupons.discount.fixed.apply_to_items | | | campaign.gift_vouchers | | | campaign.gift_vouchers.gift.apply_to_order | | | campaign.gift_vouchers.gift.apply_to_items | | | campaign.referral_program | | | campaign.referral_program.discount.apply_to_order | | | campaign.referral_program.discount.apply_to_items | | | campaign.referral_program.discount.apply_to_items_proportionally | | | campaign.referral_program.discount.apply_to_items_proportionally_by_quantity | | | campaign.referral_program.discount.fixed.apply_to_items | | | campaign.promotion | | | campaign.promotion.discount.apply_to_order | | | campaign.promotion.discount.apply_to_items | | | campaign.promotion.discount.apply_to_items_proportionally | | | campaign.promotion.discount.apply_to_items_proportionally_by_quantity | | | campaign.promotion.discount.fixed.apply_to_items | | | campaign.loyalty_program | | | voucher.discount_voucher | | | voucher.discount_voucher.discount.apply_to_order | | | voucher.discount_voucher.discount.apply_to_items | | | voucher.discount_voucher.discount.apply_to_items_proportionally | | | voucher.discount_voucher.discount.apply_to_items_proportionally_by_quantity | | | voucher.discount_voucher.discount.fixed.apply_to_items | | | voucher.gift_voucher | | | voucher.gift_voucher.gift.apply_to_order | | | voucher.gift_voucher.gift.apply_to_items | | | voucher.loyalty_card | | | distribution.custom_event | | | reward_assignment.pay_with_points | | | global | |- Returns:
- contextType
-
setContextType
-
id
-
getId
Unique validation rule ID.- Returns:
- id
-
setId
-
createdAt
-
getCreatedAt
Timestamp representing the date and time when the validation rule was created. The value is shown in the ISO 8601 format.- Returns:
- createdAt
-
setCreatedAt
-
updatedAt
-
getUpdatedAt
Timestamp representing the date and time when the validation rule was updated. The value is shown in the ISO 8601 format.- Returns:
- updatedAt
-
setUpdatedAt
-
assignmentsCount
-
getAssignmentsCount
The number of instances the validation rule has been assigned to different types of redeemables.- Returns:
- assignmentsCount
-
setAssignmentsCount
-
_object
-
getObject
The type of the object represented by JSON. This object stores information about the validation rule.- Returns:
- _object
-
setObject
-
equals
-
hashCode
public int hashCode() -
toString
-
fromJson
Create an instance of ValidationRulesGetResponseBody given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of ValidationRulesGetResponseBody
- Throws:
IOException- if the JSON string is invalid with respect to ValidationRulesGetResponseBody
-
toJson
Convert an instance of ValidationRulesGetResponseBody to an JSON string- Returns:
- JSON string
-