Translate (request for document translation)
    • PDF

    Translate (request for document translation)

    • PDF

    Article summary

    Overview

    • API for requesting to translate document files (POST)
    • For normal uploads, it is used to issue request ID and → call Status/Download API.
    • Concurrent requests are limited (limits API calls when a document is already in the translation process).

    Header

    NameDescription
    Content-TypeNeed to send in multipart/form-data format
    X-NCP-APIGW-API-KEY-IDClient ID issued when registering the NAVER Cloud Platform app
    X-NCP-APIGW-API-KEYSecret key issued when registering the NAVER Cloud Platform app

    Parameter

    NameTypeRequiredDescription
    sourceString{ko,ja,en,zh-CN}trueSource language code
    * If set to auto, the source language is automatically detected
    targetString{ko,ja,en,zh-CN}trueTarget language code
    fileFiletrueFile to be translated

    Response

    Return in JSON format

    Field NameTypeDescription
    dataJSON Object
    data requestidStringIssue request ID for the requested file translation

    Example on successful request

    {
      "data": {
        "requestId": "20201007_2522985202669_001"
      }
    }
    

    Errors

    {
      "error": {
        "errorCode": "25001",
        "message": "API call failed"
      }
    }
    
    HTTP Status CodeCodeMessageDescription
    40000006API call failedRequest to unsupported language pairs, file extensions
    50025001API call failedInternal server error
    41325004Request Entity Too LargeExceeded the limited file size (100 MB)
    42925005Too many requestsIf you have a file currently being translated

    CURL Example

    $ curl -X POST -F file=@a.xlsx -F source=ko -F target=en 'https://naveropenapi.apigw.ntruss.com/doc-trans/v1/translate'
    {"data":{"requestId":"20201007_2522985202669"}}
    

    Was this article helpful?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.