[FEATURE] Add PATCH endpoint for partial user updates
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 970
- Forks
- 486
- Avg merge
- 3d 33m
- Merged PRs (30d)
- 170
Description
Problem
The current PUT /api/v1/users endpoint requires all mandatory fields (userId, firstName, lastName, email) even when updating a single field. This creates unnecessary complexity for API consumers.
Current behavior:
PUT /api/v1/users { "userId": "dotcms.org.2806", "firstName": "John", // Required even if not changing "lastName": "Doe", // Required even if not changing "email": "new@email.com" // The only field being updated }
Goal
Proposed Solution
Add a PATCH /api/v1/users endpoint that supports partial updates, allowing users to update only specific fields.
New behavior:
PATCH /api/v1/users{
"userId": "dotcms.org.2806",
"email": "new@email.com" // Only send what's changing
}
Target Personas
- Developer teams
- Content teams
- DevOps teams
- System administrators (dotCMS)
Demo Expectations
Able to use update user
Acceptance Criteria
- PATCH endpoint accepts userId + any optional user fields
-Unspecified fields retain existing values - Email, firstName, lastName, and password can each be updated independently
User Stories
No response
Links
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the existing PUT /api/v1/users implementation and its user update tests. Trace how required fields are validated and persisted, then add the PATCH behavior described in the acceptance criteria and verify that omitted fields retain their existing values while email, firstName, lastName, and password can be updated independently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100