mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 06:40:44 +00:00
fix(extensions): type web search onboarding scopes
This commit is contained in:
@@ -1,13 +1,14 @@
|
||||
import { createWebSearchProviderContractFields } from "openclaw/plugin-sdk/provider-web-search-contract";
|
||||
|
||||
const EXA_CREDENTIAL_PATH = "plugins.entries.exa.config.webSearch.apiKey";
|
||||
const EXA_ONBOARDING_SCOPES: Array<"text-inference"> = ["text-inference"];
|
||||
|
||||
export function createExaWebSearchProviderBase() {
|
||||
return {
|
||||
id: "exa",
|
||||
label: "Exa Search",
|
||||
hint: "Neural + keyword search with date filters and content extraction",
|
||||
onboardingScopes: ["text-inference"],
|
||||
onboardingScopes: [...EXA_ONBOARDING_SCOPES],
|
||||
credentialLabel: "Exa API key",
|
||||
envVars: ["EXA_API_KEY"],
|
||||
placeholder: "exa-...",
|
||||
|
||||
@@ -9,6 +9,7 @@ export const DEFAULT_PERPLEXITY_BASE_URL = "https://openrouter.ai/api/v1";
|
||||
export const PERPLEXITY_DIRECT_BASE_URL = "https://api.perplexity.ai";
|
||||
export const PERPLEXITY_CREDENTIAL_PATH = "plugins.entries.perplexity.config.webSearch.apiKey";
|
||||
|
||||
const PERPLEXITY_ONBOARDING_SCOPES: Array<"text-inference"> = ["text-inference"];
|
||||
const PERPLEXITY_KEY_PREFIXES = ["pplx-"];
|
||||
const OPENROUTER_KEY_PREFIXES = ["sk-or-"];
|
||||
|
||||
@@ -26,7 +27,7 @@ export function createPerplexityWebSearchProviderBase() {
|
||||
id: "perplexity",
|
||||
label: "Perplexity Search",
|
||||
hint: "Requires Perplexity API key or OpenRouter API key · structured results",
|
||||
onboardingScopes: ["text-inference"],
|
||||
onboardingScopes: [...PERPLEXITY_ONBOARDING_SCOPES],
|
||||
credentialLabel: "Perplexity API key",
|
||||
envVars: ["PERPLEXITY_API_KEY", "OPENROUTER_API_KEY"],
|
||||
placeholder: "pplx-...",
|
||||
|
||||
Reference in New Issue
Block a user