Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

An unofficial Duckduckgo.com API with performance and simplicity in mind

License

NotificationsYou must be signed in to change notification settings

nstrydom2/duckduckgo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

90 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CI

This is an unofficial Duckduckgo API created to grab the first 25 results queried from <duckduckgo.com>. The website <duckduckgo.com> does provide an api, however I didn't like the results. So, now we are here... I rolled my own unofficial Duckduckgo API for easy utilization in a Java based project. Just make sure you're rocking maven in project, and you're in our little club 😉

Getting Started

These instructions will get you a copy of the project up and running on your localmachine for development and testing purposes. See deployment for notes on how todeploy the project on a live system.

Prerequisites

Java 8 is required to run this application, other than that there are noprerequisites for the project, as the dependencies are included in thepom.xml file.

Installing

To install the library is as simple as cloning the repository and building a jar fileby running

mvn clean package

Then it's as easy as importing the jar into you project as a dependency! Alternatively,you can install the library via a maven repository. Simply add the following to yourprojectspom.xml file

<dependency>    <groupId>org.bitnick.web</groupId>    <artifactId>duckduckgo</artifactId>    <version>[CURRENT VERSION]</version></dependency>

And have fun!

Dev Notes

Run unit tests locally:

mvntest

Usage

Import the module and instantiate theWebSearch() constructor by calling the static methodWebSearch.instanceOf(). Finally, call the search method and enjoy!

WebSearchwebSearchTest =WebSearch.instanceOf();List<SearchResult>anonfileResults =webSearchTest.search("anonfile api");anonfileResults.forEach(x ->System.out.printf("%s\n%s\n%s\n\n",x.getTitle(),x.getUrl(),x.getDescription()));

Lightweight and simple searching on the Duckduckgo website. Enjoy!

Built With

  • jsoup - Java HTML Parser
  • JUnit - Unit Testing Framework
  • JSON - A Java JSON library

Versioning

Navigate totags on this repositoryto see all available versions.

Authors

NameMail AddressGitHub Profile
Nicholas Strydomnstrydom@gmail.comnstrydom2

See also the list ofcontributorswho participated in this project.

License

This project is licensed under the MIT License - see the LICENSE.md license file for more details.

Acknowledgments

  • My Family
  • Paps
  • Hat tip to anyone whose code was used
  • Inspiration
  • etc

About

An unofficial Duckduckgo.com API with performance and simplicity in mind

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp