
com.infobip.model.WhatsAppInteractiveProductActionContent Maven / Gradle / Ivy
/*
* This class is auto generated from the Infobip OpenAPI specification
* through the OpenAPI Specification Client API libraries (Re)Generator (OSCAR),
* powered by the OpenAPI Generator (https://openapi-generator.tech).
*
* Do not edit manually. To learn how to raise an issue, see the CONTRIBUTING guide
* or contact us @ [email protected].
*/
package com.infobip.model;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Objects;
/**
* Allows you to specify catalog and product details sent in the product message.
*/
public class WhatsAppInteractiveProductActionContent {
private String catalogId;
private String productRetailerId;
/**
* Sets catalogId.
*
* Field description:
* The ID that uniquely identifies the [catalog](https://www.infobip.com/docs/whatsapp/manage-connection#manage-catalog) registered with Facebook and connected to the WhatsApp Business Account the sender belongs to.
*
* The field is required.
*
* @param catalogId
* @return This {@link WhatsAppInteractiveProductActionContent instance}.
*/
public WhatsAppInteractiveProductActionContent catalogId(String catalogId) {
this.catalogId = catalogId;
return this;
}
/**
* Returns catalogId.
*
* Field description:
* The ID that uniquely identifies the [catalog](https://www.infobip.com/docs/whatsapp/manage-connection#manage-catalog) registered with Facebook and connected to the WhatsApp Business Account the sender belongs to.
*
* The field is required.
*
* @return catalogId
*/
@JsonProperty("catalogId")
public String getCatalogId() {
return catalogId;
}
/**
* Sets catalogId.
*
* Field description:
* The ID that uniquely identifies the [catalog](https://www.infobip.com/docs/whatsapp/manage-connection#manage-catalog) registered with Facebook and connected to the WhatsApp Business Account the sender belongs to.
*
* The field is required.
*
* @param catalogId
*/
@JsonProperty("catalogId")
public void setCatalogId(String catalogId) {
this.catalogId = catalogId;
}
/**
* Sets productRetailerId.
*
* Field description:
* Product-unique identifier, as defined in catalog.
*
* The field is required.
*
* @param productRetailerId
* @return This {@link WhatsAppInteractiveProductActionContent instance}.
*/
public WhatsAppInteractiveProductActionContent productRetailerId(String productRetailerId) {
this.productRetailerId = productRetailerId;
return this;
}
/**
* Returns productRetailerId.
*
* Field description:
* Product-unique identifier, as defined in catalog.
*
* The field is required.
*
* @return productRetailerId
*/
@JsonProperty("productRetailerId")
public String getProductRetailerId() {
return productRetailerId;
}
/**
* Sets productRetailerId.
*
* Field description:
* Product-unique identifier, as defined in catalog.
*
* The field is required.
*
* @param productRetailerId
*/
@JsonProperty("productRetailerId")
public void setProductRetailerId(String productRetailerId) {
this.productRetailerId = productRetailerId;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
WhatsAppInteractiveProductActionContent whatsAppInteractiveProductActionContent =
(WhatsAppInteractiveProductActionContent) o;
return Objects.equals(this.catalogId, whatsAppInteractiveProductActionContent.catalogId)
&& Objects.equals(this.productRetailerId, whatsAppInteractiveProductActionContent.productRetailerId);
}
@Override
public int hashCode() {
return Objects.hash(catalogId, productRetailerId);
}
@Override
public String toString() {
String newLine = System.lineSeparator();
return new StringBuilder()
.append("class WhatsAppInteractiveProductActionContent {")
.append(newLine)
.append(" catalogId: ")
.append(toIndentedString(catalogId))
.append(newLine)
.append(" productRetailerId: ")
.append(toIndentedString(productRetailerId))
.append(newLine)
.append("}")
.toString();
}
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
String lineSeparator = System.lineSeparator();
String lineSeparatorFollowedByIndentation = lineSeparator + " ";
return o.toString().replace(lineSeparator, lineSeparatorFollowedByIndentation);
}
}