@rubytech/create-maxy-code 0.1.467 → 0.1.468
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.
package/package.json
CHANGED
|
@@ -1,6 +1,25 @@
|
|
|
1
1
|
# Google Auth Reference
|
|
2
2
|
|
|
3
|
-
## Status: Phase 0
|
|
3
|
+
## Status: Phase 0 gate CLOSED — token-verified 2026-07-18
|
|
4
|
+
|
|
5
|
+
The round-trip was run against the live `sitedesk-code` client and succeeded. Recorded
|
|
6
|
+
outcome (values themselves deliberately not recorded):
|
|
7
|
+
|
|
8
|
+
| Check | Result |
|
|
9
|
+
|---|---|
|
|
10
|
+
| Calendar scope granted via browser consent | **yes** — `scope=https://www.googleapis.com/auth/calendar` returned on the redirect and echoed in the token response |
|
|
11
|
+
| Refresh token issued (`access_type=offline`, `prompt=consent`) | **yes** — `refresh_token` present |
|
|
12
|
+
| Access-token lifetime | `expires_in: 3599` (1 hour) |
|
|
13
|
+
| Refresh-token lifetime in **Testing** | `refresh_token_expires_in: 604799` — **6.99 days**, confirming the predicted 7-day Testing cap empirically |
|
|
14
|
+
| Device-code refusal (Verdict 1) | not run empirically; rests on Google's published allowlist. Optional, changes no decision (see the live-test section) |
|
|
15
|
+
|
|
16
|
+
The 604799 figure is the concrete argument for completing brand verification: in Testing,
|
|
17
|
+
every connected account silently re-consents weekly. Verification removes it.
|
|
18
|
+
|
|
19
|
+
Phases 1–2 may now proceed against the flow below, with one caveat: the client-secret
|
|
20
|
+
storage location is an **open Phase 1 decision** (see "Open Phase 1 decision" below).
|
|
21
|
+
|
|
22
|
+
## Original spike verdict (documentation-backed, now confirmed)
|
|
4
23
|
|
|
5
24
|
This is the Phase 0 deliverable: the OAuth-flow verdict for a per-account
|
|
6
25
|
**Google Calendar** plugin on a headless install where the operator consents from a phone
|
|
@@ -184,12 +203,32 @@ on that brand, exactly as `outlookClientId` does. The client id ships as the bra
|
|
|
184
203
|
`GOOGLE_CLIENT_ID` and inherited down the spawn chain (manager unit env → PTY → MCP child).
|
|
185
204
|
|
|
186
205
|
Divergence from Outlook: the recommended Web-application flow (Option B) also needs a
|
|
187
|
-
**client secret
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
206
|
+
**client secret**, and where that secret lives is an **open Phase 1 decision**, not a
|
|
207
|
+
settled one. A brand that ships `googleClientId` empty has the plugin inert with an
|
|
208
|
+
actionable signal (`clientIdConfigured=false`), register refuses, and no operator action
|
|
209
|
+
makes it work until the vendor client exists — mirroring Outlook's inert behaviour.
|
|
210
|
+
|
|
211
|
+
### Open Phase 1 decision: there is no brand-level secret store
|
|
212
|
+
|
|
213
|
+
An earlier draft of this file said the secret is "held in the brand's secret store, the same
|
|
214
|
+
way Cloudflare tokens are held". That was wrong, and Phase 1 must resolve it before the
|
|
215
|
+
register path is built. The two stores that actually exist are:
|
|
216
|
+
|
|
217
|
+
- **`brands/<brand>/brand.json`** — ships inside the published npm package. It can carry the
|
|
218
|
+
client **id** (public, non-secret, exactly like `outlookClientId`) and must never carry a
|
|
219
|
+
secret.
|
|
220
|
+
- **`~/<brand>-code/data/accounts/<accountId>/secrets`** — where the Cloudflare master token
|
|
221
|
+
lives (`platform/plugins/cloudflare/references/api.md`). This is **account-scoped**, one
|
|
222
|
+
per install.
|
|
223
|
+
|
|
224
|
+
The mismatch: the Google client secret is **per-brand** (one vendor app serves every install
|
|
225
|
+
of that brand), but the only real secret store is **per-account**. Outlook never hit this
|
|
226
|
+
because its device-code flow is secret-less, so there is no precedent to copy. Phase 1 must
|
|
227
|
+
choose and record one of: replicate the brand secret into each install's account-scoped
|
|
228
|
+
secrets at provisioning time; introduce a genuine brand-scoped secret store; or drop to
|
|
229
|
+
Option A (Desktop client), whose installed-app secret Google documents as non-confidential
|
|
230
|
+
and which therefore needs no confidential store at all. Do not assume a brand secret store
|
|
231
|
+
exists — nothing implements one today.
|
|
193
232
|
|
|
194
233
|
---
|
|
195
234
|
|
|
@@ -211,8 +250,15 @@ follow-up once the plugin lands (mirroring Outlook 1479/1485).
|
|
|
211
250
|
- **Option B (recommended):** application type **Web application**. Add the authorized
|
|
212
251
|
redirect URI `https://<brand-public-host>/api/google/oauth/callback` (the `/api/`
|
|
213
252
|
prefix is required — see Option B above). Copy the **Client ID**
|
|
214
|
-
(→ `brand.json#googleClientId`)
|
|
215
|
-
|
|
253
|
+
(→ `brand.json#googleClientId`).
|
|
254
|
+
|
|
255
|
+
**The client secret is shown exactly once and cannot be retrieved afterwards.** The
|
|
256
|
+
console displays only the last four characters from then on ("Viewing and downloading
|
|
257
|
+
client secrets is no longer available. If you have lost the secret below, please add a
|
|
258
|
+
new one."). Capture it at creation into its final destination, or plan to rotate. It is
|
|
259
|
+
never pasted into a chat transcript, a shell command that lands in history, or the repo.
|
|
260
|
+
Rotation is free and has no downtime: **Add secret**, store the new one, delete the old.
|
|
261
|
+
Where it should finally live is an open Phase 1 decision — see above.
|
|
216
262
|
- **Option A (fallback):** application type **Desktop app**. Copy the **Client ID**.
|
|
217
263
|
5. Set `googleClientId` in the brand's `brand.json` and re-bundle:
|
|
218
264
|
```jsonc
|
|
@@ -338,8 +384,13 @@ met and Phases 1–2 (the plugin build) proceed against the confirmed flow.
|
|
|
338
384
|
|
|
339
385
|
| Brand | Client type | Redirect URI | Client ID | Status |
|
|
340
386
|
|---|---|---|---|---|
|
|
341
|
-
| `sitedesk-code` | Web application | `https://public.sitedesk.online/api/google/oauth/callback` | `1032860640027-p61l59fnog4mad5o7grginpaps9jnu8c.apps.googleusercontent.com` | Testing —
|
|
387
|
+
| `sitedesk-code` | Web application | `https://public.sitedesk.online/api/google/oauth/callback` | `1032860640027-p61l59fnog4mad5o7grginpaps9jnu8c.apps.googleusercontent.com` | **Testing** — round-trip verified 2026-07-18; brand verification not started; secret pending rotation into its Phase 1 home |
|
|
342
388
|
|
|
343
389
|
The public host was confirmed live and routing to the `platform/ui` server (it serves the
|
|
344
|
-
brand's public page).
|
|
345
|
-
|
|
390
|
+
brand's public page). No secret or token is recorded here. The secret minted at creation was
|
|
391
|
+
exposed to shell history during the manual round-trip and should be rotated (**Add secret** →
|
|
392
|
+
store → delete old) when Phase 1 decides where it lives.
|
|
393
|
+
|
|
394
|
+
Per-brand next step for `sitedesk-code`: start **brand/consent-screen verification** to lift
|
|
395
|
+
the 100-test-user cap and the 7-day re-consent measured above. That review is the slow part;
|
|
396
|
+
everything else is minutes.
|