mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-04-26 21:05:49 +00:00
fix(web): use self.api_key instead of undefined api_key
Made-with: Cursor
This commit is contained in:
parent
cc425102ac
commit
7a3788fee9
@ -80,7 +80,7 @@ class WebSearchTool(Tool):
|
|||||||
r = await client.get(
|
r = await client.get(
|
||||||
"https://api.search.brave.com/res/v1/web/search",
|
"https://api.search.brave.com/res/v1/web/search",
|
||||||
params={"q": query, "count": n},
|
params={"q": query, "count": n},
|
||||||
headers={"Accept": "application/json", "X-Subscription-Token": api_key},
|
headers={"Accept": "application/json", "X-Subscription-Token": self.api_key},
|
||||||
timeout=10.0
|
timeout=10.0
|
||||||
)
|
)
|
||||||
r.raise_for_status()
|
r.raise_for_status()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user