Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.
Rust acpagent-client-protocolai-agentsai-assistantclaudeclaude-codecodexcoding-agentscursorgeminigemini-cligrok-bot-alternativeiosiphonelinuxmacosmcpopen-sourcerustself-hosted
merge: bring required sign-in into same-account pairing, 2.36.0
leepokaif2a77e39706f
diff --cc apps/Codync.xcodeproj/project.pbxprojindex dc9ad2bc,86e4b6eb..2ec60874--- a/apps/Codync.xcodeproj/project.pbxproj+++ b/apps/Codync.xcodeproj/project.pbxproj@@@ -846,7 -850,7 +850,7 @@@GCC_WARN_UNUSED_VARIABLE = YES;IPHONEOS_DEPLOYMENT_TARGET = 26.0;MACOSX_DEPLOYMENT_TARGET = 14.0;- MARKETING_VERSION = 2.34.2;- MARKETING_VERSION = 2.35.0;++ MARKETING_VERSION = 2.36.0;MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;MTL_FAST_MATH = YES;ONLY_ACTIVE_ARCH = YES;@@@ -944,7 -948,7 +948,7 @@@GCC_WARN_UNUSED_VARIABLE = YES;IPHONEOS_DEPLOYMENT_TARGET = 26.0;MACOSX_DEPLOYMENT_TARGET = 14.0;- MARKETING_VERSION = 2.34.2;- MARKETING_VERSION = 2.35.0;++ MARKETING_VERSION = 2.36.0;MTL_ENABLE_DEBUG_INFO = NO;MTL_FAST_MATH = YES;PRODUCT_NAME = "$(TARGET_NAME)";@@@ -1203,7 -1207,7 +1207,7 @@@GCC_WARN_UNUSED_VARIABLE = YES;IPHONEOS_DEPLOYMENT_TARGET = 26.0;MACOSX_DEPLOYMENT_TARGET = 14.0;- MARKETING_VERSION = 2.34.2;- MARKETING_VERSION = 2.35.0;++ MARKETING_VERSION = 2.36.0;MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;MTL_FAST_MATH = YES;ONLY_ACTIVE_ARCH = YES;@@@ -1353,7 -1357,7 +1357,7 @@@GCC_WARN_UNUSED_VARIABLE = YES;IPHONEOS_DEPLOYMENT_TARGET = 26.0;MACOSX_DEPLOYMENT_TARGET = 14.0;- MARKETING_VERSION = 2.34.2;- MARKETING_VERSION = 2.35.0;++ MARKETING_VERSION = 2.36.0;MTL_ENABLE_DEBUG_INFO = NO;MTL_FAST_MATH = YES;PRODUCT_NAME = "$(TARGET_NAME)";diff --cc apps/android/WhatsNew.mdindex b6af3444,2613a2e0..74c58047--- a/apps/android/WhatsNew.md+++ b/apps/android/WhatsNew.md@@@ -7,9 -7,13 +7,17 @@@ released version's section; a version welse a generic "Bug fixes and improvements" line. Delete old sections.-->- ## 2.34.2-## 2.35.0++## 2.36.0### zh-Hant- - 有很多 Docker 或虛擬機網路的電腦,現在也能配對與連線,不會再顯示配對碼已損毀。+ - Codync 現在需要用 Apple 或 Google 登入。以前沒登入就配對的電腦,第一次登入時會一起移進你的賬戶,不用再掃一次。+ - 登出時,這支手機會從它連得到的電腦和你的賬戶中移除。+ - 可以在 App 裡刪除賬戶:點 Bots 分頁左上角的賬戶按鈕,再點「刪除賬戶」。++- 配對會確認賬戶:在別人賬戶裡的電腦會告訴你它在誰的賬戶;還不在任何賬戶的電腦,會先在電腦上問一聲,再加入你的賬戶。++- 也可以輸入 `codync-host pair` 印出的短代碼來配對,不用掃 QR code。### en-US- - Computers with many Docker or virtual machine networks now pair and connect, instead of reporting a damaged pairing code.-- Codync now asks you to sign in with Apple or Google. Computers you paired without signing in move into your account the first time you sign in, with no new scan.-- Signing out now also removes this phone from the computers it can reach and from your account.-- You can delete your account in the app: tap the account button at the top left of the Bots tab, then Delete account.++- Codync now asks you to sign in with Apple or Google. Computers you paired before come along, no new scan.++- Signing out removes this phone from its computers and your account.++- Delete your account in the app: account button (top left of Bots), then Delete account.++- Pairing checks your account: a computer in another account says whose; one in no account asks first, then joins yours.++- Or type the short code `codync-host pair` prints instead of scanning.diff --cc apps/android/app/src/main/kotlin/com/codync/android/AccountStoreLinks.ktindex 09c5264c,34922b81..deac092b--- a/apps/android/app/src/main/kotlin/com/codync/android/AccountStoreLinks.kt+++ b/apps/android/app/src/main/kotlin/com/codync/android/AccountStoreLinks.kt@@@ -39,21 -28,12 +39,23 @@@ internal fun AccountStore.pair(text: StmutableState.update { it.copy(setupComplete = true) }Analytics.capture(AnalyticsEvent.ComputerPaired(via, computer.id))Analytics.completeOnboarding(OnboardingVia.Paired)+ // The computer joined this account: the account takes it in (or it stays paired, outside the account).+ val signed = paired.claim+ // In the background, as on iOS: the computer is already paired.+ if (client != null && claim != null && signed != null) {+ contextScope.launch {+ bestEffort("complete the claim") { client.completeClaim(claim.claimId, signed) }+ refreshCloud()+ }+ }} catch (error: CancellationException) { throw error }catch (error: Exception) {-- Analytics.capture(AnalyticsEvent.PairingFailed(PairingFailure.of(error)))++ val reason = PairingFailure.of(error)++ Analytics.capture(AnalyticsEvent.PairingFailed(reason))++ mutableState.update { it.copy(pairingUnreachable = reason == PairingFailure.Unreachable || reason == PairingFailure.Timeout) }showError(error)}- finally { mutableState.update { it.copy(pairing = false) } }+ finally { mutableState.update { it.copy(pairing = false, pairingCheck = null) } }}}diff --cc apps/android/app/src/main/kotlin/com/codync/android/AnalyticsEvent.ktindex e1974f05,6cd4d600..fb7f4d55--- a/apps/android/app/src/main/kotlin/com/codync/android/AnalyticsEvent.kt+++ b/apps/android/app/src/main/kotlin/com/codync/android/AnalyticsEvent.kt@@@ -2,6 -2,6 +2,7 @@@ package com.codync.androiimport android.content.Contextimport android.os.Build++import com.codync.android.core.CloudErrorimport com.codync.android.core.HostErrorimport com.codync.android.core.PairingProblemimport java.io.IOException@@@ -122,14 -129,8 +130,16 @@@ internal enum class PairingFailure(overPairingProblem.Kind.OutdatedHost -> OutdatedHostPairingProblem.Kind.Invalid -> Invalid}- // 400: a host from before Android phones turns the platform down; 403: the code expired or was used.- error is HostError -> when (error.status) { 400 -> OutdatedHost; 403 -> Expired; 426 -> UpgradeRequired; else -> Other }+ // 400: a host from before Android phones turns the platform down. 403: the code expired or was used, or the+ // computer turned this phone away (another account, declined, an account it couldn't confirm), as on iOS.+ error is HostError -> when (error.status) {+ 400 -> OutdatedHost+ 403 -> if (error.message.startsWith("This pairing code expired")) Expired else Unauthorized+ 426 -> UpgradeRequired+ else -> Other+ }++ // The cloud answered (a short code that's spent, an account it couldn't confirm): as on iOS.++ error is CloudError -> Other// The computer's keys don't match the code's.error is SecurityException -> Unauthorizederror.isTimeout -> Timeoutdiff --cc apps/android/app/src/main/kotlin/com/codync/android/AppState.ktindex f69c11fe,a8ee5871..d94e8226--- a/apps/android/app/src/main/kotlin/com/codync/android/AppState.kt+++ b/apps/android/app/src/main/kotlin/com/codync/android/AppState.kt@@@ -27,8 -27,6 +27,10 @@@ data class AccountContextval setupComplete: Boolean = false,val loading: Boolean = true,val pairing: Boolean = false,+ /** While pairing, the code the computer shows if it asks whether to let this phone in. */+ val pairingCheck: String? = null,++ /** The last pairing failed because the phone couldn't reach the computer (not a refusal): the network hint helps. */++ val pairingUnreachable: Boolean = false,/** This phone's computers, in the order it shows them. */val computers: List<Computer> = emptyList(),/** The computer whose lead "Talk to Codync" calls; null is Automatic (iOS `shortcutLeadComputer`). */diff --cc apps/android/app/src/main/kotlin/com/codync/android/PairingView.ktindex 6125b914,2e3bb316..e3b48acb--- a/apps/android/app/src/main/kotlin/com/codync/android/PairingView.kt+++ b/apps/android/app/src/main/kotlin/com/codync/android/PairingView.kt@@@ -245,7 -239,7 +245,7 @@@ private enum class ComputerOS { Mac, LiColumn(verticalArrangement = Arrangement.spacedBy(6.dp)) {Text(tr(error.orEmpty()), style = Type.footnote, color = Palette.danger)// The usual cause: the phone has no road to the computer yet.-- IconLabel("Check that this phone and the computer are on the same Wi-Fi or both on Tailscale, or that “Reach from anywhere” is on in Codync on the computer.",++ if (state.pairingUnreachable) IconLabel("Check that this phone and the computer are on the same Wi-Fi or both on Tailscale, or that “Reach from anywhere” is on in Codync on the computer.","wifi.exclamationmark", Palette.secondary)}}diff --cc apps/android/core/src/test/kotlin/com/codync/android/core/CloudClientTest.ktindex bdeed310,918c8d65..08a7ea76--- a/apps/android/core/src/test/kotlin/com/codync/android/core/CloudClientTest.kt+++ b/apps/android/core/src/test/kotlin/com/codync/android/core/CloudClientTest.kt@@@ -153,51 -133,22 +153,70 @@@ class CloudClientTest} finally { server.shutdown() }}+ private fun certificateBody(exp: Long) =+ """{"certificate":{"payload":${JsonPrimitive("""{"v":1,"deviceKey":"${identity.publicKey}","userId":"u","exp":$exp}""")},"sig":"s"}}"""++ @Test fun `a certificate is reused while more than a day is left and a new key is registered first`() = runBlocking {+ val server = MockWebServer()+ server.start()+ try {+ val client = CloudClient(server.url("/").toString(), identity, { "session" }, OkHttpClient(), 1, Unit)+ val day = 24L * 60 * 60 * 1000+ val lasting = DeviceCertificate("""{"exp":${System.currentTimeMillis() + 2 * day}}""", "s")+ assertSame(lasting, client.certificate(lasting, "Pixel"))+ assertEquals(0, server.requestCount)++ val exp = System.currentTimeMillis() + 7 * day+ server.enqueue(MockResponse().setResponseCode(403).setBody("""{"error":{"code":"forbidden"}}"""))+ server.enqueue(MockResponse().setBody("{}"))+ server.enqueue(MockResponse().setBody(certificateBody(exp)))+ val ending = DeviceCertificate("""{"exp":${System.currentTimeMillis() + day / 2}}""", "s")+ val fresh = client.certificate(ending, "Pixel")+ assertEquals(exp, fresh.expiresAt)+ assertEquals("s", fresh.sig)+ val asked = server.takeRequest()+ assertEquals("POST", asked.method)+ assertEquals("/v1/devices/certificate", asked.path)+ assertEquals("Bearer session", asked.getHeader("Authorization"))+ assertTrue(requireNotNull(asked.getHeader("Codync-Sig")).contains("kid=${identity.publicKey}"))+ assertEquals("/v1/devices", server.takeRequest().path)+ assertEquals("/v1/devices/certificate", server.takeRequest().path)+ } finally { server.shutdown() }+ }++ @Test fun `a claim is made then completed with the computer's signed object as is`() = runBlocking {+ val server = MockWebServer()+ server.start()+ try {+ server.enqueue(MockResponse().setBody("""{"claimId":"clm_1","nonce":"n","expiresAt":1}"""))+ server.enqueue(MockResponse().setBody("""{"computer":{}}"""))+ val client = CloudClient(server.url("/").toString(), identity, { "session" }, OkHttpClient(), 1, Unit)+ assertEquals(PairingClaim("clm_1", "n"), client.createClaim())+ val signed = buildJsonObject { put("computerId", id); put("signKey", hostKey.base64Url()); put("sig", "x"); put("device", JsonNull) }+ client.completeClaim("clm_1", signed)+ assertEquals("/v1/claims", server.takeRequest().path)+ val complete = server.takeRequest()+ assertEquals("/v1/claims/clm_1/complete", complete.path)+ assertEquals(signed, Json.parseToJsonElement(complete.body.readUtf8()))+ } finally { server.shutdown() }+ }+++ @Test fun `signing out deletes only this device from the account, on the token taken before`() = runBlocking {+ val server = MockWebServer()+ server.start()+ try {+ server.enqueue(MockResponse().setBody("""{"devices":[{"deviceId":"other","deviceKey":"elsewhere"},{"deviceId":"mine","deviceKey":"${identity.publicKey}"}]}"""))+ server.enqueue(MockResponse().setBody("{}"))+ var signedIn = true+ val client = CloudClient(server.url("/").toString(), identity, { check(signedIn); "session" }, OkHttpClient(), 1, Unit)+ val pinned = requireNotNull(client.pinningToken())+ signedIn = false+ pinned.revokeThisDevice()+ val list = server.takeRequest()+ assertEquals("/v1/devices" to "Bearer session", list.path to list.getHeader("Authorization"))+ val delete = server.takeRequest()+ assertEquals("DELETE" to "/v1/devices/mine", delete.method to delete.path)+ assertEquals(null, client.pinningToken())+ } finally { server.shutdown() }+ }}diff --cc apps/desktop/package-lock.jsonindex 1076b87b,a2560f16..a1817518--- a/apps/desktop/package-lock.json+++ b/apps/desktop/package-lock.json@@@ -1,12 -1,12 +1,12 @@@{"name": "codync-desktop",- "version": "2.34.2",- "version": "2.35.0",++ "version": "2.36.0","lockfileVersion": 3,"requires": true,"packages": {"": {"name": "codync-desktop",- "version": "2.34.2",- "version": "2.35.0",++ "version": "2.36.0","license": "Apache-2.0","dependencies": {"electron-updater": "^6.8.9"diff --cc apps/desktop/package.jsonindex 045f01be,fb3930ca..5ab0f6f9--- a/apps/desktop/package.json+++ b/apps/desktop/package.json@@@ -1,7 -1,7 +1,7 @@@{"name": "codync-desktop","productName": "Codync",- "version": "2.34.2",- "version": "2.35.0",++ "version": "2.36.0","description": "Codync for macOS, Linux and Windows: your coding agents as teammates.","author": {"name": "leepokai",diff --cc apps/desktop/src/renderer/lib/auto-claim.test.tsindex 31c06ddd,b1e57484..0b5e5969--- a/apps/desktop/src/renderer/lib/auto-claim.test.ts+++ b/apps/desktop/src/renderer/lib/auto-claim.test.ts@@@ -1,6 -1,6 +1,6 @@@import assert from 'node:assert/strict'import { test } from 'node:test'- import { mayAutoClaim, mayJoinAfterInstall, mayOfferMove } from './auto-claim.ts'-import { accountMismatch, mayAutoClaim, mayOfferMove } from './auto-claim.ts'++import { accountMismatch, mayAutoClaim, mayJoinAfterInstall, mayOfferMove } from './auto-claim.ts'const host = { id: 'new', online: true, cloud: { enabled: true, owner: null } }@@@ -35,10 -35,16 +35,24 @@@ test('a computer in another account offassert.equal(mayOfferMove({ ...host, cloud: { enabled: true, owner: { userId: 'a' }, relay: 'private' } }, 'b', []), false)})+test('an SSH computer installed from here joins unless it is in an account or on a private relay', () => {+ // Its cloud may still be off: Add to account turns it on, as installing shows the intent.+ assert.equal(mayJoinAfterInstall({ owner: null }), true)+ assert.equal(mayJoinAfterInstall({ owner: null, relay: 'codync' }), true)+ assert.equal(mayJoinAfterInstall({ owner: { userId: 'a' } }), false)+ assert.equal(mayJoinAfterInstall({ owner: null, relay: 'private' }), false)+})+++ test('the sidebar line says when this computer and the signed-in account differ', () => {+ const owned = { ...host, cloud: { enabled: true, owner: { userId: 'a', email: '[email protected]' } } }+ assert.deepEqual(accountMismatch(owned, 'b', [], []), { kind: 'other', email: '[email protected]' })+ assert.equal(accountMismatch(owned, 'a', [], []), null, 'the same account')+ assert.deepEqual(accountMismatch(owned, 'b', ['new'], []), { kind: 'other', email: '[email protected]' }, 'still shown after keep it there')+ assert.equal(accountMismatch(host, 'b', [], []), null, 'joining on its own')+ assert.deepEqual(accountMismatch({ ...host, cloud: { enabled: false } }, 'b', [], []), { kind: 'none', reason: 'cloudOff' })+ assert.deepEqual(accountMismatch({ ...host, cloud: { enabled: true, relay: 'private' } }, 'b', [], []), { kind: 'none', reason: 'privateRelay' })+ assert.deepEqual(accountMismatch(host, 'b', ['new'], []), { kind: 'none', reason: 'keptOut' })+ assert.deepEqual(accountMismatch(host, 'b', [], ['new']), { kind: 'none', reason: 'keptOut' }, 'removed from the account elsewhere')+ assert.equal(accountMismatch({ ...owned, online: false }, 'b', [], []), null, "an offline host can't say")+ assert.equal(accountMismatch({ ...host, cloud: null }, 'b', [], []), null)+ })diff --cc apps/desktop/src/renderer/store/cloud.tsindex 571f6485,8ca9bd15..e314a82c--- a/apps/desktop/src/renderer/store/cloud.ts+++ b/apps/desktop/src/renderer/store/cloud.ts@@@ -1,5 -1,5 +1,5 @@@import type { CloudStatus, ClaimSignature } from '@shared/models'- import { mayAutoClaim, mayJoinAfterInstall, mayOfferMove, type ClaimCandidate } from '../lib/auto-claim'-import { accountMismatch, mayAutoClaim, mayOfferMove, type AccountMismatch, type ClaimCandidate } from '../lib/auto-claim'++import { accountMismatch, mayAutoClaim, mayJoinAfterInstall, mayOfferMove, type AccountMismatch, type ClaimCandidate } from '../lib/auto-claim'import { Observable } from '../lib/observable'import { isOlderCopy } from '../lib/older-copy'import { relayAddressToSave } from '../lib/relay-address'diff --cc apps/desktop/src/renderer/views/ChatWindow.tsxindex d23950cb,b833f30e..01bb1f71--- a/apps/desktop/src/renderer/views/ChatWindow.tsx+++ b/apps/desktop/src/renderer/views/ChatWindow.tsx@@@ -38,7 -37,7 +37,8 @@@ export { EmptyState } from './HostStateimport { RefreshIndicator } from './RefreshIndicator'import { StarPrompt } from './StarPrompt'import { MoveComputerPrompt } from './MoveComputerPrompt'+import { PairingRequestPrompt } from './PairingRequestPrompt'+ import { DeleteAccountPrompt } from './DeleteAccountPrompt'import { OpenVoiceSettings } from './call/CallView'import { AccountPanelLayer, ProfileAvatar } from './PanelMenus'import { DesktopActionMenu, type ActionItem } from './DesktopActionMenu'diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/de.jsonindex feb9abb2,318c2a42..97ada03b--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/de.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/de.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "Neue Geräte fragen mit einem 6-stelligen Code nach Zugriff.","Keep it there": "Dort lassen","Move here": "Hierher verschieben",+ "If the computer asks, check it shows {code}.": "Wenn der Computer fragt, prüfe, dass er {code} anzeigt.",+ "Connect to the internet to pair, so Codync can confirm your account.": "Verbinde dich mit dem Internet, damit Codync beim Koppeln dein Konto bestätigen kann.",+ "Let {name} in?": "{name} hereinlassen?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} möchte diesen Computer nutzen, der dann dem Konto von {email} beitritt. Prüfe, dass {name} {code} anzeigt.",+ "Let in": "Hereinlassen",+ "Don't allow": "Nicht erlauben",+ "A Codync account": "Ein Codync-Konto",+ "Every device of {email}'s account loses access.": "Alle Geräte des Kontos von {email} verlieren den Zugriff.",+ "Every device of that account loses access.": "Alle Geräte dieses Kontos verlieren den Zugriff.",+ "Access comes back only when you add {name} to the account again on {name} itself.": "Der Zugriff kommt erst zurück, wenn du {name} auf {name} selbst wieder zum Konto hinzufügst.",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} möchte diesen Computer nutzen. Er tritt dem Konto von {email} bei. Prüfe, dass das Telefon {code} anzeigt.",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "In keinem Konto: Ein angemeldetes Telefon, das dies scannt, bittet darum, den Computer in sein Konto aufzunehmen.",+ "Paste a pairing link, or type the code from the computer": "Füge einen Kopplungslink ein oder gib den Code vom Computer ein",+ "That code isn't valid. Check it on the computer.": "Dieser Code ist ungültig. Prüfe ihn auf dem Computer.",+ "That code expired or was used. Show a new one on the computer.": "Dieser Code ist abgelaufen oder wurde schon verwendet. Lass dir auf dem Computer einen neuen anzeigen.",+ "Installing codync-host…": "codync-host wird installiert…",+ "Starting codync-host…": "codync-host wird gestartet…",+ "Couldn't install codync-host on {name}.": "codync-host konnte nicht auf {name} installiert werden.",+ "codync-host isn't installed on {name}.": "codync-host ist auf {name} nicht installiert.",+ "To keep codync-host running on {name} after you log out, run this there:": "Damit codync-host auf {name} weiterläuft, wenn du dich abmeldest, führe dort Folgendes aus:",- "Copy command": "Befehl kopieren"++ "Copy command": "Befehl kopieren",+ "Delete account": "Konto löschen",+ "Delete your Codync account?": "Dein Codync-Konto löschen?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "Dein Konto, seine Computerliste und der Zugriff jedes Geräts darüber werden gelöscht. Deine Computer behalten ihre Bots und Chats. Das lässt sich nicht rückgängig machen.",+ "Couldn't delete your account. Check your connection and try again.": "Konto konnte nicht gelöscht werden. Prüfe deine Verbindung und versuche es erneut.",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "Melde dich an, um deinen Computer weiter zu nutzen. Er wandert in dein Konto, du musst nicht erneut scannen.",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "Melde dich an, um deine {count} Computer weiter zu nutzen. Sie wandern in dein Konto, du musst nicht erneut scannen.",+ "This computer is in {name}'s account": "Dieser Computer ist im Konto von {name}",+ "This computer is in another account": "Dieser Computer ist in einem anderen Konto",+ "This computer isn't in an account: its cloud is off": "Dieser Computer ist in keinem Konto: seine Cloud ist aus",+ "This computer isn't in an account: it uses a private relay": "Dieser Computer ist in keinem Konto: er nutzt ein privates Relay",+ "This computer isn't in your account": "Dieser Computer ist nicht in deinem Konto"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/es.jsonindex 65287ed1,fa627307..ebb0d4ae--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/es.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/es.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "Los dispositivos nuevos piden acceso con un código de 6 dígitos.","Keep it there": "Dejarla ahí","Move here": "Mover aquí",+ "If the computer asks, check it shows {code}.": "Si el ordenador lo pregunta, comprueba que muestra {code}.",+ "Connect to the internet to pair, so Codync can confirm your account.": "Conéctate a internet para vincular, así Codync puede confirmar tu cuenta.",+ "Let {name} in?": "¿Dejar entrar a {name}?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} quiere usar esta computadora, que luego se une a la cuenta de {email}. Comprueba que {name} muestra {code}.",+ "Let in": "Dejar entrar",+ "Don't allow": "No permitir",+ "A Codync account": "Una cuenta de Codync",+ "Every device of {email}'s account loses access.": "Todos los dispositivos de la cuenta de {email} pierden el acceso.",+ "Every device of that account loses access.": "Todos los dispositivos de esa cuenta pierden el acceso.",+ "Access comes back only when you add {name} to the account again on {name} itself.": "El acceso solo vuelve cuando añades {name} a la cuenta de nuevo desde {name}.",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} quiere usar esta computadora. Se une a la cuenta de {email}. Comprueba que el teléfono muestra {code}.",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "Sin cuenta: un teléfono con sesión iniciada que escanee esto pedirá añadir la computadora a su cuenta.",+ "Paste a pairing link, or type the code from the computer": "Pega un enlace de emparejamiento o escribe el código de la computadora",+ "That code isn't valid. Check it on the computer.": "Ese código no es válido. Revísalo en la computadora.",+ "That code expired or was used. Show a new one on the computer.": "Ese código caducó o ya se usó. Muestra uno nuevo en la computadora.",+ "Installing codync-host…": "Instalando codync-host…",+ "Starting codync-host…": "Iniciando codync-host…",+ "Couldn't install codync-host on {name}.": "No se pudo instalar codync-host en {name}.",+ "codync-host isn't installed on {name}.": "codync-host no está instalado en {name}.",+ "To keep codync-host running on {name} after you log out, run this there:": "Para que codync-host siga funcionando en {name} cuando cierres la sesión, ejecuta esto allí:",- "Copy command": "Copiar comando"++ "Copy command": "Copiar comando",+ "Delete account": "Eliminar cuenta",+ "Delete your Codync account?": "¿Eliminar tu cuenta de Codync?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "Se eliminan tu cuenta, su lista de ordenadores y el acceso de cada dispositivo a través de ella. Tus ordenadores conservan sus bots y chats. No se puede deshacer.",+ "Couldn't delete your account. Check your connection and try again.": "No se pudo eliminar tu cuenta. Comprueba tu conexión e inténtalo de nuevo.",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "Inicia sesión para seguir usando tu ordenador. Pasa a tu cuenta, así que no tendrás que volver a escanear.",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "Inicia sesión para seguir usando tus {count} ordenadores. Pasan a tu cuenta, así que no tendrás que volver a escanear.",+ "This computer is in {name}'s account": "Este ordenador está en la cuenta de {name}",+ "This computer is in another account": "Este ordenador está en otra cuenta",+ "This computer isn't in an account: its cloud is off": "Este ordenador no está en ninguna cuenta: su nube está desactivada",+ "This computer isn't in an account: it uses a private relay": "Este ordenador no está en ninguna cuenta: usa un relé privado",+ "This computer isn't in your account": "Este ordenador no está en tu cuenta"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/fr.jsonindex b35c2ef5,70e0277a..13c5c224--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/fr.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/fr.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "Les nouveaux appareils demandent l'accès avec un code à 6 chiffres.","Keep it there": "Le laisser là","Move here": "Déplacer ici",+ "If the computer asks, check it shows {code}.": "Si l'ordinateur le demande, vérifiez qu'il affiche {code}.",+ "Connect to the internet to pair, so Codync can confirm your account.": "Connectez-vous à Internet pour appairer, afin que Codync confirme votre compte.",+ "Let {name} in?": "Laisser entrer {name} ?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} veut utiliser cet ordinateur, qui rejoint alors le compte de {email}. Vérifiez que {name} affiche {code}.",+ "Let in": "Laisser entrer",+ "Don't allow": "Ne pas autoriser",+ "A Codync account": "Un compte Codync",+ "Every device of {email}'s account loses access.": "Tous les appareils du compte de {email} perdent l’accès.",+ "Every device of that account loses access.": "Tous les appareils de ce compte perdent l’accès.",+ "Access comes back only when you add {name} to the account again on {name} itself.": "L’accès ne revient que si vous ajoutez de nouveau {name} au compte depuis {name} lui-même.",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} veut utiliser cet ordinateur. Il rejoint le compte de {email}. Vérifiez que le téléphone affiche {code}.",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "Dans aucun compte : un téléphone connecté qui scanne ceci demande à ajouter l’ordinateur à son compte.",+ "Paste a pairing link, or type the code from the computer": "Collez un lien d'appairage ou saisissez le code affiché sur l'ordinateur",+ "That code isn't valid. Check it on the computer.": "Ce code n'est pas valide. Vérifiez-le sur l'ordinateur.",+ "That code expired or was used. Show a new one on the computer.": "Ce code a expiré ou a déjà été utilisé. Affichez-en un nouveau sur l'ordinateur.",+ "Installing codync-host…": "Installation de codync-host…",+ "Starting codync-host…": "Démarrage de codync-host…",+ "Couldn't install codync-host on {name}.": "Impossible d’installer codync-host sur {name}.",+ "codync-host isn't installed on {name}.": "codync-host n’est pas installé sur {name}.",+ "To keep codync-host running on {name} after you log out, run this there:": "Pour que codync-host continue de tourner sur {name} après votre déconnexion, exécutez ceci là-bas :",- "Copy command": "Copier la commande"++ "Copy command": "Copier la commande",+ "Delete account": "Supprimer le compte",+ "Delete your Codync account?": "Supprimer votre compte Codync ?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "Votre compte, sa liste d'ordinateurs et l'accès de chaque appareil qui en dépend sont supprimés. Vos ordinateurs gardent leurs bots et leurs conversations. Action irréversible.",+ "Couldn't delete your account. Check your connection and try again.": "Suppression du compte impossible. Vérifiez votre connexion réseau et réessayez.",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "Connectez-vous pour continuer à utiliser votre ordinateur. Il rejoint votre compte : inutile de scanner à nouveau.",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "Connectez-vous pour continuer à utiliser vos {count} ordinateurs. Ils rejoignent votre compte : inutile de scanner à nouveau.",+ "This computer is in {name}'s account": "Cet ordinateur est dans le compte de {name}",+ "This computer is in another account": "Cet ordinateur est dans un autre compte",+ "This computer isn't in an account: its cloud is off": "Cet ordinateur n'est dans aucun compte : son cloud est désactivé",+ "This computer isn't in an account: it uses a private relay": "Cet ordinateur n'est dans aucun compte : il utilise un relais privé",+ "This computer isn't in your account": "Cet ordinateur n'est pas dans votre compte"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ja.jsonindex 8799dcbf,4edddba8..0af03220--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ja.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ja.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "新しいデバイスは6桁のコードでアクセスをリクエストします。","Keep it there": "そのままにする","Move here": "ここに移動",+ "If the computer asks, check it shows {code}.": "コンピュータに確認を求められたら、{code} と表示されているか確かめてください。",+ "Connect to the internet to pair, so Codync can confirm your account.": "ペアリングするにはインターネットに接続してください。Codync がアカウントを確認します。",+ "Let {name} in?": "{name} を許可しますか?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} がこのコンピュータを使おうとしています。許可すると、このコンピュータは {email} のアカウントに加わります。{name} に {code} と表示されているか確かめてください。",+ "Let in": "許可",+ "Don't allow": "許可しない",+ "A Codync account": "Codync アカウント",+ "Every device of {email}'s account loses access.": "{email} のアカウントのすべてのデバイスがアクセスできなくなります。",+ "Every device of that account loses access.": "そのアカウントのすべてのデバイスがアクセスできなくなります。",+ "Access comes back only when you add {name} to the account again on {name} itself.": "{name} 自体で {name} を再びアカウントに追加したときだけ、アクセスが戻ります。",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} がこのコンピュータを使おうとしています。このコンピュータは {email} のアカウントに加わります。スマートフォンに {code} と表示されているか確かめてください。",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "アカウントに入っていません:サインイン済みのスマートフォンがこれをスキャンすると、このコンピュータをそのアカウントに加えるよう求めます。",+ "Paste a pairing link, or type the code from the computer": "ペアリングリンクを貼り付けるか、コンピューターに表示されたコードを入力します",+ "That code isn't valid. Check it on the computer.": "このコードは無効です。コンピューターで確認してください。",+ "That code expired or was used. Show a new one on the computer.": "このコードは期限切れか、すでに使用されています。コンピューターで新しいコードを表示してください。",+ "Installing codync-host…": "codync-host をインストール中…",+ "Starting codync-host…": "codync-host を起動中…",+ "Couldn't install codync-host on {name}.": "{name} に codync-host をインストールできませんでした。",+ "codync-host isn't installed on {name}.": "codync-host は {name} にインストールされていません。",+ "To keep codync-host running on {name} after you log out, run this there:": "ログアウト後も {name} で codync-host を動かし続けるには、そこで次を実行してください:",- "Copy command": "コマンドをコピー"++ "Copy command": "コマンドをコピー",+ "Delete account": "アカウントを削除",+ "Delete your Codync account?": "Codync アカウントを削除しますか?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "アカウント、そのコンピュータの一覧、アカウント経由の各デバイスのアクセス権が削除されます。コンピュータのボットとチャットは残ります。元に戻すことはできません。",+ "Couldn't delete your account. Check your connection and try again.": "アカウントを削除できませんでした。接続を確認して、もう一度お試しください。",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "サインインすると、このコンピュータをそのまま使えます。アカウントに移されるので、もう一度スキャンする必要はありません。",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "サインインすると、{count} 台のコンピュータをそのまま使えます。アカウントに移されるので、もう一度スキャンする必要はありません。",+ "This computer is in {name}'s account": "このコンピュータは {name} のアカウントにあります",+ "This computer is in another account": "このコンピュータは別のアカウントにあります",+ "This computer isn't in an account: its cloud is off": "このコンピュータはどのアカウントにもありません: クラウドがオフです",+ "This computer isn't in an account: it uses a private relay": "このコンピュータはどのアカウントにもありません: プライベートリレーを使っています",+ "This computer isn't in your account": "このコンピュータはあなたのアカウントにありません"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ko.jsonindex 76df4e20,8efe98eb..6c0e56d2--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ko.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/ko.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "새 기기는 6자리 코드로 접근을 요청합니다.","Keep it there": "그대로 두기","Move here": "여기로 옮기기",+ "If the computer asks, check it shows {code}.": "컴퓨터가 물으면 {code}가 표시되는지 확인하세요.",+ "Connect to the internet to pair, so Codync can confirm your account.": "페어링하려면 인터넷에 연결하세요. Codync가 계정을 확인해야 합니다.",+ "Let {name} in?": "{name}의 접속을 허용할까요?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email}에서 이 컴퓨터를 사용하려고 합니다. 허용하면 이 컴퓨터가 {email} 계정에 추가됩니다. {name}에 {code}가 표시되는지 확인하세요.",+ "Let in": "허용",+ "Don't allow": "허용 안 함",+ "A Codync account": "Codync 계정",+ "Every device of {email}'s account loses access.": "{email} 계정의 모든 기기가 접근 권한을 잃습니다.",+ "Every device of that account loses access.": "그 계정의 모든 기기가 접근 권한을 잃습니다.",+ "Access comes back only when you add {name} to the account again on {name} itself.": "{name}에서 직접 {name}을(를) 다시 계정에 추가해야만 접근 권한이 돌아옵니다.",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name}에서 이 컴퓨터를 사용하려고 합니다. 이 컴퓨터는 {email} 계정에 추가됩니다. 휴대폰에 {code}가 표시되는지 확인하세요.",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "계정에 속해 있지 않음: 로그인된 휴대폰이 이것을 스캔하면 이 컴퓨터를 그 계정에 추가하도록 요청합니다.",+ "Paste a pairing link, or type the code from the computer": "페어링 링크를 붙여넣거나 컴퓨터에 표시된 코드를 입력하세요",+ "That code isn't valid. Check it on the computer.": "유효하지 않은 코드입니다. 컴퓨터에서 확인하세요.",+ "That code expired or was used. Show a new one on the computer.": "코드가 만료되었거나 이미 사용되었습니다. 컴퓨터에서 새 코드를 표시하세요.",+ "Installing codync-host…": "codync-host 설치 중…",+ "Starting codync-host…": "codync-host 시작 중…",+ "Couldn't install codync-host on {name}.": "{name}에 codync-host를 설치하지 못했습니다.",+ "codync-host isn't installed on {name}.": "{name}에 codync-host가 설치되지 않았습니다.",+ "To keep codync-host running on {name} after you log out, run this there:": "로그아웃한 뒤에도 {name}에서 codync-host가 계속 실행되게 하려면 해당 컴퓨터에서 다음을 실행하세요:",- "Copy command": "명령 복사"++ "Copy command": "명령 복사",+ "Delete account": "계정 삭제",+ "Delete your Codync account?": "Codync 계정을 삭제할까요?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "계정, 계정의 컴퓨터 목록, 계정을 통한 모든 기기의 접근 권한이 삭제됩니다. 컴퓨터의 봇과 대화는 그대로 남습니다. 되돌릴 수 없습니다.",+ "Couldn't delete your account. Check your connection and try again.": "계정을 삭제하지 못했습니다. 연결을 확인하고 다시 시도하세요.",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "로그인하면 컴퓨터를 계속 사용할 수 있습니다. 계정으로 옮겨지므로 다시 스캔할 필요가 없습니다.",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "로그인하면 컴퓨터 {count}대를 계속 사용할 수 있습니다. 계정으로 옮겨지므로 다시 스캔할 필요가 없습니다.",+ "This computer is in {name}'s account": "이 컴퓨터는 {name}의 계정에 있습니다",+ "This computer is in another account": "이 컴퓨터는 다른 계정에 있습니다",+ "This computer isn't in an account: its cloud is off": "이 컴퓨터는 어떤 계정에도 없습니다: 클라우드가 꺼져 있습니다",+ "This computer isn't in an account: it uses a private relay": "이 컴퓨터는 어떤 계정에도 없습니다: 개인 릴레이를 사용합니다",+ "This computer isn't in your account": "이 컴퓨터는 내 계정에 없습니다"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hans.jsonindex e0bbd4ff,6cc5d606..0c711c8f--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hans.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hans.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "新设备要用 6 位验证码请求访问。","Keep it there": "留在原处","Move here": "移到这里",+ "If the computer asks, check it shows {code}.": "如果电脑问你,确认它显示 {code}。",+ "Connect to the internet to pair, so Codync can confirm your account.": "请连上网络再配对,Codync 才能确认你的账户。",+ "Let {name} in?": "要让 {name} 进入吗?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} 想使用这台电脑,之后这台电脑会加入 {email} 的账户。请确认 {name} 显示 {code}。",+ "Let in": "允许进入",+ "Don't allow": "不允许",+ "A Codync account": "一个 Codync 账户",+ "Every device of {email}'s account loses access.": "{email} 账户的所有设备都会失去访问。",+ "Every device of that account loses access.": "该账户的所有设备都会失去访问。",+ "Access comes back only when you add {name} to the account again on {name} itself.": "只有在 {name} 本机上将 {name} 重新加入账户,访问才会恢复。",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} 想使用这台电脑。这台电脑会加入 {email} 的账户。请确认手机显示 {code}。",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "不在任何账户中:已登录的手机扫描这个码时,会请求把这台电脑加入它的账户。",+ "Paste a pairing link, or type the code from the computer": "粘贴配对链接,或输入电脑上的代码",+ "That code isn't valid. Check it on the computer.": "代码无效,请在电脑上核对。",+ "That code expired or was used. Show a new one on the computer.": "代码已过期或已被使用,请在电脑上显示新的代码。",+ "Installing codync-host…": "正在安装 codync-host…",+ "Starting codync-host…": "正在启动 codync-host…",+ "Couldn't install codync-host on {name}.": "无法在 {name} 上安装 codync-host。",+ "codync-host isn't installed on {name}.": "{name} 上还没有安装 codync-host。",+ "To keep codync-host running on {name} after you log out, run this there:": "要让 codync-host 在你退出登录后继续在 {name} 上运行,请在那里运行:",- "Copy command": "复制命令"++ "Copy command": "复制命令",+ "Delete account": "删除账户",+ "Delete your Codync account?": "要删除你的 Codync 账户吗?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "你的账户、账户里的电脑列表,以及每台设备通过账户获得的使用权都会删除。电脑上的 bot 和对话会保留。无法撤销。",+ "Couldn't delete your account. Check your connection and try again.": "删除账户失败。检查网络后再试一次。",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "登录后就能继续使用你的电脑。它会移进你的账户,不用再扫一次。",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "登录后就能继续使用你的 {count} 台电脑。它们会移进你的账户,不用再扫一次。",+ "This computer is in {name}'s account": "这台电脑在 {name} 的账户里",+ "This computer is in another account": "这台电脑在另一个账户里",+ "This computer isn't in an account: its cloud is off": "这台电脑不在任何账户里:它的云端已关闭",+ "This computer isn't in an account: it uses a private relay": "这台电脑不在任何账户里:它用私人中继",+ "This computer isn't in your account": "这台电脑不在你的账户里"}diff --cc apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hant.jsonindex 2142b788,8cc914ab..e955b633--- a/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hant.json+++ b/apps/ios/Kit/Sources/CodyncKit/Resources/Languages/zh-Hant.json@@@ -1479,25 -1479,15 +1478,36 @@@"New devices ask for access with a 6-digit code.": "新裝置要用 6 位驗證碼請求訪問。","Keep it there": "留在原處","Move here": "移到這裡",+ "If the computer asks, check it shows {code}.": "如果電腦問你,確認它顯示 {code}。",+ "Connect to the internet to pair, so Codync can confirm your account.": "請連上網路再配對,Codync 才能確認你的賬戶。",+ "Let {name} in?": "要讓 {name} 進入嗎?",+ "{email} wants to use this computer, which then joins {email}'s account. Check {name} shows {code}.": "{email} 想使用這臺電腦,之後這臺電腦會加入 {email} 的賬戶。請確認 {name} 顯示 {code}。",+ "Let in": "允許進入",+ "Don't allow": "不允許",+ "A Codync account": "一個 Codync 賬戶",+ "Every device of {email}'s account loses access.": "{email} 賬戶的所有裝置都會失去訪問。",+ "Every device of that account loses access.": "該賬戶的所有裝置都會失去訪問。",+ "Access comes back only when you add {name} to the account again on {name} itself.": "只有在 {name} 本機上將 {name} 重新加入賬戶,訪問才會恢復。",+ "{name} wants to use this computer. It joins {email}'s account. Check the phone shows {code}.": "{name} 想使用這臺電腦。這臺電腦會加入 {email} 的賬戶。請確認手機顯示 {code}。",+ "Not in an account: a signed-in phone that scans this asks to bring the computer into its account.": "不在任何賬戶中:已登入的手機掃描這個碼時,會請求把這臺電腦加入它的賬戶。",+ "Paste a pairing link, or type the code from the computer": "貼上配對連結,或輸入電腦上的代碼",+ "That code isn't valid. Check it on the computer.": "代碼無效,請到電腦上確認。",+ "That code expired or was used. Show a new one on the computer.": "代碼已過期或已使用過,請在電腦上顯示新的代碼。",+ "Installing codync-host…": "正在安裝 codync-host…",+ "Starting codync-host…": "正在啟動 codync-host…",+ "Couldn't install codync-host on {name}.": "無法在 {name} 上安裝 codync-host。",+ "codync-host isn't installed on {name}.": "{name} 上還沒有安裝 codync-host。",+ "To keep codync-host running on {name} after you log out, run this there:": "要讓 codync-host 在你登出後繼續在 {name} 上執行,請在那裡執行:",- "Copy command": "複製命令"++ "Copy command": "複製命令",+ "Delete account": "刪除賬戶",+ "Delete your Codync account?": "要刪除你的 Codync 賬戶嗎?",+ "Your account, its list of computers and every device's access through it are deleted. Your computers keep their bots and chats. This can't be undone.": "你的賬戶、賬戶裡的電腦清單,以及每台裝置透過賬戶取得的使用權都會刪除。電腦上的 bot 和對話會保留。無法撤銷。",+ "Couldn't delete your account. Check your connection and try again.": "刪除賬戶失敗。檢查網路後再試一次。",+ "Sign in to keep using your computer. It moves into your account, so you won't need to scan again.": "登入後就能繼續使用你的電腦。它會移進你的賬戶,不用再掃一次。",+ "Sign in to keep using your {count} computers. They move into your account, so you won't need to scan again.": "登入後就能繼續使用你的 {count} 台電腦。它們會移進你的賬戶,不用再掃一次。",+ "This computer is in {name}'s account": "這臺電腦在 {name} 的賬戶裡",+ "This computer is in another account": "這臺電腦在另一個賬戶裡",+ "This computer isn't in an account: its cloud is off": "這臺電腦不在任何賬戶裡:它的雲端已關閉",+ "This computer isn't in an account: it uses a private relay": "這臺電腦不在任何賬戶裡:它用私人中繼",+ "This computer isn't in your account": "這臺電腦不在你的賬戶裡"}diff --cc apps/ios/Views/PairingView.swiftindex c622f125,a793d32e..88f7704b--- a/apps/ios/Views/PairingView.swift+++ b/apps/ios/Views/PairingView.swift@@@ -212,6 -212,6 +212,8 @@@ private struct ScanPage: View@State private var pairing = false@State private var pasted = ""@State private var error: String?++ /// The phone couldn't reach the computer (not a refusal from it or the cloud): the network hint helps.++ @State private var unreachable = false/// Bumped after a failed pair so the scanner starts looking again.@State private var attempt = 0@State private var tailscaleOn = Tailscale.isConnected@@@ -250,12 -250,12 +252,12 @@@if let error {VStack(alignment: .leading, spacing: 6) {- Text(error).font(.footnote).foregroundStyle(Palette.danger)+ Text(L10n.tr(error)).font(.footnote).foregroundStyle(Palette.danger)// The usual cause: the phone has no road to the computer yet.-- Label(L10n.tr("Check that this iPhone and the computer are on the same Wi-Fi or both on Tailscale, or that “Reach from anywhere” is on in Codync on the computer."),++ if unreachable { Label(L10n.tr("Check that this iPhone and the computer are on the same Wi-Fi or both on Tailscale, or that “Reach from anywhere” is on in Codync on the computer."),systemImage: "wifi.exclamationmark").font(.footnote)-- .foregroundStyle(Palette.secondary)++ .foregroundStyle(Palette.secondary) }}.transition(.opacity)}@@@ -310,6 -310,6 +312,8 @@@Image(systemName: "qrcode.viewfinder").font(.system(size: 44, weight: .light))Text(L10n.tr("Camera not available. Paste the link below.")).font(.footnote)}++ // The pairing progress takes its place.++ .opacity(pairing ? 0 : 1).foregroundStyle(Palette.tertiary).frame(maxWidth: .infinity, maxHeight: .infinity).background(Palette.surface)@@@ -357,7 -348,7 +361,11 @@@private func show(_ error: Error) {attempt += 1-- withAnimation(Motion.reduced(Motion.layout, reduceMotion)) { self.error = error.localizedDescription }++ let reason = AnalyticsEvent.PairingFailure(error)++ withAnimation(Motion.reduced(Motion.layout, reduceMotion)) {++ self.error = error.localizedDescription++ unreachable = reason == .unreachable || reason == .timeout++ }}}diff --cc apps/ios/WhatsNew.mdindex 1d3a3758,abf4c30b..14522d8f--- a/apps/ios/WhatsNew.md+++ b/apps/ios/WhatsNew.md@@@ -5,3 -5,14 +5,18 @@@ listing what iPhone users notice, withoany left). tools/asc-submit.py reads the released version's section;a version without one gets a generic "Bug fixes and improvements" line. Delete old sections.-->+-## 2.35.0++## 2.36.0+ ### zh-Hant+ - Codync 現在需要用 Apple 或 Google 登入。以前沒登入就配對的電腦,第一次登入時會一起移進你的賬戶,不用再掃一次。+ - 登出時,這支手機會從它連得到的電腦和你的賬戶中移除。+ - 可以在 App 裡刪除賬戶:點 Bots 分頁左上角的賬戶按鈕,再點「刪除賬戶」。++- 配對會確認賬戶:在別人賬戶裡的電腦會告訴你它在誰的賬戶;還不在任何賬戶的電腦,會先在電腦上問一聲,再加入你的賬戶。++- 也可以輸入 `codync-host pair` 印出的短代碼來配對,不用掃 QR code。++ ### en-US+ - Codync now asks you to sign in with Apple or Google. Computers you paired without signing in move into your account the first time you sign in, with no new scan.+ - Signing out now also removes this phone from the computers it can reach and from your account.+ - You can delete your account in the app: tap the account button at the top left of the Bots tab, then Delete account.++- Pairing checks your account: a computer in someone else's account tells you whose, and a computer in no account asks on the computer first, then joins your account.++- You can also type the short code `codync-host pair` prints instead of scanning the QR code.diff --cc apps/project.ymlindex 32fe635c,562c3d35..93cf0d61--- a/apps/project.yml+++ b/apps/project.yml@@@ -25,7 -25,7 +25,7 @@@ configsDevRelease: releasesettings:base:- MARKETING_VERSION: 2.34.2- MARKETING_VERSION: 2.35.0++ MARKETING_VERSION: 2.36.0CURRENT_PROJECT_VERSION: 24SWIFT_VERSION: "6.0"SWIFT_STRICT_CONCURRENCY: completediff --cc docs/architecture/connections.mdindex 89ea17f7,ad06eb22..5b79c6d5--- a/docs/architecture/connections.md+++ b/docs/architecture/connections.md@@@ -71,7 -71,7 +71,7 @@@ The app manages its computer through loA computer with only the host (SSH-only server, VPS) never signs in. It joins an account in one of two ways:--- A manager's desktop app adds it over SSH: add the SSH computer, install the host (one click, planned), then it joins the manager app's account.++- A manager's desktop app adds it over SSH: add the SSH computer, install the host in one click, then it joins the manager app's account on its own.- A signed-in phone scans `codync-host pair` (or types its short code) and the terminal confirms.`codync-host cloud` and the TUI's account screen say which account the computer is in, or how to add it to one.@@@ -86,8 -86,8 +86,8 @@@ The agents themselves (Claude Code, Cod| --- | --- | --- | --- || 1 | VPS | Install the agents and sign them in | Same || 2 | Desktop | Settings → Computers → Over SSH → **Add SSH computer**, pick the host from `~/.ssh/config`, compare the host key, **Trust and connect** | Built |--| 3 | Desktop | **Install** on the card: `install.sh --host-only` and `codync-host install` over SSH. `loginctl enable-linger` needs sudo, so when it fails the card shows that one command | Planned: today the card shows a `brew` command to copy, which fails on Linux |--| 4 | Desktop | The VPS joins the desktop app's account on its own | Planned: today **Add to account** is a separate tap |++| 3 | Desktop | **Install** on the card: `install.sh --host-only` and `codync-host install` over SSH. Linger is turned on where the system lets the user do it (Ubuntu 24.04 does); otherwise the card shows `sudo loginctl enable-linger "$USER"` | Built (2.36.0); Codync Dev shows the command instead |++| 4 | Desktop | The VPS joins the desktop app's account on its own | Built (2.36.0) || 5 | Phone | The VPS appears in the account list: **Ask for access**, then compare the 6 digits on the desktop and Allow. Or open **Pair iPhone** on the VPS card and scan | Built || 6 | Desktop | Optionally add it to the network in one click | Built |@@@ -97,9 -97,9 +97,9 @@@| --- | --- | --- | --- || 1 | VPS | Install the agents and sign them in | Same || 2 | VPS | `curl -fsSL …/install.sh \| sh -s -- --host-only`, `codync-host install`, `sudo loginctl enable-linger "$USER"` | Built |--| 3 | VPS | `codync-host pair` prints a QR code and a short code | QR built; short code planned |--| 4 | Phone (signed in) | Scan, or type the code. The terminal asks to add the VPS to this account and let this phone in, with a matching code; answer `y` | Planned: today the scan pairs at once and the VPS stays out of any account |--| 5 | Later | Other phones of the same account scan once and are in. Phones that ask remotely are approved with `codync-host access approve` over SSH or in the TUI, or by turning on **Skip the 6-digit check** (`codync-host cloud approval auto`) | Partly built (same-account rule planned) |++| 3 | VPS | `codync-host pair` prints a QR code and a short code | Built (2.36.0) |++| 4 | Phone (signed in) | Scan, or type the code in the paste field. The terminal asks to add the VPS to this account and let this phone in, with a matching code; answer `y` | Built (2.36.0) |++| 5 | Later | Other phones of the same account scan once and are in. Phones that ask remotely are approved with `codync-host access approve` over SSH, or by turning on **Skip the 6-digit check** (`codync-host cloud approval auto`) | Built (2.36.0) |Either way the VPS uses the Codync relay by default, with no port to open; Tailscale on both ends gives a direct route. A headless VPS has no remote screen, and its new bots start without connectors (no credential store). `codync-host tui` over SSH chats on the VPS itself.@@@ -108,8 -108,8 +108,8 @@@| Belongs to | States | Code today || --- | --- | --- || Computer's account | Not in an account · In your account · In another account; also: Cloud off | `cloud.owner`, `cloud.enabled` |--| App vs its computer | Same · Computer in another account · Computer in no account | — (planned) |--| Manage (SSH) | Idle → Connecting → Check host key → Not installed → Installing (planned) → Connected; on errors: Retrying · Failed | `SSHStatus` |++| App vs its computer | Same · Computer in another account · Computer in no account | `accountMismatch` (desktop) |++| Manage (SSH) | Idle → Connecting → Check host key → Not installed → Installing → Connected; on errors: Retrying · Failed | `SSHStatus` || Use: access (device × computer) | None → Waiting for OK → Can use (in person / remote); later: Can't confirm right now · Removed | `unpaired`, `pending`, `local` / `account`, `leaseExpired`, `revoked` || Use: connection | Connecting · Online · Computer offline · Offline | `Connection` || Network role | Not in a network · Member · Admin · Creator | `Role` (`owner` becomes Creator) |@@@ -135,13 -135,13 +135,13 @@@ Phases, file-level steps, tests and ris| Order | Change | Status || --- | --- | --- |- | 1 | Delete the account from inside the apps (App Store 5.1.1(v), Google Play). The cloud already cleans up on Clerk's `user.deleted` | Not built: no client has it |- | 2 | Sign-out hands the key back (iPhone, Android) | Not built: iPhone erases locally only; Android tells only the computer it is connected to |- | 3 | Sign-in required in every app; the phone's signed-out pairings move into the account on first sign-in (with their device and push keys when the account context is new on that phone, otherwise a list to scan again). Builds without Clerk keep the signed-out context | Not built |- | 4 | Same-account QR: the cloud-signed account proof, the host recording each device's account, joining an unowned computer on first scan with a confirmation, short codes, the refusal message | Not built: QR pairs any phone holding the code |- | 5 | Changing accounts drops every old-account device; the move dialog's text says so | Not built: QR devices are kept today |- | 6 | The main-window line for an app and computer in different accounts; the phone's refusal text | Not built: Settings and the one-time dialog only |- | 7 | One-click host install over SSH, then **Add to account** on its own | Not built: shows a `brew` command to copy |+ | 1 | Delete the account from inside the apps (App Store 5.1.1(v), Google Play). The cloud already cleans up on Clerk's `user.deleted` | Built (2.35.0) |+ | 2 | Sign-out hands the key back (iPhone, Android; the desktop revokes its cloud device) | Built (2.35.0) |+ | 3 | Sign-in required in every app; the phone's signed-out pairings move into the account on first sign-in (with their device and push keys when the account context is new on that phone, otherwise a list to scan again). Builds without Clerk keep the signed-out context | Built (2.35.0) |-| 4 | Same-account QR: the cloud-signed account proof, the host recording each device's account, joining an unowned computer on first scan with a confirmation, short codes, the refusal message | Not built: QR pairs any phone holding the code |-| 5 | Changing accounts drops every old-account device; the move dialog's text says so | Not built: QR devices are kept today |-| 6 | The main-window line for an app and computer in different accounts; the phone's refusal text | Desktop line built (2.35.0); the refusal text comes with item 4 |-| 7 | One-click host install over SSH, then **Add to account** on its own | Not built: shows a `brew` command to copy |++| 4 | Same-account QR: the cloud-signed account proof, the host recording each device's account, joining an unowned computer on first scan with a confirmation, short codes, the refusal message | Built (2.36.0) |++| 5 | Changing accounts drops every old-account device; the move dialog's text says so | Built (2.36.0); joining a first account keeps the phones paired before 2.36.0 |++| 6 | The main-window notice for an app and computer in different accounts; the phone's refusal text | Built (2.35.0, 2.36.0) |++| 7 | One-click host install over SSH, then **Add to account** on its own | Built (2.36.0) || 8 | Honor the 15-minute lease when the relay drops | Not built: account devices are refused until the cloud state syncs again || 9 | The renames above, in every client | Not built || 10 | Desktop apps as devices (encrypted channel), so one computer can use another's bots | Not built |diff --cc docs/plans/require-sign-in.mdindex 443dfc0a,6492a99d..f55487a3--- a/docs/plans/require-sign-in.md+++ b/docs/plans/require-sign-in.md@@@ -1,6 -1,6 +1,6 @@@# Require sign-in- Plan agreed 2026-11-02 for [connections and accounts](../architecture/connections.md): every app is signed in, every phone-to-computer link lives in one account, and QR stays as the in-person way to pair. Nothing here is built yet.-Plan agreed 2026-11-02 for [connections and accounts](../architecture/connections.md): every app is signed in, every phone-to-computer link lives in one account, and QR stays as the in-person way to pair. Phase 1 is built (2.35.0); phases 2 and 3 are not.++Plan agreed 2026-11-02 for [connections and accounts](../architecture/connections.md): every app is signed in, every phone-to-computer link lives in one account, and QR stays as the in-person way to pair. All three phases are built (2.36.0). Phase 2 needs the cloud's certificate key before it works against a cloud: see [Release steps](#release-steps).## Decisions@@@ -22,7 -22,7 +22,7 @@@| 3 | VPS convenience: one-click host install over SSH, joining the account afterwards on its own, headless hints, short pairing codes | desktop, host, cloud || Later | 15-minute lease grace, renames, desktop apps as devices | — |--Each phase is one release with a minor version bump. Phase 1 needs no `minApp` change. Phase 2 does; see below.++Phase 1 was 2.35.0 on `dev`; no release went out before phases 2 and 3 joined it, so all three ship as 2.36.0. Phase 2 raises `minApp`; see below.## Phase 1: require sign-in@@@ -160,30 -164,30 +164,40 @@@ After either case the signed-out contex## Phase 2: same-account pairing**Account proof**--- The cloud signs a short-lived device certificate `{deviceKey, userId, exp}` with its own Ed25519 key (`POST /v1/devices/certificate`). It publishes the public key at `/v1/keys`.--- A host pins that key when it joins an account and keeps it with the owner. Checking a certificate is a signature check, so it works offline, with the cloud off or on a private relay.++- The cloud signs a device certificate with its own Ed25519 key, the `DEVICE_CERT_KEY` secret (a JWK): `POST /v1/devices/certificate` (Clerk session plus `Codync-Sig` from a registered, unrevoked device key) returns `{certificate: {payload, sig}}`. The payload is `{v: 1, deviceKey, userId, email, exp}`, valid 7 days; `sig` signs `"codync/device-cert/v1\n" + payload` (`cloud/src/certificate.ts`).++- Hosts compile in the public half for their environment (`host/src/environment.rs` `device_cert_key`; `CODYNC_DEVICE_CERT_KEY` overrides it for a self-hosted cloud). Checking a certificate is a signature check with no network, so it works from the first run, with the cloud off or on a private relay. There is no `/v1/keys` route.++- The private keys live in the git-ignored `.env.development` / `.env.production` (`CODYNC_DEVICE_CERT_KEY`).--**`pair` takes the certificate**++**`pair` takes the certificate** (`host/src/remote/channel/pairing.rs`). The certificate and the account are checked before the one-time code is spent, so a phone that can't come in doesn't use it up. The account the computer belongs to is kept on the computer (`remote/owner.rs`, kv `account_owner`) and compared offline.| The computer | Result || --- | --- |--| Has an owner | The certificate's `userId` must equal the owner. Otherwise the error is `otherAccount`, with the owner's masked email |--| Has no owner | The computer confirms first. The desktop shows a dialog: a new `pairingRequest` event and a `decidePairing` method. `codync-host pair` and the TUI ask `y/N` with a matching code. After that the host joins the phone's account through a new host-signed route that takes the certificate, and pins the cloud key |++| No certificate (an app older than 2.36.0) | `reject` `unsupportedVersion`: "Update Codync to connect to this computer." |++| Certificate not valid for this device key | 403 "Couldn't confirm your Codync account. Sign in again, then scan a new code." |++| In the phone's account | The phone is let in at once |++| In another account | 403 "This computer is in k•••@example.com's account. Move it to your account in Codync on that computer, or sign in with that account." |++| In no account | The computer asks for up to 2 minutes (`remote/pairing_requests.rs`: the loopback-only `pairingRequests` event and method, `decidePairing`): the desktop app and the terminal UI show a dialog, `codync-host pair` asks `y/N`. Both screens show the same 6-digit code, `sha256("codync/pair-check/v1" ‖ deviceKey ‖ hostSignKey)`. Declined or unanswered: 403 "The computer didn't let this phone in." Let in: the computer signs the claim the phone made (`POST /v1/claims`) and the phone completes it (`POST /v1/claims/{id}/complete`), so joining needs no new cloud route. With the cloud off or a private relay there is no claim; the phone is let in and the computer stays out of any account |--**Each device records its account.** Devices get `account_user_id`. When the host changes the account it belongs to (joining one, moving, or leaving with **Remove from account**), devices of any other account are dropped. The move dialog's text then reads: "Every device of {email}'s account loses access." Networks stay as they are: a computer handed to someone else is taken out of a network by the network's creator or an admin, like its SSH key is taken off the manager.++**Each device records its account** (`devices.account`, schema 7). When the host changes the account it belongs to (joining one, moving, or leaving with **Remove from account**), devices of any other account are dropped. Joining a first account keeps the phones paired before devices recorded their account, so updating doesn't cost anyone a phone. The desktop's move and remove dialogs say: "Every device of {email}'s account loses access." Networks stay as they are: a computer handed to someone else is taken out of a network by the network's creator or an admin, like its SSH key is taken off the manager.--**Phones:** send the certificate when pairing, and explain `otherAccount`: "This computer is in a•••@gmail.com's account. Move it to your account in Codync on that computer, or sign in with that account."++**Phones** fetch a certificate before pairing (kept in memory per account; a new one when less than a day is left; registering the device again on 403; an unexpired one is used offline), make a claim, send both, wait up to 150 seconds, and show "If the computer asks, check it shows 123 456." while they wait. Without a certificate: "Connect to the internet to pair, so Codync can confirm your account."--**Compatibility:** apps older than this release can't send a certificate. A host refuses their QR pairing with `unsupportedVersion` ("Update Codync"). That is a new requirement on the phone, so `minApp` rises with this release and [the release gate](../reference/compatibility.md) holds it until both stores have the apps.++**Compatibility:** apps older than this release can't send a certificate, so `minApp` is 2.36.0 and [the release gate](../reference/compatibility.md) holds the release until both stores have the apps.## Phase 3: VPS convenience--- **One-click install over SSH** (`apps/desktop/src/main/ssh*.ts`):-- - On `notInstalled`, **Install** runs `install.sh --host-only` and `codync-host install` over the existing SSH connection, with a new `installing` SSH state.-- - `loginctl enable-linger` needs sudo. When it fails, the card shows that one command to run. It replaces today's `brew` command, which fails on Linux.--- **Joining the account after install:** the manager app's **Add to account** runs on its own, because installing shows the intent.--- **Headless hints:** `codync-host cloud` and the TUI account screen say which account the computer is in, or how to add it ([connections: headless](../architecture/connections.md#headless-computers)).--- **Short pairing codes:** `codync-host pair` also prints a code like `QRTX-4821`, which the host registers with the cloud as a pairing offer. The app resolves the code to the pairing link. The terminal's matching code catches a cloud that swaps keys.++- **One-click install over SSH** (`apps/desktop/src/main/ssh*.ts`): on `notInstalled` the card shows **Install**, which runs `install.sh --host-only` into `~/.local/bin` and `codync-host install` over the existing SSH connection (SSH state `installing`). Linger is checked and enabled without sudo where the system allows it (Ubuntu 24.04 does); otherwise the card shows `sudo loginctl enable-linger "$USER"` to copy. Codync Dev keeps showing the command, since there is no released dev host to install.++- **Joining the account after install:** once the installed computer connects, the app's **Add to account** runs on its own, when the app is signed in and the computer is in no account and not on a private relay.++- **Headless hints:** `codync-host cloud` says how a computer out of an account joins one; the terminal UI's pair sheet says a signed-in phone that scans asks to bring the computer into its account (there is no account screen in the terminal UI).++- **Short pairing codes:** `codync-host pair` asks the host for a code (`pairing {shortCode: true}`); the host registers its link with the cloud (`POST /v1/host/pairing-codes`, migration `0005`), and prints a code like `QRTX-4821`, valid 10 minutes, single use. The phones' paste field takes it and trades it for the link (`GET /v1/pairing-codes/{code}`, signed-in). The computer's own check code catches a cloud that hands out another link.++++## Release steps++++Phase 2 and 3 need these once per cloud, before the hosts that ask for them ship (the cloud is deployed by hand):++++1. `DEVICE_CERT_KEY`: `grep '^CODYNC_DEVICE_CERT_KEY=' .env.development | cut -d= -f2- | npx wrangler secret put DEVICE_CERT_KEY --env dev` from `cloud/` (and the same from `.env.production` without `--env` for main).++2. The pairing codes table: `npx wrangler d1 migrations apply codync-dev --env dev --remote` (main: `codync`).++3. `npm run deploy:dev`, then `npm run deploy:main` right after the release merges.## Laterdiff --cc docs/reference/remote-relay.mdindex 9aa1c928,3dd59073..ae073e60--- a/docs/reference/remote-relay.md+++ b/docs/reference/remote-relay.md@@@ -120,7 -122,7 +122,7 @@@ See [architecture](../architecture/over## 4. 配對與授權流程--### 4.1 QR 配對(無帳號也可用)++### 4.1 QR 配對(同一個帳號,2.36.0 起)QR/連結保留 `codync://pair` scheme,**移除 `token`**,欄位:@@@ -145,9 -147,9 +147,11 @@@ codync://pair?v=3&name=<pct>&id=<comput2. 手機載入/建立 device key,用 §7.5 的連線策略連線,hello 帶 `"pair": true`(中繼另需 URL `pair=<offerId>`)。3. 握手成功(手機已用 QR 的 `sk` 驗證 host)後,第一個 request 必須是:```json-- {"id":1,"m":"pair","b":{"code":"<code>","name":"Kevin's iPhone","platform":"ios"}}++ {"id":1,"m":"pair","b":{"code":"<code>","name":"Kevin's iPhone","platform":"ios",++ "certificate":{"payload":"…","sig":"…"},"claim":{"claimId":"clm_…","nonce":"…"}}}```--4. host 驗 code(常數時間比較、未過期、未用過)→ 刪除該 code → 新增裝置列(`source=local`,`grant_id=NULL`,`scopes=["control","screen"]`,無 lease)→ 回 `{"id":1,"ok":{"computerId":"…","name":"…"}}` → **關閉這條 channel,close code `4100 paired`**(中繼:host 依序送 `data`(回應)→ `close {link, code:4100}` → 新 ACL(移除 offer、加入 dk);同一條 host socket 保序,所以回應一定先到)。++ `certificate` 是雲端簽的裝置憑證(`POST /v1/devices/certificate`,payload `{v:1, deviceKey, userId, email, exp}`,簽 `"codync/device-cert/v1\n" + payload`,host 用編譯進去的公鑰離線驗證,`host/src/remote/certificate.rs`)。`claim` 是手機先向雲端要的 claim(`POST /v1/claims`),選填。++4. host 先驗憑證與帳號,再花掉 code([require sign-in](../plans/require-sign-in.md#phase-2-same-account-pairing)):沒有憑證 → `reject unsupportedVersion`;憑證不是這把 device key 的 → 403;電腦在別的帳號 → 403,訊息帶 owner 遮罩過的 email;電腦在手機的帳號 → 直接放行;電腦不在任何帳號 → 在電腦上問(loopback 的 `pairingRequests` 事件/方法、`decidePairing`,最多 2 分鐘,兩邊顯示同一組 6 位數 `sha256("codync/pair-check/v1" ‖ dk ‖ hostSignKey)`),同意後 host 簽手機的 claim,回應帶 `claim`,手機自己 `POST /v1/claims/{id}/complete`。接著驗 code(常數時間比較、未過期、未用過)→ 刪除該 code → 新增裝置列(`source=local`,`grant_id=NULL`,`account=<userId>`,`scopes=["control","screen"]`,無 lease)→ 回 `{"id":1,"ok":{"computerId":"…","name":"…","claim":{…}|null}}` → **關閉這條 channel,close code `4100 paired`**(中繼:host 依序送 `data`(回應)→ `close {link, code:4100}` → 新 ACL(移除 offer、加入 dk);同一條 host socket 保序,所以回應一定先到)。5. client 收到 `4100` 立即以一般模式重連(§7.5,不帶 `pair`)。直連與中繼行為相同;DO 不需要「升級」pairing socket。`Caller::Pairing` 的 channel 只接受 `pair`:第一個 inner 訊息不是 `pair`、或 `pair` 之後還有任何訊息 → 關閉 `4002 protocolError`。@@@ -489,6 -491,6 +493,8 @@@ The route table below summarizes the co**Clerk(使用者)**- `GET /v1/me` → `{"userId","email","createdAt"}`- `POST /v1/devices`(Clerk + Sig(dev))`{"name","platform":"ios"|"macos"|"linux"|"windows"}` → `{"device":{"deviceId","deviceKey","name","platform","createdAt"}}`。以 `(owner, sign_pub)` upsert;已撤銷的同一把 key → `403 forbidden`(需換 key)。++- `POST /v1/devices/certificate`(Clerk + Sig(dev))→ `{"certificate":{"payload","sig"}}`:證明這把已註冊、未撤銷的 device key 屬於這個帳號,7 天有效(§4.1)。雲端沒設 `DEVICE_CERT_KEY` → `503 notConfigured`。++- `POST /v1/host/pairing-codes`(Sig(host))`{"link","expiresAt"}` → `{"code":"QRTX-4821","expiresAt"}`;`GET /v1/pairing-codes/{code}`(Clerk)→ `{"link"}`,只能用一次、10 分鐘。`codync-host pair` 的短代碼。- `GET /v1/devices` → `{"devices":[{"deviceId","deviceKey","name","platform","createdAt","lastUsedAt","revoked":bool}]}`- `DELETE /v1/devices/{deviceId}` → `{}`;撤銷裝置與其所有 grants(`deviceRevoked`),對相關 computers 呼叫 DO `/internal/block` + `cloud.changed`。- `POST /v1/claims` → `{"claimId","nonce","expiresAt"}`(nonce = 16 random bytes b64url)diff --cc host/src/api/remote.rsindex baaeaf68,ecc4f787..e8ad8443--- a/host/src/api/remote.rs+++ b/host/src/api/remote.rs@@@ -79,22 -79,10 +79,16 @@@ pub(super) async fn call(hub: &Arc<Hub>.collect();json!({"devices": devices})}- "revokeDevice" => {- let key = str_arg(&b, "key")?;- let device = hub.store.device(key).ok_or_else(|| anyhow!("unknown device"))?;- hub.revoke_device(key)?;- if let Some(grant) = device.grant_id.filter(|_| device.source == DeviceSource::Account) {- tokio::spawn(crate::remote::cloud::revoke_grant(hub.clone(), grant));- }- json!({})- }+ "revokeDevice" => revoke(hub, str_arg(&b, "key")?)?,+ // A device leaving on its own (signing out): the same as revoking it at the computer.+ "forgetDevice" => revoke(hub, caller.device_key())?,"accessRequests" => json!({"requests": hub.cloud.requests_json()}),+ "pairingRequests" => json!({"requests": hub.pairing_requests.json()}),+ "decidePairing" => {+ let approve = b["approve"].as_bool().ok_or_else(|| anyhow!("`approve` is required"))?;+ crate::remote::pairing_requests::decide(hub, str_arg(&b, "requestId")?, approve)?;+ json!({})+ }"decideAccessRequest" => {let approve = b["approve"].as_bool().ok_or_else(|| anyhow!("`approve` is required"))?;let id = str_arg(&b, "requestId")?;@@@ -132,8 -120,18 +126,18 @@@}))}+ /// Removes a device, and its cloud grant when it was approved through the account.+ fn revoke(hub: &Arc<Hub>, key: &str) -> Result<Value> {+ let device = hub.store.device(key).ok_or_else(|| anyhow!("unknown device"))?;+ hub.revoke_device(key)?;+ if let Some(grant) = device.grant_id.filter(|_| device.source == DeviceSource::Account) {+ tokio::spawn(crate::remote::cloud::revoke_grant(hub.clone(), grant));+ }+ Ok(json!({}))+ }+/// A new one-time pairing code and the QR that carries it (§4.1).-async fn pairing(hub: &Arc<Hub>) -> Result<Value> {+async fn pairing(hub: &Arc<Hub>, short_code: bool) -> Result<Value> {let port = hub.port;// Shells out to `tailscale`: keep it off the async workers.let urls = tokio::task::spawn_blocking(move || crate::service::addresses(port)).await?;@@@ -190,3 -179,41 +194,42 @@@ pub(crate) async fn claim_sign(hub: &Ar"sig": crypto::b64(&hub.identity.sign(input.as_bytes())),}))}++ #[cfg(test)]+ mod tests {+ #![allow(clippy::unwrap_used)]+ use super::*;+ use crate::remote::identity::Identity;+ use crate::store::{Device, Scope, Store};++ #[tokio::test]+ async fn a_device_forgets_only_itself() {+ let dir = std::env::temp_dir().join(format!("codync-forget-{}", uuid::Uuid::new_v4()));+ std::fs::create_dir_all(&dir).unwrap();+ let store = Store::open(&dir.join("t.db")).unwrap();+ let hub = Hub::new(store, "test".into(), Identity::load_or_create(&dir).unwrap(), "token".into(), 0);+ let phone = Device {+ key: "me".into(),+ name: "Phone".into(),+ platform: "ios".into(),+ source: DeviceSource::Local,+ grant_id: None,+ scopes: vec![Scope::Control, Scope::Screen],+ lease_until: None,+ created_at: 1,+ last_seen_at: None,++ account: None,+ };+ hub.store.put_device(&phone).unwrap();+ hub.store.put_device(&Device { key: "other".into(), ..phone.clone() }).unwrap();+ hub.store.add_push_ticket("t1", "me", None, None, "Phone").unwrap();+ let me = Caller::Device { key: "me".into(), scopes: phone.scopes.clone() };++ assert!(call(&hub, &me, "forgetDevice", json!({"key": "other"})).await.unwrap().is_break());+ assert!(hub.store.device("me").is_none());+ assert!(hub.store.device("other").is_some(), "only the caller's own device goes");+ assert!(hub.store.push_tickets().is_empty());+ assert!(call(&hub, &me, "forgetDevice", json!({})).await.is_err(), "already gone");+ let _ = std::fs::remove_dir_all(dir);+ }+ }diff --cc web/content/docs/linux-servers.mdxindex 7f663da7,4a81c8e0..79432189--- a/web/content/docs/linux-servers.mdx+++ b/web/content/docs/linux-servers.mdx@@@ -42,7 -42,7 +42,7 @@@ codync-host statu## Pair your phone- With the host running, run `codync-host pair` over SSH. It prints a QR code in your terminal. On the iPhone, scan it from the welcome screen or later from **Manage computers → Pair a computer** (tap the connection status at the top of the Bots tab, such as **1 connected**). If scanning a terminal QR code is awkward, run `codync-host pair --json` and paste the `codync://pair` link into the field under the scanner.-With the host running, run `codync-host pair` over SSH. It prints a QR code in your terminal. On the iPhone, signed in, scan it from the welcome screen or later from **Manage computers → Pair a computer** (tap the connection status at the top of the Bots tab, such as **1 connected**). If scanning a terminal QR code is awkward, run `codync-host pair --json` and paste the `codync://pair` link into the field under the scanner.++With the host running, run `codync-host pair` over SSH. It prints a QR code and a short code like `QRTX-4821`. On the iPhone, signed in, scan the QR code from the welcome screen or later from **Manage computers → Pair a computer** (tap the connection status at the top of the Bots tab, such as **1 connected**), or type the short code into the field under the scanner. A server that isn't in an account yet asks in the terminal whether to let the phone in and join your account: check the phone shows the same 6-digit code, then answer `y`. `codync-host cloud` says which account the server is in.The code works once and expires after 10 minutes. More about pairing and accounts: [Remote access](/docs/remote-access).@@@ -61,6 -61,6 +61,8 @@@ CODYNC_TOKEN=$(ssh your-server 'cat ~/.The desktop app on macOS, Linux or Windows can run the server's bots alongside its own. Open **Settings → Computers**, and under **Over SSH** choose **Add SSH computer**. Fill in the host (an SSH alias or hostname) and, if your SSH config doesn't already set them, the user, port and key. Sign-in must work with a key or ssh-agent: nothing prompts for a password. On the first connection, compare the host key fingerprint with the server's, then choose **Trust and connect**.++If the server doesn't have the host yet, choose **Install** on its card: the app installs `codync-host` over SSH and connects, then adds the server to your Codync account. Where the server doesn't let your user keep services running after logging out, the card shows the one `sudo loginctl enable-linger "$USER"` command to run there.++From that computer's card you can also show its pairing code, turn the relay on or off, and choose **Add to account** to put the server in your Codync account.On Windows, enable **OpenSSH Client** in **Windows Settings → Optional features** if it is missing. Codync uses the Windows SSH config, keys and agent; keys stay on that computer.diff --cc web/content/docs/remote-access.mdxindex b1ed1e1e,cde89f99..c3a99e30--- a/web/content/docs/remote-access.mdx+++ b/web/content/docs/remote-access.mdx@@@ -26,13 -26,13 +26,21 @@@ Show the code on the computer- **Terminal:** run `codync-host pair`. It prints the QR code in the terminal. `codync-host pair --json` prints the link instead.- **Terminal UI:** press `^k` and choose **Pair a phone…**.--Then, on the iPhone, scan it from the welcome screen, or later from **Manage computers → Pair a computer** (tap the connection status at the top of the Bots tab, such as **1 connected**). You can also paste the `codync://pair` link instead of scanning.++Then, on the iPhone, scan it from the welcome screen, or later from **Manage computers → Pair a computer** (tap the connection status at the top of the Bots tab, such as **1 connected**). You can also paste the `codync://pair` link instead of scanning, or type the short code `codync-host pair` prints, like `QRTX-4821`.- A code works once and expires after 10 minutes. If it has expired, show a new one on the computer. Pairing needs no account and works over any route, including the relay.+ A code works once and expires after 10 minutes. If it has expired, show a new one on the computer. Pairing works over any route, including the relay.- ## Signing in (optional)++Pairing checks your account, so a phone and a computer pair only when they're in the same Codync account:+- You can sign in with Apple or Google on the iPhone and in the desktop app. Signing in doesn't give any device access by itself. It lets your phone find the computers in your account without scanning a code:++- **The computer is in your account:** the phone is let in right away.++- **The computer is in someone else's account:** the phone says whose (for example *k•••@example.com*). Move the computer to your account on that computer, or sign in to that account.++- **The computer isn't in an account yet:** the computer asks first. The desktop app asks whether to let the phone in, and the terminal UI and `codync-host pair` ask you to answer `y`. Check that the phone shows the same 6-digit code, then let it in. The computer joins your account.++++Changing the account a computer belongs to (moving it, or **Remove from account**) takes away access from every device of the old account. A computer joining its first account keeps the phones that were already paired.+++ ## Signing in++ The iPhone, Android and desktop apps ask you to sign in with Apple or Google before you use them. Signing in doesn't give any device access by itself. It lets your phone find the computers in your account without scanning a code:1. On the computer, sign in to the desktop app. The computer joins your account. For an SSH computer, choose **Add to account** on its card in **Settings → Computers**.2. On the iPhone, sign in with the same account and open **Manage computers**. Your account's computers are listed there. Tap **Ask for access**. The phone shows a 6-digit code.