Логотип Shoo Auth

Shoo Auth

Сообщество
Firstp1ck
shoo-auth

Используйте этот навык для оценки, внедрения, проверки или отладки входа через Google с помощью Shoo auth (shoo.dev) в браузерных приложениях, в том числе с @shoojs/react, @shoojs/auth, размещённым shoo.js, пользовательской интеграцией JWT в Convex, обратными вызовами PKCE, проверками сессий и серверной проверкой id_token. Не используйте его для других систем аутентификации.

Обзор

ИздательFirstp1ck
Репозиторийpi-coding-agent-forge
Название навыкаshoo-auth
Звёзды
93
Форки
22
Файлы в комплекте
2
ЛицензияMIT
Ссылки
  • Инструкции в формате Markdown

    Модель загружает файл SKILL.md по мере необходимости, поэтому токены расходуются только при подходящем запросе.

  • Работает с любой большой языковой моделью

    Навыки ИИ — это обычный Markdown, а не код для конкретного поставщика, поэтому они работают с GPT, Claude, Gemini, Grok и локальными моделями.

  • Файлы в комплекте: 2

    Скрипты, шаблоны и справочные материалы, которые модель может читать во время работы. Файлы доступны только для чтения и никогда не выполняются.

  • Открытый исходный код

    Издатель навыка на GitHub — Firstp1ck. Перед установкой изучите исходные материалы.

Установка

Установите навык ИИ Shoo Auth в TypingMind, чтобы использовать его с любой LLM, или добавьте его в другой агент, который умеет читать SKILL.md.

1

Установка в TypingMind

TypingMind устанавливает навык прямо из его папки на GitHub: читает SKILL.md, собирает файлы ресурсов и сохраняет результат локально.

  1. Откройте приложение и перейдите в раздел «Плагины → Навыки».
  2. Выберите «Установить из GitHub».
  3. Вставьте указанную ниже ссылку на папку навыка и подтвердите установку.
    https://github.com/Firstp1ck/pi-coding-agent-forge/tree/main/pi-skill-shoo-auth/skills/shoo-auth
  4. Включите навык в каждом чате, где хотите его использовать.
Плагины → Навыки → Добавить навык → По ссылке GitHub, затем вставьте ссылку на папку и нажмите «Продолжить».
2

Установка в другом агенте

Любой агент с поддержкой формата Agent Skills может использовать этот навык — скопируйте папку в каталог навыков этого агента.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Firstp1ck/pi-coding-agent-forge.git /tmp/pi-coding-agent-forge
mkdir -p .claude/skills
cp -r /tmp/pi-coding-agent-forge/pi-skill-shoo-auth/skills/shoo-auth .claude/skills/shoo-auth
После копирования перезапустите Claude Code, чтобы загрузить новый навык.

Использование в TypingMind

Включите навык Shoo Auth в любом чате TypingMind, и дальше модель всё сделает сама. Его название и описание хранятся в системном промпте, а при появлении подходящего запроса модель сама загружает полные инструкции. Вам не нужно вызывать навык вручную, и до фактического использования он не расходует токены.

Модель сама загружает навык Shoo Auth, как только появляется подходящий для него запрос.

Работает с любой моделью ИИ

Навыки ИИ — это обычные инструкции в Markdown, а не код для конкретного поставщика, поэтому навык Shoo Auth не привязан к модели, для которой он был создан. Установите его один раз в TypingMind и используйте с GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama или локальной моделью, которую запускаете самостоятельно, — со своими ключами API.

  • Загружается только при необходимости

    Системный промпт содержит только название и описание. Инструкции загружаются при первом подходящем запросе, поэтому неиспользуемый навык не расходует токены.

  • Меняйте модели прямо в чате

    Навык состоит из инструкций, а не кода, поэтому смена модели не нарушает его работу: новая модель читает тот же файл SKILL.md.

Инструкции навыка

Это содержимое файла SKILL.md, которое загружает модель. Прочитайте его перед установкой: навык — это инструкции, которым будет следовать ваша модель.

Shoo Auth

Deterministic workflow for deciding when Shoo fits and for applying it safely. This draft is not enabled automatically.

Primary reference snapshot: references/shoo-docs-summary.md. Refresh the live Shoo docs before high-stakes or production decisions.

When to Use

Use this skill when the task mentions any of:

  • Shoo, shoo.dev, @shoojs/auth, @shoojs/react, window.Shoo, shoo.js, or pairwise_sub.
  • Adding minimal Google sign-in to a browser app without Google client registration.
  • Choosing between Shoo React, vanilla JS, framework-agnostic, hosted-script, or Convex integration.
  • Implementing or reviewing Shoo callback handling, PKCE flow, session/revocation checks, or server-side id_token verification.
  • Debugging Shoo audience, callback, storage, Convex JWT, or missing-PII issues.

Do not use this skill as the primary workflow for unrelated auth providers or generic OAuth/OIDC work, except to explicitly decide that Shoo is not a fit.

Do Not Use / Escalate

Do not recommend Shoo as the sole answer when requirements include:

  • Non-Google identity providers, passwords, enterprise SSO/SAML/SCIM, or rich hosted user management.
  • Server-only auth without a browser redirect flow.
  • Production authorization based only on browser-local identity, localStorage, or decoded-but-unverified JWT claims.
  • Security/compliance-critical auth where maturity, SLAs, audit evidence, or operational ownership must be established first.

When any of these apply, state the mismatch and either ask whether Shoo is still mandatory or recommend comparing established auth providers.

Inputs and Assumptions

Before changing code, determine these from the user or the project:

  • Frontend shape: React, Next.js, vanilla/static, Convex, or another browser client.
  • App origin for each environment, e.g. http://localhost:3000 and https://app.example.com.
  • Callback path and whether that path is served by the app/router.
  • Server/runtime that will verify Shoo id_tokens.
  • Whether PII (email, name, picture) is actually needed.
  • Package manager and existing auth/session conventions.

If these are missing and the repository is available, inspect manifests/routes before asking. If app origin or production verification path is unknown, ask; do not guess for production auth.

Fit Gate

Apply this gate before implementation:

  1. Identity provider: if Google-only sign-in is not acceptable, Shoo is not a fit.
  2. Client model: if the app cannot perform browser redirects and store callback state in browser storage, Shoo is likely not a fit.
  3. Identifier model: if an opaque per-origin stable ID is acceptable, use pairwise_sub/sub as the user key; if a global Google subject is required, Shoo is not a fit.
  4. PII minimization: default to no PII. Use requestPii: true only when the app genuinely needs email, name, or picture and the UI explains why.
  5. Production rule: production access control requires server verification of every Shoo id_token before trusting identity.
  6. Maturity rule: for business-critical auth, verify current docs/package status and explicitly surface adoption risk before recommending Shoo.

Workflow

1. Choose the integration path

Use the first matching path:

Project needUseNotes
React SPA or React client component@shoojs/react + useShooAuth()Primary path for React. SSR-safe hook initializes in browser.
Next.js App Router@shoojs/react plus a client callback pageAdd a page at the configured callback path so the redirect does not 404.
Convex + React@shoojs/react + createShooConvexAuth() + Convex customJwtAlso configure issuer/JWKS/ES256 and preferably audience/application ID.
Static/vanilla/no bundlerHosted script https://shoo.dev/shoo.jsUse window.Shoo.startSignIn(), getIdentity(), clearIdentity().
Framework-agnostic browser client@shoojs/authUse lower-level client methods for custom flows.
Server APIJWT verification onlyShoo sign-in is browser-oriented; the server should verify tokens, not initiate trust from localStorage.

2. Add the client integration

  • Use the repository's package manager (bun, npm, pnpm, or yarn); ask before dependency changes unless implementation was explicitly requested.
  • Default Shoo base URL is https://shoo.dev.
  • Default framework-agnostic callback path is /auth/callback; docs also show /shoo/callback for Convex/hosted examples. Keep the configured callback path consistent across client, routes, and server expectations.
  • React: call useShooAuth() in a client-side component; render sign-in when !identity.userId; call signIn() or signIn({ requestPii: true }); call clearIdentity() for sign-out.
  • Vanilla/hosted script: include https://shoo.dev/shoo.js; use window.Shoo.startSignIn({ returnTo, requestPii }); read window.Shoo.getIdentity(); clear with window.Shoo.clearIdentity().
  • Custom client: create createShooAuth({ callbackPath, shooBaseUrl }); use startSignIn(), handleCallback() or finishSignIn(), getIdentity(), clearIdentity().
  • Keep returnTo relative or same-origin unless the app has an explicit open-redirect defense.

3. Handle callback deterministically

  • Ensure the callback path is served by the SPA/router/static host.
  • For Next.js App Router, create a client callback page that calls useShooAuth() and renders a transient "Signing in…" state.
  • Prefer the high-level callback handler (useShooAuth auto handling or handleCallback) unless the app needs custom redirect control.
  • If using manual handling, remove callback params after exchange and consume return-to state once.

4. Verify tokens server-side before authorization

Never authorize from identity.userId, localStorage, or decodeIdentityClaims() alone. Server verification must check:

CheckRequired value
Issuerhttps://shoo.dev
Audienceorigin:{new URL(appOrigin).origin}
SignatureES256 against https://shoo.dev/.well-known/jwks.json
ExpirationNot expired
Core claimpairwise_sub exists and is a string

TypeScript shape with jose:

ts
import { createRemoteJWKSet, jwtVerify } from "jose";

const jwks = createRemoteJWKSet(
  new URL("/.well-known/jwks.json", "https://shoo.dev"),
);

export async function verifyShooToken(idToken: string, appOrigin: string) {
  const audience = `origin:${new URL(appOrigin).origin}`;
  const { payload } = await jwtVerify(idToken, jwks, {
    issuer: "https://shoo.dev",
    audience,
  });

  if (typeof payload.pairwise_sub !== "string") {
    throw new Error("Shoo token missing pairwise_sub");
  }

  return payload;
}

Treat email, email_verified, name, and picture as optional display/profile claims. Do not require them unless PII was requested and consented.

5. Add session/revocation handling when persistent sessions matter

  • @shoojs/auth exposes checkSession() and startSessionMonitor().
  • @shoojs/react has autoSessionMonitor enabled by default and uses a 60s default interval.
  • On login_required with reason revoked, expired, or invalid_token, clear local identity and prompt sign-in.
  • If checkSession() reports unsupported, degrade gracefully and rely on token expiration/server verification.

6. Convex path

For Convex, configure a custom JWT provider:

ts
export default {
  providers: [
    {
      type: "customJwt",
      issuer: "https://shoo.dev",
      jwks: "https://shoo.dev/.well-known/jwks.json",
      algorithm: "ES256",
      // Prefer also setting applicationID: "origin:https://your-app-origin"
    },
  ],
};

Then create a module with createShooConvexAuth({ callbackPath }), pass its useAuth to ConvexProviderWithAuth, and use identity.subject from ctx.auth.getUserIdentity() as the stable user ID.

Common Failure Map

SymptomLikely causeDeterministic check
Server rejects token for audienceAPP_ORIGIN, redirect URI origin, or Convex application ID mismatchCompare exact new URL(origin).origin values; audience must be origin:{origin}.
Callback route 404Router/static host does not serve callback pathAdd route/page at configured callback path.
No identity after redirectCallback handler did not run, state/verifier lost, storage key mismatch, or code/state absentCheck callback URL, sessionStorage PKCE state, localStorage identity key, and handler execution.
PII claims missingPII not requested or user did not consentUse requestPii: true only when needed; treat claims as optional.
Convex unauthenticatedProvider config mismatch or token not passed by adapterCheck issuer, JWKS, ES256, applicationID, and fetchAccessToken().
Works locally but fails in productionOrigin/audience or callback path differsConfigure per-environment origin and callback path explicitly.

