···190190191191## TanStack Query
192192193193+**Always use the generated query options from `@opnshelf/api`** - never use raw `fetch()`. The API client is pre-configured with the base URL and handles authentication automatically.
194194+195195+```typescript
196196+// ✅ Correct - use generated options
197197+const { data } = useQuery({
198198+ ...searchControllerSearchAllOptions({
199199+ query: { query: searchTerm },
200200+ }),
201201+});
202202+203203+// ❌ Wrong - don't use fetch directly
204204+const response = await fetch(`${API_URL}/search/all?query=...`);
205205+```
206206+193207**Always use `mutationKey`** on all `useMutation` calls. This enables better debugging, caching, and mutation state tracking.
194208195209```typescript