from typing import List
from datetime import datetime


def get_closest_timestamp(timestamps: List[datetime], ref_timestamp: datetime) -> datetime:
    """ Get the timestamo closest to the reference timestamp """
    closest_idx = 0
    for i, ts in enumerate(timestamps):
        if abs((ts - ref_timestamp).days) < abs((timestamps[closest_idx] - ref_timestamp).days):
            closest_idx = i
    return timestamps[closest_idx]