Skip to content

feat: Add support for POST requests on searches for privacy#5551

Open
Fijxu wants to merge 1 commit intoiv-org:masterfrom
Fijxu:post-search-request
Open

feat: Add support for POST requests on searches for privacy#5551
Fijxu wants to merge 1 commit intoiv-org:masterfrom
Fijxu:post-search-request

Conversation

@Fijxu
Copy link
Member

@Fijxu Fijxu commented Nov 30, 2025

Add support for POST requests on the search field for people that do not want their search history saved in their browser history.

image

@unixfox
Copy link
Member

unixfox commented Dec 3, 2025

Sounds like a neat feature. I know searx(ng) have that feature too.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a privacy-focused search feature that allows users to submit search queries via POST requests instead of GET requests, preventing search terms from being saved in browser history. Users can enable this feature through a new "Search privacy" preference in their settings.

Key Changes:

  • Added a new search_privacy boolean preference to user and config preferences
  • Modified the search form to use POST method when search privacy is enabled
  • Updated the search page title to display "Search" instead of the query text when privacy mode is active

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/invidious/routing.cr Added POST route handler for /search endpoint
src/invidious/routes/search.cr Updated search handler to accept both GET and POST requests by checking request method
src/invidious/views/components/search_box.ecr Conditionally sets form method to POST or GET based on search_privacy preference
src/invidious/views/search.ecr Modified page title to hide search query when search_privacy is enabled
src/invidious/user/preferences.cr Added search_privacy property to Preferences struct
src/invidious/routes/preferences.cr Added handling for search_privacy form parameter
src/invidious/config.cr Added search_privacy default configuration option
locales/en-US.json Added localization strings for the search privacy preference UI
src/invidious/views/user/preferences.ecr Added checkbox UI for enabling/disabling search privacy feature

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Fijxu
Copy link
Member Author

Fijxu commented Dec 6, 2025

Now looks like this:

image

Use already set preferences variable

Use span for description, grammar fix from Copilot
@Fijxu Fijxu force-pushed the post-search-request branch from 57beac8 to 2f67855 Compare January 31, 2026 00:03
@Fijxu Fijxu requested a review from unixfox February 16, 2026 20:42
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.

3 participants