Returns a translated text string of the vocabulary word or text fragment.
Method: GET, URL: api/v2/dictionary/translate
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
string |
string | Body | True |
Vocabulary or text you want to translate (maximum 5000 characters) . |
from_lang |
string | Body | False |
Source text language (default is auto ). Supported Language List |
to_lang |
string | Body | False |
Target text language (default is vi ). Supported Language List |
Example: GET https://api.datpmt.com/api/v2/dictionary/translate?string=summer
=> "mùa hè"
Returns an array containing the alternative translations..
Method: GET, URL: api/v2/dictionary/alternate_translations
Parameter | Type | Position | Required | Description |
---|---|---|---|---|
string |
string | Body | True |
Vocabulary or text you want to get alternate translations (maximum 5000 characters) . |
from_lang |
string | Body | False |
Source text language (default is auto ). Supported Language List |
to_lang |
string | Body | False |
Target text language (default is vi ). Supported Language List |
Example: GET https://api.datpmt.com/api/v2/dictionary/alternate_translations?string=summer
[ "mùa hè", "mùa hạ", "hè" ]
Returns an array containing JSON definitions of the keyword by word type (noun, verb, adjective...).
Method: GET, URL: api/v2/dictionary/definitions
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
keyword |
string (single word) |
Body | True |
Vocabulary or text you want to get definitions (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/definitions?keyword=summer
[ { "noun": [ [ "The warmest season of the year, in the northern hemisphere from june to august and in the southern hemisphere from december to february.", "summer vacation.", null ], [ "A horizontal bearing beam, especially one supporting joists or rafters.", null, null ] ] }, { "verb": [ [ "Spend the summer in a particular place.", null, null ] ] } ]
Returns an array containing single-sentence strings containing the keyword.
Method: GET, URL: api/v2/dictionary/examples
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
keyword |
string (single word) |
Body | True |
Vocabulary or text you want to get examples (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/examples?keyword=summer
[ "summer vacation.", "The plant flowers in late summer.", "The golden summer of her life.", "A long hot summer." ]
Returns the transliteration of the keyword as a string.
Method: GET, URL: api/v2/dictionary/transliteration
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
keyword |
string (single word) |
Body | True |
Vocabulary you want to get transliteration (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/transliteration?keyword=summer
=> "ˈsəmər"
Returns a vocabulary or text string that suggests correct spelling.
Method: GET, URL: api/v2/dictionary/suggest
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
string |
string | Body | True |
Vocabulary or text you want to get suggest (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/suggest?string=how%20aboutt%20you?
=> "how about you?"
Returns an array with the first value being the language ISO-639 code, the second value being the precision.
Method: GET, URL: api/v2/dictionary/detection
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
string |
string | Body | True |
Vocabulary or text you want to detection (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/detection?string=summer
=> ["en",0.93254006]
Returns suggested keywords to see more.
Method: GET, URL: api/v2/dictionary/see_more
Parameter | Type | Position | Require | Description |
---|---|---|---|---|
keyword |
string | Body | True |
Vocabulary you want to see more (maximum 5000 characters) . |
Example: GET https://api.datpmt.com/api/v2/dictionary/see_more?keyword=kids
=> "kid"
Removed:
Fixed:
Added:
Fixed:
Security:
from_lang
and to_lang
).Changed:
from_lang
from en
to auto
Fixed:
from_lang
and to_lang
).Updated:
from_lang
and to_lang
).from_lang
).from_lang
).from_lang
).from_lang
).Introduction:
v2
API introduces a range of new features and improvements designed to enhance performance and usability.v1
users and incorporates advanced functionalities to better support your needs.If you have any questions or need assistance, please reach out to me on GitHub.