class_docstr: Search engine using SerperDev API. Given a query, it returns a list of URLs that are the most relevant.
  
  See the [Serper Dev website](https://serper.dev/) for more details.
docstr: Serialize this component to a dictionary.
code: def to_dict(self) -> Dict[str, Any]:
      """
      Serialize this component to a dictionary.
      """
      return default_to_dict(
          self,
          top_k=self.top_k,
          allowed_domains=self.allowed_domains,
          search_params=self.search_params,
      )
  
file_path: haystack/haystack/components/websearch/serper_dev.py
imports: import json
  import logging
  from typing import Dict, List, Optional, Any
  import os
  import requests
  from haystack import Document, component, default_to_dict, ComponentError
label_desc: Use image node_id 2 for calling the SerperDevWebSearch obj's underlying member method code with example usage: obj.to_dict() and returns: default_to_dict