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

com.mailgun.model.domains.DomainRequest Maven / Gradle / Ivy

Go to download

The Mailgun SDK for Java enables Java developers to work with Mailgun API efficiently.

The newest version!
package com.mailgun.model.domains;

import com.mailgun.enums.SpamAction;
import com.mailgun.enums.WebScheme;
import feign.form.FormProperty;
import lombok.Builder;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;

import java.util.List;

/**
 * 

* New domain request. *

* * @see Domains */ @Getter @ToString @EqualsAndHashCode @Builder public class DomainRequest { /** *

* Name of the domain (ex. domain.com). *

*/ String name; /** *

* Spam action: disabled, block or tag. *

* {@link SpamAction} * *

* If disabled, no spam filtering will occur for inbound messages. * If block, inbound spam messages will not be delivered. * If tag, inbound messages will be tagged with a spam header. *

* *

* The default is disabled. *

*/ @FormProperty("spam_action") String spamAction; /** *

* Determines whether the domain will accept email for sub-domains when sending messages. * true or false *

* *

* The default is false. *

*/ Boolean wildcard; /** *

* true or false *

* *

* If set to true, the domain will be the DKIM authority for itself * even if the root domain is registered on the same mailgun account *

* *

* If set to false, the domain will have the same DKIM authority as the root domain * registered on the same mailgun account *

* *

* The default is false. *

*/ @FormProperty("force_dkim_authority") Boolean forceDkimAuthority; /** *

* Set the length of your domain’s generated DKIM key *

* *

* 1024 or 2048 *

* *

* The default is 1024. *

*/ @FormProperty("dkim_key_size") Integer dkimKeySize; /** *

* An optional, comma-separated list of IP addresses to be assigned to this domain. * If not specified, all dedicated IP addresses on the account will be assigned. * If the request cannot be fulfilled (e.g. a requested IP is not assigned to the account, etc), a 400 will be returned. *

*/ List ips; /** *

* The id of the IP Pool that you wish to assign to the domain. * The pool must contain at least 1 IP. *

*

* Note: IP Pools are only available on certain plans; *

* * @see Pricing */ @FormProperty("pool_id") String poolId; /** *

* Set your open, click and unsubscribe URLs to use http or https. *

* {@link WebScheme} */ @FormProperty("web_scheme") String webScheme; public static class DomainRequestBuilder { /** *

* Spam action: disabled, block or tag. *

* {@link SpamAction} * *

* If disabled, no spam filtering will occur for inbound messages. * If block, inbound spam messages will not be delivered. * If tag, inbound messages will be tagged with a spam header. *

* * @param spamAction {@link SpamAction} * @return Returns a reference to this object so that method calls can be chained together. */ public DomainRequest.DomainRequestBuilder spamAction(SpamAction spamAction) { this.spamAction = spamAction.getValue(); return this; } /** *

* Set your open, click and unsubscribe URLs to use http or https. *

* * @param webScheme {@link WebScheme} * @return Returns a reference to this object so that method calls can be chained together. */ public DomainRequest.DomainRequestBuilder webScheme(WebScheme webScheme) { this.webScheme = webScheme.getValue(); return this; } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy