Object Subtitles

Methods: enable | info | enabledefault | enableautoplay | upload | download

enable

Enable subtitles

Parameters:

  • String apikey (apikey of your project)
  • String media_code (your media key)
  • Boolean enable (enable/disable subtitles, values are 1 and 0)

Sample query:

https://boomstream.com/api/subtitles/enable?apikey=[API_KEY]&code=[MEDIA_CODE]&format=json&enable=1

Sample response:

"Message": "Changes have been successfully saved",
"enable": "yes",
"Status": "Success",
"Version": "1.0"

info

Subtitles info

Parameters:

  • String apikey (apikey of your project)
  • String media_code (your media key)

Sample query:

https://boomstream.com/api/subtitles/info?apikey=[API_KEY]&code=[MEDIA_CODE]&format=json

Sample response:

"enabled": "yes",
    "languages": [
        {
            "index": 1,
            "lang_code": "en",
            "lang_title": "English",
            "subtitles": [
                {
                    "title": "first",
                    "time_from": "00:00:00.000",
                    "time_to": "00:00:05.000"
                },
                {
                    "title": "second",
                    "time_from": "00:00:05.000",
                    "time_to": "00:00:20.000"
                },
                {
                    "title": "third",
                    "time_from": "00:00:20.000",
                    "time_to": "00:00:30.000"
                },
                {
                    "title": "fourth",
                    "time_from": "00:00:30.000",
                    "time_to": "00:00:45.000"
                }
            ],
            "is_default": "no",
            "is_autoplay": "no"
        }
    ],
    "Status": "Success",
    "Version": "1.0"

enabledefault

Select default subtitle language

Parameters:

  • String apikey (apikey of your project)
  • String media_code (your media key)
  • Boolean enable (enable/disable subtitles, values are 1 and 0)
  • String lang_code (language code)

Sample query:

https://boomstream.com/api/subtitles/enabledefault?apikey=[API_KEY]&code=[MEDIA_CODE]&format=json&lang_code=en&enable=1

Sample response:

"Message": "The default language selected is English",
"Status": "Success",
"Version": "1.0"

enableautoplay

Select subtitle language for autoplay

Parameters:

  • String apikey (apikey of your project)
  • String media_code (your media key)
  • Boolean enable (enable/disable subtitles, values are 1 and 0)
  • String lang_code (language code)

Sample query:

https://boomstream.com/api/subtitles/enableautoplay?apikey=[API_KEY]&code=[MEDIA_CODE]&format=json&lang_code=en&enable=1

Sample response:

"Message": "The default language selected is English",
"Status": "Success",
"Version": "1.0"

upload

Download subtitles using POST method

Sample query:

https://boomstream.com/api/subtitles/upload

This is a POST method, you need to upload a file with subtitles to use it

download

Download subtitles

Parameters:

  • String apikey (apikey of your project)
  • String media_code (your media key)

Sample query:

https://boomstream.com/api/subtitles/download?apikey=[API_KEY]&code=[MEDIA_CODE]&lang_code=ru