Microsoft Translator Node.js samples (v3)
This repository includes Node.js code samples for Microsoft Translator. The samples are designed to run on Node 8.12.x or later. Each sample corresponds to a Quickstart activity on doc.microsoft.com, including:
- Translating text
- Transliterating text
- Identifying the language of source text
- Getting alternate translations
- Getting a complete list of supported languages
- Determining sentence length
Here's what you'll need before you use these samples:
- Your favorite IDE or text editor
- Node 8.12.x or later
- An Azure subscription - Sign-up for a free account!
- A Translator resource - Create a Translator resource
This repository includes a sample for each of the methods made available by the Microsoft Translator API v3. To use each of the samples, follow these instructions:
- Create a new project in your favorite IDE or editor.
- Copy the code from one of the samples into your project.
- Set your subscription key.
- Run the program. For example: