TypeScript
const options = { method: 'PATCH', headers: {'Content-Type': 'application/json'}, body: JSON.stringify({name: '<string>', image: '<string>'}) }; fetch('http://localhost:8000/v1/auth/me', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err));
{ "success": true, "data": { "id": "<string>", "email": "jsmith@example.com", "name": "<string>", "image": "<string>", "emailVerified": true, "createdAt": "2023-11-07T05:31:56Z", "role": "<string>" }, "meta": { "requestId": "<string>", "timestamp": "<string>" } }
Update the authenticated user profile (name, image)
Updated user profile
true
Show child attributes
Was this page helpful?