from typing import Union
from datetime import datetime


def timestamp(date: Union[datetime, int, float]) -> int:
    """Adjust any datetime value to POSIX timestamp

    Arguments:
        date {Union[datetime, int, float]} -- datetime instance or timestamp

    Returns:
        int -- integer POSIX timestamp
    """
    if isinstance(date, (float, int)):
        return int(date)
    return int(date.timestamp())