Problem: We need a way to change parameter defaults or available choices in an enum when an API module is exposed via a REST framework adapter. A typical use case for implementing adjustAllowedParams is changing the "prop" parameter to use a different default and accept more or less options. The will become relevant when we expose things like ApiQueryCategoryMembers or ApiQueryRecentChanges.
Draft: inject information about the route definition into the action API module class via the ApiRestHybrid interface. Let the module class adjust parameters as needed. Provide helper code in the ApiRestHelper base class.
Note that this requires the API module class to be aware that it is operating in "REST mode". That ability is what the ApiRestHybrid interface represents.
Original implementation draft (Obsolete)
Allow param settings to be modified by the ApiRestHelper.
In ApiRestHelper:
public function adjustAllowedParams( array $params ): array { // do nothing per default, subclasses can override } }The new method needs to be called from GenericActionHandler::filterSupportedParams.