The Perplexity Search API returns real-time, grounded web search results.Documentation Index
Fetch the complete documentation index at: https://docs.langchain.com/llms.txt
Use this file to discover all available pages before exploring further.
PerplexitySearchResults is a LangChain tool wrapper that lets agents query the API and receive a JSON array of search results.
Overview
Integration details
| Class | Package | PY support | Version |
|---|---|---|---|
PerplexitySearchResults | @langchain/perplexity | ✅ |
Setup
The integration lives in the@langchain/perplexity package:
Credentials
Set up a Perplexity API key and set it as an environment variable namedPERPLEXITY_API_KEY:
Instantiation
maxResults, country, searchDomainFilter, searchRecencyFilter, searchAfterDate, and searchBeforeDate. See the Perplexity Search API parameters for details.
Invocation
Direct call
title, url, snippet, date, and last_updated.
Use with an agent
API reference
For detailed documentation of allPerplexitySearchResults features and configurations head to the API reference.
Connect these docs to Claude, VSCode, and more via MCP for real-time answers.

