CREATE TABLE head_app_sessions_history (
    history_event_id SERIAL PRIMARY KEY,
    history_user_id text NOT NULL,
    history_originator_id text,
    history_action text NOT NULL,
    history_timestamp integer NOT NULL,
    history_comment text,

    user_id uuid,
    car_id uuid,
    head_id text NOT NULL,
    head_device_id varchar(32),
    dummy_id text NOT NULL,
    passport_key text,
    passport_key_status text,
    launch_app boolean DEFAULT false,

    FOREIGN KEY(car_id) REFERENCES "car"(id)
);
