Dictionary API Entry

class Dicthon.Dictionary_API_Entry(word: str)[source]

Instantiate a Dictionary API entry. https://dictionaryapi.dev/ This instance will query the entry on the API and enables you to access the following: ✔︎ List of Audio Pronunciation Links

✔︎ List of Antonyms

✔︎ List of Synonyms

✔︎ List of Word Classes

✔︎ List of Definitions

✔︎ List of Definitions with Example

✔︎ List of Phonetic Text Representations

✔︎ Raw JSON entry

Parameters

word (str.) – The word to search.

get_all_antonyms()[source]

A list with the antonyms found for the word

Returns

list with antonyms.

Return type

list

A list with the audio pronunciation links

Returns

list with links.

Return type

list

get_all_definitions()[source]

A list with all the word definitions

Returns

list with definitions.

Return type

list

get_all_definitions_with_example()[source]

A list with all the word definitions which have an example.

Returns

list definition and example.

Return type

list

get_all_meanings()[source]

A list with lists of meanings

Returns

list with lists of meanings.

Return type

list

get_all_parts_of_speech()[source]

A list with all classes the word has.

Returns

list word classes.

Return type

list

get_all_phonetic_text_representation()[source]

A list with all the phonetic representations the word has.

Returns

list with phonetic text representation.

Return type

list

get_all_phonetics()[source]

A list with all the word phonetics and links.

Returns

list with phonetics.

Return type

list

get_all_synonyms()[source]

A list with the synonyms found for the word

Returns

list with synonyms.

Return type

list

get_dict_entry()[source]

Based on the word defined in the initialization, do a GET request in the API.

Returns

the API answer.

Return type

list