"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import builtins
import collections.abc
import google.protobuf.descriptor
import google.protobuf.internal.containers
import google.protobuf.internal.enum_type_wrapper
import google.protobuf.message
import google.protobuf.timestamp_pb2
import sys
import typing

if sys.version_info >= (3, 10):
    import typing as typing_extensions
else:
    import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class _PostalVerificationStatus:
    ValueType = typing.NewType("ValueType", builtins.int)
    V: typing_extensions.TypeAlias = ValueType

class _PostalVerificationStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_PostalVerificationStatus.ValueType], builtins.type):
    DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
    POSTAL_VERIFICATION_STATUS_UNKNOWN: _PostalVerificationStatus.ValueType  # 0
    POSTAL_VERIFICATION_STATUS_PENDING_ADDRESS_CONFIRMATION: _PostalVerificationStatus.ValueType  # 1
    POSTAL_VERIFICATION_STATUS_IN_PROGRESS: _PostalVerificationStatus.ValueType  # 2
    POSTAL_VERIFICATION_STATUS_AWAITING_VERIFICATION: _PostalVerificationStatus.ValueType  # 3
    POSTAL_VERIFICATION_STATUS_SUCCEEDED: _PostalVerificationStatus.ValueType  # 4
    POSTAL_VERIFICATION_STATUS_FAILED: _PostalVerificationStatus.ValueType  # 5
    POSTAL_VERIFICATION_STATUS_CANCELLED: _PostalVerificationStatus.ValueType  # 6

class PostalVerificationStatus(_PostalVerificationStatus, metaclass=_PostalVerificationStatusEnumTypeWrapper): ...

POSTAL_VERIFICATION_STATUS_UNKNOWN: PostalVerificationStatus.ValueType  # 0
POSTAL_VERIFICATION_STATUS_PENDING_ADDRESS_CONFIRMATION: PostalVerificationStatus.ValueType  # 1
POSTAL_VERIFICATION_STATUS_IN_PROGRESS: PostalVerificationStatus.ValueType  # 2
POSTAL_VERIFICATION_STATUS_AWAITING_VERIFICATION: PostalVerificationStatus.ValueType  # 3
POSTAL_VERIFICATION_STATUS_SUCCEEDED: PostalVerificationStatus.ValueType  # 4
POSTAL_VERIFICATION_STATUS_FAILED: PostalVerificationStatus.ValueType  # 5
POSTAL_VERIFICATION_STATUS_CANCELLED: PostalVerificationStatus.ValueType  # 6
Global___PostalVerificationStatus: typing_extensions.TypeAlias = PostalVerificationStatus

@typing.final
class PostalAddress(google.protobuf.message.Message):
    """Postal address for international mail delivery.
    Required fields: address_line_1, city, country
    Optional fields: address_line_2, state, postal_code (varies by country)
    """

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    ADDRESS_LINE_1_FIELD_NUMBER: builtins.int
    ADDRESS_LINE_2_FIELD_NUMBER: builtins.int
    CITY_FIELD_NUMBER: builtins.int
    STATE_FIELD_NUMBER: builtins.int
    POSTAL_CODE_FIELD_NUMBER: builtins.int
    COUNTRY_FIELD_NUMBER: builtins.int
    address_line_1: builtins.str
    """Required: street address, house number, building name, etc."""
    address_line_2: builtins.str
    """Optional: apartment, suite, unit, floor, etc. Empty string if not provided."""
    city: builtins.str
    """Required: city, town, or locality name"""
    state: builtins.str
    """Optional: state, province, region, prefecture, etc. Empty string if not applicable."""
    postal_code: builtins.str
    """Optional: postal/ZIP code. Empty string if country doesn't use postal codes."""
    country: builtins.str
    """Required: ISO 3166-1 alpha-2 country code (e.g., "US", "DE", "JP")"""
    def __init__(
        self,
        *,
        address_line_1: builtins.str | None = ...,
        address_line_2: builtins.str | None = ...,
        city: builtins.str | None = ...,
        state: builtins.str | None = ...,
        postal_code: builtins.str | None = ...,
        country: builtins.str | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["address_line_1", b"address_line_1", "address_line_2", b"address_line_2", "city", b"city", "country", b"country", "postal_code", b"postal_code", "state", b"state"]) -> None: ...

Global___PostalAddress: typing_extensions.TypeAlias = PostalAddress

@typing.final
class InitiatePostalVerificationReq(google.protobuf.message.Message):
    """Step 1: Submit address for validation"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    ADDRESS_FIELD_NUMBER: builtins.int
    @property
    def address(self) -> Global___PostalAddress: ...
    def __init__(
        self,
        *,
        address: Global___PostalAddress | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["address", b"address"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["address", b"address"]) -> None: ...

Global___InitiatePostalVerificationReq: typing_extensions.TypeAlias = InitiatePostalVerificationReq

@typing.final
class InitiatePostalVerificationRes(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    CORRECTED_ADDRESS_FIELD_NUMBER: builtins.int
    ADDRESS_WAS_CORRECTED_FIELD_NUMBER: builtins.int
    postal_verification_attempt_id: builtins.int
    """The ID of the created postal verification attempt"""
    address_was_corrected: builtins.bool
    """Whether the address needed correction"""
    @property
    def corrected_address(self) -> Global___PostalAddress:
        """The validated/corrected address"""

    def __init__(
        self,
        *,
        postal_verification_attempt_id: builtins.int | None = ...,
        corrected_address: Global___PostalAddress | None = ...,
        address_was_corrected: builtins.bool | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["corrected_address", b"corrected_address"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["address_was_corrected", b"address_was_corrected", "corrected_address", b"corrected_address", "postal_verification_attempt_id", b"postal_verification_attempt_id"]) -> None: ...

Global___InitiatePostalVerificationRes: typing_extensions.TypeAlias = InitiatePostalVerificationRes

@typing.final
class ConfirmPostalAddressReq(google.protobuf.message.Message):
    """Step 2: Confirm the (possibly corrected) address and send postcard"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    postal_verification_attempt_id: builtins.int
    def __init__(
        self,
        *,
        postal_verification_attempt_id: builtins.int | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["postal_verification_attempt_id", b"postal_verification_attempt_id"]) -> None: ...

Global___ConfirmPostalAddressReq: typing_extensions.TypeAlias = ConfirmPostalAddressReq

@typing.final
class ConfirmPostalAddressRes(google.protobuf.message.Message):
    """Empty on success, postcard will be sent"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(
        self,
    ) -> None: ...

Global___ConfirmPostalAddressRes: typing_extensions.TypeAlias = ConfirmPostalAddressRes

@typing.final
class GetPostalVerificationStatusReq(google.protobuf.message.Message):
    """Get current postal verification status"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    postal_verification_attempt_id: builtins.int
    """Optional: if 0 or not provided, returns latest attempt"""
    def __init__(
        self,
        *,
        postal_verification_attempt_id: builtins.int | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["postal_verification_attempt_id", b"postal_verification_attempt_id"]) -> None: ...

Global___GetPostalVerificationStatusReq: typing_extensions.TypeAlias = GetPostalVerificationStatusReq

