API usage overview
This guide provides an overview of using the Cloud Translation API and itsreference documentation.
Client libraries, REST, and gRPC
You can access the API through client libraries, REST, or gRPC(Cloud Translation - Advanced only).
Client libraries
Google provides client libraries for many popular languages to access the APIs.If your desired programming language is supported by the client libraries, werecommend that you use this option.
- Cloud Translation - Basicclientlibraries
- Cloud Translation - Advancedclientlibraries
| Pros | Cons |
|---|---|
| Maintained by Google. Built-inauthentication. Built-in retries. Idiomatic for each language. Efficientprotocol buffer HTTP request body. | Not available for all programming languages. |
REST
The Cloud Translation API supportsREST.
- Cloud Translation - Basictranslate text method
- Cloud Translation - Advancedoverview.
| Pros | Cons |
|---|---|
| Simple JSON interface. Well supported by many Google and third-party tools and libraries. | You must build your own client. You mustimplement authentication. You must implement retries. Less efficient JSON HTTP request body. |
gRPC
Cloud Translation - Advanced supportsgRPC. For moreinformation, see theRPC reference,which provides a generic description of the types, methods, and fields generatedfor a gRPC library.
| Pros | Cons |
|---|---|
| Supportsmany programming languages. Efficientprotocol buffer HTTP request body. | You must generate your own client from Google-supplied protocol buffers. You mustimplement authentication. You must implement retries. |
Type, method, and field names
Depending on whether you are using client libraries, REST, or gRPC, the type,method, and field names for the API vary:
- REST is arranged by resource hierarchies and their methods.
- Client libraries and gRPC are arranged by services and their methods.
- REST field names use camel case, though the API service will accept eithercamel case or snake case.
- gRPC field names use snake case.
- Client library field names use either title case, camel case or snake case,depending on which name is idiomatic for the language.
API editions
Cloud Translation offers two editions: Basic (v2) and Advanced (v3). Each editionhas its own set of APIs and capabilities. For more information, see theEditions page.
What's next
- For more information about using client libraries or REST, see get startedtranslating text withv3 orv2.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-12-15 UTC.