ddg3
A Python library for querying the Duck Duck Go API.
Copyright Michael Stephens me@mikej.st, released under a BSD-style license.
Updated for Python3 by Jacobi Petrucciani jacobi@mimirhq.com
Source: https://github.com/jpetrucciani/python-duckduckgo
Installation
To install run
pip install ddg3
or
python setup.py install
Usage
import ddg3
r = ddg3.query('Duck Duck Go')
r.type # 'answer'
r.results[0].text # 'Official site'
r.results[0].url # '<http://duckduckgo.com/>'
r.abstract.url # '<http://en.wikipedia.org/wiki/Duck_Duck_Go>'
r.abstract.source # 'Wikipedia'
r = ddg3.query('Python')
r.type # 'disambiguation'
r.related[6].text # 'Python (programming language), a computer programming language'
r.related[6].url # '<http://duckduckgo.com/Python_(programming_language)>'
r = ddg3.query('1 + 1')
r.type # 'nothing'
r.answer.text # '1 + 1 = 2'
r.answer.type # 'calc'
Metadata
Release files for ddg3 0.6.8
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| ddg3-0.6.8.tar.gz | 5.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| ddg3-0.6.8-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.9 kB
Release files / ddg3-0.6.8.tar.gz
| Download URL | ddg3-0.6.8.tar.gz |
|---|---|
| Size | 5.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3a91ecec252296cbe0e37d9366b0b4ad2d89d0b425d56efa0e1f1c583aa6e4dd
|
|
BLAKE2b-256 checksum How to use checksums |
b6abc3eba78bc73477a5ca85aaf6d4999f0960437069d43a14ab4121eb633af3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.6
|
Release files / ddg3-0.6.8-py3-none-any.whl
| Download URL | ddg3-0.6.8-py3-none-any.whl |
|---|---|
| Size | 4.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f152fa0d7903506e16cf9cfe5b5f092244af520a4b55cab49d365f8109cc9d09
|
|
BLAKE2b-256 checksum How to use checksums |
e3cffbdb53b36891ddb6669ccbf17e8c26e82eefb9726e5a0ed23dbb50b6449c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.6
|