diff --git a/docs/plan.md b/docs/plan.md index a9f26fe..e3b9d46 100644 --- a/docs/plan.md +++ b/docs/plan.md @@ -200,4 +200,6 @@ they push to `docs/`. hosts). - CI deploys right away through a `wristcode` entry in `~/Server/ci-deploy.sh`, with Watchtower's nightly pull as the fallback. -- The bundle ID is `org.gbrown.wristcode`. +- The App Store record uses `org.gbrown.wristcode`, an empty iOS wrapper the App Store requires + around a watch-only app. The watch app itself is `org.gbrown.wristcode.watchkitapp`, which is also + its APNs topic. diff --git a/gateway/src/apns.ts b/gateway/src/apns.ts index 0871ff4..297a75f 100644 --- a/gateway/src/apns.ts +++ b/gateway/src/apns.ts @@ -9,7 +9,7 @@ export interface ApnsConfig { teamId: string; /** The .p8 key's PEM text. */ key: string; - /** The app's bundle ID. */ + /** The watch app's bundle ID, which is its APNs topic. */ topic: string; } diff --git a/gateway/src/config.ts b/gateway/src/config.ts index dbc6ace..94f4c93 100644 --- a/gateway/src/config.ts +++ b/gateway/src/config.ts @@ -20,7 +20,7 @@ export function loadConfig(env = process.env): Config { dbPath: env.WRISTCODE_DB ?? "data/wristcode.sqlite", apns: keyId && teamId && key - ? { keyId, teamId, key: key.replace(/\\n/g, "\n"), topic: env.APNS_TOPIC ?? "org.gbrown.wristcode" } + ? { keyId, teamId, key: key.replace(/\\n/g, "\n"), topic: env.APNS_TOPIC ?? "org.gbrown.wristcode.watchkitapp" } : null, }; }