Verification

For implementation tasks, verify at the smallest meaningful level:

  • Build/typecheck/lint/tests for the modified repository.
  • Callback path exists and does not 404.
  • A successful sign-in produces an identity whose userId/pairwise_sub is present and starts with the expected opaque ps_ form.
  • Server verification succeeds for a real Shoo token from the current app origin.
  • Negative verification rejects a token with the wrong audience, a tampered signature, or an expired token when feasible in tests.
  • Authorization decisions use server-verified payloads, not client-decoded claims.
  • Optional PII is absent by default and appears only after explicit requestPii: true/consent.
  • Convex: an authenticated query can read ctx.auth.getUserIdentity() and returns identity.subject.

Optional endpoint sanity checks:

bash
curl -fsS https://shoo.dev/.well-known/openid-configuration
curl -fsS https://shoo.dev/.well-known/jwks.json

Safety and Failure Modes

  • Shoo sign-in contacts shoo.dev and Google and changes browser storage; disclose this for manual tests.
  • Do not log, paste, persist, or commit raw id_tokens or OAuth callback URLs containing codes/state.
  • Do not store secrets or user tokens in skill memory, fixtures, or examples.
  • Do not make production auth recommendations without server verification and a maturity/risk caveat.
  • Do not present decodeIdentityClaims() as verification; it is display-only.
  • Be careful with localStorage-based identity in XSS-sensitive apps; server verification does not remove the need for normal frontend security controls.
  • Ask before enabling this draft skill or moving it into an auto-discovered skill root.

Sources and Maintenance

  • Live docs root: https://docs.shoo.dev/docs.
  • API refs: /docs/api-reference/shoo-react and /docs/api-reference/shoo-auth.
  • Verification docs: /docs/server-verification.
  • Flow docs: /docs/how-it-works.
  • Convex docs: /docs/convex.
  • Discovery/JWKS: https://shoo.dev/.well-known/openid-configuration and https://shoo.dev/.well-known/jwks.json.

If the live docs conflict with this skill, prefer the live docs and update the skill.

Pi Adapter

  • In Pi, fetch the Shoo docs directly for current claims when the decision is production/security-sensitive.
  • Before editing an unfamiliar app, use repository exploration first, then make the smallest route/config/client/server changes needed.
  • This file is a disabled draft under a non-discovered draft directory; review and ask before enabling.

Файлы в комплекте

Модель читает эти файлы по мере необходимости, пока навык загружен. Они доступны только для чтения и никогда не выполняются.

Часто задаваемые вопросы

Что делает навык ИИ Shoo Auth?

Используйте этот навык для оценки, внедрения, проверки или отладки входа через Google с помощью Shoo auth (shoo.dev) в браузерных приложениях, в том числе с @shoojs/react, @shoojs/auth, размещённым shoo.js, пользовательской интеграцией JWT в Convex, обратными вызовами PKCE, проверками сессий и серверной проверкой id_token. Не используйте его для других систем аутентификации.

Зачем использовать Shoo Auth в TypingMind?

Потому что вы устанавливаете навык один раз и используете его с любой моделью. Shoo Auth — это обычный текст в формате Markdown, а не код для конкретного поставщика, поэтому один и тот же навык работает с GPT-5, Claude, Gemini, Grok или локальной моделью. Вы можете менять модель прямо во время чата, и навык продолжит работать. TypingMind использует ваши собственные ключи API, поэтому вы платите поставщикам напрямую, а не оформляете подписку с оплатой за каждое место. Ваши навыки и чаты остаются в вашем собственном хранилище.

