Add member approve_all API endpoint
What does this MR do and why?
Adds a new REST API endpoint for approving all pending members (users who are added to a group which has hit it's user cap).
The user cap feature is behind a feature flag that is currently disabled as it's in development, so this endpoint will not be used and will not do anything for existing members (because they'll never be an awaiting state right now).
How to set up and validate locally
- Make a member pending/awaiting
Member.last.wait! Member.last.awaiting? => true
- Hit the API endpoint for that member's group/user
curl --request POST \ --url http://127.0.0.1:3000/api/v4/groups/:group_id/members/approve_all \ --header 'PRIVATE-TOKEN: <your token>' \
- Verify the change
Member.last.active? => true
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Relates to #332596 (closed)
Edited by Corinna Gogolok