From 215e99a7f5b418df7a5c4b32763e7975706fedb3 Mon Sep 17 00:00:00 2001 From: olivierapivideo Date: Mon, 7 Oct 2024 08:28:51 +0000 Subject: [PATCH] Add transcript feature --- .../oas_apivideo.yaml-defaut-cli.sha256 | 2 +- Sources/Models/Video.swift | 16 ++++++- Sources/Models/VideoCreationPayload.swift | 47 ++++++++++++++++++- Sources/Models/VideoUpdatePayload.swift | 47 ++++++++++++++++++- .../payloads/videos/create/responses/201.json | 2 + .../create/responses/{400.json => 400-0.json} | 0 .../videos/create/responses/400-1.json | 7 +++ .../videos/create/responses/400-2.json | 7 +++ .../payloads/videos/get/responses/200.json | 2 + .../payloads/videos/list/responses/200.json | 6 +++ .../payloads/videos/update/responses/200.json | 2 + .../update/responses/{400.json => 400-0.json} | 0 .../videos/update/responses/400-1.json | 7 +++ .../videos/update/responses/400-2.json | 7 +++ .../uploadWithUploadToken/responses/201.json | 1 + docs/Video.md | 2 + docs/VideoCreationPayload.md | 2 + docs/VideoUpdatePayload.md | 2 + docs/VideosAPI.md | 4 +- 19 files changed, 157 insertions(+), 6 deletions(-) rename Tests/TestResources/payloads/videos/create/responses/{400.json => 400-0.json} (100%) create mode 100644 Tests/TestResources/payloads/videos/create/responses/400-1.json create mode 100644 Tests/TestResources/payloads/videos/create/responses/400-2.json rename Tests/TestResources/payloads/videos/update/responses/{400.json => 400-0.json} (100%) create mode 100644 Tests/TestResources/payloads/videos/update/responses/400-1.json create mode 100644 Tests/TestResources/payloads/videos/update/responses/400-2.json diff --git a/.openapi-generator/oas_apivideo.yaml-defaut-cli.sha256 b/.openapi-generator/oas_apivideo.yaml-defaut-cli.sha256 index 0b1c058..3edc83e 100644 --- a/.openapi-generator/oas_apivideo.yaml-defaut-cli.sha256 +++ b/.openapi-generator/oas_apivideo.yaml-defaut-cli.sha256 @@ -1 +1 @@ -49fece4f39cb92341dc77e0eb7371a152903bf6aebcfa250d289efc9018b0f72 \ No newline at end of file +408ded0eac343dc4e06f2885cbfff90ed5b358f8841ee006d063b93ab0fb7f9b \ No newline at end of file diff --git a/Sources/Models/Video.swift b/Sources/Models/Video.swift index 2204749..9ba9576 100644 --- a/Sources/Models/Video.swift +++ b/Sources/Models/Video.swift @@ -12,6 +12,10 @@ import AnyCodable public struct Video: Codable, Hashable { + public enum LanguageOrigin: String, Codable, CaseIterable { + case api = "api" + case auto = "auto" + } /** The unique identifier of the video object. */ public var videoId: String /** When a video was created, presented in ATOM UTC format. */ @@ -30,6 +34,10 @@ public struct Video: Codable, Hashable { public var deletesAt: Date? /** Returns `true` for videos you discarded when you have the Video Restore feature enabled. Returns `false` for every other video. */ public var discarded: Bool? + /** Returns the language of a video in [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. You can set the language during video creation via the API, otherwise it is detected automatically. */ + public var language: String? + /** Returns the origin of the last update on the video's `language` attribute. - `api` means that the last update was requested from the API. - `auto` means that the last update was done automatically by the API. */ + public var languageOrigin: LanguageOrigin? /** One array of tags (each tag is a string) in order to categorize a video. Tags may include spaces. */ public var tags: [String]? /** Metadata you can use to categorise and filter videos. Metadata is a list of dictionaries, where each dictionary represents a key value pair for categorising a video. */ @@ -45,7 +53,7 @@ public struct Video: Codable, Hashable { /** This lets you know whether mp4 is supported. If enabled, an mp4 URL will be provided in the response for the video. */ public var mp4Support: Bool? - public init(videoId: String, createdAt: Date? = nil, title: String? = nil, description: String? = nil, publishedAt: Date? = nil, updatedAt: Date? = nil, discardedAt: Date? = nil, deletesAt: Date? = nil, discarded: Bool? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil, source: VideoSource? = nil, assets: VideoAssets? = nil, playerId: String? = nil, _public: Bool? = nil, panoramic: Bool? = nil, mp4Support: Bool? = nil) { + public init(videoId: String, createdAt: Date? = nil, title: String? = nil, description: String? = nil, publishedAt: Date? = nil, updatedAt: Date? = nil, discardedAt: Date? = nil, deletesAt: Date? = nil, discarded: Bool? = nil, language: String? = nil, languageOrigin: LanguageOrigin? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil, source: VideoSource? = nil, assets: VideoAssets? = nil, playerId: String? = nil, _public: Bool? = nil, panoramic: Bool? = nil, mp4Support: Bool? = nil) { self.videoId = videoId self.createdAt = createdAt self.title = title @@ -55,6 +63,8 @@ public struct Video: Codable, Hashable { self.discardedAt = discardedAt self.deletesAt = deletesAt self.discarded = discarded + self.language = language + self.languageOrigin = languageOrigin self.tags = tags self.metadata = metadata self.source = source @@ -75,6 +85,8 @@ public struct Video: Codable, Hashable { case discardedAt case deletesAt case discarded + case language + case languageOrigin case tags case metadata case source @@ -98,6 +110,8 @@ public struct Video: Codable, Hashable { try container.encodeIfPresent(discardedAt, forKey: .discardedAt) try container.encodeIfPresent(deletesAt, forKey: .deletesAt) try container.encodeIfPresent(discarded, forKey: .discarded) + try container.encodeIfPresent(language, forKey: .language) + try container.encodeIfPresent(languageOrigin, forKey: .languageOrigin) try container.encodeIfPresent(tags, forKey: .tags) try container.encodeIfPresent(metadata, forKey: .metadata) try container.encodeIfPresent(source, forKey: .source) diff --git a/Sources/Models/VideoCreationPayload.swift b/Sources/Models/VideoCreationPayload.swift index 9ef38ef..0cfadfd 100644 --- a/Sources/Models/VideoCreationPayload.swift +++ b/Sources/Models/VideoCreationPayload.swift @@ -12,6 +12,41 @@ import AnyCodable public struct VideoCreationPayload: Codable, Hashable { + public enum Language: String, Codable, CaseIterable { + case ar = "ar" + case ca = "ca" + case cs = "cs" + case da = "da" + case de = "de" + case el = "el" + case en = "en" + case es = "es" + case fa = "fa" + case fi = "fi" + case fr = "fr" + case he = "he" + case hi = "hi" + case hr = "hr" + case hu = "hu" + case it = "it" + case ja = "ja" + case ko = "ko" + case ml = "ml" + case nl = "nl" + case nn = "nn" + case _false = "false" + case pl = "pl" + case pt = "pt" + case ru = "ru" + case sk = "sk" + case sl = "sl" + case te = "te" + case tr = "tr" + case uk = "uk" + case ur = "ur" + case vi = "vi" + case zh = "zh" + } /** The title of your new video. */ public var title: String /** A brief description of your video. */ @@ -32,8 +67,12 @@ public struct VideoCreationPayload: Codable, Hashable { public var metadata: [Metadata]? public var clip: VideoClip? public var watermark: VideoWatermark? + /** Use this parameter to set the language of the video. When this parameter is set, the API creates a transcript of the video using the language you specify. You must use the [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. `language` is a permanent attribute of the video. You can update it to another language using the [`PATCH /videos/{videoId}`](https://docs.api.video/reference/api/Videos#update-a-video-object) operation. This triggers the API to generate a new transcript using a different language. */ + public var language: Language? + /** Use this parameter to enable transcription. - When `true`, the API generates a transcript for the video. - The default value is `false`. - If you define a video language using the `language` parameter, the API uses that language to transcribe the video. If you do not define a language, the API detects it based on the video. - When the API generates a transcript, it will be available as a caption for the video. */ + public var transcript: Bool? - public init(title: String, description: String? = nil, source: String? = nil, _public: Bool? = true, panoramic: Bool? = false, mp4Support: Bool? = true, playerId: String? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil, clip: VideoClip? = nil, watermark: VideoWatermark? = nil) { + public init(title: String, description: String? = nil, source: String? = nil, _public: Bool? = true, panoramic: Bool? = false, mp4Support: Bool? = true, playerId: String? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil, clip: VideoClip? = nil, watermark: VideoWatermark? = nil, language: Language? = nil, transcript: Bool? = nil) { self.title = title self.description = description self.source = source @@ -45,6 +84,8 @@ public struct VideoCreationPayload: Codable, Hashable { self.metadata = metadata self.clip = clip self.watermark = watermark + self.language = language + self.transcript = transcript } public enum CodingKeys: String, CodingKey, CaseIterable { @@ -59,6 +100,8 @@ public struct VideoCreationPayload: Codable, Hashable { case metadata case clip case watermark + case language + case transcript } // Encodable protocol methods @@ -76,6 +119,8 @@ public struct VideoCreationPayload: Codable, Hashable { try container.encodeIfPresent(metadata, forKey: .metadata) try container.encodeIfPresent(clip, forKey: .clip) try container.encodeIfPresent(watermark, forKey: .watermark) + try container.encodeIfPresent(language, forKey: .language) + try container.encodeIfPresent(transcript, forKey: .transcript) } } diff --git a/Sources/Models/VideoUpdatePayload.swift b/Sources/Models/VideoUpdatePayload.swift index 53ce90c..8cd0ee3 100644 --- a/Sources/Models/VideoUpdatePayload.swift +++ b/Sources/Models/VideoUpdatePayload.swift @@ -12,6 +12,41 @@ import AnyCodable public struct VideoUpdatePayload: Codable, Hashable { + public enum Language: String, Codable, CaseIterable { + case ar = "ar" + case ca = "ca" + case cs = "cs" + case da = "da" + case de = "de" + case el = "el" + case en = "en" + case es = "es" + case fa = "fa" + case fi = "fi" + case fr = "fr" + case he = "he" + case hi = "hi" + case hr = "hr" + case hu = "hu" + case it = "it" + case ja = "ja" + case ko = "ko" + case ml = "ml" + case nl = "nl" + case nn = "nn" + case _false = "false" + case pl = "pl" + case pt = "pt" + case ru = "ru" + case sk = "sk" + case sl = "sl" + case te = "te" + case tr = "tr" + case uk = "uk" + case ur = "ur" + case vi = "vi" + case zh = "zh" + } /** The unique ID for the player you want to associate with your video. */ public var playerId: NullableString? /** The title you want to use for your video. */ @@ -28,8 +63,12 @@ public struct VideoUpdatePayload: Codable, Hashable { public var tags: [String]? /** A list (array) of dictionaries where each dictionary contains a key value pair that describes the video. As with tags, you must send the complete list of metadata you want as whatever you send here will overwrite the existing metadata for the video. */ public var metadata: [Metadata]? + /** Use this parameter to set the language of the video. When this parameter is set, the API creates a transcript of the video using the language you specify. You must use the [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. `language` is a permanent attribute of the video. You can update it to another language using the [`PATCH /videos/{videoId}`](https://docs.api.video/reference/api/Videos#update-a-video-object) operation. This triggers the API to generate a new transcript using a different language. */ + public var language: Language? + /** Use this parameter to enable transcription. - When `true`, the API generates a transcript for the video. - The default value is `false`. - If you define a video language using the `language` parameter, the API uses that language to transcribe the video. If you do not define a language, the API detects it based on the video. - When the API generates a transcript, it will be available as a caption for the video. */ + public var transcript: Bool? - public init(playerId: NullableString? = nil, title: String? = nil, description: String? = nil, _public: Bool? = nil, panoramic: Bool? = nil, mp4Support: Bool? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil) { + public init(playerId: NullableString? = nil, title: String? = nil, description: String? = nil, _public: Bool? = nil, panoramic: Bool? = nil, mp4Support: Bool? = nil, tags: [String]? = nil, metadata: [Metadata]? = nil, language: Language? = nil, transcript: Bool? = nil) { self.playerId = playerId self.title = title self.description = description @@ -38,6 +77,8 @@ public struct VideoUpdatePayload: Codable, Hashable { self.mp4Support = mp4Support self.tags = tags self.metadata = metadata + self.language = language + self.transcript = transcript } public enum CodingKeys: String, CodingKey, CaseIterable { @@ -49,6 +90,8 @@ public struct VideoUpdatePayload: Codable, Hashable { case mp4Support case tags case metadata + case language + case transcript } // Encodable protocol methods @@ -63,6 +106,8 @@ public struct VideoUpdatePayload: Codable, Hashable { try container.encodeIfPresent(mp4Support, forKey: .mp4Support) try container.encodeIfPresent(tags, forKey: .tags) try container.encodeIfPresent(metadata, forKey: .metadata) + try container.encodeIfPresent(language, forKey: .language) + try container.encodeIfPresent(transcript, forKey: .transcript) } } diff --git a/Tests/TestResources/payloads/videos/create/responses/201.json b/Tests/TestResources/payloads/videos/create/responses/201.json index fbcda04..6d0d225 100644 --- a/Tests/TestResources/payloads/videos/create/responses/201.json +++ b/Tests/TestResources/payloads/videos/create/responses/201.json @@ -2,6 +2,8 @@ "videoId" : "vi4blUQJFrYWbaG44NChkH27", "title" : "Maths video", "description" : "An amazing video explaining the string theory", + "language" : "en", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, diff --git a/Tests/TestResources/payloads/videos/create/responses/400.json b/Tests/TestResources/payloads/videos/create/responses/400-0.json similarity index 100% rename from Tests/TestResources/payloads/videos/create/responses/400.json rename to Tests/TestResources/payloads/videos/create/responses/400-0.json diff --git a/Tests/TestResources/payloads/videos/create/responses/400-1.json b/Tests/TestResources/payloads/videos/create/responses/400-1.json new file mode 100644 index 0000000..c67814e --- /dev/null +++ b/Tests/TestResources/payloads/videos/create/responses/400-1.json @@ -0,0 +1,7 @@ +{ + "type" : "https://docs.api.video/reference/invalid-attribute", + "title" : "An attribute is invalid.", + "status" : 400, + "detail" : "The \"language\" attribute must contain only letters and dashes (for example \"fr\", \"fr-BE\").", + "name" : "language" +} \ No newline at end of file diff --git a/Tests/TestResources/payloads/videos/create/responses/400-2.json b/Tests/TestResources/payloads/videos/create/responses/400-2.json new file mode 100644 index 0000000..fc103e0 --- /dev/null +++ b/Tests/TestResources/payloads/videos/create/responses/400-2.json @@ -0,0 +1,7 @@ +{ + "type" : "https://docs.api.video/reference/invalid-attribute", + "title" : "An attribute is invalid.", + "status" : 400, + "detail" : "The \"language\" attribute is not valid.", + "name" : "language" +} \ No newline at end of file diff --git a/Tests/TestResources/payloads/videos/get/responses/200.json b/Tests/TestResources/payloads/videos/get/responses/200.json index c6df209..05a4a7a 100644 --- a/Tests/TestResources/payloads/videos/get/responses/200.json +++ b/Tests/TestResources/payloads/videos/get/responses/200.json @@ -3,6 +3,8 @@ "playerId" : "pl45KFKdlddgk654dspkze", "title" : "Maths video", "description" : "An amazing video explaining string theory", + "language" : "en", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, diff --git a/Tests/TestResources/payloads/videos/list/responses/200.json b/Tests/TestResources/payloads/videos/list/responses/200.json index 16b27a5..e2747ed 100644 --- a/Tests/TestResources/payloads/videos/list/responses/200.json +++ b/Tests/TestResources/payloads/videos/list/responses/200.json @@ -4,6 +4,8 @@ "playerId" : "pl45KFKdlddgk654dspkze", "title" : "Maths video", "description" : "An amazing video explaining the string theory", + "language" : "en", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, @@ -32,6 +34,8 @@ "videoId" : "vi4blUQJFrYWbaG44NChkH27", "title" : "Video Title", "description" : "A description for your video.", + "language" : "en", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, @@ -64,6 +68,8 @@ "playerId" : "pl45KFKdlddgk654dspkze", "title" : "My Video Title", "description" : "A brief description of the video.", + "language" : "fr", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, diff --git a/Tests/TestResources/payloads/videos/update/responses/200.json b/Tests/TestResources/payloads/videos/update/responses/200.json index f466a51..db100f4 100644 --- a/Tests/TestResources/payloads/videos/update/responses/200.json +++ b/Tests/TestResources/payloads/videos/update/responses/200.json @@ -3,6 +3,8 @@ "playerId" : "pl45KFKdlddgk654dspkze", "title" : "Maths video", "description" : "An amazing video explaining the string theory", + "language" : "en", + "languageOrigin" : "api", "public" : false, "panoramic" : false, "mp4Support" : true, diff --git a/Tests/TestResources/payloads/videos/update/responses/400.json b/Tests/TestResources/payloads/videos/update/responses/400-0.json similarity index 100% rename from Tests/TestResources/payloads/videos/update/responses/400.json rename to Tests/TestResources/payloads/videos/update/responses/400-0.json diff --git a/Tests/TestResources/payloads/videos/update/responses/400-1.json b/Tests/TestResources/payloads/videos/update/responses/400-1.json new file mode 100644 index 0000000..c67814e --- /dev/null +++ b/Tests/TestResources/payloads/videos/update/responses/400-1.json @@ -0,0 +1,7 @@ +{ + "type" : "https://docs.api.video/reference/invalid-attribute", + "title" : "An attribute is invalid.", + "status" : 400, + "detail" : "The \"language\" attribute must contain only letters and dashes (for example \"fr\", \"fr-BE\").", + "name" : "language" +} \ No newline at end of file diff --git a/Tests/TestResources/payloads/videos/update/responses/400-2.json b/Tests/TestResources/payloads/videos/update/responses/400-2.json new file mode 100644 index 0000000..fc103e0 --- /dev/null +++ b/Tests/TestResources/payloads/videos/update/responses/400-2.json @@ -0,0 +1,7 @@ +{ + "type" : "https://docs.api.video/reference/invalid-attribute", + "title" : "An attribute is invalid.", + "status" : 400, + "detail" : "The \"language\" attribute is not valid.", + "name" : "language" +} \ No newline at end of file diff --git a/Tests/TestResources/payloads/videos/uploadWithUploadToken/responses/201.json b/Tests/TestResources/payloads/videos/uploadWithUploadToken/responses/201.json index 8aeb102..37424d1 100644 --- a/Tests/TestResources/payloads/videos/uploadWithUploadToken/responses/201.json +++ b/Tests/TestResources/payloads/videos/uploadWithUploadToken/responses/201.json @@ -3,6 +3,7 @@ "playerId" : "pl45KFKdlddgk654dspkze", "title" : "Maths video", "description" : "An amazing video explaining the string theory", + "language" : "en", "public" : false, "panoramic" : false, "tags" : [ "maths", "string theory", "video" ], diff --git a/docs/Video.md b/docs/Video.md index 2156f95..6d425e8 100644 --- a/docs/Video.md +++ b/docs/Video.md @@ -12,6 +12,8 @@ Name | Type | Description | Notes **discardedAt** | **Date** | The date and time the video was discarded. The API populates this field only if you have the Video Restore feature enabled and discard a video. Date and time are provided using ATOM UTC format. | [optional] **deletesAt** | **Date** | The date and time the video will be permanently deleted. The API populates this field only if you have the Video Restore feature enabled and discard a video. Discarded videos are pemanently deleted after 90 days. Date and time are provided using ATOM UTC format. | [optional] **discarded** | **Bool** | Returns `true` for videos you discarded when you have the Video Restore feature enabled. Returns `false` for every other video. | [optional] +**language** | **String** | Returns the language of a video in [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. You can set the language during video creation via the API, otherwise it is detected automatically. | [optional] +**languageOrigin** | **String** | Returns the origin of the last update on the video's `language` attribute. - `api` means that the last update was requested from the API. - `auto` means that the last update was done automatically by the API. | [optional] **tags** | **[String]** | One array of tags (each tag is a string) in order to categorize a video. Tags may include spaces. | [optional] **metadata** | [Metadata] | Metadata you can use to categorise and filter videos. Metadata is a list of dictionaries, where each dictionary represents a key value pair for categorising a video. | [optional] **source** | [**VideoSource**](VideoSource.md) | | [optional] diff --git a/docs/VideoCreationPayload.md b/docs/VideoCreationPayload.md index 4b383f2..0019ddf 100644 --- a/docs/VideoCreationPayload.md +++ b/docs/VideoCreationPayload.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **metadata** | [Metadata] | A list of key value pairs that you use to provide metadata for your video. | [optional] **clip** | [**VideoClip**](VideoClip.md) | | [optional] **watermark** | [**VideoWatermark**](VideoWatermark.md) | | [optional] +**language** | **String** | Use this parameter to set the language of the video. When this parameter is set, the API creates a transcript of the video using the language you specify. You must use the [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. `language` is a permanent attribute of the video. You can update it to another language using the [`PATCH /videos/{videoId}`](https://docs.api.video/reference/api/Videos#update-a-video-object) operation. This triggers the API to generate a new transcript using a different language. | [optional] +**transcript** | **Bool** | Use this parameter to enable transcription. - When `true`, the API generates a transcript for the video. - The default value is `false`. - If you define a video language using the `language` parameter, the API uses that language to transcribe the video. If you do not define a language, the API detects it based on the video. - When the API generates a transcript, it will be available as a caption for the video. | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/docs/VideoUpdatePayload.md b/docs/VideoUpdatePayload.md index ef29ef5..3b150fc 100644 --- a/docs/VideoUpdatePayload.md +++ b/docs/VideoUpdatePayload.md @@ -11,6 +11,8 @@ Name | Type | Description | Notes **mp4Support** | **Bool** | Whether the player supports the mp4 format. | [optional] **tags** | **[String]** | A list of terms or words you want to tag the video with. Make sure the list includes all the tags you want as whatever you send in this list will overwrite the existing list for the video. | [optional] **metadata** | [Metadata] | A list (array) of dictionaries where each dictionary contains a key value pair that describes the video. As with tags, you must send the complete list of metadata you want as whatever you send here will overwrite the existing metadata for the video. | [optional] +**language** | **String** | Use this parameter to set the language of the video. When this parameter is set, the API creates a transcript of the video using the language you specify. You must use the [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) format. `language` is a permanent attribute of the video. You can update it to another language using the [`PATCH /videos/{videoId}`](https://docs.api.video/reference/api/Videos#update-a-video-object) operation. This triggers the API to generate a new transcript using a different language. | [optional] +**transcript** | **Bool** | Use this parameter to enable transcription. - When `true`, the API generates a transcript for the video. - The default value is `false`. - If you define a video language using the `language` parameter, the API uses that language to transcribe the video. If you do not define a language, the API detects it based on the video. - When the API generates a transcript, it will be available as a caption for the video. | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/docs/VideosAPI.md b/docs/VideosAPI.md index bc5adda..994c5c0 100644 --- a/docs/VideosAPI.md +++ b/docs/VideosAPI.md @@ -35,7 +35,7 @@ Creates a video object. More information on video objects can be found [here](ht // The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new import ApiVideoClient -let videoCreationPayload = VideoCreationPayload(title: "title_example", description: "description_example", source: "source_example", _public: true, panoramic: false, mp4Support: true, playerId: "playerId_example", tags: ["tags_example"], metadata: [Metadata(key: "key_example", value: "value_example")], clip: VideoClip(startTimecode: "startTimecode_example", endTimecode: "endTimecode_example"), watermark: VideoWatermark(id: "id_example", top: "top_example", _left: "_left_example", bottom: "bottom_example", _right: "_right_example", width: "width_example", height: "height_example", opacity: "opacity_example")) // VideoCreationPayload | video to create +let videoCreationPayload = VideoCreationPayload(title: "title_example", description: "description_example", source: "source_example", _public: true, panoramic: false, mp4Support: true, playerId: "playerId_example", tags: ["tags_example"], metadata: [Metadata(key: "key_example", value: "value_example")], clip: VideoClip(startTimecode: "startTimecode_example", endTimecode: "endTimecode_example"), watermark: VideoWatermark(id: "id_example", top: "top_example", _left: "_left_example", bottom: "bottom_example", _right: "_right_example", width: "width_example", height: "height_example", opacity: "opacity_example"), language: "language_example", transcript: false) // VideoCreationPayload | video to create // Create a video object VideosAPI.create(videoCreationPayload: videoCreationPayload) { (response, error) in @@ -272,7 +272,7 @@ NOTE: If you are updating an array, you must provide the entire array as what yo import ApiVideoClient let videoId = "videoId_example" // String | The video ID for the video you want to update. -let videoUpdatePayload = VideoUpdatePayload(playerId: NullableString(value: "pl4k0jvEUuaTdRAEjQ4Jfrgz"), title: "title_example", description: "description_example", _public: true, panoramic: false, mp4Support: true, tags: ["tags_example"], metadata: [Metadata(key: "key_example", value: "value_example")]) // VideoUpdatePayload | +let videoUpdatePayload = VideoUpdatePayload(playerId: NullableString(value: "pl4k0jvEUuaTdRAEjQ4Jfrgz"), title: "title_example", description: "description_example", _public: true, panoramic: false, mp4Support: true, tags: ["tags_example"], metadata: [Metadata(key: "key_example", value: "value_example")], language: "language_example", transcript: false) // VideoUpdatePayload | // Update a video object VideosAPI.update(videoId: videoId, videoUpdatePayload: videoUpdatePayload) { (response, error) in