sibModel.Order Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sib-api-v3-sdk Show documentation
Show all versions of sib-api-v3-sdk Show documentation
SendinBlue's API v3 Java Library
The newest version!
/*
* SendinBlue API
* SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed | | 406 | Error. Not Acceptable |
*
* OpenAPI spec version: 3.0.0
* Contact: [email protected]
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package sibModel;
import org.apache.commons.lang3.ObjectUtils;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import sibModel.OrderBilling;
import sibModel.OrderProducts;
/**
* Order
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2023-02-28T15:16:18.937+05:30")
public class Order {
@SerializedName("id")
private String id = null;
@SerializedName("createdAt")
private String createdAt = null;
@SerializedName("updatedAt")
private String updatedAt = null;
@SerializedName("status")
private String status = null;
@SerializedName("amount")
private BigDecimal amount = null;
@SerializedName("products")
private List products = new ArrayList();
@SerializedName("email")
private String email = null;
@SerializedName("billing")
private OrderBilling billing = null;
@SerializedName("coupons")
private List coupons = null;
public Order id(String id) {
this.id = id;
return this;
}
/**
* Unique ID of the order.
* @return id
**/
@ApiModelProperty(example = "14", required = true, value = "Unique ID of the order.")
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public Order createdAt(String createdAt) {
this.createdAt = createdAt;
return this;
}
/**
* Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created.
* @return createdAt
**/
@ApiModelProperty(example = "2021-07-29T20:59:23.383Z", required = true, value = "Event occurrence UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when order is actually created.")
public String getCreatedAt() {
return createdAt;
}
public void setCreatedAt(String createdAt) {
this.createdAt = createdAt;
}
public Order updatedAt(String updatedAt) {
this.updatedAt = updatedAt;
return this;
}
/**
* Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated.
* @return updatedAt
**/
@ApiModelProperty(example = "2021-07-30T10:59:23.383Z", required = true, value = "Event updated UTC date-time (YYYY-MM-DDTHH:mm:ssZ), when the status of the order is actually changed/updated.")
public String getUpdatedAt() {
return updatedAt;
}
public void setUpdatedAt(String updatedAt) {
this.updatedAt = updatedAt;
}
public Order status(String status) {
this.status = status;
return this;
}
/**
* State of the order.
* @return status
**/
@ApiModelProperty(example = "completed", required = true, value = "State of the order.")
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
public Order amount(BigDecimal amount) {
this.amount = amount;
return this;
}
/**
* Total amount of the order, including all shipping expenses, tax and the price of items.
* @return amount
**/
@ApiModelProperty(example = "308.42", required = true, value = "Total amount of the order, including all shipping expenses, tax and the price of items.")
public BigDecimal getAmount() {
return amount;
}
public void setAmount(BigDecimal amount) {
this.amount = amount;
}
public Order products(List products) {
this.products = products;
return this;
}
public Order addProductsItem(OrderProducts productsItem) {
this.products.add(productsItem);
return this;
}
/**
* Get products
* @return products
**/
@ApiModelProperty(required = true, value = "")
public List getProducts() {
return products;
}
public void setProducts(List products) {
this.products = products;
}
public Order email(String email) {
this.email = email;
return this;
}
/**
* Email of the contact, Mandatory if \"phone\" field is not passed in \"billing\" parameter.
* @return email
**/
@ApiModelProperty(example = "[email protected]", value = "Email of the contact, Mandatory if \"phone\" field is not passed in \"billing\" parameter.")
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public Order billing(OrderBilling billing) {
this.billing = billing;
return this;
}
/**
* Get billing
* @return billing
**/
@ApiModelProperty(value = "")
public OrderBilling getBilling() {
return billing;
}
public void setBilling(OrderBilling billing) {
this.billing = billing;
}
public Order coupons(List coupons) {
this.coupons = coupons;
return this;
}
public Order addCouponsItem(String couponsItem) {
if (this.coupons == null) {
this.coupons = new ArrayList();
}
this.coupons.add(couponsItem);
return this;
}
/**
* Coupons applied to the order. Stored case insensitive.
* @return coupons
**/
@ApiModelProperty(example = "[\"EASTER15OFF\"]", value = "Coupons applied to the order. Stored case insensitive.")
public List getCoupons() {
return coupons;
}
public void setCoupons(List coupons) {
this.coupons = coupons;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Order order = (Order) o;
return ObjectUtils.equals(this.id, order.id) &&
ObjectUtils.equals(this.createdAt, order.createdAt) &&
ObjectUtils.equals(this.updatedAt, order.updatedAt) &&
ObjectUtils.equals(this.status, order.status) &&
ObjectUtils.equals(this.amount, order.amount) &&
ObjectUtils.equals(this.products, order.products) &&
ObjectUtils.equals(this.email, order.email) &&
ObjectUtils.equals(this.billing, order.billing) &&
ObjectUtils.equals(this.coupons, order.coupons);
}
@Override
public int hashCode() {
return ObjectUtils.hashCodeMulti(id, createdAt, updatedAt, status, amount, products, email, billing, coupons);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Order {\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n");
sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n");
sb.append(" status: ").append(toIndentedString(status)).append("\n");
sb.append(" amount: ").append(toIndentedString(amount)).append("\n");
sb.append(" products: ").append(toIndentedString(products)).append("\n");
sb.append(" email: ").append(toIndentedString(email)).append("\n");
sb.append(" billing: ").append(toIndentedString(billing)).append("\n");
sb.append(" coupons: ").append(toIndentedString(coupons)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy