CREATE TABLE IF NOT EXISTS `mod_contabomanager_settings` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `client_id` varchar(255) DEFAULT NULL,
    `client_secret` varchar(255) DEFAULT NULL,
    `api_username` varchar(255) DEFAULT NULL,
    `api_password` varchar(255) DEFAULT NULL,
    `updated_at` datetime DEFAULT NULL,
    PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

CREATE TABLE IF NOT EXISTS `mod_contabomanager_instances` (
    `instance_id` varchar(100) NOT NULL,
    `client_id` int(11) NOT NULL,
    `display_name` varchar(255) DEFAULT NULL,
    PRIMARY KEY (`instance_id`),
    KEY `client_id_idx` (`client_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
