Passing ServiceProviderConfig to the serialization and validation context would allow to check for additional things.
For example:
- if
changePassword is not supported by a server, then it could raise a ValidationError when used in a RESOURCE_REPLACEMENT_QUERY_CONTEXT for instance.
- if
etag is not supported, then response contexts should reject payloads containing etags.
- if
filter or sort are not supported, then they should not be passed when building SearchRequest objects.