MCPcopy Create free account
hub / github.com/OpenBMB/BMTools / __init__

Method __init__

bmtools/tools/google_serper/api.py:12–19  ·  view source on GitHub ↗
(self, subscription_key)

Source from the content-addressed store, hash-verified

10
11class GoogleSerperAPIWrapper:
12 def __init__(self, subscription_key) -> None:
13 self.k: int = 10
14 self.gl: str = "us"
15 self.hl: str = "en"
16 self.type: str = "search" # type: search, images, places, news
17 self.tbs: Optional[str] = None
18 self.serper_api_key: str = subscription_key
19 self.aiosession: Optional[aiohttp.ClientSession] = None
20
21 def results(self, query: str, **kwargs: Any) -> Dict:
22 """Run query through GoogleSearch."""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected