curl -X POST https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create \ -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." \ -H "Content-Type: application/json" \ -d '{ "title": "My Daily Reflection", "content": "Today I learned about the importance of gratitude in my spiritual journey.", "status": "DRAFT" }'
const response = await fetch('https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create', { method: 'POST', headers: { 'Authorization': `Bearer ${accessToken}`, 'Content-Type': 'application/json' }, body: JSON.stringify({ title: 'My Daily Reflection', content: 'Today I learned about the importance of gratitude in my spiritual journey.', status: 'DRAFT' })});const note = await response.json();
final response = await http.post( Uri.parse('https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create'), headers: { 'Authorization': 'Bearer $accessToken', 'Content-Type': 'application/json', }, body: jsonEncode({ 'title': 'My Daily Reflection', 'content': 'Today I learned about the importance of gratitude in my spiritual journey.', 'status': 'DRAFT', }),);final note = jsonDecode(response.body);
{ "message": "Note created successfully", "data": { "id": "42f688be-1751-4935-8572-78039910b6fe", "title": "My Daily Reflection", "content": "Today I learned about the importance of gratitude in my spiritual journey.", "status": "DRAFT", "createdBy": "f9cc094c-ba9c-4a0a-82b9-e40d589e97db", "createdAt": "2025-10-14T07:19:33.294Z", "updatedAt": "2025-10-14T07:19:33.294Z" }, "success": true}
{ "error": "At least title or content is required", "success": false}
curl -X POST https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create \ -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." \ -H "Content-Type: application/json" \ -d '{ "title": "My Daily Reflection", "content": "Today I learned about the importance of gratitude in my spiritual journey.", "status": "DRAFT" }'
const response = await fetch('https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create', { method: 'POST', headers: { 'Authorization': `Bearer ${accessToken}`, 'Content-Type': 'application/json' }, body: JSON.stringify({ title: 'My Daily Reflection', content: 'Today I learned about the importance of gratitude in my spiritual journey.', status: 'DRAFT' })});const note = await response.json();
final response = await http.post( Uri.parse('https://rzqklwfhwqmviintncqh.supabase.co/functions/v1/notes-create'), headers: { 'Authorization': 'Bearer $accessToken', 'Content-Type': 'application/json', }, body: jsonEncode({ 'title': 'My Daily Reflection', 'content': 'Today I learned about the importance of gratitude in my spiritual journey.', 'status': 'DRAFT', }),);final note = jsonDecode(response.body);
{ "message": "Note created successfully", "data": { "id": "42f688be-1751-4935-8572-78039910b6fe", "title": "My Daily Reflection", "content": "Today I learned about the importance of gratitude in my spiritual journey.", "status": "DRAFT", "createdBy": "f9cc094c-ba9c-4a0a-82b9-e40d589e97db", "createdAt": "2025-10-14T07:19:33.294Z", "updatedAt": "2025-10-14T07:19:33.294Z" }, "success": true}
{ "error": "At least title or content is required", "success": false}
Privacy Protection: All notes endpoints automatically filter results to show only notes belonging to the authenticated user. Users cannot access other users’ notes.