# coding: utf-8

"""
    Fingerprint Server API

    Fingerprint Server API allows you to search, update, and delete identification events in a server environment. It can be used for data exports, decision-making, and data analysis scenarios. Server API is intended for server-side usage, it's not intended to be used from the client side, whether it's a browser or a mobile device.   # noqa: E501

    OpenAPI spec version: 3
    Contact: support@fingerprint.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import re  # noqa: F401
from typing import Dict, List, Optional  # noqa: F401
from fingerprint_pro_server_api_sdk.base_model import BaseModel
from datetime import datetime


class ProxyDetails(BaseModel):
    """
    Proxy detection details (present if proxy is detected)

    NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """
    """
    Attributes:
      swagger_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.
    """
    swagger_types = {
        'proxy_type': 'str',
        'last_seen_at': 'datetime'
    }

    nullable_map = {
        'proxy_type': False,
        'last_seen_at': False
    }

    attribute_map = {
        'proxy_type': 'proxyType',
        'last_seen_at': 'lastSeenAt'
    }

    def __init__(self, proxy_type=None, last_seen_at=None):  # noqa: E501
        """ProxyDetails - a model defined in Swagger"""  # noqa: E501
        self._proxy_type = None
        self._last_seen_at = None
        self.discriminator = None
        self.proxy_type = proxy_type
        if last_seen_at is not None:
            self.last_seen_at = last_seen_at

    @property
    def proxy_type(self) -> str:
        """Gets the proxy_type of this ProxyDetails.  # noqa: E501

        Residential proxies use real user IP addresses to appear as legitimate traffic,  while data center proxies are public proxies hosted in data centers   # noqa: E501

        :return: The proxy_type of this ProxyDetails.  # noqa: E501
        """
        return self._proxy_type

    @proxy_type.setter
    def proxy_type(self, proxy_type: str):
        """Sets the proxy_type of this ProxyDetails.

        Residential proxies use real user IP addresses to appear as legitimate traffic,  while data center proxies are public proxies hosted in data centers   # noqa: E501

        :param proxy_type: The proxy_type of this ProxyDetails.  # noqa: E501
        """
        if proxy_type is None:
            raise ValueError("Invalid value for `proxy_type`, must not be `None`")  # noqa: E501
        allowed_values = ["residential", "data_center"]  # noqa: E501
        if (proxy_type not in allowed_values):
            raise ValueError(
                "Invalid value for `proxy_type` ({0}), must be one of {1}"  # noqa: E501
                .format(proxy_type, allowed_values)
            )

        self._proxy_type = proxy_type

    @property
    def last_seen_at(self) -> Optional[datetime]:
        """Gets the last_seen_at of this ProxyDetails.  # noqa: E501

        ISO 8601 formatted timestamp in UTC with hourly resolution of when this IP was last seen as a proxy when available.   # noqa: E501

        :return: The last_seen_at of this ProxyDetails.  # noqa: E501
        """
        return self._last_seen_at

    @last_seen_at.setter
    def last_seen_at(self, last_seen_at: Optional[datetime]):
        """Sets the last_seen_at of this ProxyDetails.

        ISO 8601 formatted timestamp in UTC with hourly resolution of when this IP was last seen as a proxy when available.   # noqa: E501

        :param last_seen_at: The last_seen_at of this ProxyDetails.  # noqa: E501
        """

        self._last_seen_at = last_seen_at

