create table audit_logs
(
    id        VARCHAR(26)  not null
        constraint audit_logs_pkey
            primary key,
    user_id   integer,
    action    varchar(255) not null,
    timestamp timestamptz default current_timestamp,
    details   jsonb
);

create index idx_audit_logs_action on audit_logs (action);
create index idx_audit_logs_user_id on audit_logs (user_id);
create index idx_audit_logs_timestamp on audit_logs (timestamp);