diff --git a/Conductor/Api/IIntegrationResourceApi.cs b/Conductor/Api/IIntegrationResourceApi.cs
new file mode 100644
index 00000000..b87c0102
--- /dev/null
+++ b/Conductor/Api/IIntegrationResourceApi.cs
@@ -0,0 +1,567 @@
+using Conductor.Client;
+using Conductor.Client.Models;
+using System.Collections.Generic;
+using EventLog = Conductor.Client.Models.EventLog;
+using ThreadTask = System.Threading.Tasks;
+
+namespace conductor_csharp.Api
+{
+ ///
+ /// Represents a collection of functions to interact with the API endpoints
+ ///
+ public interface IIntegrationResourceApi : IApiAccessor
+ {
+ #region Synchronous Operations
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ ///
+ void AssociatePromptWithIntegration(string integrationProvider, string integrationName, string promptName);
+
+ ///
+ /// Delete an Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ void DeleteIntegrationApi(string name, string integrationName);
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ void DeleteIntegrationProvider(string name);
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ ///
+ void DeleteTagForIntegration(List body, string name, string integrationName);
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ ///
+ void DeleteTagForIntegrationProvider(List body, string name);
+
+ ///
+ /// Get Integration details
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// IntegrationApi
+ IntegrationApi GetIntegrationApi(string name, string integrationName);
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// List
+ List GetIntegrationApis(string name, bool? activeOnly = null);
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// List
+ List GetIntegrationAvailableApis(string name);
+
+ ///
+ /// Get Integration provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Integration
+ Integration GetIntegrationProvider(string name);
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// List
+ List GetIntegrationProviderDefs();
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// List
+ List GetIntegrationProviders(string category = null, bool? activeOnly = null);
+
+ ///
+ /// Get the list of prompt templates associated with an integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// List
+ List GetPromptsWithIntegration(string integrationProvider, string integrationName);
+
+ ///
+ /// Get Integrations Providers and Integrations combo
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// List
+ List GetProvidersAndIntegrations(string type = null, bool? activeOnly = null);
+
+ ///
+ /// Get tags by Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// List
+ List GetTagsForIntegration(string name, string integrationName);
+
+ ///
+ /// Get tags by Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// List
+ List GetTagsForIntegrationProvider(string name);
+
+ ///
+ /// Get Token Usage by Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// int?
+ int? GetTokenUsageForIntegration(string name, string integrationName);
+
+ ///
+ /// Get Token Usage by Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Dictionary
+ Dictionary GetTokenUsageForIntegrationProvider(string name);
+
+ ///
+ /// Put a tag to Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the integration to associate the tag with.
+ /// The name of the model to associate the tag with.
+ ///
+ void PutTagForIntegration(List body, string name, string integrationName);
+
+ ///
+ /// Put a tag to Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the integration to associate the tag with.
+ ///
+ void PutTagForIntegrationProvider(List body, string name);
+
+ ///
+ /// Record Event Stats
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ void RecordEventStats(List body, string type);
+
+ ///
+ /// Register Token usage
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ ///
+ void RegisterTokenUsage(int? body, string name, string integrationName);
+
+ ///
+ /// Create or Update Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ ///
+ void SaveIntegrationApi(IntegrationApiUpdate body, string name, string integrationName);
+
+ ///
+ /// Create or Update Integration provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ void SaveIntegrationProvider(IntegrationUpdate body, string name);
+
+ #endregion Synchronous Operations
+
+ #region Asynchronous Operations
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task AssociatePromptWithIntegrationAsync(string integrationProvider, string integrationName, string promptName);
+
+ ///
+ /// Delete an Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task DeleteIntegrationApiAsync(string name, string integrationName);
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of void
+ ThreadTask.Task DeleteIntegrationProviderAsync(string name);
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ /// Task of void
+ ThreadTask.Task DeleteTagForIntegrationAsync(List body, string name, string integrationName);
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// Task of void
+ ThreadTask.Task DeleteTagForIntegrationProviderAsync(List body, string name);
+
+ ///
+ /// Get Integration details
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of IntegrationApi
+ ThreadTask.Task GetIntegrationApiAsync(string name, string integrationName);
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// Task of List
+ ThreadTask.Task> GetIntegrationApisAsync(string name, bool? activeOnly = null);
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of List
+ ThreadTask.Task> GetIntegrationAvailableApisAsync(string name);
+
+ ///
+ /// Get Integration provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of Integration
+ ThreadTask.Task GetIntegrationProviderAsync(string name);
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// Task of List
+ ThreadTask.Task> GetIntegrationProviderDefsAsync();
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// Task of List
+ ThreadTask.Task> GetIntegrationProvidersAsync(string category = null, bool? activeOnly = null);
+
+ ///
+ /// Get the list of prompt templates associated with an integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of List
+ ThreadTask.Task> GetPromptsWithIntegrationAsync(string integrationProvider, string integrationName);
+
+ ///
+ /// Get Integrations Providers and Integrations combo
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// Task of List
+ ThreadTask.Task> GetProvidersAndIntegrationsAsync(string type = null, bool? activeOnly = null);
+
+ ///
+ /// Get tags by Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of List
+ ThreadTask.Task> GetTagsForIntegrationAsync(string name, string integrationName);
+
+ ///
+ /// Get tags by Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of List
+ ThreadTask.Task> GetTagsForIntegrationProviderAsync(string name);
+
+ ///
+ /// Get Token Usage by Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of int?
+ ThreadTask.Task GetTokenUsageForIntegrationAsync(string name, string integrationName);
+
+ ///
+ /// Get Token Usage by Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of Dictionary
+ ThreadTask.Task> GetTokenUsageForIntegrationProviderAsync(string name);
+
+ ///
+ /// Put a tag to Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the integration to associate the tag with.
+ /// The name of the model to associate the tag with.
+ /// Task of void
+ ThreadTask.Task PutTagForIntegrationAsync(List body, string name, string integrationName);
+
+ ///
+ /// Put a tag to Integration Provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the integration to associate the tag with.
+ /// Task of void
+ ThreadTask.Task PutTagForIntegrationProviderAsync(List body, string name);
+
+ ///
+ /// Record Event Stats
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task RecordEventStatsAsync(List body, string type);
+
+ ///
+ /// Register Token usage
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task RegisterTokenUsageAsync(int? body, string name, string integrationName);
+
+ ///
+ /// Create or Update Integration
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task SaveIntegrationApiAsync(IntegrationApiUpdate body, string name, string integrationName);
+
+ ///
+ /// Create or Update Integration provider
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of void
+ ThreadTask.Task SaveIntegrationProviderAsync(IntegrationUpdate body, string name);
+ #endregion Asynchronous Operations
+ }
+}
diff --git a/Conductor/Api/IPromptResourceApi.cs b/Conductor/Api/IPromptResourceApi.cs
new file mode 100644
index 00000000..37a887c1
--- /dev/null
+++ b/Conductor/Api/IPromptResourceApi.cs
@@ -0,0 +1,200 @@
+using Conductor.Client;
+using Conductor.Client.Models;
+using System.Collections.Generic;
+
+namespace conductor_csharp.Api
+{
+ ///
+ /// Represents a collection of functions to interact with the API endpoints
+ ///
+ public interface IPromptResourceApi : IApiAccessor
+ {
+ #region Synchronous Operations
+ ///
+ /// Delete Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ void DeleteMessageTemplate(string name);
+
+ ///
+ /// Delete a tag for Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the Prompt the tag should be deleted from.
+ ///
+ void DeleteTagForPromptTemplate(List body, string name);
+
+ ///
+ /// Get Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// MessageTemplate
+ MessageTemplate GetMessageTemplate(string name);
+
+ ///
+ /// Get Templates
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// List
+ List GetMessageTemplates();
+
+ ///
+ /// Get tags by Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// List
+ List GetTagsForPromptTemplate(string name);
+
+ ///
+ /// Put a tag to Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the Prompt the tag should be updated with.
+ ///
+ void PutTagForPromptTemplate(List body, string name);
+
+ ///
+ /// Create or Update Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// (optional)
+ ///
+ void SaveMessageTemplate(string body, string description, string name, List models = null);
+
+ ///
+ /// Test Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// string
+ string TestMessageTemplate(PromptTemplateTestRequest body);
+
+ #endregion Synchronous Operations
+ #region Asynchronous Operations
+ ///
+ /// Delete Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of void
+ System.Threading.Tasks.Task DeleteMessageTemplateAsync(string name);
+
+ ///
+ /// Delete a tag for Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the Prompt the tag should be deleted from.
+ /// Task of void
+ System.Threading.Tasks.Task DeleteTagForPromptTemplateAsync(List body, string name);
+
+ ///
+ /// Get Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of MessageTemplate
+ System.Threading.Tasks.Task GetMessageTemplateAsync(string name);
+
+ ///
+ /// Get Templates
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// Task of List
+ System.Threading.Tasks.Task> GetMessageTemplatesAsync();
+
+ ///
+ /// Get tags by Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of List
+ System.Threading.Tasks.Task> GetTagsForPromptTemplateAsync(string name);
+
+ ///
+ /// Put a tag to Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be updated.
+ /// The name of the Prompt the tag should be updated with.
+ /// Task of void
+ System.Threading.Tasks.Task PutTagForPromptTemplateAsync(List body, string name);
+
+ ///
+ /// Create or Update Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// (optional)
+ /// Task of void
+ System.Threading.Tasks.Task SaveMessageTemplateAsync(string body, string description, string name, List models = null);
+
+ ///
+ /// Test Prompt Template
+ ///
+ ///
+ ///
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of string
+ System.Threading.Tasks.Task TestMessageTemplateAsync(PromptTemplateTestRequest body);
+ #endregion Asynchronous Operations
+ }
+}
diff --git a/Conductor/Api/IntegrationResourceApi.cs b/Conductor/Api/IntegrationResourceApi.cs
new file mode 100644
index 00000000..c946818f
--- /dev/null
+++ b/Conductor/Api/IntegrationResourceApi.cs
@@ -0,0 +1,3504 @@
+using Conductor.Client;
+using Conductor.Client.Models;
+using conductor_csharp.Api;
+using RestSharp;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+
+namespace Conductor.Api
+{
+ ///
+ /// Represents a collection of functions to interact with the API endpoints
+ ///
+ public partial class IntegrationResourceApi : IIntegrationResourceApi
+ {
+ private ExceptionFactory _exceptionFactory = (name, response) => null;
+
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ ///
+ public IntegrationResourceApi(string basePath)
+ {
+ this.Configuration = new Conductor.Client.Configuration { BasePath = basePath };
+
+ ExceptionFactory = Conductor.Client.Configuration.DefaultExceptionFactory;
+ }
+
+ ///
+ /// Initializes a new instance of the class
+ ///
+ ///
+ public IntegrationResourceApi()
+ {
+ this.Configuration = Conductor.Client.Configuration.Default;
+
+ ExceptionFactory = Conductor.Client.Configuration.DefaultExceptionFactory;
+ }
+
+ ///
+ /// Initializes a new instance of the class
+ /// using Configuration object
+ ///
+ /// An instance of Configuration
+ ///
+ public IntegrationResourceApi(Conductor.Client.Configuration configuration = null)
+ {
+ if (configuration == null) // use the default one in Configuration
+ this.Configuration = Conductor.Client.Configuration.Default;
+ else
+ this.Configuration = configuration;
+
+ ExceptionFactory = Conductor.Client.Configuration.DefaultExceptionFactory;
+ }
+
+ ///
+ /// Gets the base path of the API client.
+ ///
+ /// The base path
+ public string GetBasePath()
+ {
+ return this.Configuration.ApiClient.RestClient.Options.BaseUrl.ToString();
+ }
+
+
+ ///
+ /// Gets or sets the configuration object
+ ///
+ /// An instance of the Configuration
+ public Conductor.Client.Configuration Configuration { get; set; }
+
+ ///
+ /// Provides a factory method hook for the creation of exceptions.
+ ///
+ public Conductor.Client.ExceptionFactory ExceptionFactory
+ {
+ get
+ {
+ if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1)
+ {
+ throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported.");
+ }
+ return _exceptionFactory;
+ }
+ set { _exceptionFactory = value; }
+ }
+
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ ///
+ public void AssociatePromptWithIntegration(string integrationProvider, string integrationName, string promptName)
+ {
+ AssociatePromptWithIntegrationWithHttpInfo(integrationProvider, integrationName, promptName);
+ }
+
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// ApiResponse of Object(void)
+ public ApiResponse AssociatePromptWithIntegrationWithHttpInfo(string integrationProvider, string integrationName, string promptName)
+ {
+ // verify the required parameter 'integrationProvider' is set
+ if (integrationProvider == null)
+ throw new ApiException(400, "Missing required parameter 'integrationProvider' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+ // verify the required parameter 'promptName' is set
+ if (promptName == null)
+ throw new ApiException(400, "Missing required parameter 'promptName' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+
+ var localVarPath = "/integrations/provider/{integration_provider}/integration/{integration_name}/prompt/{prompt_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (integrationProvider != null) localVarPathParams.Add("integration_provider", this.Configuration.ApiClient.ParameterToString(integrationProvider)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ if (promptName != null) localVarPathParams.Add("prompt_name", this.Configuration.ApiClient.ParameterToString(promptName)); // path parameter
+ // authentication (api_key) required
+ if (!String.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Post, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, this.Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("AssociatePromptWithIntegration", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), null);
+ }
+
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// Task of void
+ public async System.Threading.Tasks.Task AssociatePromptWithIntegrationAsync(string integrationProvider, string integrationName, string promptName)
+ {
+ await AssociatePromptWithIntegrationAsyncWithHttpInfo(integrationProvider, integrationName, promptName);
+
+ }
+
+ ///
+ /// Associate a Prompt Template with an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ /// Task of ApiResponse
+ public async System.Threading.Tasks.Task> AssociatePromptWithIntegrationAsyncWithHttpInfo(string integrationProvider, string integrationName, string promptName)
+ {
+ // verify the required parameter 'integrationProvider' is set
+ if (integrationProvider == null)
+ throw new ApiException(400, "Missing required parameter 'integrationProvider' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+ // verify the required parameter 'promptName' is set
+ if (promptName == null)
+ throw new ApiException(400, "Missing required parameter 'promptName' when calling IntegrationResourceApi->AssociatePromptWithIntegration");
+
+ var localVarPath = "/integrations/provider/{integration_provider}/integration/{integration_name}/prompt/{prompt_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (integrationProvider != null) localVarPathParams.Add("integration_provider", this.Configuration.ApiClient.ParameterToString(integrationProvider)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ if (promptName != null) localVarPathParams.Add("prompt_name", this.Configuration.ApiClient.ParameterToString(promptName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Post, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("AssociatePromptWithIntegration", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ ///
+ public void DeleteIntegrationApi(string name, string integrationName)
+ {
+ DeleteIntegrationApiWithHttpInfo(name, integrationName);
+ }
+
+ ///
+ /// Delete an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// ApiResponse of Object(void)
+ public ApiResponse DeleteIntegrationApiWithHttpInfo(string name, string integrationName)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteIntegrationApi");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->DeleteIntegrationApi");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteIntegrationApi", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of void
+ public async System.Threading.Tasks.Task DeleteIntegrationApiAsync(string name, string integrationName)
+ {
+ await DeleteIntegrationApiAsyncWithHttpInfo(name, integrationName);
+
+ }
+
+ ///
+ /// Delete an Integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of ApiResponse
+ public async System.Threading.Tasks.Task> DeleteIntegrationApiAsyncWithHttpInfo(string name, string integrationName)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteIntegrationApi");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->DeleteIntegrationApi");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteIntegrationApi", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ public void DeleteIntegrationProvider(string name)
+ {
+ DeleteIntegrationProviderWithHttpInfo(name);
+ }
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// ApiResponse of Object(void)
+ public ApiResponse DeleteIntegrationProviderWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of void
+ public async System.Threading.Tasks.Task DeleteIntegrationProviderAsync(string name)
+ {
+ await DeleteIntegrationProviderAsyncWithHttpInfo(name);
+
+ }
+
+ ///
+ /// Delete an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of ApiResponse
+ public async System.Threading.Tasks.Task> DeleteIntegrationProviderAsyncWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ ///
+ public void DeleteTagForIntegration(List body, string name, string integrationName)
+ {
+ DeleteTagForIntegrationWithHttpInfo(body, name, integrationName);
+ }
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ /// ApiResponse of Object(void)
+ public ApiResponse DeleteTagForIntegrationWithHttpInfo(List body, string name, string integrationName)
+ {
+ // verify the required parameter 'body' is set
+ if (body == null)
+ throw new ApiException(400, "Missing required parameter 'body' when calling IntegrationResourceApi->DeleteTagForIntegration");
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteTagForIntegration");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->DeleteTagForIntegration");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}/tags";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { "application/json" };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ if (body != null && body.GetType() != typeof(byte[]))
+ {
+ localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
+ }
+ else
+ {
+ localVarPostBody = body; // byte array
+ }
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteTagForIntegration", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ /// Task of void
+ public async System.Threading.Tasks.Task DeleteTagForIntegrationAsync(List body, string name, string integrationName)
+ {
+ await DeleteTagForIntegrationAsyncWithHttpInfo(body, name, integrationName);
+
+ }
+
+ ///
+ /// Delete a tag for Integration
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// The name of the model associated with the tag.
+ /// Task of ApiResponse
+ public async System.Threading.Tasks.Task> DeleteTagForIntegrationAsyncWithHttpInfo(List body, string name, string integrationName)
+ {
+ // verify the required parameter 'body' is set
+ if (body == null)
+ throw new ApiException(400, "Missing required parameter 'body' when calling IntegrationResourceApi->DeleteTagForIntegration");
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteTagForIntegration");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->DeleteTagForIntegration");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}/tags";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { "application/json" };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ if (body != null && body.GetType() != typeof(byte[]))
+ {
+ localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
+ }
+ else
+ {
+ localVarPostBody = body; // byte array
+ }
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteTagForIntegration", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ ///
+ public void DeleteTagForIntegrationProvider(List body, string name)
+ {
+ DeleteTagForIntegrationProviderWithHttpInfo(body, name);
+ }
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// ApiResponse of Object(void)
+ public ApiResponse DeleteTagForIntegrationProviderWithHttpInfo(List body, string name)
+ {
+ // verify the required parameter 'body' is set
+ if (body == null)
+ throw new ApiException(400, "Missing required parameter 'body' when calling IntegrationResourceApi->DeleteTagForIntegrationProvider");
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteTagForIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}/tags";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { "application/json" };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (body != null && body.GetType() != typeof(byte[]))
+ {
+ localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
+ }
+ else
+ {
+ localVarPostBody = body; // byte array
+ }
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteTagForIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// Task of void
+ public async System.Threading.Tasks.Task DeleteTagForIntegrationProviderAsync(List body, string name)
+ {
+ await DeleteTagForIntegrationProviderAsyncWithHttpInfo(body, name);
+
+ }
+
+ ///
+ /// Delete a tag for Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ /// The list of tags to be deleted.
+ /// The name of the integration associated with the tag
+ /// Task of ApiResponse
+ public async System.Threading.Tasks.Task> DeleteTagForIntegrationProviderAsyncWithHttpInfo(List body, string name)
+ {
+ // verify the required parameter 'body' is set
+ if (body == null)
+ throw new ApiException(400, "Missing required parameter 'body' when calling IntegrationResourceApi->DeleteTagForIntegrationProvider");
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->DeleteTagForIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}/tags";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { "application/json" };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (body != null && body.GetType() != typeof(byte[]))
+ {
+ localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
+ }
+ else
+ {
+ localVarPostBody = body; // byte array
+ }
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("DeleteTagForIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ null);
+ }
+
+ ///
+ /// Get Integration details
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// IntegrationApi
+ public IntegrationApi GetIntegrationApi(string name, string integrationName)
+ {
+ ApiResponse localVarResponse = GetIntegrationApiWithHttpInfo(name, integrationName);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get Integration details
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// ApiResponse of IntegrationApi
+ public ApiResponse GetIntegrationApiWithHttpInfo(string name, string integrationName)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationApi");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->GetIntegrationApi");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationApi", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (IntegrationApi)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(IntegrationApi)));
+ }
+
+ ///
+ /// Get Integration details
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of IntegrationApi
+ public async System.Threading.Tasks.Task GetIntegrationApiAsync(string name, string integrationName)
+ {
+ ApiResponse localVarResponse = await GetIntegrationApiAsyncWithHttpInfo(name, integrationName);
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get Integration details
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// Task of ApiResponse (IntegrationApi)
+ public async System.Threading.Tasks.Task> GetIntegrationApiAsyncWithHttpInfo(string name, string integrationName)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationApi");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->GetIntegrationApi");
+
+ var localVarPath = "/integrations/provider/{name}/integration/{integration_name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationApi", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (IntegrationApi)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(IntegrationApi)));
+ }
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// List
+ public List GetIntegrationApis(string name, bool? activeOnly = null)
+ {
+ ApiResponse> localVarResponse = GetIntegrationApisWithHttpInfo(name, activeOnly);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// ApiResponse of List
+ public ApiResponse> GetIntegrationApisWithHttpInfo(string name, bool? activeOnly = null)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationApis");
+
+ var localVarPath = "/integrations/provider/{name}/integration";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (activeOnly != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "activeOnly", activeOnly)); // query parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationApis", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// Task of List
+ public async System.Threading.Tasks.Task> GetIntegrationApisAsync(string name, bool? activeOnly = null)
+ {
+ ApiResponse> localVarResponse = await GetIntegrationApisAsyncWithHttpInfo(name, activeOnly);
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get Integrations of an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// (optional, default to true)
+ /// Task of ApiResponse (List)
+ public async System.Threading.Tasks.Task>> GetIntegrationApisAsyncWithHttpInfo(string name, bool? activeOnly = null)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationApis");
+
+ var localVarPath = "/integrations/provider/{name}/integration";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ if (activeOnly != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "activeOnly", activeOnly)); // query parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationApis", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// List
+ public List GetIntegrationAvailableApis(string name)
+ {
+ ApiResponse> localVarResponse = GetIntegrationAvailableApisWithHttpInfo(name);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// ApiResponse of List
+ public ApiResponse> GetIntegrationAvailableApisWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationAvailableApis");
+
+ var localVarPath = "/integrations/provider/{name}/integration/all";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationAvailableApis", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of List
+ public async System.Threading.Tasks.Task> GetIntegrationAvailableApisAsync(string name)
+ {
+ ApiResponse> localVarResponse = await GetIntegrationAvailableApisAsyncWithHttpInfo(name);
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get Integrations Available for an Integration Provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of ApiResponse (List)
+ public async System.Threading.Tasks.Task>> GetIntegrationAvailableApisAsyncWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationAvailableApis");
+
+ var localVarPath = "/integrations/provider/{name}/integration/all";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationAvailableApis", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get Integration provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Integration
+ public Integration GetIntegrationProvider(string name)
+ {
+ ApiResponse localVarResponse = GetIntegrationProviderWithHttpInfo(name);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get Integration provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// ApiResponse of Integration
+ public ApiResponse GetIntegrationProviderWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (Integration)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Integration)));
+ }
+
+ ///
+ /// Get Integration provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of Integration
+ public async System.Threading.Tasks.Task GetIntegrationProviderAsync(string name)
+ {
+ ApiResponse localVarResponse = await GetIntegrationProviderAsyncWithHttpInfo(name);
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get Integration provider
+ ///
+ /// Thrown when fails to make API call
+ ///
+ /// Task of ApiResponse (Integration)
+ public async System.Threading.Tasks.Task> GetIntegrationProviderAsyncWithHttpInfo(string name)
+ {
+ // verify the required parameter 'name' is set
+ if (name == null)
+ throw new ApiException(400, "Missing required parameter 'name' when calling IntegrationResourceApi->GetIntegrationProvider");
+
+ var localVarPath = "/integrations/provider/{name}";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (name != null) localVarPathParams.Add("name", this.Configuration.ApiClient.ParameterToString(name)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProvider", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (Integration)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Integration)));
+ }
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ /// Thrown when fails to make API call
+ /// List
+ public List GetIntegrationProviderDefs()
+ {
+ ApiResponse> localVarResponse = GetIntegrationProviderDefsWithHttpInfo();
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ /// Thrown when fails to make API call
+ /// ApiResponse of List
+ public ApiResponse> GetIntegrationProviderDefsWithHttpInfo()
+ {
+
+ var localVarPath = "/integrations/def";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProviderDefs", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ /// Thrown when fails to make API call
+ /// Task of List
+ public async System.Threading.Tasks.Task> GetIntegrationProviderDefsAsync()
+ {
+ ApiResponse> localVarResponse = await GetIntegrationProviderDefsAsyncWithHttpInfo();
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get Integration provider definitions
+ ///
+ /// Thrown when fails to make API call
+ /// Task of ApiResponse (List)
+ public async System.Threading.Tasks.Task>> GetIntegrationProviderDefsAsyncWithHttpInfo()
+ {
+
+ var localVarPath = "/integrations/def";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProviderDefs", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// List
+ public List GetIntegrationProviders(string category = null, bool? activeOnly = null)
+ {
+ ApiResponse> localVarResponse = GetIntegrationProvidersWithHttpInfo(category, activeOnly);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// ApiResponse of List
+ public ApiResponse> GetIntegrationProvidersWithHttpInfo(string category = null, bool? activeOnly = null)
+ {
+
+ var localVarPath = "/integrations/provider";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (category != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "category", category)); // query parameter
+ if (activeOnly != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "activeOnly", activeOnly)); // query parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProviders", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// Task of List
+ public async System.Threading.Tasks.Task> GetIntegrationProvidersAsync(string category = null, bool? activeOnly = null)
+ {
+ ApiResponse> localVarResponse = await GetIntegrationProvidersAsyncWithHttpInfo(category, activeOnly);
+ return localVarResponse.Data;
+
+ }
+
+ ///
+ /// Get all Integrations Providers
+ ///
+ /// Thrown when fails to make API call
+ /// (optional)
+ /// (optional, default to true)
+ /// Task of ApiResponse (List)
+ public async System.Threading.Tasks.Task>> GetIntegrationProvidersAsyncWithHttpInfo(string category = null, bool? activeOnly = null)
+ {
+
+ var localVarPath = "/integrations/provider";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (category != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "category", category)); // query parameter
+ if (activeOnly != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "activeOnly", activeOnly)); // query parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetIntegrationProviders", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///
+ /// Get the list of prompt templates associated with an integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// List
+ public List GetPromptsWithIntegration(string integrationProvider, string integrationName)
+ {
+ ApiResponse> localVarResponse = GetPromptsWithIntegrationWithHttpInfo(integrationProvider, integrationName);
+ return localVarResponse.Data;
+ }
+
+ ///
+ /// Get the list of prompt templates associated with an integration
+ ///
+ /// Thrown when fails to make API call
+ ///
+ ///
+ /// ApiResponse of List
+ public ApiResponse> GetPromptsWithIntegrationWithHttpInfo(string integrationProvider, string integrationName)
+ {
+ // verify the required parameter 'integrationProvider' is set
+ if (integrationProvider == null)
+ throw new ApiException(400, "Missing required parameter 'integrationProvider' when calling IntegrationResourceApi->GetPromptsWithIntegration");
+ // verify the required parameter 'integrationName' is set
+ if (integrationName == null)
+ throw new ApiException(400, "Missing required parameter 'integrationName' when calling IntegrationResourceApi->GetPromptsWithIntegration");
+
+ var localVarPath = "/integrations/provider/{integration_provider}/integration/{integration_name}/prompt";
+ var localVarPathParams = new Dictionary();
+ var localVarQueryParams = new List>();
+ var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader);
+ var localVarFormParams = new Dictionary();
+ var localVarFileParams = new Dictionary();
+ Object localVarPostBody = null;
+
+ // to determine the Content-Type header
+ string[] localVarHttpContentTypes = new string[] { };
+ string localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
+
+ // to determine the Accept header
+ string[] localVarHttpHeaderAccepts = new string[] { "application/json" };
+ string localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
+ if (localVarHttpHeaderAccept != null)
+ localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
+
+ if (integrationProvider != null) localVarPathParams.Add("integration_provider", this.Configuration.ApiClient.ParameterToString(integrationProvider)); // path parameter
+ if (integrationName != null) localVarPathParams.Add("integration_name", this.Configuration.ApiClient.ParameterToString(integrationName)); // path parameter
+ // authentication (api_key) required
+ if (!string.IsNullOrEmpty(this.Configuration.AccessToken))
+ {
+ localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
+ }
+
+ // make the HTTP request
+ RestResponse localVarResponse = (RestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
+ Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
+ localVarPathParams, localVarHttpContentType, Configuration);
+
+ int localVarStatusCode = (int)localVarResponse.StatusCode;
+
+ if (ExceptionFactory != null)
+ {
+ Exception exception = ExceptionFactory("GetPromptsWithIntegration", localVarResponse);
+ if (exception != null) throw exception;
+ }
+
+ return new ApiResponse>(localVarStatusCode,
+ localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
+ (List)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(List)));
+ }
+
+ ///