Text-Translation-API-V3-C-Sharp icon indicating copy to clipboard operation
Text-Translation-API-V3-C-Sharp copied to clipboard


page_type: sample name: Microsoft Translator C# samples (v3) description: This repository includes C# code samples for Microsoft Translator. urlFragment: translator-c-sharp-v3 languages:

  • csharp products:
  • azure
  • azure-cognitive-services
  • azure-translator

Translator API V3 - .NET Core Samples, C#

This repository includes .NET Core samples for Microsoft Translator. 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

Get started with the Translator quickstart.

Prerequisites

Here's what you'll need before you use these samples:

Code samples

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: dotnet new console -o your_project_name
  • Copy the code from one of the samples into Program.cs.
  • Set your subscription key.
  • Run the program from the project directory: dotnet run.

Resources