implemente bulk update/import users to list#95
Merged
jeroenrinzema merged 4 commits intomainfrom Dec 2, 2025
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR implements bulk user import functionality for static lists via CSV upload. The implementation includes CSV parsing with flexible column ordering, user upsert operations, and list membership management.
Key changes:
- Refactored
UpsertUserto use a structured params object instead of individual parameters - Changed
users_countfrom optional to required field in the List schema - Added CSV import endpoint for bulk adding users to lists
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| services/nexus/oapi/resources.yml | Made users_count a required field in List schema |
| services/nexus/oapi/resources_gen.go | Updated generated code to reflect required users_count field |
| services/nexus/internal/store/users.go | Refactored UpsertUser to accept structured UpsertUserParams |
| services/nexus/internal/store/users_test.go | Updated tests to use new UpsertUserParams structure |
| services/nexus/internal/store/lists.go | Added typed constants for list types/states and AddUserToList method |
| services/nexus/internal/importer/users.go | New CSV mapper for transforming CSV rows to user upsert parameters |
| services/nexus/internal/http/controllers/v1/users.go | Updated to use UpsertUserParams structure |
| services/nexus/internal/http/controllers/v1/lists.go | Added ImportListUsers endpoint with CSV processing |
| services/nexus/internal/http/controllers/v1/lists_test.go | Added comprehensive tests for CSV import functionality |
| services/nexus/internal/http/controllers/v1/controller.go | Wired up max upload size configuration for lists controller |
| services/nexus/internal/http/controllers/v1/test/users/*.csv | Test fixtures for CSV import scenarios |
| services/console/public/templates/users.csv | Updated template to match supported import fields |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.