import { useState } from "react"; import { Button } from "@/components/ui/button"; import ApiResponse from "@/components/ApiResponse"; import { krowSDK } from "@/api/krowSDK"; const GetMe = () => { const [response, setResponse] = useState(null); const [error, setError] = useState(null); const [loading, setLoading] = useState(false); const handleGetMe = async () => { setLoading(true); setError(null); setResponse(null); try { const res = await krowSDK.auth.me(); setResponse(res); } catch (err) { setError(err.response?.data || err.message); } finally { setLoading(false); } }; return (

Get Me

Fetches the currently authenticated user's profile.

Test `/auth/me`
); }; // We need to re-import Card components because they are not globally available. import { Card, CardHeader, CardTitle, CardContent } from "@/components/ui/card"; export default GetMe;