English Word Translator API

FREEMIUM
By Gary | Updated 5 days ago | Translation
Popularity

9.3 / 10

Latency

467ms

Service Level

100%

Health Check

100%

README

Quick Usage

Step 1: Get language code

> You can skip this if hou already know the language code.

curl --request GET \
	--url https://english-word-translator-api.p.rapidapi.com/languages \
	--header 'X-RapidAPI-Key: Your-API-Key'

It will return following JSON:

[
  {
    "code": "af",
    "name": "Afrikaans",
    "nativeName": "Afrikaans"
  },
  {
    "code": "ar",
    "name": "Arabic",
    "nativeName": "العربية"
  },
  // more languages
  {
    "code": "zh-Hans",
    "name": "Chinese Simplified",
    "nativeName": "中文 (简体)"
  }
]

The value of code column is the target language we will use.

Step2: Get word translation

curl --request GET \
	--url 'https://english-word-translator-api.p.rapidapi.com/translate?text=apple&to_lang=ar' \
	--header 'X-RapidAPI-Key: Your-API-Key'

We need to pass 2 parameters:

  • text: The word to translate.
  • to_lang: The target language, which should be the language code from Step 1.

This will response:

{
  "word": "apple",
  "language": "ar",
  "proficiency": "A1",
  "pronunciations": [
    {
      "id": "af3ece18c8ad5f84",
      "pronunciation": "/ˈæpl/",
      "accent": "UK",
      "hasAudio": true
    },
    {
      "id": "af3ece18c8ad5f85",
      "pronunciation": "/ˈæpl/",
      "accent": "US",
      "hasAudio": true
    }
  ],
  "translations": [
    {
      "translation": "ابل",
      "confidence": 0.3298,
      "posTag": "NOUN"
    },
    // more translations
  ]
}

Step 3: Get audio (Optional)

curl --request GET \
	--url 'https://english-word-translator-api.p.rapidapi.com/audio?pronunciation_id=the_pronunciation_id' \
	--header 'X-RapidAPI-Key: Your-API-Key'

We need pass 1 parameter:

  • pronunciation_id: The pronunciation id from Step 2.

This will response a stream that can be embedded to you code or download it as mp3.

Followers: 2
API Creator:
Rapid account: Gary
Gary
guozaom
Log In to Rate API
Rating: 5 - Votes: 2