com.chargebee.models
Class Coupon

java.lang.Object
  extended by com.chargebee.internal.Resource<Coupon>
      extended by com.chargebee.models.Coupon

public class Coupon
extends Resource<Coupon>


Nested Class Summary
static class Coupon.AddonConstraint
           
static class Coupon.ApplyDiscountOn
          Deprecated. 
static class Coupon.ApplyOn
           
static class Coupon.CopyRequest
           
static class Coupon.CouponListRequest
           
static class Coupon.CreateRequest
           
static class Coupon.DiscountType
           
static class Coupon.DurationType
           
static class Coupon.PlanConstraint
           
static class Coupon.Status
           
 
Field Summary
 
Fields inherited from class com.chargebee.internal.Resource
jsonObj
 
Constructor Summary
Coupon(org.json.JSONObject jsonObj)
           
Coupon(String jsonStr)
           
 
Method Summary
 Coupon.AddonConstraint addonConstraint()
           
 List<String> addonIds()
           
 Coupon.ApplyDiscountOn applyDiscountOn()
          Deprecated. 
 Coupon.ApplyOn applyOn()
           
 Timestamp archivedAt()
           
static Coupon.CopyRequest copy()
           
static Coupon.CreateRequest create()
           
 Timestamp createdAt()
           
 String currencyCode()
           
static Request delete(String id)
           
 Integer discountAmount()
           
 Double discountPercentage()
           
 Integer discountQuantity()
          Deprecated. 
 Coupon.DiscountType discountType()
           
 Integer durationMonth()
           
 Coupon.DurationType durationType()
           
 String id()
           
 String invoiceName()
           
 String invoiceNotes()
           
static Coupon.CouponListRequest list()
           
 Integer maxRedemptions()
           
 org.json.JSONObject metaData()
           
 String name()
           
 Coupon.PlanConstraint planConstraint()
           
 List<String> planIds()
           
 Integer redemptions()
           
 Long resourceVersion()
           
static Request retrieve(String id)
           
 Coupon.Status status()
           
static Request unarchive(String id)
           
 Timestamp updatedAt()
           
 Timestamp validTill()
           
 
Methods inherited from class com.chargebee.internal.Resource
apiVersionCheck, nullCheck, optBigDecimal, optBoolean, optDouble, optEnum, optInteger, optJSONObject, optList, optLong, optString, optSubResource, optTimestamp, reqBigDecimal, reqBoolean, reqDouble, reqEnum, reqInteger, reqJSONObject, reqList, reqLong, reqString, reqSubResource, reqTimestamp, toJson, toString, uri
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Coupon

public Coupon(String jsonStr)

Coupon

public Coupon(org.json.JSONObject jsonObj)
Method Detail

id

public String id()

name

public String name()

invoiceName

public String invoiceName()

discountType

public Coupon.DiscountType discountType()

discountPercentage

public Double discountPercentage()

discountAmount

public Integer discountAmount()

discountQuantity

@Deprecated
public Integer discountQuantity()
Deprecated. 


currencyCode

public String currencyCode()

durationType

public Coupon.DurationType durationType()

durationMonth

public Integer durationMonth()

validTill

public Timestamp validTill()

maxRedemptions

public Integer maxRedemptions()

status

public Coupon.Status status()

applyDiscountOn

@Deprecated
public Coupon.ApplyDiscountOn applyDiscountOn()
Deprecated. 


applyOn

public Coupon.ApplyOn applyOn()

planConstraint

public Coupon.PlanConstraint planConstraint()

addonConstraint

public Coupon.AddonConstraint addonConstraint()

createdAt

public Timestamp createdAt()

archivedAt

public Timestamp archivedAt()

resourceVersion

public Long resourceVersion()

updatedAt

public Timestamp updatedAt()

planIds

public List<String> planIds()

addonIds

public List<String> addonIds()

redemptions

public Integer redemptions()

invoiceNotes

public String invoiceNotes()

metaData

public org.json.JSONObject metaData()

create

public static Coupon.CreateRequest create()
                                   throws IOException
Throws:
IOException

list

public static Coupon.CouponListRequest list()
                                     throws IOException
Throws:
IOException

retrieve

public static Request retrieve(String id)
                        throws IOException
Throws:
IOException

delete

public static Request delete(String id)
                      throws IOException
Throws:
IOException

copy

public static Coupon.CopyRequest copy()
                               throws IOException
Throws:
IOException

unarchive

public static Request unarchive(String id)
                         throws IOException
Throws:
IOException


Copyright © 2017 ChargeBee. All Rights Reserved.