Skip to main content

User

Users are the people who use our application. Each login is tied to a single user.

📄️ Update User

Updates fields on an existing user. Partial updates are supported: only the fields provided in `user` are changed, and `user.userId` defaults to the authenticated user when omitted. Send `startDate: null` to clear the start date. Requires the `user:update` permission for the target user, and archiving or restoring a user (`isDeleted`) also requires `user:manage`. Fields listed in the company `lockedUserFields` preference can be changed only by callers with `user:manage` on the user, and changing your own locked fields needs company-wide `user:manage`. A request from anyone else that changes a locked field is rejected and nothing is saved. Locking `avatar` instead withholds `uploadAvatarUrl` from `/user/profile` under the same rule. To change team membership or roles on a team, use `/team/member/add` or `/team/member/update` instead.

📄️ List Users

Lists users visible to the authenticated user. Provide `userIds` to fetch specific users from the database, `teamId` to list users on that team and its downline teams, or neither to list all users you can see in the company. Without `userIds`, role data comes from the search index and can be stale; `/user/get` is the source of truth for one user's role assignments. Archived users are excluded unless `showArchived` is set. Requires the `user:list` permission. Use `/user/search` to find users by name, or `/user/get` for full details on one user.

📄️ Search Users

Searches users visible to the authenticated user by name or phone number, with optional company, team, closer status, archive, downline, and result-size filters. Returns up to 20 users by default and excludes archived users unless `archived` is set. Without `companyId` it searches only your own company, so use `/search` to find users in other companies. Use this to find a user ID from a name; use `/user/list` to list every user on a team or company, or `/search` to search across multiple entity types at once.