Skip to content

feat: library entry point + search filters (v1.1.0) - #125

Merged
rbuchmayer-pplx merged 3 commits into
perplexityai:mainfrom
rbuchmayer-pplx:feat-library-exports
Jul 27, 2026
Merged

feat: library entry point + search filters (v1.1.0)#125
rbuchmayer-pplx merged 3 commits into
perplexityai:mainfrom
rbuchmayer-pplx:feat-library-exports

Conversation

@rbuchmayer-pplx

@rbuchmayer-pplx rbuchmayer-pplx commented Jul 27, 2026

Copy link
Copy Markdown
Collaborator

Two additions bundled into one 1.1.0 release.

Library entry point

  • The package is bin-only today: the root entry starts a stdio server at import time, so the server cannot be embedded in another Node process
  • Adds an exports map with . -> dist/server.js (side effect free) so hosts can import { createPerplexityServer } and mount their own transport
  • Enables TypeScript declaration output and ships .d.ts files in the tarball
  • perplexity-mcp bin and npx behavior unchanged

Search filters

  • perplexity_search now supports search_recency_filter and search_domain_filter, the same fields perplexity_ask and perplexity_reason already expose, passed through to the search endpoint

Verified by installing the packed tarball into a clean project (library import returns a working server, bin still runs) and by live calls confirming domain and recency filtering behavior.

Note: merging publishes 1.1.0 (the publish workflow triggers on package.json changes).

The package was bin-only: dist/index.js starts a stdio server at import
time, so there was no way to embed the MCP server in another Node
process. Add a proper exports map pointing at dist/server.js (side
effect free) with TypeScript declarations, so hosts can
import { createPerplexityServer } and mount their own transport. The
perplexity-mcp bin and npx behavior are unchanged.
perplexity_ask and perplexity_reason already expose
search_recency_filter and search_domain_filter; perplexity_search did
not, even though the search endpoint supports both. Reuse the same
shared schema fields and pass them through to the search request.
@rbuchmayer-pplx rbuchmayer-pplx changed the title feat: expose the server factory as a library entry point (v1.1.0) feat: library entry point + search filters (v1.1.0) Jul 27, 2026
@rbuchmayer-pplx
rbuchmayer-pplx marked this pull request as ready for review July 27, 2026 18:13
The MCP initialize response and User-Agent come from a VERSION constant
that was still 1.0.0. Bump it, add a test pinning the advertised
version to package.json so they cannot drift again, remove an
accidentally committed pack tarball, and gitignore *.tgz.
@rbuchmayer-pplx
rbuchmayer-pplx merged commit 703edf7 into perplexityai:main Jul 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant