Initializes the endpoint with the context keys based on the passed
        and/or based on the query parameters (request.GET).

def initialize_context(self, request: HttpRequest, *args, **kwargs) -> None:
        """
        Initializes the endpoint with the context keys based on the passed
        and/or based on the query parameters (request.GET).
        """
        for key in self.CONTEXT_KEYS:
            setattr(self, key, kwargs.get(key))
        for key in self.QUERY_CONTEXT_KEYS:
            setattr(self, key, request.query_params.get(key))
        self._initialize_context()
        self.validate_context()