Loading skill
Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Standardized guidelines and patterns for Frontend Data Api Layer.
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | -12% | 0% |
| case-06 | ✗→✓ | ▲ Improved | -25% | 0% |
| case-08 | ✗→✓ | ▲ Improved | -54% | 0% |
| case-11 | ✗→✓ | ▲ Improved | -25% | 0% |
| case-12 | ✗→✓ | ▲ Improved | -18% | 0% |
typescript// api/client.ts import axios from 'axios'; export const apiClient = axios.create({ baseURL: import.meta.env.VITE_API_URL, headers: { 'Content-Type': 'application/json' } }); apiClient.interceptors.request.use((config) => { const token = localStorage.getItem('token'); if (token) config.headers.Authorization = `Bearer ${token}`; return config; });
typescript// api/users.ts export const usersApi = { getAll: () => apiClient.get<User[]>('/users'), getById: (id: string) => apiClient.get<User>(`/users/${id}`), create: (data: CreateUserDto) => apiClient.post<User>('/users', data), update: (id: string, data: UpdateUserDto) => apiClient.put<User>(`/users/${id}`, data), delete: (id: string) => apiClient.delete(`/users/${id}`) };
Other measured skills in the registry, with their headline benchmark lift.