feat: add iCloud integration

This commit is contained in:
2026-01-18 22:17:13 +07:00
parent c6e4333395
commit a43d38d87f
13 changed files with 746 additions and 5 deletions

View File

@@ -0,0 +1,21 @@
<?php
declare(strict_types=1);
return function (PDO $db): void {
$db->exec("PRAGMA foreign_keys = ON;");
$db->exec("
CREATE TABLE IF NOT EXISTS icloud_accounts (
id INTEGER PRIMARY KEY AUTOINCREMENT,
user_id INTEGER NOT NULL,
remote_name TEXT NOT NULL UNIQUE,
apple_id TEXT NOT NULL,
trust_token TEXT,
cookies TEXT,
status TEXT NOT NULL DEFAULT 'pending',
connected_at INTEGER,
created_at INTEGER NOT NULL,
FOREIGN KEY(user_id) REFERENCES users(id)
);
");
};