CREATE TABLE IF NOT EXISTS telemetry_events (
    id_event BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
    event VARCHAR(120) NOT NULL,
    props MEDIUMTEXT NULL,
    ip VARCHAR(45) NULL,
    created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
    PRIMARY KEY (id_event),
    KEY idx_event_date (event, created_at)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
