skills$openclaw/perplexity-search
m4vf142.2k

by m4vf14

perplexity-search – OpenClaw Skill

perplexity-search is an OpenClaw Skills integration for coding workflows. Search the web using Perplexity's Search API for ranked, real-time web results with advanced filtering. Use when you need to search for current information, market research, trending topics, or when Brave Search is unavailable. Supports recency filtering (day/week/month/year) and returns structured results with titles, URLs, and snippets.

2.2k stars6.5k forksSecurity L1
Updated Feb 7, 2026Created Feb 7, 2026coding

Skill Snapshot

nameperplexity-search
descriptionSearch the web using Perplexity's Search API for ranked, real-time web results with advanced filtering. Use when you need to search for current information, market research, trending topics, or when Brave Search is unavailable. Supports recency filtering (day/week/month/year) and returns structured results with titles, URLs, and snippets. OpenClaw Skills integration.
ownerm4vf14
repositorym4vf14/perplexity-search-skill
languageMarkdown
licenseMIT
topics
securityL1
installopenclaw add @m4vf14/perplexity-search-skill
last updatedFeb 7, 2026

Maintainer

m4vf14

m4vf14

Maintains perplexity-search in the OpenClaw Skills directory.

View GitHub profile
File Explorer
9 files
.
scripts
search.py
4.2 KB
_meta.json
298 B
CHANGELOG.md
700 B
PUBLISHING.md
2.7 KB
README.md
2.2 KB
SECURITY_AUDIT.md
3.4 KB
skill.json
1.0 KB
SKILL.md
2.9 KB
SKILL.md

Perplexity Search

Search the web using Perplexity's Search API for ranked, real-time results.

Quick Start

Basic search:

python3 {baseDir}/scripts/search.py "your search query"

With options:

# Get 10 results
python3 {baseDir}/scripts/search.py "AI trends 2024" --count 10

# Filter by recency
python3 {baseDir}/scripts/search.py "recent AI news" --recency week

# Get raw JSON output
python3 {baseDir}/scripts/search.py "market research" --json

API Key Setup

The script requires a PERPLEXITY_API_KEY environment variable.

Option 1: Set in OpenClaw config (recommended)

Add to ~/.openclaw/openclaw.json:

{
  "skills": {
    "perplexity-search": {
      "env": {
        "PERPLEXITY_API_KEY": "your-api-key-here"
      }
    }
  }
}

Option 2: Environment variable

export PERPLEXITY_API_KEY="your-api-key-here"

Get your API key from: https://perplexity.ai/account/api

Parameters

  • query - Search query string (required)
  • --count N - Number of results (1-10, default: 5)
  • --recency FILTER - Recency filter: day, week, month, or year
  • --json - Output raw JSON instead of formatted results

Response Format

The API returns:

{
  "results": [
    {
      "title": "Article title",
      "url": "https://example.com/article",
      "snippet": "Brief excerpt from the page...",
      "date": "2024-01-15",
      "last_updated": "2024-02-01"
    }
  ],
  "id": "search-request-id"
}

Use Cases

Market Research:

python3 {baseDir}/scripts/search.py "golf coaching Instagram trends" --count 10

Recent News:

python3 {baseDir}/scripts/search.py "AI regulation updates" --recency week

Competitive Analysis:

python3 {baseDir}/scripts/search.py "AI golf training apps" --count 10

Pricing

Perplexity Search API: $5 per 1,000 requests

Track your usage at: https://perplexity.ai/account/api

Security

  • API key loaded from environment only - never hardcoded
  • Output sanitization prevents terminal injection
  • Error messages don't expose sensitive information
  • 30-second timeout prevents hanging requests
  • Input validation on all parameters

Notes

  • Results are ranked by relevance
  • Includes real-time web data
  • Supports filtering by recency
  • Returns structured JSON or formatted text
  • Rate limits apply based on your Perplexity plan
README.md

Search the web using Perplexity's Search API. Returns ranked, real-time web results with titles, URLs, and snippets.

Features

  • 🔍 Real-time web search
  • 📊 Ranked results by relevance
  • ⏰ Recency filtering (day/week/month/year)
  • 🛡️ Secure API key handling
  • 🚀 Simple Python script, no dependencies

Installation

Via ClawHub (Recommended)

clawhub install perplexity-search

Manual Installation

  1. Clone or download this skill to your OpenClaw skills directory:

    cd ~/.openclaw/skills/
    git clone https://github.com/YourUsername/perplexity-search-openclaw.git perplexity-search
    
  2. Add your API key to OpenClaw config (~/.openclaw/openclaw.json):

    {
      "skills": {
        "perplexity-search": {
          "env": {
            "PERPLEXITY_API_KEY": "your-api-key-here"
          }
        }
      }
    }
    
  3. Restart OpenClaw gateway

Usage

Your OpenClaw agent will automatically use this skill when searching the web. You can also call it directly:

python3 ~/.openclaw/skills/perplexity-search/scripts/search.py "your query"

Options

  • --count N - Number of results (1-10, default: 5)
  • --recency FILTER - Filter by day, week, month, or year
  • --json - Output raw JSON

Examples

# Basic search
python3 scripts/search.py "best AI coding agents 2024"

# Get 10 results
python3 scripts/search.py "market research tools" --count 10

# Recent news only
python3 scripts/search.py "AI regulation" --recency week

API Key

Get your Perplexity API key at: https://perplexity.ai/account/api

Pricing: $5 per 1,000 requests

Security

  • ✅ API key stored in config, never in code
  • ✅ Output sanitization prevents injection attacks
  • ✅ Error messages don't expose sensitive info
  • ✅ 30-second timeout on requests
  • ✅ Input validation on all parameters

Requirements

  • Python 3.7+
  • OpenClaw
  • Perplexity API key

No additional Python packages required - uses only stdlib.

License

MIT License - See LICENSE file

Support

Permissions & Security

Security level L1: Low-risk skills with minimal permissions. Review inputs and outputs before running in production.

- API key loaded from environment only - never hardcoded - Output sanitization prevents terminal injection - Error messages don't expose sensitive information - 30-second timeout prevents hanging requests - Input validation on all parameters

Requirements

  • OpenClaw CLI installed and configured.
  • Language: Markdown
  • License: MIT
  • Topics:

FAQ

How do I install perplexity-search?

Run openclaw add @m4vf14/perplexity-search-skill in your terminal. This installs perplexity-search into your OpenClaw Skills catalog.

Does this skill run locally or in the cloud?

OpenClaw Skills execute locally by default. Review the SKILL.md and permissions before running any skill.

Where can I verify the source code?

The source repository is available at https://github.com/openclaw/skills/tree/main/skills/m4vf14/perplexity-search-skill. Review commits and README documentation before installing.