Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/AndrewwCO/Panahashi/llms.txt

Use this file to discover all available pages before exploring further.

Both user profile endpoints operate on the account of the currently logged-in user, identified by the Firebase token in the request. Neither endpoint accepts a user ID parameter — the identity is always derived from the auth token.
Every users endpoint requires an Authorization: Bearer <token> header. Calls made without a valid Firebase token will be rejected.

GET /users/me — fetchMyProfile()

Returns the profile record for the authenticated user.

Response fields

displayName
string
The user’s display name.
phone
string
The user’s phone number.
email
string
The user’s email address as registered in Firebase Auth.
fcmToken
string
Firebase Cloud Messaging token used to send push notifications to this user’s device.

Example

import { fetchMyProfile } from './services/api';

const profile = await fetchMyProfile();

PATCH /users/me — updateMyProfile(displayName, phone, fcmToken)

Updates one or more fields on the authenticated user’s profile. Only the fields you provide are changed; omitting a parameter leaves that field unchanged.
Pass undefined for any field you do not want to update. The function only includes defined values in the request body.

Request parameters

displayName
string
New display name for the user. Omit to leave unchanged.
phone
string
New phone number for the user. Omit to leave unchanged.
fcmToken
string
Updated Firebase Cloud Messaging token. Pass this whenever the device token rotates to keep push notifications working. Omit to leave unchanged.

How the request body is built

Only defined arguments are included in the PATCH body, matching the implementation in services/api.js:
const body = {};
if (displayName !== undefined) body.displayName = displayName;
if (phone       !== undefined) body.phone       = phone;
if (fcmToken    !== undefined) body.fcmToken    = fcmToken;

Response fields

Returns the updated user profile object with the same shape as fetchMyProfile().

Example

import { updateMyProfile } from './services/api';

await updateMyProfile('Ana García', '+573001234567', undefined);

Build docs developers (and LLMs) love