Skip to main content

py-urbandict

Build Status

py-urbandict is a client for urbandictionary.com.

Project page on github: https://github.com/novel/py-urbandict PyPI: https://pypi.org/project/urbandict/

Installation

Just run:

sudo setup.py install

Usage

To use it from command line, just use 'urbancli' tool like that:

$ urbandicli xterm
1. xterm
  Godly creature, omnipotent, guru in every way imaginable.
  
  Examples:
  
  * I wish i was an xterm

$

Usage from Python:

$ python3.2
Python 3.2 (r32:88445, Feb 27 2011, 09:51:00) 
[GCC 4.2.1 20070719  [FreeBSD]] on freebsd8
Type "help", "copyright", "credits" or "license" for more information.
>>> import urbandict
>>> urbandict.define('xterm')
[{'word': 'xterm', 'example': 'I wish i was an xterm', 'def': 'Godly creature, omnipotent, guru in every way imaginable.'}]
>>> 

It returns list of defitinitions for a term. Each list item is a dict with the following keys:

  • word -- the word itself
  • def -- definition of the term
  • example -- example of its usage (could be empty)

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

urbandict-0.6.1.tar.gz (22.3 kB view details)

Uploaded Source

File details

Details for the file urbandict-0.6.1.tar.gz.

File metadata

  • Download URL: urbandict-0.6.1.tar.gz
  • Upload date:
  • Size: 22.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.8.0 tqdm/4.35.0 CPython/3.6.9

File hashes

Hashes for urbandict-0.6.1.tar.gz
Algorithm Hash digest
SHA256 a19685ffa2450bea2df9bf328a6ce7c3c1e2213c95171ae2263b987cc54d201b
MD5 867d7a91471d9380373620da05e745e2
BLAKE2b-256 4bf01c118ab4ada5a86c511382ccb3cca614efafe499d7fd45682171c0ad612f

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.6.1 This release

1 file

0.6

1 file

0.5

1 file

0.4

1 file

0.2

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page