CREATE TABLE billing_account_history (
    history_event_id BIGSERIAL 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,

    account_id bigint,
    type_id integer NOT NULL,
    spent bigint DEFAULT 0,
    version bigint DEFAULT 0,
    created_at integer NOT NULL,
    active boolean DEFAULT 'false',
    account_meta text,
    external_id text,
    sprav_id text
);
