[GH-ISSUE #423] API for Removing a user from a team deletes whole team #6159

Closed
opened 2026-04-20 16:46:06 -05:00 by GiteaMirror · 2 comments
Owner

Originally created by @Srolfe657 on GitHub (Mar 15, 2025).
Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/423

Description

I'm testing some stuff in python and haven't been able to get a function to work that's supposed to remove a team member from a given team. It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team. They are also not the only member, I'm doing this from my admin account with a valid JWT token.

I tested the DELETE /teams/{id}/members/{userID} endpoint in Postman and it says "message": "Successfully deleted." but when I refresh the page the whole team is deleted.

Attempted to repro in vikunja demo but can't create new users there.

Vikunja Version

v0.24.6

Browser and version

Chrome 134.0.6998.89

Can you reproduce the bug on the Vikunja demo site?

No

Screenshots

Here you'll see the project number is 123 and in the debug its 122 but thats because I manually recreated it after an attempt to remove the user deleted the team.

Image
Image

Originally created by @Srolfe657 on GitHub (Mar 15, 2025). Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/423 ### Description I'm testing some stuff in python and haven't been able to get a function to work that's supposed to remove a team member from a given team. It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team. They are also not the only member, I'm doing this from my admin account with a valid JWT token. I tested the DELETE /teams/{id}/members/{userID} endpoint in Postman and it says "message": "Successfully deleted." but when I refresh the page the whole team is deleted. Attempted to repro in vikunja demo but can't create new users there. ### Vikunja Version v0.24.6 ### Browser and version Chrome 134.0.6998.89 ### Can you reproduce the bug on the Vikunja demo site? No ### Screenshots Here you'll see the project number is 123 and in the debug its 122 but thats because I manually recreated it after an attempt to remove the user deleted the team. ![Image](https://github.com/user-attachments/assets/4ea847f1-ef67-4dd0-9fac-e6095eb447d5) ![Image](https://github.com/user-attachments/assets/452a88c1-53e4-45d9-99fe-285a2e67e260)
Author
Owner

@kolaente commented on GitHub (Mar 16, 2025):

It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team.

That's expected because you need to provide the username, not the user id. I've just now pushed a change to clarify this in the docs.

I'm unable to reproduce the other issue. Can you provide a curl which I can run locally?

<!-- gh-comment-id:2727541263 --> @kolaente commented on GitHub (Mar 16, 2025): > It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team. That's expected because you need to provide the username, not the user id. I've just now pushed a change to clarify this in the docs. I'm unable to reproduce the other issue. Can you provide a curl which I can run locally?
Author
Owner

@Srolfe657 commented on GitHub (Mar 16, 2025):

It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team.

That's expected because you need to provide the username, not the user id. I've just now pushed a change to clarify this in the docs.

I'm unable to reproduce the other issue. Can you provide a curl which I can run locally?

Ah okay yes it works with their username! thank you!

I can't reproduce the team deletion either now. crazy.

I'll close this report.

<!-- gh-comment-id:2727625304 --> @Srolfe657 commented on GitHub (Mar 16, 2025): > > It always gives {"code":1005,"message":"The user does not exist."} even though they absolutely do exist and are a member of the given team. > > That's expected because you need to provide the username, not the user id. I've just now pushed a change to clarify this in the docs. > > I'm unable to reproduce the other issue. Can you provide a curl which I can run locally? Ah okay yes it works with their username! thank you! I can't reproduce the team deletion either now. crazy. I'll close this report.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vikunja#6159