A Fawx WASM skill that performs web searches via the Brave Search API.
{
"query": "search terms",
"count": 5,
"api_key": "BSA..."
}| Field | Type | Required | Default | Description |
|---|---|---|---|---|
query |
string | yes | — | Search query |
count |
u8 | no | 5 | Number of results (1–10) |
api_key |
string | no | — | Brave API key (overrides stored credential) |
The skill resolves the Brave API key in this order:
api_keyfield in the input JSONBRAVE_API_KEYfrom host key-value storage (set as a credential by the agent runtime)
{
"results": [
{
"title": "Example Page",
"url": "https://example.com",
"description": "A description of the page."
}
]
}{
"error": "Missing BRAVE_API_KEY: provide api_key in input or set it as a host credential"
}# Run tests (native)
cargo test
# Build WASM module
rustup target add wasm32-wasip1
cargo build --target wasm32-wasip1 --releaseThe compiled skill will be at target/wasm32-wasip1/release/brave_search_skill.wasm.
name = "brave_search"
version = "1.0.0"
api_version = "host_api_v1"
capabilities = ["network"]
entry_point = "run"MIT