Module mailslurp_client.models.generate_spf_record_options
MailSlurp API
MailSlurp is an API for sending and receiving emails and SMS from dynamically allocated email addresses and phone numbers. It's designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more. ## Resources - Homepage - Get an API KEY - Generated SDK Clients - Examples repository # noqa: E501
The version of the OpenAPI document: 6.5.2 Contact: contact@mailslurp.dev Generated by: https://openapi-generator.tech
Classes
class GenerateSpfRecordOptions (domain=None, include_domains=None, ip4=None, ip6=None, mx=None, a=None, all_policy=None, local_vars_configuration=None)-
NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech
Do not edit the class manually.
GenerateSpfRecordOptions - a model defined in OpenAPI
Expand source code
class GenerateSpfRecordOptions(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech Do not edit the class manually. """ """ Attributes: openapi_types (dict): The key is attribute name and the value is attribute type. attribute_map (dict): The key is attribute name and the value is json key in definition. """ openapi_types = { 'domain': 'str', 'include_domains': 'list[str]', 'ip4': 'list[str]', 'ip6': 'list[str]', 'mx': 'bool', 'a': 'bool', 'all_policy': 'str' } attribute_map = { 'domain': 'domain', 'include_domains': 'includeDomains', 'ip4': 'ip4', 'ip6': 'ip6', 'mx': 'mx', 'a': 'a', 'all_policy': 'allPolicy' } def __init__(self, domain=None, include_domains=None, ip4=None, ip6=None, mx=None, a=None, all_policy=None, local_vars_configuration=None): # noqa: E501 """GenerateSpfRecordOptions - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration self._domain = None self._include_domains = None self._ip4 = None self._ip6 = None self._mx = None self._a = None self._all_policy = None self.discriminator = None self.domain = domain self.include_domains = include_domains self.ip4 = ip4 self.ip6 = ip6 self.mx = mx self.a = a self.all_policy = all_policy @property def domain(self): """Gets the domain of this GenerateSpfRecordOptions. # noqa: E501 Domain the SPF record applies to # noqa: E501 :return: The domain of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str """ return self._domain @domain.setter def domain(self, domain): """Sets the domain of this GenerateSpfRecordOptions. Domain the SPF record applies to # noqa: E501 :param domain: The domain of this GenerateSpfRecordOptions. # noqa: E501 :type: str """ if self.local_vars_configuration.client_side_validation and domain is None: # noqa: E501 raise ValueError("Invalid value for `domain`, must not be `None`") # noqa: E501 if (self.local_vars_configuration.client_side_validation and domain is not None and len(domain) > 253): raise ValueError("Invalid value for `domain`, length must be less than or equal to `253`") # noqa: E501 if (self.local_vars_configuration.client_side_validation and domain is not None and len(domain) < 0): raise ValueError("Invalid value for `domain`, length must be greater than or equal to `0`") # noqa: E501 self._domain = domain @property def include_domains(self): """Gets the include_domains of this GenerateSpfRecordOptions. # noqa: E501 Optional include domains # noqa: E501 :return: The include_domains of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._include_domains @include_domains.setter def include_domains(self, include_domains): """Sets the include_domains of this GenerateSpfRecordOptions. Optional include domains # noqa: E501 :param include_domains: The include_domains of this GenerateSpfRecordOptions. # noqa: E501 :type: list[str] """ self._include_domains = include_domains @property def ip4(self): """Gets the ip4 of this GenerateSpfRecordOptions. # noqa: E501 Optional IPv4 CIDRs or hosts # noqa: E501 :return: The ip4 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._ip4 @ip4.setter def ip4(self, ip4): """Sets the ip4 of this GenerateSpfRecordOptions. Optional IPv4 CIDRs or hosts # noqa: E501 :param ip4: The ip4 of this GenerateSpfRecordOptions. # noqa: E501 :type: list[str] """ self._ip4 = ip4 @property def ip6(self): """Gets the ip6 of this GenerateSpfRecordOptions. # noqa: E501 Optional IPv6 CIDRs or hosts # noqa: E501 :return: The ip6 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._ip6 @ip6.setter def ip6(self, ip6): """Sets the ip6 of this GenerateSpfRecordOptions. Optional IPv6 CIDRs or hosts # noqa: E501 :param ip6: The ip6 of this GenerateSpfRecordOptions. # noqa: E501 :type: list[str] """ self._ip6 = ip6 @property def mx(self): """Gets the mx of this GenerateSpfRecordOptions. # noqa: E501 Whether to include the MX mechanism # noqa: E501 :return: The mx of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool """ return self._mx @mx.setter def mx(self, mx): """Sets the mx of this GenerateSpfRecordOptions. Whether to include the MX mechanism # noqa: E501 :param mx: The mx of this GenerateSpfRecordOptions. # noqa: E501 :type: bool """ if self.local_vars_configuration.client_side_validation and mx is None: # noqa: E501 raise ValueError("Invalid value for `mx`, must not be `None`") # noqa: E501 self._mx = mx @property def a(self): """Gets the a of this GenerateSpfRecordOptions. # noqa: E501 Whether to include the A mechanism # noqa: E501 :return: The a of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool """ return self._a @a.setter def a(self, a): """Sets the a of this GenerateSpfRecordOptions. Whether to include the A mechanism # noqa: E501 :param a: The a of this GenerateSpfRecordOptions. # noqa: E501 :type: bool """ if self.local_vars_configuration.client_side_validation and a is None: # noqa: E501 raise ValueError("Invalid value for `a`, must not be `None`") # noqa: E501 self._a = a @property def all_policy(self): """Gets the all_policy of this GenerateSpfRecordOptions. # noqa: E501 :return: The all_policy of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str """ return self._all_policy @all_policy.setter def all_policy(self, all_policy): """Sets the all_policy of this GenerateSpfRecordOptions. :param all_policy: The all_policy of this GenerateSpfRecordOptions. # noqa: E501 :type: str """ if self.local_vars_configuration.client_side_validation and all_policy is None: # noqa: E501 raise ValueError("Invalid value for `all_policy`, must not be `None`") # noqa: E501 allowed_values = ["FAIL", "SOFTFAIL", "NEUTRAL"] # noqa: E501 if self.local_vars_configuration.client_side_validation and all_policy not in allowed_values: # noqa: E501 raise ValueError( "Invalid value for `all_policy` ({0}), must be one of {1}" # noqa: E501 .format(all_policy, allowed_values) ) self._all_policy = all_policy def to_dict(self): """Returns the model properties as a dict""" result = {} for attr, _ in six.iteritems(self.openapi_types): value = getattr(self, attr) if isinstance(value, list): result[attr] = list(map( lambda x: x.to_dict() if hasattr(x, "to_dict") else x, value )) elif hasattr(value, "to_dict"): result[attr] = value.to_dict() elif isinstance(value, dict): result[attr] = dict(map( lambda item: (item[0], item[1].to_dict()) if hasattr(item[1], "to_dict") else item, value.items() )) else: result[attr] = value return result def to_str(self): """Returns the string representation of the model""" return pprint.pformat(self.to_dict()) def __repr__(self): """For `print` and `pprint`""" return self.to_str() def __eq__(self, other): """Returns true if both objects are equal""" if not isinstance(other, GenerateSpfRecordOptions): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" if not isinstance(other, GenerateSpfRecordOptions): return True return self.to_dict() != other.to_dict()Class variables
var attribute_mapvar openapi_types
Instance variables
prop a-
Gets the a of this GenerateSpfRecordOptions. # noqa: E501
Whether to include the A mechanism # noqa: E501
:return: The a of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool
Expand source code
@property def a(self): """Gets the a of this GenerateSpfRecordOptions. # noqa: E501 Whether to include the A mechanism # noqa: E501 :return: The a of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool """ return self._a prop all_policy-
Gets the all_policy of this GenerateSpfRecordOptions. # noqa: E501
:return: The all_policy of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str
Expand source code
@property def all_policy(self): """Gets the all_policy of this GenerateSpfRecordOptions. # noqa: E501 :return: The all_policy of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str """ return self._all_policy prop domain-
Gets the domain of this GenerateSpfRecordOptions. # noqa: E501
Domain the SPF record applies to # noqa: E501
:return: The domain of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str
Expand source code
@property def domain(self): """Gets the domain of this GenerateSpfRecordOptions. # noqa: E501 Domain the SPF record applies to # noqa: E501 :return: The domain of this GenerateSpfRecordOptions. # noqa: E501 :rtype: str """ return self._domain prop include_domains-
Gets the include_domains of this GenerateSpfRecordOptions. # noqa: E501
Optional include domains # noqa: E501
:return: The include_domains of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str]
Expand source code
@property def include_domains(self): """Gets the include_domains of this GenerateSpfRecordOptions. # noqa: E501 Optional include domains # noqa: E501 :return: The include_domains of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._include_domains prop ip4-
Gets the ip4 of this GenerateSpfRecordOptions. # noqa: E501
Optional IPv4 CIDRs or hosts # noqa: E501
:return: The ip4 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str]
Expand source code
@property def ip4(self): """Gets the ip4 of this GenerateSpfRecordOptions. # noqa: E501 Optional IPv4 CIDRs or hosts # noqa: E501 :return: The ip4 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._ip4 prop ip6-
Gets the ip6 of this GenerateSpfRecordOptions. # noqa: E501
Optional IPv6 CIDRs or hosts # noqa: E501
:return: The ip6 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str]
Expand source code
@property def ip6(self): """Gets the ip6 of this GenerateSpfRecordOptions. # noqa: E501 Optional IPv6 CIDRs or hosts # noqa: E501 :return: The ip6 of this GenerateSpfRecordOptions. # noqa: E501 :rtype: list[str] """ return self._ip6 prop mx-
Gets the mx of this GenerateSpfRecordOptions. # noqa: E501
Whether to include the MX mechanism # noqa: E501
:return: The mx of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool
Expand source code
@property def mx(self): """Gets the mx of this GenerateSpfRecordOptions. # noqa: E501 Whether to include the MX mechanism # noqa: E501 :return: The mx of this GenerateSpfRecordOptions. # noqa: E501 :rtype: bool """ return self._mx
Methods
def to_dict(self)-
Returns the model properties as a dict
def to_str(self)-
Returns the string representation of the model