expo-auth
Patrones de autenticación: useAuth hook, token management, Google Sign-In, requestWithAuth.
Skill by myquota
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/cabrerojas-expo-auth
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: security
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/expo-auth
What's inside
- Skill name
expo-auth- Description
- Patrones de autenticación: useAuth hook, token management, Google Sign-In, requestWithAuth. Trigger: Cuando se trabaja con autenticación, tokens, o Google Sign-In.
- License
- MIT
- Metadata
- author: myquota · version: 1.0
- Instructions
- 210 lines in SKILL.md · view on GitHub
Before installing
- Instructions call the network
Files (1)
- SKILL.md
SKILL.md (first lines)
## Propósito
Entender y trabajar con el sistema de autenticación de MyQuota App.
---
## Flujo de Autenticación
```
1. Usuario abre app
└── src/app/index.tsx revisa SecureStore
2. Si hay token → /dashboard
Si no hay token → /login
3. En login:
└── Google Sign-In → POST /login/google → { accessToken, refreshToken }
4. Tokens se guardan:
└── SecureStore (primario)
└── AsyncStorage (legacy/fallback)
5. Requests autenticadas:
└── requestWithAuth adjunta Bearer token
└── Si 401 → refresh automático
└── Si refresh falla → limpiar tokens → /login
```
---
## Archivo Clave
`src/features/auth/hooks/useAuth.ts` exporta:
- `requestWithAuth` — HTTP client autenticado
- `signInWithGoogle` — Flujo de Google Sign-In
- `signOut` — Logout
- `getAccessToken` — Obtener token actual
---
## requestWithAuth
```typescript
import { requestWithAuth } from "@/features/auth/hooks/useAuth";
// Uso básico
const response = await requestWithAuth(`${API_BASE_URL}/items`);
// Con opciones
const response = await requestWithAuth(`${API_BASE_URL}/items`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(data),
});
```
**Comportamiento automático:**
1. Adjunta `Authorization: Bearer <accessToken>`
2. Si 401 con `code: "token_expired"` → intenta refresh
3. Si refresh OK → reintenta request original
4. Si refresh falla → limpia tokens → redirige a login
---
## Almacenamiento de Tokens
```typescript
import * as SecureStore from "expo-secure-store";
// Guardar
await SecureStore.setItemAsync("accessToken", token);
await SecureStore.setItemAsync("refreshToken", refreshToken);
// Leer
const token = await SecureStore.getItemAsync("accessToken");
// Eliminar
await SecureStore.deleteItemAsync("accessToken");
```
**Nota**: Actualmente también se usa AsyncStorage como fallback (deuda técnica).
---
## Google Sign-In
Desde el hook `useAuth`:
```typescript
import { useAuth } from "@/features/auth/hooks/useAuth";
export default function LoginScreen() {
const { signInWithGoogle, loading, error } = useAuth();
const handleLogin = async () => {
try {
await signInWithGoogle();
// Si éxito, redirige automáticamente a /dashboard
} catch (err) {
// Error ya manejado por el hook
}
};
return (
<Button title="Iniciar con Google" onPress={handleLogin} disabled={loading} />
);
}
```
---
## Logout
```typescript
import { useAuth } from "@/features/auth/hooks/useAuth";
const { signOut } = useAuth();From cabrerojas/myquota-app, MIT.
More from cabrerojas/myquota-app
- 0.554score
sync-types
myquota
Sincronización de tipos entre backend y frontend.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
skill-audit
myquota
Audita y sugiere/actualiza skills existentes tras cambios en patrones, convenciones o arquitectura.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
skill-creator
myquota
Guía y templatea la creación de nuevos skills para AI agents.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-module
myquota
Patrones para crear features completos en MyQuota App: estructura, screens, services, components.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-routes
myquota
Patrones de expo-router: layouts, drawer config, navegación programática.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-screens
myquota
Patrones de screens con data fetching: loading, error states, useCallback, useEffect.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-services
myquota
Patrones de servicios API: requestWithAuth, manejo de errores, tipado.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-theme
myquota
Patrones de estilos: theme tokens, StyleSheet.create, colores, spacing.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-types
myquota
Patrones de TypeScript: interfaces, tipos compartidos, strict mode.
SkillBFreshness: B★ 2Claude Code +9 - 0.551score
skill-sync
myquota
Meta-skill para sincronizar las tablas de Auto-invoke en AGENTS.md a partir del metadata.auto_invoke de cada SKILL.md.
SkillBFreshness: B★ 2Claude Code +9 - 0.385score
vercel-react-native
vercel
React Native and Expo best practices for building performant mobile apps.
SkillBFreshness: B★ 2Claude Code +9
Signals
- Stars
- 2
- Forks
- 0
- Open issues
- 0
- Last commit (this folder)
- Aug 15, 2026 (2 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 1.0
- License
- MIT
- Repository
- github.com/cabrerojas/myquota-app
- Website
- myquota.vercel.app
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from myquota
- 0.554score
sync-types
myquota
Sincronización de tipos entre backend y frontend.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-module
myquota
Patrones para crear features completos en MyQuota App: estructura, screens, services, components.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-routes
myquota
Patrones de expo-router: layouts, drawer config, navegación programática.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-screens
myquota
Patrones de screens con data fetching: loading, error states, useCallback, useEffect.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-services
myquota
Patrones de servicios API: requestWithAuth, manejo de errores, tipado.
SkillBFreshness: B★ 2Claude Code +9 - 0.554score
expo-theme
myquota
Patrones de estilos: theme tokens, StyleSheet.create, colores, spacing.
SkillBFreshness: B★ 2Claude Code +9
Cite this page
expo-auth skill. Agent Mart. https://agentmart.dev/skills/cabrerojas-expo-auth (last updated 2026-10-24)