User
SDK reference for user operations
Overview
Internal user profile and account management system
- Category:
internal - Auth Required: No
- Supported Modes: standard, delegated, service
Operations
getProfile
Get user profile information including username, email, timezone, phone, and usage stats
Returns:
UserProfile - User profile object with all profile fields
Example:
updateProfile
Update user profile fields (username, email, timezone, phone)
Arguments:
username(string, optional): New username (3-30 characters, alphanumeric with underscores/hyphens)email(string, optional): New email addresstimezone(string, optional): IANA timezone identifier (e.g., America/Los_Angeles)phoneNumber(string, optional): Phone number (7-15 digits with optional formatting)
Returns:
UserProfile - Updated user profile object
Example:
updatePreferences
Update user preferences (notification settings, etc)
Arguments:
timezone(string, optional): Preferred timezone for schedulingsocials(object, optional): Social media links (twitter, discord)
Returns:
UserPreferences - Updated user preferences
Example:
getUsageStats
Get token usage statistics, quota, and billing information
Returns:
UsageStats - Token usage and quota information
Example:
getSessions
Get active sessions/devices (based on push token registrations)
Returns:
Session[] - Array of active sessions/devices
Example:
deactivateAccount
Soft delete user account (set inactive flag) - CAUTION: This marks the account for deletion
Arguments:
confirm(boolean, required): Must be true to confirm account deactivation
Returns:
void - No return value on success
Example: