Skip to content
RSFlowHub
  1. Home
  2. APIs
  3. Text & Language
  4. Multilingual AI Translation API
Text & Language API

Multilingual AI Translation API

High-accuracy, context-aware AI text translation with HTML tag preservation.

POST https://rsflowhub.com/api/v1/ai/translation
  • 1 credit per call
  • X-API-Key header
  • JSON in, JSON out
POST /api/v1/ai/translation
{
    "text": "Hello, how can I help you today?",
    "translate": true,
    "target_language": "Spanish"
}
200 OK response.json
{
    "result": {
        "detected_language": "en",
        "translation_applied": true,
        "translated_text": "Tu pedido ha sido enviado y llegar\u00e1 el viernes.",
        "target_language": "es",
        "translations": [
            {
                "target_language": "es",
                "translated_text": "Tu pedido ha sido enviado y llegar\u00e1 el viernes."
            }
        ]
    }
}
Definition

What is the Multilingual AI Translation API?

Multilingual AI Translation API is a REST API on RSFlowHub for web, mobile and AI agent applications. Send a JSON request to POST /api/v1/ai/translation with your API key; RSFlowHub runs it on a tuned AI model, falls back to a backup provider if needed, and returns a structured JSON result, usually within 1 to 3 seconds.

Try it without code or signup: Free hinglish and hindi translator

Endpoint
POST /api/v1/ai/translation
Authentication
X-API-Key header
Price
1 credit per call
Rate limit
10 to 120 requests / minute by plan
Typical response
1 to 3 seconds
Format
JSON, UTF-8

Request parameters

Send these fields as a JSON body. An invalid or missing field returns a 422 error that names the field.

FieldTypeRequiredDescription
text string Required The user text to analyze or translate (Max: 15,000 characters).
translate boolean Optional Whether to apply translation. Set to false to just detect language. Default is true.
target_language string Optional A single language to translate into. Required if target_languages is not provided.
target_languages array of strings Optional Translate text into multiple languages at once (Max 10 items).
preserve_formatting boolean Optional Optional. If true, preserves HTML/XML tags and Markdown symbols verbatim without translating them. Default is true.
protected_keys array of strings Optional Optional. List of dynamic placeholders/variables (e.g. ["user_name", "count"]) that must NOT be translated. Max 30 items.
glossary object Optional Optional. Custom key-value terminology dictionary (e.g. {"Wallet": "Billetera"}) to enforce exact translations. Max 30 items.
tone string Optional Optional. Custom tone style. Options: "formal", "casual", "friendly", "professional".

Code examples

Copy, replace rfh_your_api_key with your key and run. Prefer a client library? See the official SDKs.

request.sh
curl -X POST "https://rsflowhub.com/api/v1/ai/translation" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: rfh_your_api_key" \
  -d '{"text":"Hello, how can I help you today?","translate":true,"target_language":"Spanish"}'

Response

Every RSFlowHub endpoint uses the same envelope, so one parser handles all of them. Failed calls are not charged.

response.json
{
    "success": true,
    "request_id": "req_3f9a2c7e-5b1d-4e8a-9c2f-7d6e1a0b4c8d",
    "data": {
        "result": {
            "detected_language": "en",
            "translation_applied": true,
            "translated_text": "Tu pedido ha sido enviado y llegar\u00e1 el viernes.",
            "target_language": "es",
            "translations": [
                {
                    "target_language": "es",
                    "translated_text": "Tu pedido ha sido enviado y llegar\u00e1 el viernes."
                }
            ]
        }
    },
    "meta": {
        "version": "v1",
        "timestamp": "2026-10-05T09:30:00Z"
    }
}
Envelope fields
FieldTypeMeaning
successbooleantrue when the call worked, false on any error.
request_idstringUnique id for this call. Quote it when you contact support.
data.resultobjectThe result of this endpoint (see the example).
errorobjectOnly on failure: code, message and details per field.
metaobjectAPI version and server timestamp.

All error codes: Errors reference

Features

Context-Aware Accuracy

Translates nuanced business terms, slang, and technical jargon accurately based on domain context.

HTML & Variable Protection

Preserves HTML tags, JSON keys, and {variable} placeholders without breaking markup structure.

50+ Languages Supported

Instant bidirectional translation between English, Spanish, French, German, Gujarati, Hindi, Japanese, and more.

Developer-First REST API

Clean JSON request/response format with ready-to-use SDKs and cURL, PHP, JS, and Python snippets.

Use cases

How teams use the Multilingual AI Translation API in production.

E-Commerce

E-Commerce Catalog Localization

Automatically translate product titles, bullet points, and descriptions into multiple languages upon publishing.

Input
Luxury Leather Wallet with RFID Protection
Output
Cartera de cuero de lujo con protección RFID (Spanish)

Translates new content in seconds instead of waiting days for manual localization.

Customer Support

Real-Time Support Chat Translation

Translate incoming support tickets and live chat messages for helpdesk agents in real-time.

Input
How can I reset my account password?
Output
કહેવી રીતે હું મારૂ એકાઉન્ટ પાસવર્ડ રિસેટ કરી શકું? (Gujarati)

Supports global customers without hiring multi-lingual support teams.

SaaS & Apps

Dynamic SaaS App Internationalization (i18n)

Translate dynamic user notifications, transactional emails, and dashboard UI copy on the fly.

Input
Your subscription was renewed successfully!
Output
Votre abonnement a été renouvelé avec succès ! (French)

Seamless global scaling for web and mobile applications.

AI chatbot

A multilingual AI chatbot with the translation API

Your visitors do not all write in the language your documents are in. Translate the visitor message into your support language, answer from your knowledge base, then translate the answer back, so one chatbot serves every language.

How it works in a chatbot

  1. Visitor writes in Hindi
  2. API translates it to English, the chatbot finds the answer
  3. API translates the answer back to Hindi for the visitor

One knowledge base, many languages

Write your FAQs once and let the chatbot answer in the visitor's language.

Tone and context kept

Translation keeps the meaning and tone, which matters for support replies.

Translate transcripts

Read a chat in a language you do not speak by translating it for your team.

Want a chatbot without building one? The RSFlowHub AI chatbot for your website is live in about 5 minutes with one script tag: it answers from your documents, captures leads and creates support tickets. Read the chat widget guide, try the live chatbot demo, see chatbot pricing, or build your own with the chatbots API.

Multilingual AI Translation API vs building it yourself

The same job done three ways.

TopicRSFlowHub APIRaw LLM promptsRules / regex
Output Validated JSON fieldsFree text you have to parseFixed patterns only
Setup One POST request, no promptsWrite and maintain prompts and parsingWrite and maintain rule lists
Provider outage Automatic fallback to a backup modelYou build retries and a second vendorNot applicable
Pricing 1 credit per call, failed calls freePer token, per vendorYour own servers and upkeep
Understands context Yes, AI modelYes, AI modelNo, keywords only

Frequently asked questions

Which programming languages and frameworks are supported?
RSFlowHub APIs are standard RESTful endpoints. You can call them from PHP (Laravel, Symfony), Python (Django, FastAPI), JavaScript/Node.js, Go, Java, C#, or plain cURL.
What is the average response time and platform availability?
Most Translation API requests complete in 1 to 3 seconds, depending on text length and the AI model.
Does the translation API preserve HTML tags and variable formatting?
Yes! The API intelligently identifies HTML markup (e.g., <strong>, <a href="...">), Markdown elements, and variable placeholders (e.g., {user_name}, :count), preserving them intact while translating only human text.
How many credits does each request consume?
Translation requests consume 1 base credit per call for standard payloads under character limits.
Is my text data secure and GDPR compliant?
Absolutely. All API traffic is encrypted using HTTPS/TLS 1.3. Payload data is processed in memory and never stored or used for public AI model training.

Start using the Multilingual AI Translation API

Free plan with 100 credits/month + 1,000 bonus credits when you sign in before 23 Nov. Test it in the playground first, no code needed.

RSFlowHub

Sign in to continue

You'll come straight back to this page.

Forgot password?

New to RSFlowHub? Create a free account