All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Model.GenerateCaptureContextRequest Maven / Gradle / Ivy

There is a newer version: 0.0.8
Show newest version
/*
 * CyberSource Merged Spec
 * All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
 *
 * OpenAPI spec version: 0.0.1
 * 
 *
 * 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 Model;

import java.util.Objects;
import java.util.Arrays;
import Model.Microformv2sessionsTransientTokenResponseOptions;
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.util.ArrayList;
import java.util.List;

/**
 * This is a server-to-server API request to generate the capture context that can be used to initiate an instance of Microform on an acceptance page.   The capture context is a digitally signed JWT that provides authentication, one-time keys, and the target origin to the Microform Integration application. 
 */
@ApiModel(description = "This is a server-to-server API request to generate the capture context that can be used to initiate an instance of Microform on an acceptance page.   The capture context is a digitally signed JWT that provides authentication, one-time keys, and the target origin to the Microform Integration application. ")

public class GenerateCaptureContextRequest {
  @SerializedName("clientVersion")
  private String clientVersion = null;

  @SerializedName("targetOrigins")
  private List targetOrigins = null;

  @SerializedName("allowedCardNetworks")
  private List allowedCardNetworks = null;

  @SerializedName("allowedPaymentTypes")
  private List allowedPaymentTypes = null;

  @SerializedName("transientTokenResponseOptions")
  private Microformv2sessionsTransientTokenResponseOptions transientTokenResponseOptions = null;

  public GenerateCaptureContextRequest clientVersion(String clientVersion) {
    this.clientVersion = clientVersion;
    return this;
  }

   /**
   * Specify the version of Microform that you want to use. 
   * @return clientVersion
  **/
  @ApiModelProperty(value = "Specify the version of Microform that you want to use. ")
  public String getClientVersion() {
    return clientVersion;
  }

  public void setClientVersion(String clientVersion) {
    this.clientVersion = clientVersion;
  }

  public GenerateCaptureContextRequest targetOrigins(List targetOrigins) {
    this.targetOrigins = targetOrigins;
    return this;
  }

  public GenerateCaptureContextRequest addTargetOriginsItem(String targetOriginsItem) {
    if (this.targetOrigins == null) {
      this.targetOrigins = new ArrayList();
    }
    this.targetOrigins.add(targetOriginsItem);
    return this;
  }

