diff --git a/src/libs/HeyGen/Generated/HeyGen.AssetsClient.V1AssetUpload.g.cs b/src/libs/HeyGen/Generated/HeyGen.AssetsClient.V1AssetUpload.g.cs index dedea25..a724d74 100644 --- a/src/libs/HeyGen/Generated/HeyGen.AssetsClient.V1AssetUpload.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.AssetsClient.V1AssetUpload.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class AssetsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1AssetUploadSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1AssetUploadSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1AssetUploadSecurityRequirement0, + }; partial void PrepareV1AssetUploadArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1AssetUploadRequest( @@ -28,9 +47,15 @@ partial void ProcessV1AssetUploadResponse( PrepareV1AssetUploadArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1AssetUploadSecurityRequirements, + operationName: "V1AssetUploadAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/asset", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -40,7 +65,7 @@ partial void ProcessV1AssetUploadResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.AssetsClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.AssetsClient.g.cs index 63aca81..81c009e 100644 --- a/src/libs/HeyGen/Generated/HeyGen.AssetsClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.AssetsClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Upload an image or video asset to your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1)
+ /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class AssetsClient : global::HeyGen.IAssetsClient, global: /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V1VideoDelete.g.cs b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V1VideoDelete.g.cs index 62907c7..9c95915 100644 --- a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V1VideoDelete.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V1VideoDelete.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class CreateVideoApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1VideoDeleteSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1VideoDeleteSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1VideoDeleteSecurityRequirement0, + }; partial void PrepareV1VideoDeleteArguments( global::System.Net.Http.HttpClient httpClient, ref string? videoId); @@ -35,12 +54,18 @@ partial void ProcessV1VideoDeleteResponse( httpClient: HttpClient, videoId: ref videoId); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1VideoDeleteSecurityRequirements, + operationName: "V1VideoDeleteAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/video.delete", baseUri: HttpClient.BaseAddress); __pathBuilder .AddOptionalParameter("video_id", videoId) - ; + ; var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Delete, @@ -50,7 +75,7 @@ partial void ProcessV1VideoDeleteResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V2VideoGenerate.g.cs b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V2VideoGenerate.g.cs index f906f01..f67adc2 100644 --- a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V2VideoGenerate.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.V2VideoGenerate.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class CreateVideoApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2VideoGenerateSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2VideoGenerateSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2VideoGenerateSecurityRequirement0, + }; partial void PrepareV2VideoGenerateArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.V2VideoGenerateRequest request); @@ -37,9 +56,15 @@ partial void ProcessV2VideoGenerateResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2VideoGenerateSecurityRequirements, + operationName: "V2VideoGenerateAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/video/generate", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -49,7 +74,7 @@ partial void ProcessV2VideoGenerateResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.g.cs index 23ca686..c59c875 100644 --- a/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.CreateVideoApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Create personalized avatar videos with ease using the **HeyGen API**. By selecting an avatar and a voice, you can create engaging videos for various purposes. 🌟
- /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2)
+ /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class CreateVideoApiClient : global::HeyGen.ICreateVideoAp /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Authorizations.ApiKeyInHeader.g.cs b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Authorizations.ApiKeyInHeader.g.cs index b1dae89..69a881c 100644 --- a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Authorizations.ApiKeyInHeader.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Authorizations.ApiKeyInHeader.g.cs @@ -5,13 +5,24 @@ namespace HeyGen { public sealed partial class HeyGenClient { + /// public void AuthorizeUsingApiKeyInHeader( string apiKey) { apiKey = apiKey ?? throw new global::System.ArgumentNullException(nameof(apiKey)); - Authorizations.Clear(); + for (var i = Authorizations.Count - 1; i >= 0; i--) + { + var __authorization = Authorizations[i]; + if (__authorization.Type == "ApiKey" && + __authorization.Location == "Header" && + __authorization.Name == "X-Api-Key") + { + Authorizations.RemoveAt(i); + } + } + Authorizations.Add(new global::HeyGen.EndPointAuthorization { Type = "ApiKey", diff --git a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Constructors.ApiKeyInHeader.g.cs b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Constructors.ApiKeyInHeader.g.cs index 11d2eaf..b99c911 100644 --- a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Constructors.ApiKeyInHeader.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.Constructors.ApiKeyInHeader.g.cs @@ -6,6 +6,7 @@ namespace HeyGen public sealed partial class HeyGenClient { /// + public HeyGenClient( string apiKey, global::System.Net.Http.HttpClient? httpClient = null, diff --git a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.V1VideoStatusGet.g.cs b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.V1VideoStatusGet.g.cs index bf287db..98b827a 100644 --- a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.V1VideoStatusGet.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.V1VideoStatusGet.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class HeyGenClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1VideoStatusGetSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1VideoStatusGetSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1VideoStatusGetSecurityRequirement0, + }; partial void PrepareV1VideoStatusGetArguments( global::System.Net.Http.HttpClient httpClient, ref string? videoId); @@ -35,12 +54,18 @@ partial void ProcessV1VideoStatusGetResponse( httpClient: HttpClient, videoId: ref videoId); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1VideoStatusGetSecurityRequirements, + operationName: "V1VideoStatusGetAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/video_status.get", baseUri: HttpClient.BaseAddress); __pathBuilder .AddOptionalParameter("video_id", videoId) - ; + ; var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -50,7 +75,7 @@ partial void ProcessV1VideoStatusGetResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.g.cs index e42e571..3021232 100644 --- a/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.HeyGenClient.g.cs @@ -34,7 +34,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; @@ -60,7 +60,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// Upload an image or video asset to your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1) + /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1). ///
public AssetsClient Assets => new AssetsClient(HttpClient, authorizations: Authorizations) { @@ -70,7 +70,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// Create personalized avatar videos with ease using the **HeyGen API**. By selecting an avatar and a voice, you can create engaging videos for various purposes. 🌟
- /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2) + /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2). ///
public CreateVideoApiClient CreateVideoApi => new CreateVideoApiClient(HttpClient, authorizations: Authorizations) { @@ -90,7 +90,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// Import contacts into your HeyGen **Personalized Video** campaign. 
/// **Guide**: [https://docs.heygen.com/docs/import-contacts-via-api](https://docs.heygen.com/docs/import-contacts-via-api)
- /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact) + /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact). ///
public PersonalizedVideoClient PersonalizedVideo => new PersonalizedVideoClient(HttpClient, authorizations: Authorizations) { @@ -100,7 +100,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// HeyGen's **Streaming API** allows developers to seamlessly integrate dynamic digital avatars into their applications for immersive and interactive user experiences. With this API, you can create _virtual assistants, real-time training simulations,_ and more, with a focus on real-time, low-latency communication between _users_ and _avatars_ with power of WebRTC.
- /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session) + /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session). ///
public StreamingApiClient StreamingApi => new StreamingApiClient(HttpClient, authorizations: Authorizations) { @@ -110,7 +110,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// These API endpoints allow you to manage photo avatars in your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo) + /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo). ///
public TalkingPhotoClient TalkingPhoto => new TalkingPhotoClient(HttpClient, authorizations: Authorizations) { @@ -126,7 +126,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// - **Template Videos:** In contrast, template videos offer a wide canvas for creativity. They enable you to customize existing text, images, videos, audios, voices and avatars seamlessly. If you need a richer, more versatile content format for your workflow, templates are the perfect choice.
///
/// **Guide**: [https://docs.heygen.com/docs/generate-video-from-template-v2](https://docs.heygen.com/docs/generate-video-from-template-v2)
- /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2) + /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2). /// public TemplateApiClient TemplateApi => new TemplateApiClient(HttpClient, authorizations: Authorizations) { @@ -136,7 +136,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// Obtain information about your account.
- /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2) + /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2). ///
public UserClient User => new UserClient(HttpClient, authorizations: Authorizations) { @@ -146,7 +146,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// The [Video Translate](https://labs.heygen.com/video-translate) by HeyGen provides a powerful solution for effortlessly translating videos, integrating natural voice cloning and authentic speaking styles seamlessly. Now, you can harness its capabilities programmatically through the **Video Translate API**!
- /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate) + /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate). ///
public VideoTranslateApiClient VideoTranslateApi => new VideoTranslateApiClient(HttpClient, authorizations: Authorizations) { @@ -156,7 +156,7 @@ public sealed partial class HeyGenClient : global::HeyGen.IHeyGenClient, global: /// /// Webhook events are how the **HeyGen** notifies your _endpoints_ when a variety of interactions or events happen, including when avatar video processing _succeeds_ or _fails_. Webhook events are sent by HeyGen as POST requests to your webhook endpoint.
- /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint) + /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint). ///
public WebhooksClient Webhooks => new WebhooksClient(HttpClient, authorizations: Authorizations) { diff --git a/src/libs/HeyGen/Generated/HeyGen.IAssetsClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IAssetsClient.g.cs index c4e25aa..c15db89 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IAssetsClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IAssetsClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Upload an image or video asset to your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1)
+ /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.ICreateVideoApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.ICreateVideoApiClient.g.cs index 775e529..5a0db15 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ICreateVideoApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ICreateVideoApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Create personalized avatar videos with ease using the **HeyGen API**. By selecting an avatar and a voice, you can create engaging videos for various purposes. 🌟
- /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2)
+ /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.Authorizations.ApiKeyInHeader.g.cs b/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.Authorizations.ApiKeyInHeader.g.cs index b15a4ba..42c5d89 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.Authorizations.ApiKeyInHeader.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.Authorizations.ApiKeyInHeader.g.cs @@ -9,6 +9,7 @@ public partial interface IHeyGenClient /// Authorize using ApiKey authentication. /// /// + public void AuthorizeUsingApiKeyInHeader( string apiKey); } diff --git a/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.g.cs index 9656bec..98461fa 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IHeyGenClient.g.cs @@ -63,13 +63,13 @@ public partial interface IHeyGenClient : global::System.IDisposable /// /// Upload an image or video asset to your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1) + /// **Reference**: [https://docs.heygen.com/reference/upload-asset-1](https://docs.heygen.com/reference/upload-asset-1). ///
public AssetsClient Assets { get; } /// /// Create personalized avatar videos with ease using the **HeyGen API**. By selecting an avatar and a voice, you can create engaging videos for various purposes. 🌟
- /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2) + /// **Guide**: [https://docs.heygen.com/docs/create-video](https://docs.heygen.com/docs/create-video)**Reference**: [https://docs.heygen.com/reference/create-an-avatar-video-v2](https://docs.heygen.com/reference/create-an-avatar-video-v2). ///
public CreateVideoApiClient CreateVideoApi { get; } @@ -81,19 +81,19 @@ public partial interface IHeyGenClient : global::System.IDisposable /// /// Import contacts into your HeyGen **Personalized Video** campaign. 
/// **Guide**: [https://docs.heygen.com/docs/import-contacts-via-api](https://docs.heygen.com/docs/import-contacts-via-api)
- /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact) + /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact). ///
public PersonalizedVideoClient PersonalizedVideo { get; } /// /// HeyGen's **Streaming API** allows developers to seamlessly integrate dynamic digital avatars into their applications for immersive and interactive user experiences. With this API, you can create _virtual assistants, real-time training simulations,_ and more, with a focus on real-time, low-latency communication between _users_ and _avatars_ with power of WebRTC.
- /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session) + /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session). ///
public StreamingApiClient StreamingApi { get; } /// /// These API endpoints allow you to manage photo avatars in your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo) + /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo). ///
public TalkingPhotoClient TalkingPhoto { get; } @@ -105,25 +105,25 @@ public partial interface IHeyGenClient : global::System.IDisposable /// - **Template Videos:** In contrast, template videos offer a wide canvas for creativity. They enable you to customize existing text, images, videos, audios, voices and avatars seamlessly. If you need a richer, more versatile content format for your workflow, templates are the perfect choice.
///
/// **Guide**: [https://docs.heygen.com/docs/generate-video-from-template-v2](https://docs.heygen.com/docs/generate-video-from-template-v2)
- /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2) + /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2). /// public TemplateApiClient TemplateApi { get; } /// /// Obtain information about your account.
- /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2) + /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2). ///
public UserClient User { get; } /// /// The [Video Translate](https://labs.heygen.com/video-translate) by HeyGen provides a powerful solution for effortlessly translating videos, integrating natural voice cloning and authentic speaking styles seamlessly. Now, you can harness its capabilities programmatically through the **Video Translate API**!
- /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate) + /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate). ///
public VideoTranslateApiClient VideoTranslateApi { get; } /// /// Webhook events are how the **HeyGen** notifies your _endpoints_ when a variety of interactions or events happen, including when avatar video processing _succeeds_ or _fails_. Webhook events are sent by HeyGen as POST requests to your webhook endpoint.
- /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint) + /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint). ///
public WebhooksClient Webhooks { get; } diff --git a/src/libs/HeyGen/Generated/HeyGen.IPersonalizedVideoClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IPersonalizedVideoClient.g.cs index 7d47a7a..60d4c8d 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IPersonalizedVideoClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IPersonalizedVideoClient.g.cs @@ -6,7 +6,7 @@ namespace HeyGen /// /// Import contacts into your HeyGen **Personalized Video** campaign. 
/// **Guide**: [https://docs.heygen.com/docs/import-contacts-via-api](https://docs.heygen.com/docs/import-contacts-via-api)
- /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact)
+ /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.IStreamingApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IStreamingApiClient.g.cs index b7bfb7c..2764327 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IStreamingApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IStreamingApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// HeyGen's **Streaming API** allows developers to seamlessly integrate dynamic digital avatars into their applications for immersive and interactive user experiences. With this API, you can create _virtual assistants, real-time training simulations,_ and more, with a focus on real-time, low-latency communication between _users_ and _avatars_ with power of WebRTC.
- /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session)
+ /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.ITalkingPhotoClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.ITalkingPhotoClient.g.cs index 97f9386..faf5672 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ITalkingPhotoClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ITalkingPhotoClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// These API endpoints allow you to manage photo avatars in your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo)
+ /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.ITemplateApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.ITemplateApiClient.g.cs index 68c80b6..db5f9ec 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ITemplateApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ITemplateApiClient.g.cs @@ -11,7 +11,7 @@ namespace HeyGen /// - **Template Videos:** In contrast, template videos offer a wide canvas for creativity. They enable you to customize existing text, images, videos, audios, voices and avatars seamlessly. If you need a richer, more versatile content format for your workflow, templates are the perfect choice.
///
/// **Guide**: [https://docs.heygen.com/docs/generate-video-from-template-v2](https://docs.heygen.com/docs/generate-video-from-template-v2)
- /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2)
+ /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. /// diff --git a/src/libs/HeyGen/Generated/HeyGen.IUserClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IUserClient.g.cs index b9abe72..12ef65e 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IUserClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IUserClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Obtain information about your account.
- /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2)
+ /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.IVideoTranslateApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IVideoTranslateApiClient.g.cs index 65af20a..abe28df 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IVideoTranslateApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IVideoTranslateApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// The [Video Translate](https://labs.heygen.com/video-translate) by HeyGen provides a powerful solution for effortlessly translating videos, integrating natural voice cloning and authentic speaking styles seamlessly. Now, you can harness its capabilities programmatically through the **Video Translate API**!
- /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate)
+ /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.IWebhooksClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.IWebhooksClient.g.cs index a442656..b1a5fe2 100644 --- a/src/libs/HeyGen/Generated/HeyGen.IWebhooksClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.IWebhooksClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Webhook events are how the **HeyGen** notifies your _endpoints_ when a variety of interactions or events happen, including when avatar video processing _succeeds_ or _fails_. Webhook events are sent by HeyGen as POST requests to your webhook endpoint.
- /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint)
+ /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1AvatarList.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1AvatarList.g.cs index 2acc6a5..a2c1812 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1AvatarList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1AvatarList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class ListsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1AvatarListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1AvatarListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1AvatarListSecurityRequirement0, + }; partial void PrepareV1AvatarListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1AvatarListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1AvatarListResponse( PrepareV1AvatarListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1AvatarListSecurityRequirements, + operationName: "V1AvatarListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/avatar.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1AvatarListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VideoList.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VideoList.g.cs index a9e4321..cef0731 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VideoList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VideoList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class ListsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1VideoListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1VideoListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1VideoListSecurityRequirement0, + }; partial void PrepareV1VideoListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1VideoListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1VideoListResponse( PrepareV1VideoListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1VideoListSecurityRequirements, + operationName: "V1VideoListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/video.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1VideoListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VoiceList.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VoiceList.g.cs index 3477fce..f530ccc 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VoiceList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V1VoiceList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class ListsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1VoiceListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1VoiceListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1VoiceListSecurityRequirement0, + }; partial void PrepareV1VoiceListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1VoiceListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1VoiceListResponse( PrepareV1VoiceListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1VoiceListSecurityRequirements, + operationName: "V1VoiceListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/voice.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1VoiceListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Avatars.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Avatars.g.cs index 34e1ca0..6b907e8 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Avatars.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Avatars.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class ListsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2AvatarsSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2AvatarsSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2AvatarsSecurityRequirement0, + }; partial void PrepareV2AvatarsArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2AvatarsRequest( @@ -28,9 +47,15 @@ partial void ProcessV2AvatarsResponse( PrepareV2AvatarsArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2AvatarsSecurityRequirements, + operationName: "V2AvatarsAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/avatars", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2AvatarsResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Voices.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Voices.g.cs index 24afd30..c1d934e 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Voices.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.V2Voices.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class ListsClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2VoicesSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2VoicesSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2VoicesSecurityRequirement0, + }; partial void PrepareV2VoicesArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2VoicesRequest( @@ -28,9 +47,15 @@ partial void ProcessV2VoicesResponse( PrepareV2VoicesArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2VoicesSecurityRequirements, + operationName: "V2VoicesAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/voices", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2VoicesResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.ListsClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.ListsClient.g.cs index 3234683..06ef994 100644 --- a/src/libs/HeyGen/Generated/HeyGen.ListsClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.ListsClient.g.cs @@ -12,7 +12,7 @@ public sealed partial class ListsClient : global::HeyGen.IListsClient, global::S /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.PathBuilder.g.cs b/src/libs/HeyGen/Generated/HeyGen.PathBuilder.g.cs index 6a5910a..60aab7a 100644 --- a/src/libs/HeyGen/Generated/HeyGen.PathBuilder.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.PathBuilder.g.cs @@ -224,6 +224,40 @@ public PathBuilder AddOptionalParameter( return this; } + /// + /// Adds a pre-serialized query string fragment to the URL. + /// + /// The serialized query string value. + /// The current instance. + public PathBuilder AddRawQueryString( + string value) + { + if (string.IsNullOrWhiteSpace(value)) + { + return this; + } + + value = value.TrimStart('?', '&'); + if (value.Length == 0) + { + return this; + } + + if (_firstParameter) + { + _stringBuilder.Append('?'); + _firstParameter = false; + } + else + { + _stringBuilder.Append('&'); + } + + _stringBuilder.Append(value); + + return this; + } + /// /// Returns the constructed URL as a string. /// diff --git a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAddContact.g.cs b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAddContact.g.cs index 32e4aba..976777f 100644 --- a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAddContact.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAddContact.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class PersonalizedVideoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_PersonalizedVideoAddContactSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_PersonalizedVideoAddContactSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_PersonalizedVideoAddContactSecurityRequirement0, + }; partial void PreparePersonalizedVideoAddContactArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.PersonalizedVideoAddContactRequest request); @@ -36,9 +55,15 @@ partial void ProcessPersonalizedVideoAddContactResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_PersonalizedVideoAddContactSecurityRequirements, + operationName: "PersonalizedVideoAddContactAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/personalized_video/add_contact", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessPersonalizedVideoAddContactResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAudienceDetail.g.cs b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAudienceDetail.g.cs index 7b2df76..9f53740 100644 --- a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAudienceDetail.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoAudienceDetail.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class PersonalizedVideoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_PersonalizedVideoAudienceDetailSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_PersonalizedVideoAudienceDetailSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_PersonalizedVideoAudienceDetailSecurityRequirement0, + }; partial void PreparePersonalizedVideoAudienceDetailArguments( global::System.Net.Http.HttpClient httpClient, ref string? id); @@ -35,12 +54,18 @@ partial void ProcessPersonalizedVideoAudienceDetailResponse( httpClient: HttpClient, id: ref id); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_PersonalizedVideoAudienceDetailSecurityRequirements, + operationName: "PersonalizedVideoAudienceDetailAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/personalized_video/audience/detail", baseUri: HttpClient.BaseAddress); __pathBuilder .AddOptionalParameter("id", id) - ; + ; var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -50,7 +75,7 @@ partial void ProcessPersonalizedVideoAudienceDetailResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoProjectDetail.g.cs b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoProjectDetail.g.cs index 97b17c3..18a4d9d 100644 --- a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoProjectDetail.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.PersonalizedVideoProjectDetail.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class PersonalizedVideoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_PersonalizedVideoProjectDetailSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_PersonalizedVideoProjectDetailSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_PersonalizedVideoProjectDetailSecurityRequirement0, + }; partial void PreparePersonalizedVideoProjectDetailArguments( global::System.Net.Http.HttpClient httpClient, ref string? id); @@ -35,12 +54,18 @@ partial void ProcessPersonalizedVideoProjectDetailResponse( httpClient: HttpClient, id: ref id); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_PersonalizedVideoProjectDetailSecurityRequirements, + operationName: "PersonalizedVideoProjectDetailAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/personalized_video/project/detail", baseUri: HttpClient.BaseAddress); __pathBuilder .AddOptionalParameter("id", id) - ; + ; var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -50,7 +75,7 @@ partial void ProcessPersonalizedVideoProjectDetailResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.g.cs index adc38cc..c206791 100644 --- a/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.PersonalizedVideoClient.g.cs @@ -6,7 +6,7 @@ namespace HeyGen /// /// Import contacts into your HeyGen **Personalized Video** campaign. 
/// **Guide**: [https://docs.heygen.com/docs/import-contacts-via-api](https://docs.heygen.com/docs/import-contacts-via-api)
- /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact)
+ /// Reference: [https://docs.heygen.com/reference/add-contact](https://docs.heygen.com/reference/add-contact).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -15,7 +15,7 @@ public sealed partial class PersonalizedVideoClient : global::HeyGen.IPersonaliz /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.Security.g.cs b/src/libs/HeyGen/Generated/HeyGen.Security.g.cs new file mode 100644 index 0000000..cac3c5f --- /dev/null +++ b/src/libs/HeyGen/Generated/HeyGen.Security.g.cs @@ -0,0 +1,145 @@ +#nullable enable + +namespace HeyGen +{ + internal sealed class EndPointAuthorizationRequirement + { + internal string Type { get; set; } = string.Empty; + + internal string Location { get; set; } = string.Empty; + + internal string Name { get; set; } = string.Empty; + + internal string FriendlyName { get; set; } = string.Empty; + } + + internal sealed class EndPointSecurityRequirement + { + internal global::System.Collections.Generic.IReadOnlyList Authorizations { get; set; } = + global::System.Array.Empty(); + } + + internal static class EndPointSecurityResolver + { + internal static global::System.Collections.Generic.List ResolveAuthorizations( + global::System.Collections.Generic.IReadOnlyList availableAuthorizations, + global::System.Collections.Generic.IReadOnlyList securityRequirements, + string operationName) + { + availableAuthorizations = availableAuthorizations ?? throw new global::System.ArgumentNullException(nameof(availableAuthorizations)); + securityRequirements = securityRequirements ?? throw new global::System.ArgumentNullException(nameof(securityRequirements)); + operationName = operationName ?? throw new global::System.ArgumentNullException(nameof(operationName)); + + if (securityRequirements.Count == 0) + { + return new global::System.Collections.Generic.List(); + } + + var allowsAnonymous = false; + + foreach (var requirement in securityRequirements) + { + if (requirement.Authorizations.Count == 0) + { + allowsAnonymous = true; + continue; + } + + var selected = new global::System.Collections.Generic.List(requirement.Authorizations.Count); + var satisfied = true; + + foreach (var requiredAuthorization in requirement.Authorizations) + { + var found = false; + + for (var i = 0; i < availableAuthorizations.Count; i++) + { + if (!Matches(availableAuthorizations[i], requiredAuthorization)) + { + continue; + } + + selected.Add(availableAuthorizations[i]); + found = true; + break; + } + + if (!found) + { + satisfied = false; + break; + } + } + + if (satisfied) + { + return selected; + } + } + + if (allowsAnonymous) + { + return new global::System.Collections.Generic.List(); + } + + throw new global::System.InvalidOperationException( + $"Operation '{operationName}' requires one of the configured security alternatives: {DescribeRequirements(securityRequirements)}."); + } + + private static bool Matches( + EndPointAuthorization availableAuthorization, + EndPointAuthorizationRequirement requiredAuthorization) + { + if (!string.Equals(availableAuthorization.Type, requiredAuthorization.Type, global::System.StringComparison.Ordinal)) + { + return false; + } + + return requiredAuthorization.Type switch + { + "OAuth2" => true, + "Http" => string.Equals( + availableAuthorization.Name, + requiredAuthorization.Name, + global::System.StringComparison.Ordinal), + "ApiKey" => string.Equals( + availableAuthorization.Location, + requiredAuthorization.Location, + global::System.StringComparison.Ordinal) && + string.Equals( + availableAuthorization.Name, + requiredAuthorization.Name, + global::System.StringComparison.Ordinal), + _ => string.Equals( + availableAuthorization.Location, + requiredAuthorization.Location, + global::System.StringComparison.Ordinal) && + string.Equals( + availableAuthorization.Name, + requiredAuthorization.Name, + global::System.StringComparison.Ordinal), + }; + } + + private static string DescribeRequirements( + global::System.Collections.Generic.IReadOnlyList securityRequirements) + { + var parts = new global::System.Collections.Generic.List(securityRequirements.Count); + + foreach (var requirement in securityRequirements) + { + if (requirement.Authorizations.Count == 0) + { + parts.Add("anonymous"); + continue; + } + + parts.Add(string.Join( + " + ", + global::System.Linq.Enumerable.Select(requirement.Authorizations, static x => x.FriendlyName))); + } + + return string.Join(" or ", parts); + } + } +} \ No newline at end of file diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingAvatarList.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingAvatarList.g.cs index c384cf5..d901771 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingAvatarList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingAvatarList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingAvatarListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingAvatarListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingAvatarListSecurityRequirement0, + }; partial void PrepareStreamingAvatarListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareStreamingAvatarListRequest( @@ -28,9 +47,15 @@ partial void ProcessStreamingAvatarListResponse( PrepareStreamingAvatarListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingAvatarListSecurityRequirements, + operationName: "StreamingAvatarListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming/avatar.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessStreamingAvatarListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingCreateToken.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingCreateToken.g.cs index d371d8c..0351416 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingCreateToken.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingCreateToken.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingCreateTokenSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingCreateTokenSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingCreateTokenSecurityRequirement0, + }; partial void PrepareStreamingCreateTokenArguments( global::System.Net.Http.HttpClient httpClient, object request); @@ -36,9 +55,15 @@ partial void ProcessStreamingCreateTokenResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingCreateTokenSecurityRequirements, + operationName: "StreamingCreateTokenAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.create_token", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingCreateTokenResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingIce.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingIce.g.cs index 2c216ff..d17415b 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingIce.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingIce.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingIceSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingIceSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingIceSecurityRequirement0, + }; partial void PrepareStreamingIceArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingIceRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingIceResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingIceSecurityRequirements, + operationName: "StreamingIceAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.ice", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingIceResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingInterrupt.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingInterrupt.g.cs index 319d431..1f8b5a1 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingInterrupt.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingInterrupt.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingInterruptSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingInterruptSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingInterruptSecurityRequirement0, + }; partial void PrepareStreamingInterruptArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingInterruptRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingInterruptResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingInterruptSecurityRequirements, + operationName: "StreamingInterruptAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.interrupt", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingInterruptResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingList.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingList.g.cs index dab85b9..dca0774 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingListSecurityRequirement0, + }; partial void PrepareStreamingListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareStreamingListRequest( @@ -28,9 +47,15 @@ partial void ProcessStreamingListResponse( PrepareStreamingListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingListSecurityRequirements, + operationName: "StreamingListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessStreamingListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingNew.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingNew.g.cs index d960346..3d5c45d 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingNew.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingNew.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingNewSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingNewSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingNewSecurityRequirement0, + }; partial void PrepareStreamingNewArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingNewRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingNewResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingNewSecurityRequirements, + operationName: "StreamingNewAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.new", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingNewResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStart.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStart.g.cs index 52d7db5..62355f1 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStart.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStart.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingStartSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingStartSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingStartSecurityRequirement0, + }; partial void PrepareStreamingStartArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingStartRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingStartResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingStartSecurityRequirements, + operationName: "StreamingStartAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.start", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingStartResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStop.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStop.g.cs index 7fd5292..668e983 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStop.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingStop.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingStopSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingStopSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingStopSecurityRequirement0, + }; partial void PrepareStreamingStopArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingStopRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingStopResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingStopSecurityRequirements, + operationName: "StreamingStopAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.stop", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingStopResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingTask.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingTask.g.cs index b5326da..d10473a 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingTask.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.StreamingTask.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class StreamingApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_StreamingTaskSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_StreamingTaskSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_StreamingTaskSecurityRequirement0, + }; partial void PrepareStreamingTaskArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.StreamingTaskRequest request); @@ -36,9 +55,15 @@ partial void ProcessStreamingTaskResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_StreamingTaskSecurityRequirements, + operationName: "StreamingTaskAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/streaming.task", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessStreamingTaskResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.g.cs index 2793913..5f717ee 100644 --- a/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.StreamingApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// HeyGen's **Streaming API** allows developers to seamlessly integrate dynamic digital avatars into their applications for immersive and interactive user experiences. With this API, you can create _virtual assistants, real-time training simulations,_ and more, with a focus on real-time, low-latency communication between _users_ and _avatars_ with power of WebRTC.
- /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session)
+ /// **Guide**: [https://docs.heygen.com/docs/streaming-api](https://docs.heygen.com/docs/streaming-api)**Reference**: [https://docs.heygen.com/reference/new-session](https://docs.heygen.com/reference/new-session).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class StreamingApiClient : global::HeyGen.IStreamingApiCli /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoList.g.cs b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoList.g.cs index ad6502f..bc711d0 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TalkingPhotoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1TalkingPhotoListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1TalkingPhotoListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1TalkingPhotoListSecurityRequirement0, + }; partial void PrepareV1TalkingPhotoListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1TalkingPhotoListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1TalkingPhotoListResponse( PrepareV1TalkingPhotoListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1TalkingPhotoListSecurityRequirements, + operationName: "V1TalkingPhotoListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/talking_photo.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1TalkingPhotoListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoUpload.g.cs b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoUpload.g.cs index 60aa2e5..baffa4b 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoUpload.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V1TalkingPhotoUpload.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TalkingPhotoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1TalkingPhotoUploadSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1TalkingPhotoUploadSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1TalkingPhotoUploadSecurityRequirement0, + }; partial void PrepareV1TalkingPhotoUploadArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1TalkingPhotoUploadRequest( @@ -28,9 +47,15 @@ partial void ProcessV1TalkingPhotoUploadResponse( PrepareV1TalkingPhotoUploadArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1TalkingPhotoUploadSecurityRequirements, + operationName: "V1TalkingPhotoUploadAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/talking_photo", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -40,7 +65,7 @@ partial void ProcessV1TalkingPhotoUploadResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V2TalkingPhotoIdDelete.g.cs b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V2TalkingPhotoIdDelete.g.cs index 0cc6acd..eab2c28 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V2TalkingPhotoIdDelete.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.V2TalkingPhotoIdDelete.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TalkingPhotoClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2TalkingPhotoIdDeleteSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2TalkingPhotoIdDeleteSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2TalkingPhotoIdDeleteSecurityRequirement0, + }; partial void PrepareV2TalkingPhotoIdDeleteArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2TalkingPhotoIdDeleteRequest( @@ -28,9 +47,15 @@ partial void ProcessV2TalkingPhotoIdDeleteResponse( PrepareV2TalkingPhotoIdDeleteArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2TalkingPhotoIdDeleteSecurityRequirements, + operationName: "V2TalkingPhotoIdDeleteAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/talking_photo/", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Delete, @@ -40,7 +65,7 @@ partial void ProcessV2TalkingPhotoIdDeleteResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.g.cs index 862d335..899c49b 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TalkingPhotoClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// These API endpoints allow you to manage photo avatars in your account.
- /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo)
+ /// **Reference**: [https://docs.heygen.com/reference/upload-talking-photo](https://docs.heygen.com/reference/upload-talking-photo).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class TalkingPhotoClient : global::HeyGen.ITalkingPhotoCli /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateGenerate.g.cs b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateGenerate.g.cs index eb53ec0..725e5f7 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateGenerate.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateGenerate.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TemplateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2TemplateGenerateSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2TemplateGenerateSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2TemplateGenerateSecurityRequirement0, + }; partial void PrepareV2TemplateGenerateArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.V2TemplateGenerateRequest request); @@ -37,9 +56,15 @@ partial void ProcessV2TemplateGenerateResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2TemplateGenerateSecurityRequirements, + operationName: "V2TemplateGenerateAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/template//generate", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -49,7 +74,7 @@ partial void ProcessV2TemplateGenerateResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateId.g.cs b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateId.g.cs index 55ebb05..410af90 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateId.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2TemplateId.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TemplateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2TemplateIdSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2TemplateIdSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2TemplateIdSecurityRequirement0, + }; partial void PrepareV2TemplateIdArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2TemplateIdRequest( @@ -28,9 +47,15 @@ partial void ProcessV2TemplateIdResponse( PrepareV2TemplateIdArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2TemplateIdSecurityRequirements, + operationName: "V2TemplateIdAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/template/", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2TemplateIdResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2Templates.g.cs b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2Templates.g.cs index 6323b0c..30c0999 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2Templates.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.V2Templates.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class TemplateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2TemplatesSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2TemplatesSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2TemplatesSecurityRequirement0, + }; partial void PrepareV2TemplatesArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2TemplatesRequest( @@ -28,9 +47,15 @@ partial void ProcessV2TemplatesResponse( PrepareV2TemplatesArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2TemplatesSecurityRequirements, + operationName: "V2TemplatesAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/templates", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2TemplatesResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.g.cs index 5f13a01..aa03ddd 100644 --- a/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.TemplateApiClient.g.cs @@ -11,7 +11,7 @@ namespace HeyGen /// - **Template Videos:** In contrast, template videos offer a wide canvas for creativity. They enable you to customize existing text, images, videos, audios, voices and avatars seamlessly. If you need a richer, more versatile content format for your workflow, templates are the perfect choice.
///
/// **Guide**: [https://docs.heygen.com/docs/generate-video-from-template-v2](https://docs.heygen.com/docs/generate-video-from-template-v2)
- /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2)
+ /// **Reference**: [https://docs.heygen.com/reference/generate-from-template-v2](https://docs.heygen.com/reference/generate-from-template-v2)[](https://docs.heygen.com/reference/create-an-avatar-video-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. /// @@ -20,7 +20,7 @@ public sealed partial class TemplateApiClient : global::HeyGen.ITemplateApiClien /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.UserClient.V2UserRemainingQuota.g.cs b/src/libs/HeyGen/Generated/HeyGen.UserClient.V2UserRemainingQuota.g.cs index 29e6ab1..66e63f3 100644 --- a/src/libs/HeyGen/Generated/HeyGen.UserClient.V2UserRemainingQuota.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.UserClient.V2UserRemainingQuota.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class UserClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2UserRemainingQuotaSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2UserRemainingQuotaSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2UserRemainingQuotaSecurityRequirement0, + }; partial void PrepareV2UserRemainingQuotaArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2UserRemainingQuotaRequest( @@ -28,9 +47,15 @@ partial void ProcessV2UserRemainingQuotaResponse( PrepareV2UserRemainingQuotaArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2UserRemainingQuotaSecurityRequirements, + operationName: "V2UserRemainingQuotaAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/user/remaining_quota", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2UserRemainingQuotaResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.UserClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.UserClient.g.cs index afc4657..0fdc520 100644 --- a/src/libs/HeyGen/Generated/HeyGen.UserClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.UserClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Obtain information about your account.
- /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2)
+ /// **Reference**: [https://docs.heygen.com/reference/get-remaining-quota-v2](https://docs.heygen.com/reference/get-remaining-quota-v2).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class UserClient : global::HeyGen.IUserClient, global::Sys /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslate.g.cs b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslate.g.cs index eb92ce0..638cbe8 100644 --- a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslate.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslate.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class VideoTranslateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2VideoTranslateSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2VideoTranslateSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2VideoTranslateSecurityRequirement0, + }; partial void PrepareV2VideoTranslateArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.V2VideoTranslateRequest request); @@ -36,9 +55,15 @@ partial void ProcessV2VideoTranslateResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2VideoTranslateSecurityRequirements, + operationName: "V2VideoTranslateAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/video_translate", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessV2VideoTranslateResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateIdStatus.g.cs b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateIdStatus.g.cs index cce258b..82e908e 100644 --- a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateIdStatus.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateIdStatus.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class VideoTranslateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2VideoTranslateIdStatusSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2VideoTranslateIdStatusSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2VideoTranslateIdStatusSecurityRequirement0, + }; partial void PrepareV2VideoTranslateIdStatusArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2VideoTranslateIdStatusRequest( @@ -28,9 +47,15 @@ partial void ProcessV2VideoTranslateIdStatusResponse( PrepareV2VideoTranslateIdStatusArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2VideoTranslateIdStatusSecurityRequirements, + operationName: "V2VideoTranslateIdStatusAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/video_translate/", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2VideoTranslateIdStatusResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateTargetLanguages.g.cs b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateTargetLanguages.g.cs index 3a8308a..f11825f 100644 --- a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateTargetLanguages.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.V2VideoTranslateTargetLanguages.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class VideoTranslateApiClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V2VideoTranslateTargetLanguagesSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V2VideoTranslateTargetLanguagesSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V2VideoTranslateTargetLanguagesSecurityRequirement0, + }; partial void PrepareV2VideoTranslateTargetLanguagesArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV2VideoTranslateTargetLanguagesRequest( @@ -28,9 +47,15 @@ partial void ProcessV2VideoTranslateTargetLanguagesResponse( PrepareV2VideoTranslateTargetLanguagesArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V2VideoTranslateTargetLanguagesSecurityRequirements, + operationName: "V2VideoTranslateTargetLanguagesAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v2/video_translate/target_languages", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV2VideoTranslateTargetLanguagesResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.g.cs index 42fe9ea..7bcfd08 100644 --- a/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.VideoTranslateApiClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// The [Video Translate](https://labs.heygen.com/video-translate) by HeyGen provides a powerful solution for effortlessly translating videos, integrating natural voice cloning and authentic speaking styles seamlessly. Now, you can harness its capabilities programmatically through the **Video Translate API**!
- /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate)
+ /// **Guide**: [https://docs.heygen.com/docs/video-translate-api](https://docs.heygen.com/docs/video-translate-api)**Reference**: [https://docs.heygen.com/reference/video-translate](https://docs.heygen.com/reference/video-translate).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class VideoTranslateApiClient : global::HeyGen.IVideoTrans /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true; diff --git a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointAdd.g.cs b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointAdd.g.cs index 4075d70..8f8a95c 100644 --- a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointAdd.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointAdd.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class WebhooksClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1WebhookEndpointAddSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1WebhookEndpointAddSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1WebhookEndpointAddSecurityRequirement0, + }; partial void PrepareV1WebhookEndpointAddArguments( global::System.Net.Http.HttpClient httpClient, global::HeyGen.V1WebhookEndpointAddRequest request); @@ -36,9 +55,15 @@ partial void ProcessV1WebhookEndpointAddResponse( httpClient: HttpClient, request: request); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1WebhookEndpointAddSecurityRequirements, + operationName: "V1WebhookEndpointAddAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/webhook/endpoint.add", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Post, @@ -48,7 +73,7 @@ partial void ProcessV1WebhookEndpointAddResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointDelete.g.cs b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointDelete.g.cs index ddba455..24a57aa 100644 --- a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointDelete.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointDelete.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class WebhooksClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1WebhookEndpointDeleteSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1WebhookEndpointDeleteSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1WebhookEndpointDeleteSecurityRequirement0, + }; partial void PrepareV1WebhookEndpointDeleteArguments( global::System.Net.Http.HttpClient httpClient, ref string? endpointId); @@ -35,12 +54,18 @@ partial void ProcessV1WebhookEndpointDeleteResponse( httpClient: HttpClient, endpointId: ref endpointId); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1WebhookEndpointDeleteSecurityRequirements, + operationName: "V1WebhookEndpointDeleteAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/webhook/endpoint.delete", baseUri: HttpClient.BaseAddress); __pathBuilder .AddOptionalParameter("endpoint_id", endpointId) - ; + ; var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Delete, @@ -50,7 +75,7 @@ partial void ProcessV1WebhookEndpointDeleteResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointList.g.cs b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointList.g.cs index bf5fc30..5ffec75 100644 --- a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookEndpointList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class WebhooksClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1WebhookEndpointListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1WebhookEndpointListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1WebhookEndpointListSecurityRequirement0, + }; partial void PrepareV1WebhookEndpointListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1WebhookEndpointListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1WebhookEndpointListResponse( PrepareV1WebhookEndpointListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1WebhookEndpointListSecurityRequirements, + operationName: "V1WebhookEndpointListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/webhook/endpoint.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1WebhookEndpointListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookWebhookList.g.cs b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookWebhookList.g.cs index 02bebb0..651e688 100644 --- a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookWebhookList.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.V1WebhookWebhookList.g.cs @@ -5,6 +5,25 @@ namespace HeyGen { public partial class WebhooksClient { + + + private static readonly global::HeyGen.EndPointSecurityRequirement s_V1WebhookWebhookListSecurityRequirement0 = + new global::HeyGen.EndPointSecurityRequirement + { + Authorizations = new global::HeyGen.EndPointAuthorizationRequirement[] + { new global::HeyGen.EndPointAuthorizationRequirement + { + Type = "ApiKey", + Location = "Header", + Name = "X-Api-Key", + FriendlyName = "ApiKeyInHeader", + }, + }, + }; + private static readonly global::HeyGen.EndPointSecurityRequirement[] s_V1WebhookWebhookListSecurityRequirements = + new global::HeyGen.EndPointSecurityRequirement[] + { s_V1WebhookWebhookListSecurityRequirement0, + }; partial void PrepareV1WebhookWebhookListArguments( global::System.Net.Http.HttpClient httpClient); partial void PrepareV1WebhookWebhookListRequest( @@ -28,9 +47,15 @@ partial void ProcessV1WebhookWebhookListResponse( PrepareV1WebhookWebhookListArguments( httpClient: HttpClient); + + var __authorizations = global::HeyGen.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_V1WebhookWebhookListSecurityRequirements, + operationName: "V1WebhookWebhookListAsync"); + var __pathBuilder = new global::HeyGen.PathBuilder( path: "/v1/webhook/webhook.list", - baseUri: HttpClient.BaseAddress); + baseUri: HttpClient.BaseAddress); var __path = __pathBuilder.ToString(); using var __httpRequest = new global::System.Net.Http.HttpRequestMessage( method: global::System.Net.Http.HttpMethod.Get, @@ -40,7 +65,7 @@ partial void ProcessV1WebhookWebhookListResponse( __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; #endif - foreach (var __authorization in Authorizations) + foreach (var __authorization in __authorizations) { if (__authorization.Type == "Http" || __authorization.Type == "OAuth2") diff --git a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.g.cs b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.g.cs index c093d88..90feec5 100644 --- a/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.g.cs +++ b/src/libs/HeyGen/Generated/HeyGen.WebhooksClient.g.cs @@ -5,7 +5,7 @@ namespace HeyGen { /// /// Webhook events are how the **HeyGen** notifies your _endpoints_ when a variety of interactions or events happen, including when avatar video processing _succeeds_ or _fails_. Webhook events are sent by HeyGen as POST requests to your webhook endpoint.
- /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint)
+ /// **Guide**: [https://docs.heygen.com/docs/using-heygens-webhook-events](https://docs.heygen.com/docs/using-heygens-webhook-events)**Reference**: [https://docs.heygen.com/reference/add-a-webhook-endpoint](https://docs.heygen.com/reference/add-a-webhook-endpoint).
/// If no httpClient is provided, a new one will be created.
/// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. ///
@@ -14,7 +14,7 @@ public sealed partial class WebhooksClient : global::HeyGen.IWebhooksClient, glo /// /// /// - public const string DefaultBaseUrl = "https://api.heygen.com"; + public const string DefaultBaseUrl = "https://api.heygen.com/"; private bool _disposeHttpClient = true;