@typing.final
class GetPostalVerificationStatusRes(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    HAS_POSTAL_VERIFICATION_FIELD_NUMBER: builtins.int
    HAS_ACTIVE_ATTEMPT_FIELD_NUMBER: builtins.int
    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    STATUS_FIELD_NUMBER: builtins.int
    ADDRESS_FIELD_NUMBER: builtins.int
    CREATED_FIELD_NUMBER: builtins.int
    POSTCARD_SENT_AT_FIELD_NUMBER: builtins.int
    CAN_INITIATE_NEW_ATTEMPT_FIELD_NUMBER: builtins.int
    NEXT_ATTEMPT_ALLOWED_AT_FIELD_NUMBER: builtins.int
    has_postal_verification: builtins.bool
    """Whether user has any successful postal verification"""
    has_active_attempt: builtins.bool
    """Current/latest attempt details (if any)"""
    postal_verification_attempt_id: builtins.int
    status: Global___PostalVerificationStatus.ValueType
    can_initiate_new_attempt: builtins.bool
    """Rate limit info"""
    @property
    def address(self) -> Global___PostalAddress: ...
    @property
    def created(self) -> google.protobuf.timestamp_pb2.Timestamp: ...
    @property
    def postcard_sent_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
        """Set when postcard was sent. Zero value if not yet sent."""

    @property
    def next_attempt_allowed_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
        """If rate limited, when user can try again. Zero value if not rate limited."""

    def __init__(
        self,
        *,
        has_postal_verification: builtins.bool | None = ...,
        has_active_attempt: builtins.bool | None = ...,
        postal_verification_attempt_id: builtins.int | None = ...,
        status: Global___PostalVerificationStatus.ValueType | None = ...,
        address: Global___PostalAddress | None = ...,
        created: google.protobuf.timestamp_pb2.Timestamp | None = ...,
        postcard_sent_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
        can_initiate_new_attempt: builtins.bool | None = ...,
        next_attempt_allowed_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["address", b"address", "created", b"created", "next_attempt_allowed_at", b"next_attempt_allowed_at", "postcard_sent_at", b"postcard_sent_at"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["address", b"address", "can_initiate_new_attempt", b"can_initiate_new_attempt", "created", b"created", "has_active_attempt", b"has_active_attempt", "has_postal_verification", b"has_postal_verification", "next_attempt_allowed_at", b"next_attempt_allowed_at", "postal_verification_attempt_id", b"postal_verification_attempt_id", "postcard_sent_at", b"postcard_sent_at", "status", b"status"]) -> None: ...

Global___GetPostalVerificationStatusRes: typing_extensions.TypeAlias = GetPostalVerificationStatusRes

@typing.final
class VerifyPostalCodeReq(google.protobuf.message.Message):
    """Submit verification code (from postcard or QR code)"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    CODE_FIELD_NUMBER: builtins.int
    code: builtins.str
    """6-character alphanumeric code from the postcard.
    The attempt is looked up from the user's active attempt.
    """
    def __init__(
        self,
        *,
        code: builtins.str | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["code", b"code"]) -> None: ...

Global___VerifyPostalCodeReq: typing_extensions.TypeAlias = VerifyPostalCodeReq

@typing.final
class VerifyPostalCodeRes(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    SUCCESS_FIELD_NUMBER: builtins.int
    REMAINING_ATTEMPTS_FIELD_NUMBER: builtins.int
    success: builtins.bool
    remaining_attempts: builtins.int
    """If failed, how many attempts remaining before lockout"""
    def __init__(
        self,
        *,
        success: builtins.bool | None = ...,
        remaining_attempts: builtins.int | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["remaining_attempts", b"remaining_attempts", "success", b"success"]) -> None: ...

Global___VerifyPostalCodeRes: typing_extensions.TypeAlias = VerifyPostalCodeRes

@typing.final
class CancelPostalVerificationReq(google.protobuf.message.Message):
    """Cancel an in-progress attempt"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    postal_verification_attempt_id: builtins.int
    def __init__(
        self,
        *,
        postal_verification_attempt_id: builtins.int | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["postal_verification_attempt_id", b"postal_verification_attempt_id"]) -> None: ...

Global___CancelPostalVerificationReq: typing_extensions.TypeAlias = CancelPostalVerificationReq

@typing.final
class ListPostalVerificationAttemptsReq(google.protobuf.message.Message):
    """List all postal verification attempts (history)
    No pagination needed for now - users won't have many attempts
    """

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(
        self,
    ) -> None: ...

Global___ListPostalVerificationAttemptsReq: typing_extensions.TypeAlias = ListPostalVerificationAttemptsReq

@typing.final
class ListPostalVerificationAttemptsRes(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    ATTEMPTS_FIELD_NUMBER: builtins.int
    @property
    def attempts(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[Global___PostalVerificationAttemptSummary]: ...
    def __init__(
        self,
        *,
        attempts: collections.abc.Iterable[Global___PostalVerificationAttemptSummary] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["attempts", b"attempts"]) -> None: ...

Global___ListPostalVerificationAttemptsRes: typing_extensions.TypeAlias = ListPostalVerificationAttemptsRes

@typing.final
class PostalVerificationAttemptSummary(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    POSTAL_VERIFICATION_ATTEMPT_ID_FIELD_NUMBER: builtins.int
    STATUS_FIELD_NUMBER: builtins.int
    ADDRESS_FIELD_NUMBER: builtins.int
    CREATED_FIELD_NUMBER: builtins.int
    VERIFIED_AT_FIELD_NUMBER: builtins.int
    postal_verification_attempt_id: builtins.int
    status: Global___PostalVerificationStatus.ValueType
    @property
    def address(self) -> Global___PostalAddress: ...
    @property
    def created(self) -> google.protobuf.timestamp_pb2.Timestamp: ...
    @property
    def verified_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
        """Set when verification succeeded. Zero value if not verified."""

    def __init__(
        self,
        *,
        postal_verification_attempt_id: builtins.int | None = ...,
        status: Global___PostalVerificationStatus.ValueType | None = ...,
        address: Global___PostalAddress | None = ...,
        created: google.protobuf.timestamp_pb2.Timestamp | None = ...,
        verified_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["address", b"address", "created", b"created", "verified_at", b"verified_at"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["address", b"address", "created", b"created", "postal_verification_attempt_id", b"postal_verification_attempt_id", "status", b"status", "verified_at", b"verified_at"]) -> None: ...

Global___PostalVerificationAttemptSummary: typing_extensions.TypeAlias = PostalVerificationAttemptSummary