   /**
   * The [target origin](https://developer.mozilla.org/en-US/docs/Glossary/Origin) of the website on which you will be launching Microform is defined by the scheme (protocol), hostname (domain) and port number (if used).    You must use https://hostname (unless you use http://localhost) Wildcards are NOT supported.  Ensure that subdomains are included. Any valid top-level domain is supported (e.g. .com, .co.uk, .gov.br etc)  Examples:   - https://example.com   - https://subdomain.example.com   - https://example.com:8080<br><br>  If you are embedding within multiple nested iframes you need to specify the origins of all the browser contexts used, for example:    targetOrigins: [     \"https://example.com\",     \"https://basket.example.com\",     \"https://ecom.example.com\"   ]<br><br>  You can supply up to nine origins within the targetOrigins field for nested iframes. If the list of origins exceeds five ensure that you:   - Compare the list of origins in the v2/sessions targetOrigins field against the location.ancestorOrigins of the browser.    - Ensure that the count of origins and their content matches in both.  If any origins are absent or mismatched, the system will prevent Microform from loading and display a client-side error message. 
   * @return targetOrigins
  **/
  @ApiModelProperty(value = "The [target origin](https://developer.mozilla.org/en-US/docs/Glossary/Origin) of the website on which you will be launching Microform is defined by the scheme (protocol), hostname (domain) and port number (if used).    You must use https://hostname (unless you use http://localhost) Wildcards are NOT supported.  Ensure that subdomains are included. Any valid top-level domain is supported (e.g. .com, .co.uk, .gov.br etc)  Examples:   - https://example.com   - https://subdomain.example.com   - https://example.com:8080

If you are embedding within multiple nested iframes you need to specify the origins of all the browser contexts used, for example: targetOrigins: [ \"https://example.com\", \"https://basket.example.com\", \"https://ecom.example.com\" ]

You can supply up to nine origins within the targetOrigins field for nested iframes. If the list of origins exceeds five ensure that you: - Compare the list of origins in the v2/sessions targetOrigins field against the location.ancestorOrigins of the browser. - Ensure that the count of origins and their content matches in both. If any origins are absent or mismatched, the system will prevent Microform from loading and display a client-side error message. ") public List getTargetOrigins() { return targetOrigins; } public void setTargetOrigins(List targetOrigins) { this.targetOrigins = targetOrigins; } public GenerateCaptureContextRequest allowedCardNetworks(List allowedCardNetworks) { this.allowedCardNetworks = allowedCardNetworks; return this; } public GenerateCaptureContextRequest addAllowedCardNetworksItem(String allowedCardNetworksItem) { if (this.allowedCardNetworks == null) { this.allowedCardNetworks = new ArrayList(); } this.allowedCardNetworks.add(allowedCardNetworksItem); return this; } /** * The list of card networks you want to use for this Microform transaction. Microform currently supports the following card networks: - VISA - MASTERCARD - AMEX - CARNET - CARTESBANCAIRES - CUP - DINERSCLUB - DISCOVER - EFTPOS - ELO - JCB - JCREW - MADA - MAESTRO - MEEZA **Important:** - When integrating Microform (Card) at least one card network should be specified in the allowedCardNetworks field in the capture context request. - When integrating Microform (ACH/eCheck) the allowedCardNetworks field is not required in the capture context request. - When integrating both Microform (Card) and Microform (ACH/eCheck) at least one card network should be specified in the allowedCardNetworks field in the capture context request. * @return allowedCardNetworks **/ @ApiModelProperty(value = "The list of card networks you want to use for this Microform transaction. Microform currently supports the following card networks: - VISA - MASTERCARD - AMEX - CARNET - CARTESBANCAIRES - CUP - DINERSCLUB - DISCOVER - EFTPOS - ELO - JCB - JCREW - MADA - MAESTRO - MEEZA **Important:** - When integrating Microform (Card) at least one card network should be specified in the allowedCardNetworks field in the capture context request. - When integrating Microform (ACH/eCheck) the allowedCardNetworks field is not required in the capture context request. - When integrating both Microform (Card) and Microform (ACH/eCheck) at least one card network should be specified in the allowedCardNetworks field in the capture context request. ") public List getAllowedCardNetworks() { return allowedCardNetworks; } public void setAllowedCardNetworks(List allowedCardNetworks) { this.allowedCardNetworks = allowedCardNetworks; } public GenerateCaptureContextRequest allowedPaymentTypes(List allowedPaymentTypes) { this.allowedPaymentTypes = allowedPaymentTypes; return this; } public GenerateCaptureContextRequest addAllowedPaymentTypesItem(String allowedPaymentTypesItem) { if (this.allowedPaymentTypes == null) { this.allowedPaymentTypes = new ArrayList(); } this.allowedPaymentTypes.add(allowedPaymentTypesItem); return this; } /** * The payment types that are allowed for the merchant. Possible values when launching Microform: - CARD - CHECK <br><br> * @return allowedPaymentTypes **/ @ApiModelProperty(value = "The payment types that are allowed for the merchant. Possible values when launching Microform: - CARD - CHECK

") public List getAllowedPaymentTypes() { return allowedPaymentTypes; } public void setAllowedPaymentTypes(List allowedPaymentTypes) { this.allowedPaymentTypes = allowedPaymentTypes; } public GenerateCaptureContextRequest transientTokenResponseOptions(Microformv2sessionsTransientTokenResponseOptions transientTokenResponseOptions) { this.transientTokenResponseOptions = transientTokenResponseOptions; return this; } /** * Get transientTokenResponseOptions * @return transientTokenResponseOptions **/ @ApiModelProperty(value = "") public Microformv2sessionsTransientTokenResponseOptions getTransientTokenResponseOptions() { return transientTokenResponseOptions; } public void setTransientTokenResponseOptions(Microformv2sessionsTransientTokenResponseOptions transientTokenResponseOptions) { this.transientTokenResponseOptions = transientTokenResponseOptions; } @Override public boolean equals(java.lang.Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } GenerateCaptureContextRequest generateCaptureContextRequest = (GenerateCaptureContextRequest) o; return Objects.equals(this.clientVersion, generateCaptureContextRequest.clientVersion) && Objects.equals(this.targetOrigins, generateCaptureContextRequest.targetOrigins) && Objects.equals(this.allowedCardNetworks, generateCaptureContextRequest.allowedCardNetworks) && Objects.equals(this.allowedPaymentTypes, generateCaptureContextRequest.allowedPaymentTypes) && Objects.equals(this.transientTokenResponseOptions, generateCaptureContextRequest.transientTokenResponseOptions); } @Override public int hashCode() { return Objects.hash(clientVersion, targetOrigins, allowedCardNetworks, allowedPaymentTypes, transientTokenResponseOptions); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class GenerateCaptureContextRequest {\n"); if (clientVersion != null) sb.append(" clientVersion: ").append(toIndentedString(clientVersion)).append("\n"); if (targetOrigins != null) sb.append(" targetOrigins: ").append(toIndentedString(targetOrigins)).append("\n"); if (allowedCardNetworks != null) sb.append(" allowedCardNetworks: ").append(toIndentedString(allowedCardNetworks)).append("\n"); if (allowedPaymentTypes != null) sb.append(" allowedPaymentTypes: ").append(toIndentedString(allowedPaymentTypes)).append("\n"); if (transientTokenResponseOptions != null) sb.append(" transientTokenResponseOptions: ").append(toIndentedString(transientTokenResponseOptions)).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