[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7DKZX7FQCQYRE0356VKY6C4":3,"skill-same:01M7DKZX7FQCQYRE0356VKY6C4":45},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":14,"repositoryHtmlUrl":27,"repositoryHomepageUrl":6,"ownerHtmlUrl":28,"ownerBlogUrl":6,"ownerDescription":29,"updatedAt":30,"install":31,"resources":44},"01M7DKZX7FQCQYRE0356VKY6C4","recipe-social-auth",null,"Add Sign in with Apple and Google sign-in to an App in a Box app (Supabase Auth, native ID-token flow, no web redirect). Use when the prototype works on email codes and the owner is preparing a TestFlight \u002F store build, or asks for \"social login\", \"Apple sign in\", \"Google sign in\". Covers provider setup, the mobile wiring, EAS env vars, tests and the done-means check.","foxinthehenhouse\u002Fapp-in-a-box","foxinthehenhouse","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F144333692?v=4","01M7DKXRK1CCGY9F45FYGWVD29","Kyle Fox","01M7DKXRKNG8A1ADJFXVH15RXT",0,"MIT","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Fskills\u002Frecipe-social-auth\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: recipe-social-auth\ndescription: Add Sign in with Apple and Google sign-in to an App in a Box app (Supabase Auth, native ID-token flow, no web redirect). Use when the prototype works on email codes and the owner is preparing a TestFlight \u002F store build, or asks for \"social login\", \"Apple sign in\", \"Google sign in\". Covers provider setup, the mobile wiring, EAS env vars, tests and the done-means check.\n---\n\n# Recipe: Apple + Google sign-in\n\n`$KIT` is the plugin root: `appbox.yaml` → `kit_root` if present, else\n`${CLAUDE_PLUGIN_ROOT}` (Claude Code) or the folder two levels above this file (Codex \u002F\npasted prompt).\n\nEmail one-time codes ship first (zero setup). Add social sign-in before the first\nstore build. **Apple requires Sign in with Apple on iOS if you offer any other social\nlogin** (App Review guideline 4.8), so do both or neither. Source doc:\n`$KIT\u002Fdocs\u002FSOCIAL_AUTH.md`.\n\nNo backend change: the API already verifies any Supabase session JWT\n(`backend\u002Fauth.py`), whichever provider issued it.\n\n## When to use\n\n- The core loop works end to end with email sign-in, and\n- you're about to cut a preview\u002Fproduction build (social sign-in can't be tested in\n  Expo Go; it needs a development or preview build).\n\n## Steps\n\n### Apple (iOS)\n\n1. **(owner)** Apple Developer → Identifiers → the app's bundle id → enable\n   **Sign in with Apple**.\n2. **(owner)** Supabase → Authentication → Providers → Apple: enable; add the bundle id\n   under **Client IDs**. The native flow needs no secret key.\n3. `cd mobile && npx expo install expo-apple-authentication expo-crypto`\n4. `mobile\u002Fapp.json`: `\"ios\": { \"usesAppleSignIn\": true }` and add\n   `\"expo-apple-authentication\"` to `plugins`.\n5. In `mobile\u002Flib\u002Fauth.tsx`, add `signInWithApple()`:\n   - `const nonce = Crypto.randomUUID()`; hash it with `Crypto.digestStringAsync(SHA256, nonce)`\n   - `AppleAuthentication.signInAsync({ requestedScopes: [FULL_NAME, EMAIL], nonce: hashed })`\n   - `supabase.auth.signInWithIdToken({ provider: \"apple\", token: credential.identityToken, nonce })`\n   - Apple returns the name **only on the first sign-in**: if `credential.fullName`\n     is present, `PATCH \u002Fapi\u002Fv1\u002Fme` with `displayName` right away.\n   - Treat `ERR_REQUEST_CANCELED` as a cancel, not an error.\n6. Render `AppleAuthentication.AppleAuthenticationButton` (Apple's HIG requires their\n   button) only when `AppleAuthentication.isAvailableAsync()` is true.\n\n### Google (iOS + Android)\n\n1. **(owner)** Google Cloud console: OAuth consent screen, then create a **Web** client\n   and an **iOS** client (bundle id), plus an **Android** client (package name + the\n   SHA-1 from `eas credentials`).\n2. **(owner)** Supabase → Providers → Google: enable; add the Web + iOS client ids to\n   Client IDs; tick **Skip nonce check** (the native iOS SDK doesn't pass one through).\n3. `cd mobile && npx expo install @react-native-google-signin\u002Fgoogle-signin`\n4. `mobile\u002Fapp.json` plugins:\n   `[\"@react-native-google-signin\u002Fgoogle-signin\", { \"iosUrlScheme\": \"com.googleusercontent.apps.\u003Creversed-ios-client-id>\" }]`\n5. `GoogleSignin.configure({ webClientId: process.env.EXPO_PUBLIC_GOOGLE_WEB_CLIENT_ID, iosClientId: process.env.EXPO_PUBLIC_GOOGLE_IOS_CLIENT_ID })`\n   → `GoogleSignin.signIn()` → `supabase.auth.signInWithIdToken({ provider: \"google\", token: idToken })`.\n6. If either env var is empty, **hide the button and log once**; never render a button\n   that silently does nothing (a real app shipped exactly that).\n\n### Both\n\n- Analytics: `signInStarted({ method })`, `signInSucceeded({ method })`,\n  `signInFailed({ method, error_code })` (success AND failure, per the analytics rule).\n- Accessibility: labels \"Continue with Apple\" \u002F \"Continue with Google\", 48px targets.\n- Account deletion (`DELETE \u002Fapi\u002Fv1\u002Fme`) must be reachable in-app. For Apple, App\n  Review also expects you to revoke the Apple token on deletion when you store refresh\n  tokens; with the ID-token-only flow above you store none, so note that in review notes.\n\n## Env \u002F wiring checklist\n\n| Where | What |\n|---|---|\n| EAS (preview + production) | `eas env:create --name EXPO_PUBLIC_GOOGLE_WEB_CLIENT_ID --value \u003Cid> --environment preview --environment production --visibility plaintext`, same for `EXPO_PUBLIC_GOOGLE_IOS_CLIENT_ID` |\n| `mobile\u002Fscripts\u002Fcheck-eas-shipping-env.js` | add both to `EAS_MANAGED` (the guard fails the build otherwise) |\n| Railway \u002F FEATURE_CONFIG | nothing: the backend doesn't see provider config |\n| Supabase | providers enabled; redirect URLs untouched (native flow) |\n\n## Tests to add\n\n- `mobile\u002Flib\u002F__tests__\u002Fauth.test.ts`: mock `signInWithIdToken`; Apple cancel returns\n  quietly; Apple first sign-in with a name PATCHes `\u002Fapi\u002Fv1\u002Fme`; missing Google env\n  hides the button (render test) instead of rendering a dead one.\n- Maestro: a flow that asserts both buttons are visible on the sign-in screen of a\n  preview build (the sign-in itself needs a real account; do it by hand once).\n\n## Done means\n\n- [ ] On a preview build, a fresh Apple ID and a fresh Google account each sign in, land\n      in the app, and `GET \u002Fapi\u002Fv1\u002Fme` returns their own id.\n- [ ] `node mobile\u002Fscripts\u002Fcheck-eas-shipping-env.js` passes and lists both vars.\n- [ ] PostHog shows `sign_in_succeeded` with `method=apple` and `method=google`.\n- [ ] Deleting either account from the in-app settings returns 204 and signs out.\n","# Recipe: Apple + Google sign-in\n\n`$KIT` is the plugin root: `appbox.yaml` → `kit_root` if present, else\n`${CLAUDE_PLUGIN_ROOT}` (Claude Code) or the folder two levels above this file (Codex \u002F\npasted prompt).\n\nEmail one-time codes ship first (zero setup). Add social sign-in before the first\nstore build. **Apple requires Sign in with Apple on iOS if you offer any other social\nlogin** (App Review guideline 4.8), so do both or neither. Source doc:\n`$KIT\u002Fdocs\u002FSOCIAL_AUTH.md`.\n\nNo backend change: the API already verifies any Supabase session JWT\n(`backend\u002Fauth.py`), whichever provider issued it.\n\n## When to use\n\n- The core loop works end to end with email sign-in, and\n- you're about to cut a preview\u002Fproduction build (social sign-in can't be tested in\n  Expo Go; it needs a development or preview build).\n\n## Steps\n\n### Apple (iOS)\n\n1. **(owner)** Apple Developer → Identifiers → the app's bundle id → enable\n   **Sign in with Apple**.\n2. **(owner)** Supabase → Authentication → Providers → Apple: enable; add the bundle id\n   under **Client IDs**. The native flow needs no secret key.\n3. `cd mobile && npx expo install expo-apple-authentication expo-crypto`\n4. `mobile\u002Fapp.json`: `\"ios\": { \"usesAppleSignIn\": true }` and add\n   `\"expo-apple-authentication\"` to `plugins`.\n5. In `mobile\u002Flib\u002Fauth.tsx`, add `signInWithApple()`:\n   - `const nonce = Crypto.randomUUID()`; hash it with `Crypto.digestStringAsync(SHA256, nonce)`\n   - `AppleAuthentication.signInAsync({ requestedScopes: [FULL_NAME, EMAIL], nonce: hashed })`\n   - `supabase.auth.signInWithIdToken({ provider: \"apple\", token: credential.identityToken, nonce })`\n   - Apple returns the name **only on the first sign-in**: if `credential.fullName`\n     is present, `PATCH \u002Fapi\u002Fv1\u002Fme` with `displayName` right away.\n   - Treat `ERR_REQUEST_CANCELED` as a cancel, not an error.\n6. Render `AppleAuthentication.AppleAuthenticationButton` (Apple's HIG requires their\n   button) only when `AppleAuthentication.isAvailableAsync()` is true.\n\n### Google (iOS + Android)\n\n1. **(owner)** Google Cloud console: OAuth consent screen, then create a **Web** client\n   and an **iOS** client (bundle id), plus an **Android** client (package name + the\n   SHA-1 from `eas credentials`).\n2. **(owner)** Supabase → Providers → Google: enable; add the Web + iOS client ids to\n   Client IDs; tick **Skip nonce check** (the native iOS SDK doesn't pass one through).\n3. `cd mobile && npx expo install @react-native-google-signin\u002Fgoogle-signin`\n4. `mobile\u002Fapp.json` plugins:\n   `[\"@react-native-google-signin\u002Fgoogle-signin\", { \"iosUrlScheme\": \"com.googleusercontent.apps.\u003Creversed-ios-client-id>\" }]`\n5. `GoogleSignin.configure({ webClientId: process.env.EXPO_PUBLIC_GOOGLE_WEB_CLIENT_ID, iosClientId: process.env.EXPO_PUBLIC_GOOGLE_IOS_CLIENT_ID })`\n   → `GoogleSignin.signIn()` → `supabase.auth.signInWithIdToken({ provider: \"google\", token: idToken })`.\n6. If either env var is empty, **hide the button and log once**; never render a button\n   that silently does nothing (a real app shipped exactly that).\n\n### Both\n\n- Analytics: `signInStarted({ method })`, `signInSucceeded({ method })`,\n  `signInFailed({ method, error_code })` (success AND failure, per the analytics rule).\n- Accessibility: labels \"Continue with Apple\" \u002F \"Continue with Google\", 48px targets.\n- Account deletion (`DELETE \u002Fapi\u002Fv1\u002Fme`) must be reachable in-app. For Apple, App\n  Review also expects you to revoke the Apple token on deletion when you store refresh\n  tokens; with the ID-token-only flow above you store none, so note that in review notes.\n\n## Env \u002F wiring checklist\n\n| Where | What |\n|---|---|\n| EAS (preview + production) | `eas env:create --name EXPO_PUBLIC_GOOGLE_WEB_CLIENT_ID --value \u003Cid> --environment preview --environment production --visibility plaintext`, same for `EXPO_PUBLIC_GOOGLE_IOS_CLIENT_ID` |\n| `mobile\u002Fscripts\u002Fcheck-eas-shipping-env.js` | add both to `EAS_MANAGED` (the guard fails the build otherwise) |\n| Railway \u002F FEATURE_CONFIG | nothing: the backend doesn't see provider config |\n| Supabase | providers enabled; redirect URLs untouched (native flow) |\n\n## Tests to add\n\n- `mobile\u002Flib\u002F__tests__\u002Fauth.test.ts`: mock `signInWithIdToken`; Apple cancel returns\n  quietly; Apple first sign-in with a name PATCHes `\u002Fapi\u002Fv1\u002Fme`; missing Google env\n  hides the button (render test) instead of rendering a dead one.\n- Maestro: a flow that asserts both buttons are visible on the sign-in screen of a\n  preview build (the sign-in itself needs a real account; do it by hand once).\n\n## Done means\n\n- [ ] On a preview build, a fresh Apple ID and a fresh Google account each sign in, land\n      in the app, and `GET \u002Fapi\u002Fv1\u002Fme` returns their own id.\n- [ ] `node mobile\u002Fscripts\u002Fcheck-eas-shipping-env.js` passes and lists both vars.\n- [ ] PostHog shows `sign_in_succeeded` with `method=apple` and `method=google`.\n- [ ] Deleting either account from the in-app settings returns 204 and signs out.\n",{"name":5,"description":7},"main","82b5819f074e18b5d31db7a122e1f0ae5f5abbf7","plugins\u002Fapp-in-a-box\u002Fskills\u002Frecipe-social-auth","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse","Not a developer","2026-10-06 17:24:46",{"source":8,"skillName":5,"commands":32,"prompt":42,"zipAvailable":43},[33,36,39],{"tool":34,"command":35},"npx","npx skills add foxinthehenhouse\u002Fapp-in-a-box --skill recipe-social-auth",{"tool":37,"command":38},"bunx","bunx skills add foxinthehenhouse\u002Fapp-in-a-box --skill recipe-social-auth",{"tool":40,"command":41},"pnpm","pnpm dlx skills add foxinthehenhouse\u002Fapp-in-a-box --skill recipe-social-auth","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Fskills\u002Frecipe-social-auth\u002FSKILL.md",true,[],[46,53,60,67,74,81],{"skillNo":47,"name":48,"nameZh":6,"description":49,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":50,"categories":51,"keywords":52,"publishedAt":19},"01M7DM2EPAFBTFNV5EW5GHKD5Q","ship","Release checklist for getting a build to testers or the stores. Runs the risk gate first (refuses while a risk item is open) and walks the owner through the compliance checklist. Covers the version bump, EAS build and submit, OTA updates and when they're safe, changelog, store listing, privacy nutrition label \u002F data safety form, the Accessibility Nutrition Labels, and the account-deletion requirement. Guidance-level; it never handles signing secrets. Use when asked to ship, release, submit to TestFlight \u002F App Store \u002F Play, or push an OTA update.","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Fship\u002FSKILL.md",[],[],{"skillNo":54,"name":55,"nameZh":6,"description":56,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":57,"categories":58,"keywords":59,"publishedAt":19},"01M7DM2AGRJ822B3C8NQCDK3JG","routines","Put the project's recurring rituals on a schedule, with the owner's consent. Weekly north-star report, monthly market watch, dependency triage, Supabase advisor sweep, reflect and harness-optimize. Uses Claude Code Routines (cloud cron) where they fit, and documents the Codex \u002F local cron equivalent. Use when asked to automate, schedule or \"keep the project moving on its own\", or after setup finishes.","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Froutines\u002FSKILL.md",[],[],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":19},"01M7DM27C3K1Y7FM0NZSBRSVEN","reflect","Consolidate what recent sessions learned into the project's long-term memory (.agents\u002Fmemory). Use at the end of a substantial session, after a correction from the user, after a painful debugging session, when the session-start healthcheck says reflect is overdue or a pending-reflection seed is waiting, or when MEMORY.md exceeds its budget.","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Freflect\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":19},"01M7DM2146TCNYXVVS2QXF08GS","pr-review","Review a pull request on the owner's behalf and fix what's safe to fix. Runs the deterministic gates first, then correctness\u002Fsecurity, design-system, accessibility and analytics review passes, verifies each blocking finding, applies safe fixes, re-checks, and ends with a plain-English verdict. Use when a PR is opened, when asked to review a PR, a branch or a pasted diff, or before merging anything.","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Fpr-review\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":19},"01M7DM1X6QP3QAT47ET852S0P8","north-star-report","Weekly product-analytics and reliability readout. Pulls the funnel of the brief's 5 north-star events from PostHog, finds the biggest drop-offs and errors, checks each SLO in docs\u002Fslo.yaml against its error budget, compares with last week, and proposes (then, with a yes, files) tickets that target them. Use weekly, when the session-start line says it's overdue, when the backlog is empty, or when asked \"how is the app doing?\".","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Fnorth-star-report\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M7DM1QX8F3D95JSTEHC0P9QA","next","Decide the single next best thing to work on, with two alternates. Reads setup progress, work in progress, open PRs and failing CI, the backlog (GitHub Issues or Linear), overdue harness rituals, product decisions parked until now, and north-star analytics if PostHog is connected. Use when someone asks \"what next?\", \"what should I work on?\", at the start of a session, or after a PR merges.","https:\u002F\u002Fgithub.com\u002Ffoxinthehenhouse\u002Fapp-in-a-box\u002Fblob\u002Fmain\u002Fplugins\u002Fapp-in-a-box\u002Ftemplate\u002F.agents\u002Fskills\u002Fnext\u002FSKILL.md",[],[]]