kockburn
kockburn

Reputation: 17606

What kind of string does snippet.defaultLanguage take?

When I upload a video to my youtube channel, I'd like to be able to specify the defaultLanguage. However, the docs don't seem to be specify what kind of string I should put.

string This property is confidential to trusted testers.

The language of the text in the video resource's snippet.title and snippet.description properties.

What kind of string does snippet.defaultLanguage take?

resource: {
  snippet: {
    defaultLanguage: "English" //<-- correct ?
  }
}

Upvotes: 2

Views: 764

Answers (2)

Raleigh L.
Raleigh L.

Reputation: 913

After searching through the API client code it looks like it uses the "BCP 47" standard format: https://en.wikipedia.org/wiki/IETF_language_tag

So for English, you would do en-US

Upvotes: 0

kockburn
kockburn

Reputation: 17606

"en" is the correct string to put to set the default language.

Upvotes: 1

Related Questions