In-Context Subtitle Translation Integration

Your integration with the Enterprise TMS can optionally include a live, in-context experience for subtitle files and their accompanying videos. To support this via API, you have the option to upload the video to the TMS or you can host the video and provide a URL (must be the path to the actual video file, not a link to YouTube, Vimeo, etc.).

Use this document as a guide to enable in-context translation for SRT files

Please note that if you are hosting the videos yourself you do not need the majority of the information in this guide. When you use the POST /document call, simply populate subtitle_video_url with the URL where you are hosting your video. We support links to video files supported by HTML5 (not streaming services) and m3u8 video manifest files.

API Diagram

Uploading videos and SRT files for In-Context Translation

Additional Details

  1. Before making any API calls to upload videos and documents to the TMS, the integration will need to use an access token associated with a user in the Enterprise TMS who:

    1. Has at least the Project Manager role in the TMS. 

    2. Is at least a Shared User of the project where you will be uploading the video and SRT files. 

  2. Upload the video file to the Enterprise TMS using the POST /video-service/api/videos call (more details about the actual call below). 

    1. The video file format must be compatible with HTML5 to be loaded in our context viewer

  3. This is a synchronous API call (meaning the response will be provided when the video file has successfully been uploaded to the Enterprise TMS).

    1. If you are uploading large video files, we recommend that you extend or disable the default request timeout setting.

    2. If the video fails to upload for any reason, you will be given a 400 response (see more details about responses below).

    3. Be sure to store both the URL where Enterprise is hosting the video and the UUID of the video for future use. 

  4. Use the POST /document call to upload the SRT file to the TMS. If your organization wants in-context translation for that file, make sure you also populate the subtitle_video_url parameter with the URL Enterprise provided in response to the POST /video-service/api/videos call. 

  5. When you POST the document to the TMS, we will respond with the UUID of the document, which you will use for future calls specifically for that document. See the devzone for more information. 

Available Endpoints for Managing Videos Hosted in the TMS

GET https://myaccount.lingotek.com/video-service/api/videos

  • Required authorization: project manager

  • Required parameters:

    • community_id=[uuid]

    • project_id=[uuid]

  • Returns one of the following:

    • Status 200 and a list of zero or more video JSON objects. The response does not include the video file. 

    • Status 400 and a missing/malformed parameters error

    • Status 403 and a forbidden message if not found or unauthorized.

GET https://myaccount.lingotek.com/video-service/api/videos/[uuid]

  • Required authorization: project manager

  • Required parameters:

    • (none)

  • Returns one of the following:

    • Status 200 and a video JSON object. The response does not include the video file.  

    • Status 400 and a missing/malformed parameters error message. 

    • Status 403 and a forbidden message if not found or unauthorized.

GET https://myaccount.lingotek.com/video-service/api/videos/content/[uuid]

  • Required authorization: project manager

  • Required parameters:

    • N/A

  • Returns one of the following:

    • Status 200 and the video file downloaded as an attachment.

    • Status 400 and a missing/malformed parameters error message.

    • Status 403 and a forbidden message if not found or unauthorized.

POST https://myaccount.lingotek.com/video-service/api/videos

  • Required authorization: project manager and shared user fo the project. 

  • Required parameters:

    • community_id = [uuid]

    • project_id = [uuid]

    • video_file = [multi-part]

  • Returns one of the following:

    • Status 201 and a created video object. The response does not include the video file.

      • Includes a URL with the video files' UUID to give access the video for future calls. 

    • Status 400 and a missing/malformed parameters

    • Status 403 and a forbidden message if no access to community and/or project

DELETE https://myaccount.lingotek.com/video-service/api/videos/[uuid]

  • Required authorization: project manager

  • Required parameters:

    • N/A

  • Returns one of the following:

    • Status 204 without data (means success)

    • Status 400 and a missing/malformed parameters error

    • Status 403 and a forbidden message if not found or no access to community and/or project

Video Hosting Details

  • Enterprise will only host the video for 45 days from the time it was uploaded to our system. After it has been hosted for 45 days, it will be deleted and you can re-upload it if necessary. 

  • The video will NOT be deleted when documents referencing that video are deleted or archived. It will continue to exist until the 45 days are met. 

  • Currently, you cannot upload videos larger than 2GB to the Enterprise TMS. 

  • The video file format must be compatible with HTML5 to be loaded in our context viewer

Since this video is only meant to provide context, it is best to upload smaller videos with lower quality so linguists throughout the world can easily load and view the videos while translating. Large and high-quality videos could cause buffering issues.

On this page

Related Pages