百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
G

google-this

> 编程语言
开源

这是一个简单而强大的模块,可从 Google 获取有机搜索结果以及更多内容。

378 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

这是一个简单而强大的模块,可从 Google 获取有机搜索结果以及更多内容。

Google This

A simple yet powerful module to retrieve organic search results and much more from Google.

Installation - Getting Started - Image Search - Related Projects - See Also

Installation

bash
# NPM
npm install googlethis@latest

# Yarn
yarn add googlethis@latest

# Git 
npm install LuanRT:google-this

Usage

javascript
// const google = require('googlethis');
import google from 'googlethis';

const options = {
  page: 0, 
  safe: false, // Safe Search
  parse_ads: false, // If set to true sponsored results will be parsed
  additional_params: { 
    // add additional parameters here, see https://moz.com/blog/the-ultimate-guide-to-the-google-search-parameters and https://www.seoquake.com/blog/google-search-param/
    hl: 'en' 
  }
}
  
const response = await google.search('TWDG', options);
console.log(response); 

Output

…

What else can it do?

As you can see, the library returns a lot of data. Currently, it can retrieve and parse almost everything you can get from a google search! From knowledge graph and featured snippets to Google Dictionary, Google Translate, song lyrics and more. All you have to do is search something along the lines of “define xyz”, “translate x to y” or “xyz song lyrics” and their respective fields will appear in the response.

Examples:

Knowledge Graph:

Will look like:

…

Google Translate:

Will be:

javascript
{
   //...
   "translation": {
      "source_language":"English - detected",
      "target_language":"German",
      "source_text":"this is a test",
      "target_text":"das ist ein Test"
   }
}

Google Dictionary:

↓↓↓

javascript
{
   //...
   "dictionary":{
      "word":"a·maz·ing",
      "phonetic":"/əˈmāziNG/",
      "audio":"https://ssl.gstatic.com/dictionary/static/sounds/20200429/amazing--_us_1.mp3",
      "definitions":[
         "causing great surprise or wonder; astonishing.",
         "startlingly impressive."
      ],
      "examples":[
         "\"an amazing number of people registered\"",
         "\"she makes the most amazing cakes\""
      ]
   }
}

Pretty amazing, isn't it? :D

For more info check out the examples file.

Image Search

The library also supports image search & reverse image search.

Check it out:

javascript
// const google = require('googlethis');
import google from 'googlethis';

// Image Search
const images = await google.image('The Wolf Among Us', { safe: false });
console.log(images); 
 
// Reverse Image Search
const my_awesome_image = fs.readFileSync('./wow.png');
const reverse = await google.search(my_awesome_image, { ris: true });

console.log(reverse.results);

Image Search output

…

Reverse Image Search output

…

See Also

  • YouTube.js: Full-featured wrapper around YouTube's private API.

Related Projects

  • GoogleThis by Tokipudi: A Discord bot meant to integrate features from this library.

Contributing

Contributions, issues and feature requests are welcome. Feel free to check issues page if you want to contribute.

Contributors

Contact

LuanRT - @lrt_nooneknows - [email protected]

Project Link: https://github.com/LuanRT/google-this

License

MIT

(back to top)

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

JavaScriptgooglegoogle-scrapergoogle-scrapinggoogle-search

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言