Assign users to order list for access control
PATCH/v2/orderlists/:id/assign-users
Associate users with an order list to grant access permissions.
Assigns specified users to the order list, enabling them to view, access, and place orders from the list based on their role permissions. The assignment updates access control immediately and allows users to see the order list in their available ordering options.
This endpoint allows you to:
- Grant individual users access to the order list
- Reference users from external systems via source identifiers
- Maintain unique user assignments (duplicates are handled automatically)
- Update the order list's modification timestamp
Request
Responses
- 200
- 400
- 403
- 404
- 500
Users assigned to order list successfully.
Returns the updated order list with the newly assigned users included in the userIds array.
Invalid user data.
The provided user data contains validation errors or references non-existent users.
Access denied.
Insufficient permissions to assign users to order lists.
Order list not found.
No order list exists with the specified identifier.
Server error.
An unexpected error occurred while assigning users.