api-expert
БесплатноБез исполняемых скриптовНе проверенHandles backend integration using best practices like expo/fetch and React Query. Use when the user needs to connect to an API, handle data fetching, or…
от diegosouzapw★ 68 звёзд на GitHubОб этом скилле
API Expert Skill
This skill provides expertise in integrating backend services into React Native Expo applications. It emphasizes reliability, performance, and clean architecture.
Core Principles
- Use
expo/fetch: Always preferexpo/fetchover standardfetchoraxios. - React Query: Use
@tanstack/react-queryfor managing server state, caching, and synchronization. - Service Layer: Keep API logic in the
services/directory. - Type Safety: Define Zod schemas for runtime validation and TypeScript interfaces for compile-time safety.
Instructions
- Setup Client: Ensure the React Query client is configured in
app/_layout.tsx. - Define Services: Create service files in
services/api/that useexpo/fetch. - Custom Hooks: Wrap service calls in custom React Query hooks.
- Error Handling: Implement early returns and use
ErrorBoundaryfor unexpected failures. - Validation: Use Zod to validate API responses at the network boundary.
Example
// services/api/user-service.ts
import { fetch } from 'expo/fetch';
import { z } from 'zod';
const UserSchema = z.object({
id: z.string(),
name: z.string(),
});
export const fetchUser = async (id: string) => {
const response = await fetch(`https://api.example.com/users/${id}`);
if (!response.ok) throw new Error('Failed to fetch user');
const data = await response.json();
return UserSchema.parse(data);
};
// hooks/use-user.ts
import { useQuery } from '@tanstack/react-query';
import { fetchUser } from '@/services/api/user-service';
export const useUser = (id: string) => {
return useQuery({
queryKey: ['user', id],
queryFn: () => fetchUser(id),
});
};
See API Best Practices for more details.
Установить api-expert в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл api-expert?
Handles backend integration using best practices like expo/fetch and React Query. Use when the user needs to connect to an API, handle data fetching, or implement caching.
Как установить скилл api-expert?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл api-expert запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic