@authhero/drizzle 1.15.0 → 1.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ ALTER TABLE `tenants` ADD `config_sync_hash` text(64);--> statement-breakpoint
2
+ ALTER TABLE `tenants` ADD `config_synced_at` text(35);
@@ -0,0 +1 @@
1
+ ALTER TABLE `tenants` ADD `config_sync` text(16);
@@ -0,0 +1,28 @@
1
+ CREATE TABLE `device_codes` (
2
+ `tenant_id` text NOT NULL,
3
+ `device_code_hash` text NOT NULL,
4
+ `user_code_hash` text NOT NULL,
5
+ `client_id` text NOT NULL,
6
+ `scope` text,
7
+ `audience` text,
8
+ `status` text NOT NULL,
9
+ `login_id` text,
10
+ `expires_at` text NOT NULL,
11
+ `created_at` text NOT NULL,
12
+ `last_polled_at` text,
13
+ `interval` integer NOT NULL,
14
+ `version` integer NOT NULL,
15
+ PRIMARY KEY(`tenant_id`, `device_code_hash`)
16
+ );
17
+ --> statement-breakpoint
18
+ CREATE UNIQUE INDEX `device_codes_user_code_idx` ON `device_codes` (`tenant_id`,`user_code_hash`);--> statement-breakpoint
19
+ CREATE INDEX `device_codes_expiry_idx` ON `device_codes` (`expires_at`);--> statement-breakpoint
20
+ CREATE TABLE `device_flow_limits` (
21
+ `tenant_id` text NOT NULL,
22
+ `key` text NOT NULL,
23
+ `attempts` integer NOT NULL,
24
+ `expires_at` text NOT NULL,
25
+ PRIMARY KEY(`tenant_id`, `key`)
26
+ );
27
+ --> statement-breakpoint
28
+ CREATE INDEX `device_flow_limits_expiry_idx` ON `device_flow_limits` (`expires_at`);
@@ -0,0 +1,18 @@
1
+ CREATE TABLE `tenant_member_requests` (
2
+ `tenant_id` text NOT NULL,
3
+ `id` text NOT NULL,
4
+ `kind` text NOT NULL,
5
+ `status` text NOT NULL,
6
+ `requested_by` text NOT NULL,
7
+ `payload` text NOT NULL,
8
+ `result` text,
9
+ `error` text,
10
+ `notified_at` text,
11
+ `created_at` text NOT NULL,
12
+ `updated_at` text NOT NULL,
13
+ `finished_at` text,
14
+ PRIMARY KEY(`tenant_id`, `id`)
15
+ );
16
+ --> statement-breakpoint
17
+ CREATE INDEX `tenant_member_requests_status_idx` ON `tenant_member_requests` (`tenant_id`,`status`,`created_at`);--> statement-breakpoint
18
+ CREATE INDEX `tenant_member_requests_finished_idx` ON `tenant_member_requests` (`finished_at`);