Rewrite request bodies from patch.yml using Spectacular
Add a serializer or use inline_serializer and apply it using extend_schema(request=TheSerializer)
.
-
AddSelection
(required array of elementsids
) -
RemoveSelection
(optional request body with an elementid
)-
Check using the API client that body=
is not required - Fallback if
body
cannot be made optional: just makeid
optional (body={}
will be required)
-
Edited by Eva Bardou