Как установить Shoo Auth в TypingMind?

В TypingMind откройте «Плагины → Навыки → Установить из GitHub» и вставьте https://github.com/Firstp1ck/pi-coding-agent-forge/tree/main/pi-skill-shoo-auth/skills/shoo-auth. TypingMind прочитает файл SKILL.md, включит сопутствующие файлы в пакет и установит навык, который можно включать отдельно для каждого чата.

Какие модели ИИ могут использовать Shoo Auth?

Любая модель, которую вы подключите в TypingMind. Навыки ИИ — это обычные инструкции в формате Markdown, а не код для конкретного поставщика, поэтому GPT, Claude, Gemini, Grok и локальные модели могут загружать этот навык, когда запрос ему соответствует.

Со сколькими моделями ИИ можно использовать Shoo Auth?

С любым количеством. В TypingMind вы можете использовать Shoo Auth с любой моделью, которая поддерживает навыки, в том числе с GPT, Claude, Gemini, Grok, DeepSeek, Mistral и Llama. Для этого вы используете собственные ключи API.

Бесплатен ли навык ИИ Shoo Auth?

Да. Навык опубликован на GitHub по лицензии MIT. Издатель — Firstp1ck. Вы платите только своему поставщику ИИ за использованные токены.

Что такое навыки ИИ?

Навык ИИ — это набор инструкций, которыми модель ИИ может пользоваться каждый раз, когда ей нужно выполнить конкретную задачу. Он соответствует открытому формату Agent Skills: файл SKILL.md с названием и описанием, а также любые скрипты, шаблоны или справочные файлы, которые могут понадобиться модели. Модель читает инструкции, только когда ваш запрос соответствует навыку, поэтому установленный навык ничего не стоит, пока не используется.

Чем навыки ИИ отличаются от плагинов и серверов MCP?

Плагин или сервер MCP даёт модели новые инструменты, которые она может вызывать: при вызове где-то выполняется код и возвращает результат. Навык ИИ, напротив, даёт модели знания и описывает порядок действий: как подойти к задаче, какие шаги выполнить и каким должен быть хороший результат. Навыки — это обычный текст в формате Markdown, поэтому им не нужны сервер, ключ API или среда выполнения, и они работают с любой моделью.

Все
Логотип openclaw

Release Openclaw Mac

openclaw
ОрганизацияПопулярный

Запускайте или восстанавливайте процессы подписания релизов OpenClaw для macOS, нотариального заверения, обновления appcast и публикации ресурсов.

82.2K
391K
Инструкции
Открыть
Логотип openclaw

Release Openclaw Maintainer

openclaw
ОрганизацияПопулярный

Готовьте, публикуйте, восстанавливайте или проверяйте бета-, стабильные и расширенные стабильные релизы OpenClaw, включая утверждённые обратные переносы изменений.

82.2K
391K
Файлы: 11
Открыть
Логотип openclaw

Release Openclaw Plugin Testing

openclaw
ОрганизацияПопулярный

Планируйте и проводите проверку плагинов OpenClaw перед релизом: проверяйте встроенные плагины, артефакты пакетов, команды жизненного цикла, doctor/fix, обратное преобразование конфигурации, запуск gateway, совместимость SDK, Docker E2E,…

82.2K
391K
Файлы: 1
Открыть
Логотип openclaw

Solid

openclaw
ОрганизацияПопулярный

Write, port, review, or test Solid 2 UI in OpenClaw (Control UI, plugin views, Canvas hosts), including state ownership, Lit interop during the migration, native overlays, testing, performance, and…

82.4K
391.7K
Файлы: 9
Открыть

Создайте своё рабочее пространство с ИИ прямо сейчас

Подпишитесь на нашу рассылку, чтобы узнавать о новых функциях и предстоящих розыгрышах 👇