diff --git a/CHANGELOG.md b/CHANGELOG.md index 21cc505..a2be550 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,11 @@ # DocuSign Admin C# Client Changelog See [DocuSign Support Center](https://support.docusign.com/en/releasenotes/) for Product Release Notes. +## [v2.1.0] - Admin API v2.1-1.4.3 - 2026-03-03 +### Changed +- Added support for version v2.1-1.4.3 of the DocuSign Admin API. +- Updated the SDK release version. + ## [v2.0.2] - Admin API v2.1-1.4.1 - 2024-11-15 ### Changed - Resolved an issue that prevented the use of `RequestJWTApplicationToken` with a production account URL. diff --git a/README.md b/README.md index 99a3848..be432d7 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ This client SDK is provided as open source, which enables you to customize its f ### Version Information - **API version**: v2.1 -- **Latest SDK version (Including prerelease)**: 2.0.2 +- **Latest SDK version (Including prerelease)**: 2.1.0 ### Requirements diff --git a/sdk/DocuSign.Admin.sln b/sdk/DocuSign.Admin.sln index e82f233..a367bdd 100644 --- a/sdk/DocuSign.Admin.sln +++ b/sdk/DocuSign.Admin.sln @@ -2,7 +2,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 2012 VisualStudioVersion = 12.0.0.0 MinimumVisualStudioVersion = 10.0.0.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocuSign.Admin", "src\DocuSign.Admin\DocuSign.Admin.csproj", "{1AEC973B-1BDF-4172-8FDF-0FC4FD2E9FB9}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocuSign.Admin", "src\DocuSign.Admin\DocuSign.Admin.csproj", "{7AA0EF08-F8E7-4FC0-8A1A-A1F9B15D8422}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -10,10 +10,10 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {1AEC973B-1BDF-4172-8FDF-0FC4FD2E9FB9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {1AEC973B-1BDF-4172-8FDF-0FC4FD2E9FB9}.Debug|Any CPU.Build.0 = Debug|Any CPU - {1AEC973B-1BDF-4172-8FDF-0FC4FD2E9FB9}.Release|Any CPU.ActiveCfg = Release|Any CPU - {1AEC973B-1BDF-4172-8FDF-0FC4FD2E9FB9}.Release|Any CPU.Build.0 = Release|Any CPU + {7AA0EF08-F8E7-4FC0-8A1A-A1F9B15D8422}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7AA0EF08-F8E7-4FC0-8A1A-A1F9B15D8422}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7AA0EF08-F8E7-4FC0-8A1A-A1F9B15D8422}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7AA0EF08-F8E7-4FC0-8A1A-A1F9B15D8422}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/sdk/src/DocuSign.Admin/Api/OrgConnectApi.cs b/sdk/src/DocuSign.Admin/Api/OrgConnectApi.cs new file mode 100644 index 0000000..67b2c6f --- /dev/null +++ b/sdk/src/DocuSign.Admin/Api/OrgConnectApi.cs @@ -0,0 +1,2671 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Net.Http; +using DocuSign.Admin.Client; +using DocuSign.Admin.Model; + +namespace DocuSign.Admin.Api +{ + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public interface IOrgConnectApi : IApiAccessor + { + #region Synchronous Operations + /// + /// Adds a Connect configuration for an organization + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// + OrganizationConnectConfigurationDetailsResponse CreateOrganizationConnectConfig(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest); + + /// + /// Adds a Connect configuration for an organization + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// ApiResponse of + ApiResponse CreateOrganizationConnectConfigWithHttpInfo(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest); + /// + /// Deletes information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// + OrganizationConnectHmacSecretsResponse DeleteConnectHmacSecret(Guid? organizationId, Guid? keyId); + + /// + /// Deletes information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// ApiResponse of + ApiResponse DeleteConnectHmacSecretWithHttpInfo(Guid? organizationId, Guid? keyId); + /// + /// Deletes information about an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// + Object DeleteOrganizationConnectConfig(Guid? organizationId, Guid? connectId); + + /// + /// Deletes information about an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// ApiResponse of + ApiResponse DeleteOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId); + /// + /// Deletes an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// + Object DeleteOrganizationConnectOAuthConfiguration(Guid? organizationId); + + /// + /// Deletes an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of + ApiResponse DeleteOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId); + /// + /// Returns information about Connect HMAC secrets + /// + /// + /// Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// + OrganizationConnectHmacSecretsResponse GetConnectHmacSecrets(Guid? organizationId); + + /// + /// Returns information about Connect HMAC secrets + /// + /// + /// Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of + ApiResponse GetConnectHmacSecretsWithHttpInfo(Guid? organizationId); + /// + /// Returns an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// + OrganizationConnectConfigurationDetailsResponse GetOrganizationConnectConfig(Guid? organizationId, Guid? connectId); + + /// + /// Returns an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// ApiResponse of + ApiResponse GetOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId); + /// + /// Returns a list of Connect configurations under an organization + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// + OrganizationConnectConfigsResponse GetOrganizationConnectConfigs(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null); + + /// + /// Returns a list of Connect configurations under an organization + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// ApiResponse of + ApiResponse GetOrganizationConnectConfigsWithHttpInfo(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null); + /// + /// Returns information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// + Object GetOrganizationConnectOAuthConfiguration(Guid? organizationId); + + /// + /// Returns information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of + ApiResponse GetOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId); + /// + /// Saves information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// + OrganizationConnectHmacSecretsResponse PostConnectHmacSecret(Guid? organizationId); + + /// + /// Saves information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of + ApiResponse PostConnectHmacSecretWithHttpInfo(Guid? organizationId); + /// + /// Saves information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// + OrganizationConnectOAuthConfiguration PostOrganizationConnectOAuthConfiguration(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + + /// + /// Saves information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// ApiResponse of + ApiResponse PostOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + /// + /// Updates information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// + OrganizationConnectOAuthConfiguration PutOrganizationConnectOAuthConfiguration(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + + /// + /// Updates information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// ApiResponse of + ApiResponse PutOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + /// + /// Updates an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// + OrganizationConnectConfigurationDetailsResponse UpdateOrganizationConnectConfig(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest); + + /// + /// Updates an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// ApiResponse of + ApiResponse UpdateOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest); + #endregion Synchronous Operations + #region Asynchronous Operations + /// + /// Adds a Connect configuration for an organization + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// Task of OrganizationConnectConfigurationDetailsResponse + System.Threading.Tasks.Task CreateOrganizationConnectConfigAsync(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest); + + /// + /// Adds a Connect configuration for an organization + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + System.Threading.Tasks.Task> CreateOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest); + /// + /// Deletes information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + System.Threading.Tasks.Task DeleteConnectHmacSecretAsync(Guid? organizationId, Guid? keyId); + + /// + /// Deletes information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + System.Threading.Tasks.Task> DeleteConnectHmacSecretAsyncWithHttpInfo(Guid? organizationId, Guid? keyId); + /// + /// Deletes information about an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of Object + System.Threading.Tasks.Task DeleteOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId); + + /// + /// Deletes information about an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of ApiResponse (Object) + System.Threading.Tasks.Task> DeleteOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId); + /// + /// Deletes an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of Object + System.Threading.Tasks.Task DeleteOrganizationConnectOAuthConfigurationAsync(Guid? organizationId); + + /// + /// Deletes an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (Object) + System.Threading.Tasks.Task> DeleteOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId); + /// + /// Returns information about Connect HMAC secrets + /// + /// + /// Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + System.Threading.Tasks.Task GetConnectHmacSecretsAsync(Guid? organizationId); + + /// + /// Returns information about Connect HMAC secrets + /// + /// + /// Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + System.Threading.Tasks.Task> GetConnectHmacSecretsAsyncWithHttpInfo(Guid? organizationId); + /// + /// Returns an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of OrganizationConnectConfigurationDetailsResponse + System.Threading.Tasks.Task GetOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId); + + /// + /// Returns an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + System.Threading.Tasks.Task> GetOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId); + /// + /// Returns a list of Connect configurations under an organization + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// Task of OrganizationConnectConfigsResponse + System.Threading.Tasks.Task GetOrganizationConnectConfigsAsync(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null); + + /// + /// Returns a list of Connect configurations under an organization + /// + /// + /// Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// Task of ApiResponse (OrganizationConnectConfigsResponse) + System.Threading.Tasks.Task> GetOrganizationConnectConfigsAsyncWithHttpInfo(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null); + /// + /// Returns information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of Object + System.Threading.Tasks.Task GetOrganizationConnectOAuthConfigurationAsync(Guid? organizationId); + + /// + /// Returns information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (Object) + System.Threading.Tasks.Task> GetOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId); + /// + /// Saves information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + System.Threading.Tasks.Task PostConnectHmacSecretAsync(Guid? organizationId); + + /// + /// Saves information about a Connect HMAC secret + /// + /// + /// Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + System.Threading.Tasks.Task> PostConnectHmacSecretAsyncWithHttpInfo(Guid? organizationId); + /// + /// Saves information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// Task of OrganizationConnectOAuthConfiguration + System.Threading.Tasks.Task PostOrganizationConnectOAuthConfigurationAsync(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + + /// + /// Saves information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// Task of ApiResponse (OrganizationConnectOAuthConfiguration) + System.Threading.Tasks.Task> PostOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + /// + /// Updates information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// Task of OrganizationConnectOAuthConfiguration + System.Threading.Tasks.Task PutOrganizationConnectOAuthConfigurationAsync(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + + /// + /// Updates information about an organization-level Connect OAuth configuration + /// + /// + /// Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// Task of ApiResponse (OrganizationConnectOAuthConfiguration) + System.Threading.Tasks.Task> PutOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration); + /// + /// Updates an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// Task of OrganizationConnectConfigurationDetailsResponse + System.Threading.Tasks.Task UpdateOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest); + + /// + /// Updates an organization-level Connect configuration + /// + /// + /// Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + System.Threading.Tasks.Task> UpdateOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest); + #endregion Asynchronous Operations + } + + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public partial class OrgConnectApi : IOrgConnectApi + { + private DocuSign.Admin.Client.ExceptionFactory _exceptionFactory = (name, response) => null; + + /// + /// Initializes a new instance of the class + /// using AplClient object + /// + /// An instance of AplClient + /// + public OrgConnectApi(DocuSignClient aplClient) + { + this.ApiClient = aplClient; + + ExceptionFactory = Configuration.DefaultExceptionFactory; + } + + /// + /// Gets the base path of the API client. + /// + /// The base path + public String GetBasePath() + { + return this.ApiClient.GetBasePath(); + } + + /// + /// Gets or sets the ApiClient object + /// + /// An instance of the ApiClient + public DocuSignClient ApiClient { get; set; } + + /// + /// Provides a factory method hook for the creation of exceptions. + /// + public DocuSign.Admin.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; } + } + + + /// + /// Adds a Connect configuration for an organization Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// OrganizationConnectConfigurationDetailsResponse + public OrganizationConnectConfigurationDetailsResponse CreateOrganizationConnectConfig(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest) + { + ApiResponse localVarResponse = CreateOrganizationConnectConfigWithHttpInfo(organizationId, connectRequest); + return localVarResponse.Data; + } + + /// + /// Adds a Connect configuration for an organization Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// ApiResponse of OrganizationConnectConfigurationDetailsResponse + public ApiResponse CreateOrganizationConnectConfigWithHttpInfo(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->CreateOrganizationConnectConfig"); + // verify the required parameter 'connectRequest' is set + if (connectRequest == null) + throw new ApiException(400, "Missing required parameter 'connectRequest' when calling OrgConnectApi->CreateOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectRequest != null && connectRequest.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(connectRequest); // http body (model) parameter + } + else + { + localVarPostBody = connectRequest; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("CreateOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + /// + /// Adds a Connect configuration for an organization Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// Task of OrganizationConnectConfigurationDetailsResponse + public async System.Threading.Tasks.Task CreateOrganizationConnectConfigAsync(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest) + { + ApiResponse localVarResponse = await CreateOrganizationConnectConfigAsyncWithHttpInfo(organizationId, connectRequest); + return localVarResponse.Data; + } + + /// + /// Adds a Connect configuration for an organization Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization Connect request + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + public async System.Threading.Tasks.Task> CreateOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectConfigurationRequest connectRequest) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->CreateOrganizationConnectConfig"); + // verify the required parameter 'connectRequest' is set + if (connectRequest == null) + throw new ApiException(400, "Missing required parameter 'connectRequest' when calling OrgConnectApi->CreateOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectRequest != null && connectRequest.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(connectRequest); // http body (model) parameter + } + else + { + localVarPostBody = connectRequest; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("CreateOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + + /// + /// Deletes information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// OrganizationConnectHmacSecretsResponse + public OrganizationConnectHmacSecretsResponse DeleteConnectHmacSecret(Guid? organizationId, Guid? keyId) + { + ApiResponse localVarResponse = DeleteConnectHmacSecretWithHttpInfo(organizationId, keyId); + return localVarResponse.Data; + } + + /// + /// Deletes information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// ApiResponse of OrganizationConnectHmacSecretsResponse + public ApiResponse DeleteConnectHmacSecretWithHttpInfo(Guid? organizationId, Guid? keyId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteConnectHmacSecret"); + // verify the required parameter 'keyId' is set + if (keyId == null) + throw new ApiException(400, "Missing required parameter 'keyId' when calling OrgConnectApi->DeleteConnectHmacSecret"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret/{keyId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (keyId != null) localVarPathParams.Add("keyId", this.ApiClient.ParameterToString(keyId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteConnectHmacSecret", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + /// + /// Deletes information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + public async System.Threading.Tasks.Task DeleteConnectHmacSecretAsync(Guid? organizationId, Guid? keyId) + { + ApiResponse localVarResponse = await DeleteConnectHmacSecretAsyncWithHttpInfo(organizationId, keyId); + return localVarResponse.Data; + } + + /// + /// Deletes information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The key ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + public async System.Threading.Tasks.Task> DeleteConnectHmacSecretAsyncWithHttpInfo(Guid? organizationId, Guid? keyId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteConnectHmacSecret"); + // verify the required parameter 'keyId' is set + if (keyId == null) + throw new ApiException(400, "Missing required parameter 'keyId' when calling OrgConnectApi->DeleteConnectHmacSecret"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret/{keyId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (keyId != null) localVarPathParams.Add("keyId", this.ApiClient.ParameterToString(keyId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteConnectHmacSecret", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + + /// + /// Deletes information about an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Object + public Object DeleteOrganizationConnectConfig(Guid? organizationId, Guid? connectId) + { + ApiResponse localVarResponse = DeleteOrganizationConnectConfigWithHttpInfo(organizationId, connectId); + return localVarResponse.Data; + } + + /// + /// Deletes information about an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// ApiResponse of Object + public ApiResponse DeleteOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->DeleteOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + /// + /// Deletes information about an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of Object + public async System.Threading.Tasks.Task DeleteOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId) + { + ApiResponse localVarResponse = await DeleteOrganizationConnectConfigAsyncWithHttpInfo(organizationId, connectId); + return localVarResponse.Data; + } + + /// + /// Deletes information about an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of ApiResponse (Object) + public async System.Threading.Tasks.Task> DeleteOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->DeleteOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + + /// + /// Deletes an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Object + public Object DeleteOrganizationConnectOAuthConfiguration(Guid? organizationId) + { + ApiResponse localVarResponse = DeleteOrganizationConnectOAuthConfigurationWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Deletes an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of Object + public ApiResponse DeleteOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + /// + /// Deletes an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of Object + public async System.Threading.Tasks.Task DeleteOrganizationConnectOAuthConfigurationAsync(Guid? organizationId) + { + ApiResponse localVarResponse = await DeleteOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Deletes an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (Object) + public async System.Threading.Tasks.Task> DeleteOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->DeleteOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("DELETE"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("DeleteOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + + /// + /// Returns information about Connect HMAC secrets Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// OrganizationConnectHmacSecretsResponse + public OrganizationConnectHmacSecretsResponse GetConnectHmacSecrets(Guid? organizationId) + { + ApiResponse localVarResponse = GetConnectHmacSecretsWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Returns information about Connect HMAC secrets Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of OrganizationConnectHmacSecretsResponse + public ApiResponse GetConnectHmacSecretsWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetConnectHmacSecrets"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetConnectHmacSecrets", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + /// + /// Returns information about Connect HMAC secrets Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + public async System.Threading.Tasks.Task GetConnectHmacSecretsAsync(Guid? organizationId) + { + ApiResponse localVarResponse = await GetConnectHmacSecretsAsyncWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Returns information about Connect HMAC secrets Required scopes: connect_org_hmac_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + public async System.Threading.Tasks.Task> GetConnectHmacSecretsAsyncWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetConnectHmacSecrets"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetConnectHmacSecrets", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + + /// + /// Returns an organization-level Connect configuration Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// OrganizationConnectConfigurationDetailsResponse + public OrganizationConnectConfigurationDetailsResponse GetOrganizationConnectConfig(Guid? organizationId, Guid? connectId) + { + ApiResponse localVarResponse = GetOrganizationConnectConfigWithHttpInfo(organizationId, connectId); + return localVarResponse.Data; + } + + /// + /// Returns an organization-level Connect configuration Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// ApiResponse of OrganizationConnectConfigurationDetailsResponse + public ApiResponse GetOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->GetOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + /// + /// Returns an organization-level Connect configuration Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of OrganizationConnectConfigurationDetailsResponse + public async System.Threading.Tasks.Task GetOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId) + { + ApiResponse localVarResponse = await GetOrganizationConnectConfigAsyncWithHttpInfo(organizationId, connectId); + return localVarResponse.Data; + } + + /// + /// Returns an organization-level Connect configuration Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + public async System.Threading.Tasks.Task> GetOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->GetOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + /// + /// Returns a list of Connect configurations under an organization Required scopes: connect_org_config_read_api + /// + public class GetOrganizationConnectConfigsOptions + { + /// Sorts configs by field in ascending order. Default sort by config name. Default value: name + public string sortBy {get; set;} + /// Selects configs based on siteId + public int? siteId {get; set;} + /// Selects configs based on accountId + public Guid? accountId {get; set;} + /// Selects configs based on their status + public bool? allowEnvelopePublish {get; set;} + /// Selects configs based on config id or name provided in the query parameter + public string q {get; set;} + } + + /// + /// Returns a list of Connect configurations under an organization Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// OrganizationConnectConfigsResponse + public OrganizationConnectConfigsResponse GetOrganizationConnectConfigs(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null) + { + ApiResponse localVarResponse = GetOrganizationConnectConfigsWithHttpInfo(organizationId, options); + return localVarResponse.Data; + } + + /// + /// Returns a list of Connect configurations under an organization Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// ApiResponse of OrganizationConnectConfigsResponse + public ApiResponse GetOrganizationConnectConfigsWithHttpInfo(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectConfigs"); + + var localVarPath = "/v2/organizations/{organizationId}/connect"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (options != null) + { + if (options.sortBy != null) localVarQueryParams.Add("sortBy", this.ApiClient.ParameterToString(options.sortBy)); // query parameter + if (options.siteId != null) localVarQueryParams.Add("siteId", this.ApiClient.ParameterToString(options.siteId)); // query parameter + if (options.accountId != null) localVarQueryParams.Add("accountId", this.ApiClient.ParameterToString(options.accountId)); // query parameter + if (options.allowEnvelopePublish != null) localVarQueryParams.Add("allowEnvelopePublish", this.ApiClient.ParameterToString(options.allowEnvelopePublish)); // query parameter + if (options.q != null) localVarQueryParams.Add("q", this.ApiClient.ParameterToString(options.q)); // query parameter + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectConfigs", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigsResponse))); + } + + /// + /// Returns a list of Connect configurations under an organization Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// Task of OrganizationConnectConfigsResponse + public async System.Threading.Tasks.Task GetOrganizationConnectConfigsAsync(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null) + { + ApiResponse localVarResponse = await GetOrganizationConnectConfigsAsyncWithHttpInfo(organizationId, options); + return localVarResponse.Data; + } + + /// + /// Returns a list of Connect configurations under an organization Required scopes: connect_org_config_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Options for modifying the behavior of the function. + /// Task of ApiResponse (OrganizationConnectConfigsResponse) + public async System.Threading.Tasks.Task> GetOrganizationConnectConfigsAsyncWithHttpInfo(Guid? organizationId, OrgConnectApi.GetOrganizationConnectConfigsOptions options = null) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectConfigs"); + + var localVarPath = "/v2/organizations/{organizationId}/connect"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (options != null) + { + if (options.sortBy != null) localVarQueryParams.Add("sortBy", this.ApiClient.ParameterToString(options.sortBy)); // query parameter + if (options.siteId != null) localVarQueryParams.Add("siteId", this.ApiClient.ParameterToString(options.siteId)); // query parameter + if (options.accountId != null) localVarQueryParams.Add("accountId", this.ApiClient.ParameterToString(options.accountId)); // query parameter + if (options.allowEnvelopePublish != null) localVarQueryParams.Add("allowEnvelopePublish", this.ApiClient.ParameterToString(options.allowEnvelopePublish)); // query parameter + if (options.q != null) localVarQueryParams.Add("q", this.ApiClient.ParameterToString(options.q)); // query parameter + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectConfigs", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigsResponse))); + } + + + /// + /// Returns information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Object + public Object GetOrganizationConnectOAuthConfiguration(Guid? organizationId) + { + ApiResponse localVarResponse = GetOrganizationConnectOAuthConfigurationWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Returns information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of Object + public ApiResponse GetOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + /// + /// Returns information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of Object + public async System.Threading.Tasks.Task GetOrganizationConnectOAuthConfigurationAsync(Guid? organizationId) + { + ApiResponse localVarResponse = await GetOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Returns information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_read_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (Object) + public async System.Threading.Tasks.Task> GetOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->GetOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("GET"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("GetOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (Object)this.ApiClient.Deserialize(localVarResponse, typeof(Object))); + } + + + /// + /// Saves information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// OrganizationConnectHmacSecretsResponse + public OrganizationConnectHmacSecretsResponse PostConnectHmacSecret(Guid? organizationId) + { + ApiResponse localVarResponse = PostConnectHmacSecretWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Saves information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// ApiResponse of OrganizationConnectHmacSecretsResponse + public ApiResponse PostConnectHmacSecretWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PostConnectHmacSecret"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PostConnectHmacSecret", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + /// + /// Saves information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of OrganizationConnectHmacSecretsResponse + public async System.Threading.Tasks.Task PostConnectHmacSecretAsync(Guid? organizationId) + { + ApiResponse localVarResponse = await PostConnectHmacSecretAsyncWithHttpInfo(organizationId); + return localVarResponse.Data; + } + + /// + /// Saves information about a Connect HMAC secret Required scopes: connect_org_hmac_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Task of ApiResponse (OrganizationConnectHmacSecretsResponse) + public async System.Threading.Tasks.Task> PostConnectHmacSecretAsyncWithHttpInfo(Guid? organizationId) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PostConnectHmacSecret"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/secret"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PostConnectHmacSecret", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectHmacSecretsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectHmacSecretsResponse))); + } + + + /// + /// Saves information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// OrganizationConnectOAuthConfiguration + public OrganizationConnectOAuthConfiguration PostOrganizationConnectOAuthConfiguration(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + ApiResponse localVarResponse = PostOrganizationConnectOAuthConfigurationWithHttpInfo(organizationId, configuration); + return localVarResponse.Data; + } + + /// + /// Saves information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// ApiResponse of OrganizationConnectOAuthConfiguration + public ApiResponse PostOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PostOrganizationConnectOAuthConfiguration"); + // verify the required parameter 'configuration' is set + if (configuration == null) + throw new ApiException(400, "Missing required parameter 'configuration' when calling OrgConnectApi->PostOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (configuration != null && configuration.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(configuration); // http body (model) parameter + } + else + { + localVarPostBody = configuration; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PostOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectOAuthConfiguration)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectOAuthConfiguration))); + } + + /// + /// Saves information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// Task of OrganizationConnectOAuthConfiguration + public async System.Threading.Tasks.Task PostOrganizationConnectOAuthConfigurationAsync(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + ApiResponse localVarResponse = await PostOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(organizationId, configuration); + return localVarResponse.Data; + } + + /// + /// Saves information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Add an organization-level Connect OAuth configuration + /// Task of ApiResponse (OrganizationConnectOAuthConfiguration) + public async System.Threading.Tasks.Task> PostOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PostOrganizationConnectOAuthConfiguration"); + // verify the required parameter 'configuration' is set + if (configuration == null) + throw new ApiException(400, "Missing required parameter 'configuration' when calling OrgConnectApi->PostOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (configuration != null && configuration.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(configuration); // http body (model) parameter + } + else + { + localVarPostBody = configuration; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("POST"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PostOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectOAuthConfiguration)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectOAuthConfiguration))); + } + + + /// + /// Updates information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// OrganizationConnectOAuthConfiguration + public OrganizationConnectOAuthConfiguration PutOrganizationConnectOAuthConfiguration(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + ApiResponse localVarResponse = PutOrganizationConnectOAuthConfigurationWithHttpInfo(organizationId, configuration); + return localVarResponse.Data; + } + + /// + /// Updates information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// ApiResponse of OrganizationConnectOAuthConfiguration + public ApiResponse PutOrganizationConnectOAuthConfigurationWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PutOrganizationConnectOAuthConfiguration"); + // verify the required parameter 'configuration' is set + if (configuration == null) + throw new ApiException(400, "Missing required parameter 'configuration' when calling OrgConnectApi->PutOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (configuration != null && configuration.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(configuration); // http body (model) parameter + } + else + { + localVarPostBody = configuration; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("PUT"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PutOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectOAuthConfiguration)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectOAuthConfiguration))); + } + + /// + /// Updates information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// Task of OrganizationConnectOAuthConfiguration + public async System.Threading.Tasks.Task PutOrganizationConnectOAuthConfigurationAsync(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + ApiResponse localVarResponse = await PutOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(organizationId, configuration); + return localVarResponse.Data; + } + + /// + /// Updates information about an organization-level Connect OAuth configuration Required scopes: connect_org_oauth_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// Update an organization-level Connect OAuth configuration + /// Task of ApiResponse (OrganizationConnectOAuthConfiguration) + public async System.Threading.Tasks.Task> PutOrganizationConnectOAuthConfigurationAsyncWithHttpInfo(Guid? organizationId, OrganizationConnectOAuthConfiguration configuration) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->PutOrganizationConnectOAuthConfiguration"); + // verify the required parameter 'configuration' is set + if (configuration == null) + throw new ApiException(400, "Missing required parameter 'configuration' when calling OrgConnectApi->PutOrganizationConnectOAuthConfiguration"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/oauth"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (configuration != null && configuration.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(configuration); // http body (model) parameter + } + else + { + localVarPostBody = configuration; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("PUT"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("PutOrganizationConnectOAuthConfiguration", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectOAuthConfiguration)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectOAuthConfiguration))); + } + + + /// + /// Updates an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// OrganizationConnectConfigurationDetailsResponse + public OrganizationConnectConfigurationDetailsResponse UpdateOrganizationConnectConfig(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest) + { + ApiResponse localVarResponse = UpdateOrganizationConnectConfigWithHttpInfo(organizationId, connectId, connectRequest); + return localVarResponse.Data; + } + + /// + /// Updates an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// ApiResponse of OrganizationConnectConfigurationDetailsResponse + public ApiResponse UpdateOrganizationConnectConfigWithHttpInfo(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + // verify the required parameter 'connectRequest' is set + if (connectRequest == null) + throw new ApiException(400, "Missing required parameter 'connectRequest' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + if (connectRequest != null && connectRequest.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(connectRequest); // http body (model) parameter + } + else + { + localVarPostBody = connectRequest; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("PUT"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = this.ApiClient.CallApi(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("UpdateOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + /// + /// Updates an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// Task of OrganizationConnectConfigurationDetailsResponse + public async System.Threading.Tasks.Task UpdateOrganizationConnectConfigAsync(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest) + { + ApiResponse localVarResponse = await UpdateOrganizationConnectConfigAsyncWithHttpInfo(organizationId, connectId, connectRequest); + return localVarResponse.Data; + } + + /// + /// Updates an organization-level Connect configuration Required scopes: connect_org_config_write_api + /// + /// Thrown when fails to make API call + /// The organization ID Guid + /// The configuration ID Guid + /// Add an organization Connect request + /// Task of ApiResponse (OrganizationConnectConfigurationDetailsResponse) + public async System.Threading.Tasks.Task> UpdateOrganizationConnectConfigAsyncWithHttpInfo(Guid? organizationId, Guid? connectId, OrganizationConnectConfigurationRequest connectRequest) + { + // verify the required parameter 'organizationId' is set + if (organizationId == null) + throw new ApiException(400, "Missing required parameter 'organizationId' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + // verify the required parameter 'connectId' is set + if (connectId == null) + throw new ApiException(400, "Missing required parameter 'connectId' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + // verify the required parameter 'connectRequest' is set + if (connectRequest == null) + throw new ApiException(400, "Missing required parameter 'connectRequest' when calling OrgConnectApi->UpdateOrganizationConnectConfig"); + + var localVarPath = "/v2/organizations/{organizationId}/connect/{connectId}"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new Dictionary(); + var localVarHeaderParams = new Dictionary(this.ApiClient.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new List(); + Object localVarPostBody = null; + String localVarHttpContentDisposition = string.Empty; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json" + }; + String localVarHttpContentType = this.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + // set "format" to json by default + // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json + localVarPathParams.Add("format", "json"); + if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (connectId != null) localVarPathParams.Add("connectId", this.ApiClient.ParameterToString(connectId)); // path parameter + if (connectRequest != null && connectRequest.GetType() != typeof(byte[])) + { + localVarPostBody = this.ApiClient.Serialize(connectRequest); // http body (model) parameter + } + else + { + localVarPostBody = connectRequest; // byte array + } + + // authentication (docusignAccessCode) required + // oauth required + if (!String.IsNullOrEmpty(this.ApiClient.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.ApiClient.Configuration.AccessToken; + } + + + // make the HTTP request + DocuSignRequest localVarRequest = this.ApiClient.PrepareRequest(localVarPath, new HttpMethod("PUT"), localVarQueryParams.ToList(), localVarPostBody, localVarHeaderParams.ToList(), localVarFormParams.ToList(), localVarPathParams.ToList(), localVarFileParams, localVarHttpContentType, localVarHttpContentDisposition); + DocuSignResponse localVarResponse = await this.ApiClient.CallApiAsync(localVarRequest); + + int localVarStatusCode = (int)localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("UpdateOrganizationConnectConfig", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + (OrganizationConnectConfigurationDetailsResponse)this.ApiClient.Deserialize(localVarResponse, typeof(OrganizationConnectConfigurationDetailsResponse))); + } + + } +} \ No newline at end of file diff --git a/sdk/src/DocuSign.Admin/Api/UsersApi.cs b/sdk/src/DocuSign.Admin/Api/UsersApi.cs index 2203dec..99924b5 100644 --- a/sdk/src/DocuSign.Admin/Api/UsersApi.cs +++ b/sdk/src/DocuSign.Admin/Api/UsersApi.cs @@ -299,8 +299,9 @@ public interface IUsersApi : IApiAccessor /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// - UsersUpdateResponse UpdateUser(Guid? organizationId, UpdateUsersRequest request); + UsersUpdateResponse UpdateUser(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null); /// /// Updates a user. @@ -311,8 +312,9 @@ public interface IUsersApi : IApiAccessor /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// ApiResponse of - ApiResponse UpdateUserWithHttpInfo(Guid? organizationId, UpdateUsersRequest request); + ApiResponse UpdateUserWithHttpInfo(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -591,8 +593,9 @@ public interface IUsersApi : IApiAccessor /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// Task of UsersUpdateResponse - System.Threading.Tasks.Task UpdateUserAsync(Guid? organizationId, UpdateUsersRequest request); + System.Threading.Tasks.Task UpdateUserAsync(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null); /// /// Updates a user. @@ -603,8 +606,9 @@ public interface IUsersApi : IApiAccessor /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// Task of ApiResponse (UsersUpdateResponse) - System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo(Guid? organizationId, UpdateUsersRequest request); + System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null); #endregion Asynchronous Operations } @@ -1824,6 +1828,8 @@ public class GetUserDSProfileOptions { /// Sorts user information by account name ascending public bool? sort {get; set;} + /// When true: additional details about the user's license will be included in the response. The account must have an IAM plan with licenses. + public bool? includeLicense {get; set;} } /// @@ -1888,6 +1894,7 @@ public ApiResponse GetUserDSProfileWithHttpInfo(Guid? or if (options != null) { if (options.sort != null) localVarQueryParams.Add("sort", this.ApiClient.ParameterToString(options.sort)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -1977,6 +1984,7 @@ public async System.Threading.Tasks.Task> Ge if (options != null) { if (options.sort != null) localVarQueryParams.Add("sort", this.ApiClient.ParameterToString(options.sort)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2013,6 +2021,8 @@ public class GetUserDSProfilesByEmailOptions public string email {get; set;} /// Sorts user information by account name ascending public bool? sort {get; set;} + /// When true: additional details about the user's license will be included in the response. The account must have an IAM plan with licenses. + public bool? includeLicense {get; set;} } /// @@ -2072,6 +2082,7 @@ public ApiResponse GetUserDSProfilesByEmailWithHttpInfo( { if (options.email != null) localVarQueryParams.Add("email", this.ApiClient.ParameterToString(options.email)); // query parameter if (options.sort != null) localVarQueryParams.Add("sort", this.ApiClient.ParameterToString(options.sort)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2156,6 +2167,7 @@ public async System.Threading.Tasks.Task> Ge { if (options.email != null) localVarQueryParams.Add("email", this.ApiClient.ParameterToString(options.email)); // query parameter if (options.sort != null) localVarQueryParams.Add("sort", this.ApiClient.ParameterToString(options.sort)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2190,6 +2202,8 @@ public class GetUserProfilesOptions { /// The email address public string email {get; set;} + /// When true: additional details about the user's license will be included in the response. The account must have an IAM plan with licenses. + public bool? includeLicense {get; set;} } /// @@ -2248,6 +2262,7 @@ public ApiResponse GetUserProfilesWithHttpInfo(Guid? org if (options != null) { if (options.email != null) localVarQueryParams.Add("email", this.ApiClient.ParameterToString(options.email)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2331,6 +2346,7 @@ public async System.Threading.Tasks.Task> Ge if (options != null) { if (options.email != null) localVarQueryParams.Add("email", this.ApiClient.ParameterToString(options.email)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2385,6 +2401,8 @@ public class GetUsersOptions public string lastModifiedSince {get; set;} /// Select users with groups the users belong to; account_id must be specified. The organization must have the entitlement AllowMultiApplication enabled. public bool? includeDsGroups {get; set;} + /// When true: additional details about the user's license will be included in the response; account_id must be specified and the account must have an IAM plan with licenses. + public bool? includeLicense {get; set;} } /// @@ -2453,6 +2471,7 @@ public ApiResponse GetUsersWithHttpInfo(Guid? organiz if (options.organizationReservedDomainId != null) localVarQueryParams.Add("organization_reserved_domain_id", this.ApiClient.ParameterToString(options.organizationReservedDomainId)); // query parameter if (options.lastModifiedSince != null) localVarQueryParams.Add("last_modified_since", this.ApiClient.ParameterToString(options.lastModifiedSince)); // query parameter if (options.includeDsGroups != null) localVarQueryParams.Add("include_ds_groups", this.ApiClient.ParameterToString(options.includeDsGroups)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2546,6 +2565,7 @@ public async System.Threading.Tasks.Task> if (options.organizationReservedDomainId != null) localVarQueryParams.Add("organization_reserved_domain_id", this.ApiClient.ParameterToString(options.organizationReservedDomainId)); // query parameter if (options.lastModifiedSince != null) localVarQueryParams.Add("last_modified_since", this.ApiClient.ParameterToString(options.lastModifiedSince)); // query parameter if (options.includeDsGroups != null) localVarQueryParams.Add("include_ds_groups", this.ApiClient.ParameterToString(options.includeDsGroups)); // query parameter + if (options.includeLicense != null) localVarQueryParams.Add("include_license", this.ApiClient.ParameterToString(options.includeLicense)); // query parameter } // authentication (docusignAccessCode) required @@ -2754,6 +2774,14 @@ public async System.Threading.Tasks.Task> Updat (UsersUpdateResponse)this.ApiClient.Deserialize(localVarResponse, typeof(UsersUpdateResponse))); } + /// + /// Updates a user. Required scopes: user_write + /// + public class UpdateUserOptions + { + /// If an account has an IAM plan with licenses, this query specifies how a user's license is handled. Values: true - Updates the user's existing license; false - Adds a license to the user + public bool? applyLicenseOverride {get; set;} + } /// /// Updates a user. Required scopes: user_write @@ -2761,10 +2789,11 @@ public async System.Threading.Tasks.Task> Updat /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// UsersUpdateResponse - public UsersUpdateResponse UpdateUser(Guid? organizationId, UpdateUsersRequest request) + public UsersUpdateResponse UpdateUser(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null) { - ApiResponse localVarResponse = UpdateUserWithHttpInfo(organizationId, request); + ApiResponse localVarResponse = UpdateUserWithHttpInfo(organizationId, request, options); return localVarResponse.Data; } @@ -2774,8 +2803,9 @@ public UsersUpdateResponse UpdateUser(Guid? organizationId, UpdateUsersRequest r /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// ApiResponse of UsersUpdateResponse - public ApiResponse UpdateUserWithHttpInfo(Guid? organizationId, UpdateUsersRequest request) + public ApiResponse UpdateUserWithHttpInfo(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null) { // verify the required parameter 'organizationId' is set if (organizationId == null) @@ -2811,6 +2841,10 @@ public ApiResponse UpdateUserWithHttpInfo(Guid? organizatio // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json localVarPathParams.Add("format", "json"); if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (options != null) + { + if (options.applyLicenseOverride != null) localVarQueryParams.Add("apply_license_override", this.ApiClient.ParameterToString(options.applyLicenseOverride)); // query parameter + } if (request != null && request.GetType() != typeof(byte[])) { localVarPostBody = this.ApiClient.Serialize(request); // http body (model) parameter @@ -2851,10 +2885,11 @@ public ApiResponse UpdateUserWithHttpInfo(Guid? organizatio /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// Task of UsersUpdateResponse - public async System.Threading.Tasks.Task UpdateUserAsync(Guid? organizationId, UpdateUsersRequest request) + public async System.Threading.Tasks.Task UpdateUserAsync(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null) { - ApiResponse localVarResponse = await UpdateUserAsyncWithHttpInfo(organizationId, request); + ApiResponse localVarResponse = await UpdateUserAsyncWithHttpInfo(organizationId, request, options); return localVarResponse.Data; } @@ -2864,8 +2899,9 @@ public async System.Threading.Tasks.Task UpdateUserAsync(Gu /// Thrown when fails to make API call /// The organization ID Guid /// The user details to update + /// Options for modifying the behavior of the function. /// Task of ApiResponse (UsersUpdateResponse) - public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo(Guid? organizationId, UpdateUsersRequest request) + public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo(Guid? organizationId, UpdateUsersRequest request, UsersApi.UpdateUserOptions options = null) { // verify the required parameter 'organizationId' is set if (organizationId == null) @@ -2901,6 +2937,10 @@ public async System.Threading.Tasks.Task> Updat // e.g. /pet/{petId}.{format} becomes /pet/{petId}.json localVarPathParams.Add("format", "json"); if (organizationId != null) localVarPathParams.Add("organizationId", this.ApiClient.ParameterToString(organizationId)); // path parameter + if (options != null) + { + if (options.applyLicenseOverride != null) localVarQueryParams.Add("apply_license_override", this.ApiClient.ParameterToString(options.applyLicenseOverride)); // query parameter + } if (request != null && request.GetType() != typeof(byte[])) { localVarPostBody = this.ApiClient.Serialize(request); // http body (model) parameter diff --git a/sdk/src/DocuSign.Admin/Client/Configuration.cs b/sdk/src/DocuSign.Admin/Client/Configuration.cs index a223082..10fd3e7 100644 --- a/sdk/src/DocuSign.Admin/Client/Configuration.cs +++ b/sdk/src/DocuSign.Admin/Client/Configuration.cs @@ -26,7 +26,7 @@ public class Configuration /// Version of the package. /// /// Version of the package. - public const string Version = "2.0.2"; + public const string Version = "2.1.0"; /// /// Identifier for ISO 8601 DateTime Format diff --git a/sdk/src/DocuSign.Admin/DocuSign.Admin.csproj b/sdk/src/DocuSign.Admin/DocuSign.Admin.csproj index 6a25984..6bcfe57 100644 --- a/sdk/src/DocuSign.Admin/DocuSign.Admin.csproj +++ b/sdk/src/DocuSign.Admin/DocuSign.Admin.csproj @@ -7,7 +7,7 @@ The Docusign Admin API enables you to automate user management with your existing systems while ensuring governance and compliance. DocuSign Inc. DocuSign - Copyright © Docusign 2024 + Copyright © Docusign 2026 DocuSign.Admin DocuSign Library @@ -16,7 +16,7 @@ DocuSign.Admin DocuSign.Admin en-US - 2.0.2 + 2.1.0 true true @@ -26,7 +26,7 @@ https://github.com/docusign/docusign-admin-csharp-client/blob/master/LICENSE https://github.com/docusign/docusign-admin-csharp-client git - [v2.0.2] - Admin API v2.1-1.4.1 - 11/15/2024 + [v2.1.0] - Admin API v2.1-1.4.3 - 3/3/2026 NET462 diff --git a/sdk/src/DocuSign.Admin/Model/AddUserResponseAccountProperties.cs b/sdk/src/DocuSign.Admin/Model/AddUserResponseAccountProperties.cs index d4c7670..db5fb94 100644 --- a/sdk/src/DocuSign.Admin/Model/AddUserResponseAccountProperties.cs +++ b/sdk/src/DocuSign.Admin/Model/AddUserResponseAccountProperties.cs @@ -39,12 +39,20 @@ public AddUserResponseAccountProperties() /// SiteId. /// CompanyName. /// JobTitle. - public AddUserResponseAccountProperties(Guid? Id = default(Guid?), int? SiteId = default(int?), string CompanyName = default(string), string JobTitle = default(string)) + /// LicenseType. + /// SubscriptionId. + /// PlanName. + /// LicenseStatus. + public AddUserResponseAccountProperties(Guid? Id = default(Guid?), int? SiteId = default(int?), string CompanyName = default(string), string JobTitle = default(string), string LicenseType = default(string), string SubscriptionId = default(string), string PlanName = default(string), string LicenseStatus = default(string)) { this.Id = Id; this.SiteId = SiteId; this.CompanyName = CompanyName; this.JobTitle = JobTitle; + this.LicenseType = LicenseType; + this.SubscriptionId = SubscriptionId; + this.PlanName = PlanName; + this.LicenseStatus = LicenseStatus; } /// @@ -78,6 +86,26 @@ public AddUserResponseAccountProperties() [DataMember(Name="job_title", EmitDefaultValue=false)] public string JobTitle { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// + /// Gets or Sets SubscriptionId + /// + [DataMember(Name="subscription_id", EmitDefaultValue=false)] + public string SubscriptionId { get; set; } + /// + /// Gets or Sets PlanName + /// + [DataMember(Name="plan_name", EmitDefaultValue=false)] + public string PlanName { get; set; } + /// + /// Gets or Sets LicenseStatus + /// + [DataMember(Name="license_status", EmitDefaultValue=false)] + public string LicenseStatus { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -91,6 +119,10 @@ public override string ToString() sb.Append(" DsGroups: ").Append(DsGroups).Append("\n"); sb.Append(" CompanyName: ").Append(CompanyName).Append("\n"); sb.Append(" JobTitle: ").Append(JobTitle).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); + sb.Append(" SubscriptionId: ").Append(SubscriptionId).Append("\n"); + sb.Append(" PlanName: ").Append(PlanName).Append("\n"); + sb.Append(" LicenseStatus: ").Append(LicenseStatus).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -156,6 +188,26 @@ public bool Equals(AddUserResponseAccountProperties other) this.JobTitle == other.JobTitle || this.JobTitle != null && this.JobTitle.Equals(other.JobTitle) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) + ) && + ( + this.SubscriptionId == other.SubscriptionId || + this.SubscriptionId != null && + this.SubscriptionId.Equals(other.SubscriptionId) + ) && + ( + this.PlanName == other.PlanName || + this.PlanName != null && + this.PlanName.Equals(other.PlanName) + ) && + ( + this.LicenseStatus == other.LicenseStatus || + this.LicenseStatus != null && + this.LicenseStatus.Equals(other.LicenseStatus) ); } @@ -182,6 +234,14 @@ public override int GetHashCode() hash = hash * 59 + this.CompanyName.GetHashCode(); if (this.JobTitle != null) hash = hash * 59 + this.JobTitle.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); + if (this.SubscriptionId != null) + hash = hash * 59 + this.SubscriptionId.GetHashCode(); + if (this.PlanName != null) + hash = hash * 59 + this.PlanName.GetHashCode(); + if (this.LicenseStatus != null) + hash = hash * 59 + this.LicenseStatus.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/ConnectEventData.cs b/sdk/src/DocuSign.Admin/Model/ConnectEventData.cs new file mode 100644 index 0000000..efcc1b3 --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/ConnectEventData.cs @@ -0,0 +1,138 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// ConnectEventData + /// + [DataContract] + public partial class ConnectEventData : IEquatable, IValidatableObject + { + public ConnectEventData() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// Version. + /// IncludeData. + public ConnectEventData(string Version = default(string), List IncludeData = default(List)) + { + this.Version = Version; + this.IncludeData = IncludeData; + } + + /// + /// Gets or Sets Version + /// + [DataMember(Name="version", EmitDefaultValue=false)] + public string Version { get; set; } + /// + /// Gets or Sets IncludeData + /// + [DataMember(Name="includeData", EmitDefaultValue=false)] + public List IncludeData { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class ConnectEventData {\n"); + sb.Append(" Version: ").Append(Version).Append("\n"); + sb.Append(" IncludeData: ").Append(IncludeData).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as ConnectEventData); + } + + /// + /// Returns true if ConnectEventData instances are equal + /// + /// Instance of ConnectEventData to be compared + /// Boolean + public bool Equals(ConnectEventData other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.Version == other.Version || + this.Version != null && + this.Version.Equals(other.Version) + ) && + ( + this.IncludeData == other.IncludeData || + this.IncludeData != null && + this.IncludeData.SequenceEqual(other.IncludeData) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.Version != null) + hash = hash * 59 + this.Version.GetHashCode(); + if (this.IncludeData != null) + hash = hash * 59 + this.IncludeData.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/DSGroupResponse.cs b/sdk/src/DocuSign.Admin/Model/DSGroupResponse.cs index 9c517d3..3826f1b 100644 --- a/sdk/src/DocuSign.Admin/Model/DSGroupResponse.cs +++ b/sdk/src/DocuSign.Admin/Model/DSGroupResponse.cs @@ -46,7 +46,8 @@ public DSGroupResponse() /// UserCount. /// ExternalAccountId. /// AccountName. - public DSGroupResponse(Guid? DsGroupId = default(Guid?), Guid? AccountId = default(Guid?), string SourceProductName = default(string), string GroupId = default(string), string GroupName = default(string), string Description = default(string), bool? IsAdmin = default(bool?), DateTime? LastModifiedOn = default(DateTime?), int? UserCount = default(int?), long? ExternalAccountId = default(long?), string AccountName = default(string)) + /// IsManagedByScim. + public DSGroupResponse(Guid? DsGroupId = default(Guid?), Guid? AccountId = default(Guid?), string SourceProductName = default(string), string GroupId = default(string), string GroupName = default(string), string Description = default(string), bool? IsAdmin = default(bool?), DateTime? LastModifiedOn = default(DateTime?), int? UserCount = default(int?), long? ExternalAccountId = default(long?), string AccountName = default(string), bool? IsManagedByScim = default(bool?)) { this.DsGroupId = DsGroupId; this.AccountId = AccountId; @@ -59,6 +60,7 @@ public DSGroupResponse() this.UserCount = UserCount; this.ExternalAccountId = ExternalAccountId; this.AccountName = AccountName; + this.IsManagedByScim = IsManagedByScim; } /// @@ -117,6 +119,11 @@ public DSGroupResponse() [DataMember(Name="account_name", EmitDefaultValue=false)] public string AccountName { get; set; } /// + /// Gets or Sets IsManagedByScim + /// + [DataMember(Name="is_managed_by_scim", EmitDefaultValue=false)] + public bool? IsManagedByScim { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -135,6 +142,7 @@ public override string ToString() sb.Append(" UserCount: ").Append(UserCount).Append("\n"); sb.Append(" ExternalAccountId: ").Append(ExternalAccountId).Append("\n"); sb.Append(" AccountName: ").Append(AccountName).Append("\n"); + sb.Append(" IsManagedByScim: ").Append(IsManagedByScim).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -225,6 +233,11 @@ public bool Equals(DSGroupResponse other) this.AccountName == other.AccountName || this.AccountName != null && this.AccountName.Equals(other.AccountName) + ) && + ( + this.IsManagedByScim == other.IsManagedByScim || + this.IsManagedByScim != null && + this.IsManagedByScim.Equals(other.IsManagedByScim) ); } @@ -261,6 +274,8 @@ public override int GetHashCode() hash = hash * 59 + this.ExternalAccountId.GetHashCode(); if (this.AccountName != null) hash = hash * 59 + this.AccountName.GetHashCode(); + if (this.IsManagedByScim != null) + hash = hash * 59 + this.IsManagedByScim.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/ErrorDetail.cs b/sdk/src/DocuSign.Admin/Model/ErrorDetail.cs new file mode 100644 index 0000000..9de1b7e --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/ErrorDetail.cs @@ -0,0 +1,138 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// ErrorDetail + /// + [DataContract] + public partial class ErrorDetail : IEquatable, IValidatableObject + { + public ErrorDetail() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// ErrorMessage. + /// ReferenceId. + public ErrorDetail(string ErrorMessage = default(string), string ReferenceId = default(string)) + { + this.ErrorMessage = ErrorMessage; + this.ReferenceId = ReferenceId; + } + + /// + /// Gets or Sets ErrorMessage + /// + [DataMember(Name="errorMessage", EmitDefaultValue=false)] + public string ErrorMessage { get; set; } + /// + /// Gets or Sets ReferenceId + /// + [DataMember(Name="referenceId", EmitDefaultValue=false)] + public string ReferenceId { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class ErrorDetail {\n"); + sb.Append(" ErrorMessage: ").Append(ErrorMessage).Append("\n"); + sb.Append(" ReferenceId: ").Append(ReferenceId).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as ErrorDetail); + } + + /// + /// Returns true if ErrorDetail instances are equal + /// + /// Instance of ErrorDetail to be compared + /// Boolean + public bool Equals(ErrorDetail other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.ErrorMessage == other.ErrorMessage || + this.ErrorMessage != null && + this.ErrorMessage.Equals(other.ErrorMessage) + ) && + ( + this.ReferenceId == other.ReferenceId || + this.ReferenceId != null && + this.ReferenceId.Equals(other.ReferenceId) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.ErrorMessage != null) + hash = hash * 59 + this.ErrorMessage.GetHashCode(); + if (this.ReferenceId != null) + hash = hash * 59 + this.ReferenceId.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/MembershipResponse.cs b/sdk/src/DocuSign.Admin/Model/MembershipResponse.cs index 572f95b..d082520 100644 --- a/sdk/src/DocuSign.Admin/Model/MembershipResponse.cs +++ b/sdk/src/DocuSign.Admin/Model/MembershipResponse.cs @@ -35,6 +35,7 @@ public MembershipResponse() /// /// Initializes a new instance of the class. /// + /// Id. /// Email. /// AccountId. /// ExternalAccountId. @@ -45,8 +46,12 @@ public MembershipResponse() /// CreatedOn. /// Groups. /// IsAdmin. - public MembershipResponse(string Email = default(string), Guid? AccountId = default(Guid?), string ExternalAccountId = default(string), string AccountName = default(string), bool? IsExternalAccount = default(bool?), string Status = default(string), PermissionProfileResponse PermissionProfile = default(PermissionProfileResponse), DateTime? CreatedOn = default(DateTime?), List Groups = default(List), bool? IsAdmin = default(bool?)) + /// LicenseType. + /// SubscriptionId. + /// PlanName. + public MembershipResponse(Guid? Id = default(Guid?), string Email = default(string), Guid? AccountId = default(Guid?), string ExternalAccountId = default(string), string AccountName = default(string), bool? IsExternalAccount = default(bool?), string Status = default(string), PermissionProfileResponse PermissionProfile = default(PermissionProfileResponse), DateTime? CreatedOn = default(DateTime?), List Groups = default(List), bool? IsAdmin = default(bool?), string LicenseType = default(string), string SubscriptionId = default(string), string PlanName = default(string)) { + this.Id = Id; this.Email = Email; this.AccountId = AccountId; this.ExternalAccountId = ExternalAccountId; @@ -57,8 +62,16 @@ public MembershipResponse() this.CreatedOn = CreatedOn; this.Groups = Groups; this.IsAdmin = IsAdmin; + this.LicenseType = LicenseType; + this.SubscriptionId = SubscriptionId; + this.PlanName = PlanName; } + /// + /// Gets or Sets Id + /// + [DataMember(Name="id", EmitDefaultValue=false)] + public Guid? Id { get; set; } /// /// Gets or Sets Email /// @@ -110,6 +123,21 @@ public MembershipResponse() [DataMember(Name="is_admin", EmitDefaultValue=false)] public bool? IsAdmin { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// + /// Gets or Sets SubscriptionId + /// + [DataMember(Name="subscription_id", EmitDefaultValue=false)] + public string SubscriptionId { get; set; } + /// + /// Gets or Sets PlanName + /// + [DataMember(Name="plan_name", EmitDefaultValue=false)] + public string PlanName { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -117,6 +145,7 @@ public override string ToString() { var sb = new StringBuilder(); sb.Append("class MembershipResponse {\n"); + sb.Append(" Id: ").Append(Id).Append("\n"); sb.Append(" Email: ").Append(Email).Append("\n"); sb.Append(" AccountId: ").Append(AccountId).Append("\n"); sb.Append(" ExternalAccountId: ").Append(ExternalAccountId).Append("\n"); @@ -127,6 +156,9 @@ public override string ToString() sb.Append(" CreatedOn: ").Append(CreatedOn).Append("\n"); sb.Append(" Groups: ").Append(Groups).Append("\n"); sb.Append(" IsAdmin: ").Append(IsAdmin).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); + sb.Append(" SubscriptionId: ").Append(SubscriptionId).Append("\n"); + sb.Append(" PlanName: ").Append(PlanName).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -163,6 +195,11 @@ public bool Equals(MembershipResponse other) return false; return + ( + this.Id == other.Id || + this.Id != null && + this.Id.Equals(other.Id) + ) && ( this.Email == other.Email || this.Email != null && @@ -212,6 +249,21 @@ public bool Equals(MembershipResponse other) this.IsAdmin == other.IsAdmin || this.IsAdmin != null && this.IsAdmin.Equals(other.IsAdmin) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) + ) && + ( + this.SubscriptionId == other.SubscriptionId || + this.SubscriptionId != null && + this.SubscriptionId.Equals(other.SubscriptionId) + ) && + ( + this.PlanName == other.PlanName || + this.PlanName != null && + this.PlanName.Equals(other.PlanName) ); } @@ -226,6 +278,8 @@ public override int GetHashCode() { int hash = 41; // Suitable nullity checks etc, of course :) + if (this.Id != null) + hash = hash * 59 + this.Id.GetHashCode(); if (this.Email != null) hash = hash * 59 + this.Email.GetHashCode(); if (this.AccountId != null) @@ -246,6 +300,12 @@ public override int GetHashCode() hash = hash * 59 + this.Groups.GetHashCode(); if (this.IsAdmin != null) hash = hash * 59 + this.IsAdmin.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); + if (this.SubscriptionId != null) + hash = hash * 59 + this.SubscriptionId.GetHashCode(); + if (this.PlanName != null) + hash = hash * 59 + this.PlanName.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/NewAccountUserRequest.cs b/sdk/src/DocuSign.Admin/Model/NewAccountUserRequest.cs index 7c097e4..15149a3 100644 --- a/sdk/src/DocuSign.Admin/Model/NewAccountUserRequest.cs +++ b/sdk/src/DocuSign.Admin/Model/NewAccountUserRequest.cs @@ -47,7 +47,8 @@ public NewAccountUserRequest() /// AccessCode. /// FederatedStatus. /// AutoActivateMemberships. - public NewAccountUserRequest(PermissionProfileRequest PermissionProfile = default(PermissionProfileRequest), List Groups = default(List), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string Email = default(string), Guid? DefaultAccountId = default(Guid?), string LanguageCulture = default(string), string SelectedLanguages = default(string), string AccessCode = default(string), string FederatedStatus = default(string), bool? AutoActivateMemberships = default(bool?)) + /// LicenseType. + public NewAccountUserRequest(PermissionProfileRequest PermissionProfile = default(PermissionProfileRequest), List Groups = default(List), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string Email = default(string), Guid? DefaultAccountId = default(Guid?), string LanguageCulture = default(string), string SelectedLanguages = default(string), string AccessCode = default(string), string FederatedStatus = default(string), bool? AutoActivateMemberships = default(bool?), string LicenseType = default(string)) { // to ensure "Email" is required (not null) if (Email == null) @@ -69,6 +70,7 @@ public NewAccountUserRequest() this.AccessCode = AccessCode; this.FederatedStatus = FederatedStatus; this.AutoActivateMemberships = AutoActivateMemberships; + this.LicenseType = LicenseType; } /// @@ -132,6 +134,11 @@ public NewAccountUserRequest() [DataMember(Name="auto_activate_memberships", EmitDefaultValue=false)] public bool? AutoActivateMemberships { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -151,6 +158,7 @@ public override string ToString() sb.Append(" AccessCode: ").Append(AccessCode).Append("\n"); sb.Append(" FederatedStatus: ").Append(FederatedStatus).Append("\n"); sb.Append(" AutoActivateMemberships: ").Append(AutoActivateMemberships).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -246,6 +254,11 @@ public bool Equals(NewAccountUserRequest other) this.AutoActivateMemberships == other.AutoActivateMemberships || this.AutoActivateMemberships != null && this.AutoActivateMemberships.Equals(other.AutoActivateMemberships) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) ); } @@ -284,6 +297,8 @@ public override int GetHashCode() hash = hash * 59 + this.FederatedStatus.GetHashCode(); if (this.AutoActivateMemberships != null) hash = hash * 59 + this.AutoActivateMemberships.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/NewMultiProductUserAddRequest.cs b/sdk/src/DocuSign.Admin/Model/NewMultiProductUserAddRequest.cs index 28066c4..df13778 100644 --- a/sdk/src/DocuSign.Admin/Model/NewMultiProductUserAddRequest.cs +++ b/sdk/src/DocuSign.Admin/Model/NewMultiProductUserAddRequest.cs @@ -46,7 +46,8 @@ public NewMultiProductUserAddRequest() /// AccessCode. /// FederatedStatus. /// AutoActivateMemberships. - public NewMultiProductUserAddRequest(List ProductPermissionProfiles = default(List), List DsGroups = default(List), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string Email = default(string), Guid? DefaultAccountId = default(Guid?), string LanguageCulture = default(string), string AccessCode = default(string), string FederatedStatus = default(string), bool? AutoActivateMemberships = default(bool?)) + /// LicenseType. + public NewMultiProductUserAddRequest(List ProductPermissionProfiles = default(List), List DsGroups = default(List), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string Email = default(string), Guid? DefaultAccountId = default(Guid?), string LanguageCulture = default(string), string AccessCode = default(string), string FederatedStatus = default(string), bool? AutoActivateMemberships = default(bool?), string LicenseType = default(string)) { // to ensure "ProductPermissionProfiles" is required (not null) if (ProductPermissionProfiles == null) @@ -75,6 +76,7 @@ public NewMultiProductUserAddRequest() this.AccessCode = AccessCode; this.FederatedStatus = FederatedStatus; this.AutoActivateMemberships = AutoActivateMemberships; + this.LicenseType = LicenseType; } /// @@ -133,6 +135,11 @@ public NewMultiProductUserAddRequest() [DataMember(Name="auto_activate_memberships", EmitDefaultValue=false)] public bool? AutoActivateMemberships { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -151,6 +158,7 @@ public override string ToString() sb.Append(" AccessCode: ").Append(AccessCode).Append("\n"); sb.Append(" FederatedStatus: ").Append(FederatedStatus).Append("\n"); sb.Append(" AutoActivateMemberships: ").Append(AutoActivateMemberships).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -241,6 +249,11 @@ public bool Equals(NewMultiProductUserAddRequest other) this.AutoActivateMemberships == other.AutoActivateMemberships || this.AutoActivateMemberships != null && this.AutoActivateMemberships.Equals(other.AutoActivateMemberships) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) ); } @@ -277,6 +290,8 @@ public override int GetHashCode() hash = hash * 59 + this.FederatedStatus.GetHashCode(); if (this.AutoActivateMemberships != null) hash = hash * 59 + this.AutoActivateMemberships.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/NewUserResponseAccountProperties.cs b/sdk/src/DocuSign.Admin/Model/NewUserResponseAccountProperties.cs index 636c15f..e696e69 100644 --- a/sdk/src/DocuSign.Admin/Model/NewUserResponseAccountProperties.cs +++ b/sdk/src/DocuSign.Admin/Model/NewUserResponseAccountProperties.cs @@ -41,7 +41,11 @@ public NewUserResponseAccountProperties() /// Groups. /// CompanyName. /// JobTitle. - public NewUserResponseAccountProperties(Guid? Id = default(Guid?), int? SiteId = default(int?), PermissionProfileResponse PermissionProfile = default(PermissionProfileResponse), List Groups = default(List), string CompanyName = default(string), string JobTitle = default(string)) + /// LicenseType. + /// SubscriptionId. + /// PlanName. + /// LicenseStatus. + public NewUserResponseAccountProperties(Guid? Id = default(Guid?), int? SiteId = default(int?), PermissionProfileResponse PermissionProfile = default(PermissionProfileResponse), List Groups = default(List), string CompanyName = default(string), string JobTitle = default(string), string LicenseType = default(string), string SubscriptionId = default(string), string PlanName = default(string), string LicenseStatus = default(string)) { this.Id = Id; this.SiteId = SiteId; @@ -49,6 +53,10 @@ public NewUserResponseAccountProperties() this.Groups = Groups; this.CompanyName = CompanyName; this.JobTitle = JobTitle; + this.LicenseType = LicenseType; + this.SubscriptionId = SubscriptionId; + this.PlanName = PlanName; + this.LicenseStatus = LicenseStatus; } /// @@ -82,6 +90,26 @@ public NewUserResponseAccountProperties() [DataMember(Name="job_title", EmitDefaultValue=false)] public string JobTitle { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// + /// Gets or Sets SubscriptionId + /// + [DataMember(Name="subscription_id", EmitDefaultValue=false)] + public string SubscriptionId { get; set; } + /// + /// Gets or Sets PlanName + /// + [DataMember(Name="plan_name", EmitDefaultValue=false)] + public string PlanName { get; set; } + /// + /// Gets or Sets LicenseStatus + /// + [DataMember(Name="license_status", EmitDefaultValue=false)] + public string LicenseStatus { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -95,6 +123,10 @@ public override string ToString() sb.Append(" Groups: ").Append(Groups).Append("\n"); sb.Append(" CompanyName: ").Append(CompanyName).Append("\n"); sb.Append(" JobTitle: ").Append(JobTitle).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); + sb.Append(" SubscriptionId: ").Append(SubscriptionId).Append("\n"); + sb.Append(" PlanName: ").Append(PlanName).Append("\n"); + sb.Append(" LicenseStatus: ").Append(LicenseStatus).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -160,6 +192,26 @@ public bool Equals(NewUserResponseAccountProperties other) this.JobTitle == other.JobTitle || this.JobTitle != null && this.JobTitle.Equals(other.JobTitle) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) + ) && + ( + this.SubscriptionId == other.SubscriptionId || + this.SubscriptionId != null && + this.SubscriptionId.Equals(other.SubscriptionId) + ) && + ( + this.PlanName == other.PlanName || + this.PlanName != null && + this.PlanName.Equals(other.PlanName) + ) && + ( + this.LicenseStatus == other.LicenseStatus || + this.LicenseStatus != null && + this.LicenseStatus.Equals(other.LicenseStatus) ); } @@ -186,6 +238,14 @@ public override int GetHashCode() hash = hash * 59 + this.CompanyName.GetHashCode(); if (this.JobTitle != null) hash = hash * 59 + this.JobTitle.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); + if (this.SubscriptionId != null) + hash = hash * 59 + this.SubscriptionId.GetHashCode(); + if (this.PlanName != null) + hash = hash * 59 + this.PlanName.GetHashCode(); + if (this.LicenseStatus != null) + hash = hash * 59 + this.LicenseStatus.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigResponse.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigResponse.cs new file mode 100644 index 0000000..cbd8d6c --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigResponse.cs @@ -0,0 +1,273 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectConfigResponse + /// + [DataContract] + public partial class OrganizationConnectConfigResponse : IEquatable, IValidatableObject + { + public OrganizationConnectConfigResponse() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// ConnectId. + /// ConfigurationType. + /// DisabledBy. + /// AllowSalesforcePublish. + /// Name. + /// AccountId. + /// AccountName. + /// AllowEnvelopePublish. + /// SiteId. + /// PausePublish. + /// RequiresAcknowledgement. + public OrganizationConnectConfigResponse(string ConnectId = default(string), string ConfigurationType = default(string), string DisabledBy = default(string), string AllowSalesforcePublish = default(string), string Name = default(string), string AccountId = default(string), string AccountName = default(string), string AllowEnvelopePublish = default(string), int? SiteId = default(int?), string PausePublish = default(string), string RequiresAcknowledgement = default(string)) + { + this.ConnectId = ConnectId; + this.ConfigurationType = ConfigurationType; + this.DisabledBy = DisabledBy; + this.AllowSalesforcePublish = AllowSalesforcePublish; + this.Name = Name; + this.AccountId = AccountId; + this.AccountName = AccountName; + this.AllowEnvelopePublish = AllowEnvelopePublish; + this.SiteId = SiteId; + this.PausePublish = PausePublish; + this.RequiresAcknowledgement = RequiresAcknowledgement; + } + + /// + /// Gets or Sets ConnectId + /// + [DataMember(Name="connectId", EmitDefaultValue=false)] + public string ConnectId { get; set; } + /// + /// Gets or Sets ConfigurationType + /// + [DataMember(Name="configurationType", EmitDefaultValue=false)] + public string ConfigurationType { get; set; } + /// + /// Gets or Sets DisabledBy + /// + [DataMember(Name="disabledBy", EmitDefaultValue=false)] + public string DisabledBy { get; set; } + /// + /// Gets or Sets AllowSalesforcePublish + /// + [DataMember(Name="allowSalesforcePublish", EmitDefaultValue=false)] + public string AllowSalesforcePublish { get; set; } + /// + /// Gets or Sets Name + /// + [DataMember(Name="name", EmitDefaultValue=false)] + public string Name { get; set; } + /// + /// Gets or Sets AccountId + /// + [DataMember(Name="accountId", EmitDefaultValue=false)] + public string AccountId { get; set; } + /// + /// Gets or Sets AccountName + /// + [DataMember(Name="accountName", EmitDefaultValue=false)] + public string AccountName { get; set; } + /// + /// Gets or Sets AllowEnvelopePublish + /// + [DataMember(Name="allowEnvelopePublish", EmitDefaultValue=false)] + public string AllowEnvelopePublish { get; set; } + /// + /// Gets or Sets SiteId + /// + [DataMember(Name="siteId", EmitDefaultValue=false)] + public int? SiteId { get; set; } + /// + /// Gets or Sets PausePublish + /// + [DataMember(Name="pausePublish", EmitDefaultValue=false)] + public string PausePublish { get; set; } + /// + /// Gets or Sets RequiresAcknowledgement + /// + [DataMember(Name="requiresAcknowledgement", EmitDefaultValue=false)] + public string RequiresAcknowledgement { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectConfigResponse {\n"); + sb.Append(" ConnectId: ").Append(ConnectId).Append("\n"); + sb.Append(" ConfigurationType: ").Append(ConfigurationType).Append("\n"); + sb.Append(" DisabledBy: ").Append(DisabledBy).Append("\n"); + sb.Append(" AllowSalesforcePublish: ").Append(AllowSalesforcePublish).Append("\n"); + sb.Append(" Name: ").Append(Name).Append("\n"); + sb.Append(" AccountId: ").Append(AccountId).Append("\n"); + sb.Append(" AccountName: ").Append(AccountName).Append("\n"); + sb.Append(" AllowEnvelopePublish: ").Append(AllowEnvelopePublish).Append("\n"); + sb.Append(" SiteId: ").Append(SiteId).Append("\n"); + sb.Append(" PausePublish: ").Append(PausePublish).Append("\n"); + sb.Append(" RequiresAcknowledgement: ").Append(RequiresAcknowledgement).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectConfigResponse); + } + + /// + /// Returns true if OrganizationConnectConfigResponse instances are equal + /// + /// Instance of OrganizationConnectConfigResponse to be compared + /// Boolean + public bool Equals(OrganizationConnectConfigResponse other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.ConnectId == other.ConnectId || + this.ConnectId != null && + this.ConnectId.Equals(other.ConnectId) + ) && + ( + this.ConfigurationType == other.ConfigurationType || + this.ConfigurationType != null && + this.ConfigurationType.Equals(other.ConfigurationType) + ) && + ( + this.DisabledBy == other.DisabledBy || + this.DisabledBy != null && + this.DisabledBy.Equals(other.DisabledBy) + ) && + ( + this.AllowSalesforcePublish == other.AllowSalesforcePublish || + this.AllowSalesforcePublish != null && + this.AllowSalesforcePublish.Equals(other.AllowSalesforcePublish) + ) && + ( + this.Name == other.Name || + this.Name != null && + this.Name.Equals(other.Name) + ) && + ( + this.AccountId == other.AccountId || + this.AccountId != null && + this.AccountId.Equals(other.AccountId) + ) && + ( + this.AccountName == other.AccountName || + this.AccountName != null && + this.AccountName.Equals(other.AccountName) + ) && + ( + this.AllowEnvelopePublish == other.AllowEnvelopePublish || + this.AllowEnvelopePublish != null && + this.AllowEnvelopePublish.Equals(other.AllowEnvelopePublish) + ) && + ( + this.SiteId == other.SiteId || + this.SiteId != null && + this.SiteId.Equals(other.SiteId) + ) && + ( + this.PausePublish == other.PausePublish || + this.PausePublish != null && + this.PausePublish.Equals(other.PausePublish) + ) && + ( + this.RequiresAcknowledgement == other.RequiresAcknowledgement || + this.RequiresAcknowledgement != null && + this.RequiresAcknowledgement.Equals(other.RequiresAcknowledgement) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.ConnectId != null) + hash = hash * 59 + this.ConnectId.GetHashCode(); + if (this.ConfigurationType != null) + hash = hash * 59 + this.ConfigurationType.GetHashCode(); + if (this.DisabledBy != null) + hash = hash * 59 + this.DisabledBy.GetHashCode(); + if (this.AllowSalesforcePublish != null) + hash = hash * 59 + this.AllowSalesforcePublish.GetHashCode(); + if (this.Name != null) + hash = hash * 59 + this.Name.GetHashCode(); + if (this.AccountId != null) + hash = hash * 59 + this.AccountId.GetHashCode(); + if (this.AccountName != null) + hash = hash * 59 + this.AccountName.GetHashCode(); + if (this.AllowEnvelopePublish != null) + hash = hash * 59 + this.AllowEnvelopePublish.GetHashCode(); + if (this.SiteId != null) + hash = hash * 59 + this.SiteId.GetHashCode(); + if (this.PausePublish != null) + hash = hash * 59 + this.PausePublish.GetHashCode(); + if (this.RequiresAcknowledgement != null) + hash = hash * 59 + this.RequiresAcknowledgement.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigsResponse.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigsResponse.cs new file mode 100644 index 0000000..1a25830 --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigsResponse.cs @@ -0,0 +1,153 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectConfigsResponse + /// + [DataContract] + public partial class OrganizationConnectConfigsResponse : IEquatable, IValidatableObject + { + public OrganizationConnectConfigsResponse() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// Configurations. + /// TotalSetSize. + /// ErrorDetail. + public OrganizationConnectConfigsResponse(List Configurations = default(List), int? TotalSetSize = default(int?), ErrorDetail ErrorDetail = default(ErrorDetail)) + { + this.Configurations = Configurations; + this.TotalSetSize = TotalSetSize; + this.ErrorDetail = ErrorDetail; + } + + /// + /// Gets or Sets Configurations + /// + [DataMember(Name="configurations", EmitDefaultValue=false)] + public List Configurations { get; set; } + /// + /// Gets or Sets TotalSetSize + /// + [DataMember(Name="totalSetSize", EmitDefaultValue=false)] + public int? TotalSetSize { get; set; } + /// + /// Gets or Sets ErrorDetail + /// + [DataMember(Name="errorDetail", EmitDefaultValue=false)] + public ErrorDetail ErrorDetail { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectConfigsResponse {\n"); + sb.Append(" Configurations: ").Append(Configurations).Append("\n"); + sb.Append(" TotalSetSize: ").Append(TotalSetSize).Append("\n"); + sb.Append(" ErrorDetail: ").Append(ErrorDetail).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectConfigsResponse); + } + + /// + /// Returns true if OrganizationConnectConfigsResponse instances are equal + /// + /// Instance of OrganizationConnectConfigsResponse to be compared + /// Boolean + public bool Equals(OrganizationConnectConfigsResponse other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.Configurations == other.Configurations || + this.Configurations != null && + this.Configurations.SequenceEqual(other.Configurations) + ) && + ( + this.TotalSetSize == other.TotalSetSize || + this.TotalSetSize != null && + this.TotalSetSize.Equals(other.TotalSetSize) + ) && + ( + this.ErrorDetail == other.ErrorDetail || + this.ErrorDetail != null && + this.ErrorDetail.Equals(other.ErrorDetail) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.Configurations != null) + hash = hash * 59 + this.Configurations.GetHashCode(); + if (this.TotalSetSize != null) + hash = hash * 59 + this.TotalSetSize.GetHashCode(); + if (this.ErrorDetail != null) + hash = hash * 59 + this.ErrorDetail.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationDetailsResponse.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationDetailsResponse.cs new file mode 100644 index 0000000..5954d1f --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationDetailsResponse.cs @@ -0,0 +1,348 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectConfigurationDetailsResponse + /// + [DataContract] + public partial class OrganizationConnectConfigurationDetailsResponse : IEquatable, IValidatableObject + { + public OrganizationConnectConfigurationDetailsResponse() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// ConnectId. + /// ConfigurationType. + /// AllowEnvelopePublish. + /// UrlToPublishTo. + /// DeliveryMode. + /// Events. + /// AssociatedFilterSelection. + /// AccountIds. + /// UserIds. + /// GroupIds. + /// Name. + /// SignMessageWithX509Certificate. + /// IncludeOAuth. + /// IncludeHMAC. + /// PausePublish. + /// EventData. + public OrganizationConnectConfigurationDetailsResponse(Guid? ConnectId = default(Guid?), string ConfigurationType = default(string), string AllowEnvelopePublish = default(string), string UrlToPublishTo = default(string), string DeliveryMode = default(string), List Events = default(List), string AssociatedFilterSelection = default(string), List AccountIds = default(List), List UserIds = default(List), List GroupIds = default(List), string Name = default(string), string SignMessageWithX509Certificate = default(string), string IncludeOAuth = default(string), string IncludeHMAC = default(string), string PausePublish = default(string), ConnectEventData EventData = default(ConnectEventData)) + { + this.ConnectId = ConnectId; + this.ConfigurationType = ConfigurationType; + this.AllowEnvelopePublish = AllowEnvelopePublish; + this.UrlToPublishTo = UrlToPublishTo; + this.DeliveryMode = DeliveryMode; + this.Events = Events; + this.AssociatedFilterSelection = AssociatedFilterSelection; + this.AccountIds = AccountIds; + this.UserIds = UserIds; + this.GroupIds = GroupIds; + this.Name = Name; + this.SignMessageWithX509Certificate = SignMessageWithX509Certificate; + this.IncludeOAuth = IncludeOAuth; + this.IncludeHMAC = IncludeHMAC; + this.PausePublish = PausePublish; + this.EventData = EventData; + } + + /// + /// Gets or Sets ConnectId + /// + [DataMember(Name="connectId", EmitDefaultValue=false)] + public Guid? ConnectId { get; set; } + /// + /// Gets or Sets ConfigurationType + /// + [DataMember(Name="configurationType", EmitDefaultValue=false)] + public string ConfigurationType { get; set; } + /// + /// Gets or Sets AllowEnvelopePublish + /// + [DataMember(Name="allowEnvelopePublish", EmitDefaultValue=false)] + public string AllowEnvelopePublish { get; set; } + /// + /// Gets or Sets UrlToPublishTo + /// + [DataMember(Name="urlToPublishTo", EmitDefaultValue=false)] + public string UrlToPublishTo { get; set; } + /// + /// Gets or Sets DeliveryMode + /// + [DataMember(Name="deliveryMode", EmitDefaultValue=false)] + public string DeliveryMode { get; set; } + /// + /// Gets or Sets Events + /// + [DataMember(Name="events", EmitDefaultValue=false)] + public List Events { get; set; } + /// + /// Gets or Sets AssociatedFilterSelection + /// + [DataMember(Name="associatedFilterSelection", EmitDefaultValue=false)] + public string AssociatedFilterSelection { get; set; } + /// + /// Gets or Sets AccountIds + /// + [DataMember(Name="accountIds", EmitDefaultValue=false)] + public List AccountIds { get; set; } + /// + /// Gets or Sets UserIds + /// + [DataMember(Name="userIds", EmitDefaultValue=false)] + public List UserIds { get; set; } + /// + /// Gets or Sets GroupIds + /// + [DataMember(Name="groupIds", EmitDefaultValue=false)] + public List GroupIds { get; set; } + /// + /// Gets or Sets Name + /// + [DataMember(Name="name", EmitDefaultValue=false)] + public string Name { get; set; } + /// + /// Gets or Sets SignMessageWithX509Certificate + /// + [DataMember(Name="signMessageWithX509Certificate", EmitDefaultValue=false)] + public string SignMessageWithX509Certificate { get; set; } + /// + /// Gets or Sets IncludeOAuth + /// + [DataMember(Name="includeOAuth", EmitDefaultValue=false)] + public string IncludeOAuth { get; set; } + /// + /// Gets or Sets IncludeHMAC + /// + [DataMember(Name="includeHMAC", EmitDefaultValue=false)] + public string IncludeHMAC { get; set; } + /// + /// Gets or Sets PausePublish + /// + [DataMember(Name="pausePublish", EmitDefaultValue=false)] + public string PausePublish { get; set; } + /// + /// Gets or Sets EventData + /// + [DataMember(Name="eventData", EmitDefaultValue=false)] + public ConnectEventData EventData { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectConfigurationDetailsResponse {\n"); + sb.Append(" ConnectId: ").Append(ConnectId).Append("\n"); + sb.Append(" ConfigurationType: ").Append(ConfigurationType).Append("\n"); + sb.Append(" AllowEnvelopePublish: ").Append(AllowEnvelopePublish).Append("\n"); + sb.Append(" UrlToPublishTo: ").Append(UrlToPublishTo).Append("\n"); + sb.Append(" DeliveryMode: ").Append(DeliveryMode).Append("\n"); + sb.Append(" Events: ").Append(Events).Append("\n"); + sb.Append(" AssociatedFilterSelection: ").Append(AssociatedFilterSelection).Append("\n"); + sb.Append(" AccountIds: ").Append(AccountIds).Append("\n"); + sb.Append(" UserIds: ").Append(UserIds).Append("\n"); + sb.Append(" GroupIds: ").Append(GroupIds).Append("\n"); + sb.Append(" Name: ").Append(Name).Append("\n"); + sb.Append(" SignMessageWithX509Certificate: ").Append(SignMessageWithX509Certificate).Append("\n"); + sb.Append(" IncludeOAuth: ").Append(IncludeOAuth).Append("\n"); + sb.Append(" IncludeHMAC: ").Append(IncludeHMAC).Append("\n"); + sb.Append(" PausePublish: ").Append(PausePublish).Append("\n"); + sb.Append(" EventData: ").Append(EventData).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectConfigurationDetailsResponse); + } + + /// + /// Returns true if OrganizationConnectConfigurationDetailsResponse instances are equal + /// + /// Instance of OrganizationConnectConfigurationDetailsResponse to be compared + /// Boolean + public bool Equals(OrganizationConnectConfigurationDetailsResponse other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.ConnectId == other.ConnectId || + this.ConnectId != null && + this.ConnectId.Equals(other.ConnectId) + ) && + ( + this.ConfigurationType == other.ConfigurationType || + this.ConfigurationType != null && + this.ConfigurationType.Equals(other.ConfigurationType) + ) && + ( + this.AllowEnvelopePublish == other.AllowEnvelopePublish || + this.AllowEnvelopePublish != null && + this.AllowEnvelopePublish.Equals(other.AllowEnvelopePublish) + ) && + ( + this.UrlToPublishTo == other.UrlToPublishTo || + this.UrlToPublishTo != null && + this.UrlToPublishTo.Equals(other.UrlToPublishTo) + ) && + ( + this.DeliveryMode == other.DeliveryMode || + this.DeliveryMode != null && + this.DeliveryMode.Equals(other.DeliveryMode) + ) && + ( + this.Events == other.Events || + this.Events != null && + this.Events.SequenceEqual(other.Events) + ) && + ( + this.AssociatedFilterSelection == other.AssociatedFilterSelection || + this.AssociatedFilterSelection != null && + this.AssociatedFilterSelection.Equals(other.AssociatedFilterSelection) + ) && + ( + this.AccountIds == other.AccountIds || + this.AccountIds != null && + this.AccountIds.SequenceEqual(other.AccountIds) + ) && + ( + this.UserIds == other.UserIds || + this.UserIds != null && + this.UserIds.SequenceEqual(other.UserIds) + ) && + ( + this.GroupIds == other.GroupIds || + this.GroupIds != null && + this.GroupIds.SequenceEqual(other.GroupIds) + ) && + ( + this.Name == other.Name || + this.Name != null && + this.Name.Equals(other.Name) + ) && + ( + this.SignMessageWithX509Certificate == other.SignMessageWithX509Certificate || + this.SignMessageWithX509Certificate != null && + this.SignMessageWithX509Certificate.Equals(other.SignMessageWithX509Certificate) + ) && + ( + this.IncludeOAuth == other.IncludeOAuth || + this.IncludeOAuth != null && + this.IncludeOAuth.Equals(other.IncludeOAuth) + ) && + ( + this.IncludeHMAC == other.IncludeHMAC || + this.IncludeHMAC != null && + this.IncludeHMAC.Equals(other.IncludeHMAC) + ) && + ( + this.PausePublish == other.PausePublish || + this.PausePublish != null && + this.PausePublish.Equals(other.PausePublish) + ) && + ( + this.EventData == other.EventData || + this.EventData != null && + this.EventData.Equals(other.EventData) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.ConnectId != null) + hash = hash * 59 + this.ConnectId.GetHashCode(); + if (this.ConfigurationType != null) + hash = hash * 59 + this.ConfigurationType.GetHashCode(); + if (this.AllowEnvelopePublish != null) + hash = hash * 59 + this.AllowEnvelopePublish.GetHashCode(); + if (this.UrlToPublishTo != null) + hash = hash * 59 + this.UrlToPublishTo.GetHashCode(); + if (this.DeliveryMode != null) + hash = hash * 59 + this.DeliveryMode.GetHashCode(); + if (this.Events != null) + hash = hash * 59 + this.Events.GetHashCode(); + if (this.AssociatedFilterSelection != null) + hash = hash * 59 + this.AssociatedFilterSelection.GetHashCode(); + if (this.AccountIds != null) + hash = hash * 59 + this.AccountIds.GetHashCode(); + if (this.UserIds != null) + hash = hash * 59 + this.UserIds.GetHashCode(); + if (this.GroupIds != null) + hash = hash * 59 + this.GroupIds.GetHashCode(); + if (this.Name != null) + hash = hash * 59 + this.Name.GetHashCode(); + if (this.SignMessageWithX509Certificate != null) + hash = hash * 59 + this.SignMessageWithX509Certificate.GetHashCode(); + if (this.IncludeOAuth != null) + hash = hash * 59 + this.IncludeOAuth.GetHashCode(); + if (this.IncludeHMAC != null) + hash = hash * 59 + this.IncludeHMAC.GetHashCode(); + if (this.PausePublish != null) + hash = hash * 59 + this.PausePublish.GetHashCode(); + if (this.EventData != null) + hash = hash * 59 + this.EventData.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationRequest.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationRequest.cs new file mode 100644 index 0000000..cc968d3 --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectConfigurationRequest.cs @@ -0,0 +1,348 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectConfigurationRequest + /// + [DataContract] + public partial class OrganizationConnectConfigurationRequest : IEquatable, IValidatableObject + { + public OrganizationConnectConfigurationRequest() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// ConnectId. + /// ConfigurationType. + /// AllowEnvelopePublish. + /// UrlToPublishTo. + /// DeliveryMode. + /// Events. + /// AssociatedFilterSelection. + /// GroupIds. + /// AccountIds. + /// UserIds. + /// Name. + /// SignMessageWithX509Certificate. + /// IncludeOAuth. + /// IncludeHMAC. + /// PausePublish. + /// EventData. + public OrganizationConnectConfigurationRequest(Guid? ConnectId = default(Guid?), string ConfigurationType = default(string), string AllowEnvelopePublish = default(string), string UrlToPublishTo = default(string), string DeliveryMode = default(string), List Events = default(List), string AssociatedFilterSelection = default(string), List GroupIds = default(List), List AccountIds = default(List), List UserIds = default(List), string Name = default(string), string SignMessageWithX509Certificate = default(string), string IncludeOAuth = default(string), string IncludeHMAC = default(string), string PausePublish = default(string), ConnectEventData EventData = default(ConnectEventData)) + { + this.ConnectId = ConnectId; + this.ConfigurationType = ConfigurationType; + this.AllowEnvelopePublish = AllowEnvelopePublish; + this.UrlToPublishTo = UrlToPublishTo; + this.DeliveryMode = DeliveryMode; + this.Events = Events; + this.AssociatedFilterSelection = AssociatedFilterSelection; + this.GroupIds = GroupIds; + this.AccountIds = AccountIds; + this.UserIds = UserIds; + this.Name = Name; + this.SignMessageWithX509Certificate = SignMessageWithX509Certificate; + this.IncludeOAuth = IncludeOAuth; + this.IncludeHMAC = IncludeHMAC; + this.PausePublish = PausePublish; + this.EventData = EventData; + } + + /// + /// Gets or Sets ConnectId + /// + [DataMember(Name="connectId", EmitDefaultValue=false)] + public Guid? ConnectId { get; set; } + /// + /// Gets or Sets ConfigurationType + /// + [DataMember(Name="configurationType", EmitDefaultValue=false)] + public string ConfigurationType { get; set; } + /// + /// Gets or Sets AllowEnvelopePublish + /// + [DataMember(Name="allowEnvelopePublish", EmitDefaultValue=false)] + public string AllowEnvelopePublish { get; set; } + /// + /// Gets or Sets UrlToPublishTo + /// + [DataMember(Name="urlToPublishTo", EmitDefaultValue=false)] + public string UrlToPublishTo { get; set; } + /// + /// Gets or Sets DeliveryMode + /// + [DataMember(Name="deliveryMode", EmitDefaultValue=false)] + public string DeliveryMode { get; set; } + /// + /// Gets or Sets Events + /// + [DataMember(Name="events", EmitDefaultValue=false)] + public List Events { get; set; } + /// + /// Gets or Sets AssociatedFilterSelection + /// + [DataMember(Name="associatedFilterSelection", EmitDefaultValue=false)] + public string AssociatedFilterSelection { get; set; } + /// + /// Gets or Sets GroupIds + /// + [DataMember(Name="groupIds", EmitDefaultValue=false)] + public List GroupIds { get; set; } + /// + /// Gets or Sets AccountIds + /// + [DataMember(Name="accountIds", EmitDefaultValue=false)] + public List AccountIds { get; set; } + /// + /// Gets or Sets UserIds + /// + [DataMember(Name="userIds", EmitDefaultValue=false)] + public List UserIds { get; set; } + /// + /// Gets or Sets Name + /// + [DataMember(Name="name", EmitDefaultValue=false)] + public string Name { get; set; } + /// + /// Gets or Sets SignMessageWithX509Certificate + /// + [DataMember(Name="signMessageWithX509Certificate", EmitDefaultValue=false)] + public string SignMessageWithX509Certificate { get; set; } + /// + /// Gets or Sets IncludeOAuth + /// + [DataMember(Name="includeOAuth", EmitDefaultValue=false)] + public string IncludeOAuth { get; set; } + /// + /// Gets or Sets IncludeHMAC + /// + [DataMember(Name="includeHMAC", EmitDefaultValue=false)] + public string IncludeHMAC { get; set; } + /// + /// Gets or Sets PausePublish + /// + [DataMember(Name="pausePublish", EmitDefaultValue=false)] + public string PausePublish { get; set; } + /// + /// Gets or Sets EventData + /// + [DataMember(Name="eventData", EmitDefaultValue=false)] + public ConnectEventData EventData { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectConfigurationRequest {\n"); + sb.Append(" ConnectId: ").Append(ConnectId).Append("\n"); + sb.Append(" ConfigurationType: ").Append(ConfigurationType).Append("\n"); + sb.Append(" AllowEnvelopePublish: ").Append(AllowEnvelopePublish).Append("\n"); + sb.Append(" UrlToPublishTo: ").Append(UrlToPublishTo).Append("\n"); + sb.Append(" DeliveryMode: ").Append(DeliveryMode).Append("\n"); + sb.Append(" Events: ").Append(Events).Append("\n"); + sb.Append(" AssociatedFilterSelection: ").Append(AssociatedFilterSelection).Append("\n"); + sb.Append(" GroupIds: ").Append(GroupIds).Append("\n"); + sb.Append(" AccountIds: ").Append(AccountIds).Append("\n"); + sb.Append(" UserIds: ").Append(UserIds).Append("\n"); + sb.Append(" Name: ").Append(Name).Append("\n"); + sb.Append(" SignMessageWithX509Certificate: ").Append(SignMessageWithX509Certificate).Append("\n"); + sb.Append(" IncludeOAuth: ").Append(IncludeOAuth).Append("\n"); + sb.Append(" IncludeHMAC: ").Append(IncludeHMAC).Append("\n"); + sb.Append(" PausePublish: ").Append(PausePublish).Append("\n"); + sb.Append(" EventData: ").Append(EventData).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectConfigurationRequest); + } + + /// + /// Returns true if OrganizationConnectConfigurationRequest instances are equal + /// + /// Instance of OrganizationConnectConfigurationRequest to be compared + /// Boolean + public bool Equals(OrganizationConnectConfigurationRequest other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.ConnectId == other.ConnectId || + this.ConnectId != null && + this.ConnectId.Equals(other.ConnectId) + ) && + ( + this.ConfigurationType == other.ConfigurationType || + this.ConfigurationType != null && + this.ConfigurationType.Equals(other.ConfigurationType) + ) && + ( + this.AllowEnvelopePublish == other.AllowEnvelopePublish || + this.AllowEnvelopePublish != null && + this.AllowEnvelopePublish.Equals(other.AllowEnvelopePublish) + ) && + ( + this.UrlToPublishTo == other.UrlToPublishTo || + this.UrlToPublishTo != null && + this.UrlToPublishTo.Equals(other.UrlToPublishTo) + ) && + ( + this.DeliveryMode == other.DeliveryMode || + this.DeliveryMode != null && + this.DeliveryMode.Equals(other.DeliveryMode) + ) && + ( + this.Events == other.Events || + this.Events != null && + this.Events.SequenceEqual(other.Events) + ) && + ( + this.AssociatedFilterSelection == other.AssociatedFilterSelection || + this.AssociatedFilterSelection != null && + this.AssociatedFilterSelection.Equals(other.AssociatedFilterSelection) + ) && + ( + this.GroupIds == other.GroupIds || + this.GroupIds != null && + this.GroupIds.SequenceEqual(other.GroupIds) + ) && + ( + this.AccountIds == other.AccountIds || + this.AccountIds != null && + this.AccountIds.SequenceEqual(other.AccountIds) + ) && + ( + this.UserIds == other.UserIds || + this.UserIds != null && + this.UserIds.SequenceEqual(other.UserIds) + ) && + ( + this.Name == other.Name || + this.Name != null && + this.Name.Equals(other.Name) + ) && + ( + this.SignMessageWithX509Certificate == other.SignMessageWithX509Certificate || + this.SignMessageWithX509Certificate != null && + this.SignMessageWithX509Certificate.Equals(other.SignMessageWithX509Certificate) + ) && + ( + this.IncludeOAuth == other.IncludeOAuth || + this.IncludeOAuth != null && + this.IncludeOAuth.Equals(other.IncludeOAuth) + ) && + ( + this.IncludeHMAC == other.IncludeHMAC || + this.IncludeHMAC != null && + this.IncludeHMAC.Equals(other.IncludeHMAC) + ) && + ( + this.PausePublish == other.PausePublish || + this.PausePublish != null && + this.PausePublish.Equals(other.PausePublish) + ) && + ( + this.EventData == other.EventData || + this.EventData != null && + this.EventData.Equals(other.EventData) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.ConnectId != null) + hash = hash * 59 + this.ConnectId.GetHashCode(); + if (this.ConfigurationType != null) + hash = hash * 59 + this.ConfigurationType.GetHashCode(); + if (this.AllowEnvelopePublish != null) + hash = hash * 59 + this.AllowEnvelopePublish.GetHashCode(); + if (this.UrlToPublishTo != null) + hash = hash * 59 + this.UrlToPublishTo.GetHashCode(); + if (this.DeliveryMode != null) + hash = hash * 59 + this.DeliveryMode.GetHashCode(); + if (this.Events != null) + hash = hash * 59 + this.Events.GetHashCode(); + if (this.AssociatedFilterSelection != null) + hash = hash * 59 + this.AssociatedFilterSelection.GetHashCode(); + if (this.GroupIds != null) + hash = hash * 59 + this.GroupIds.GetHashCode(); + if (this.AccountIds != null) + hash = hash * 59 + this.AccountIds.GetHashCode(); + if (this.UserIds != null) + hash = hash * 59 + this.UserIds.GetHashCode(); + if (this.Name != null) + hash = hash * 59 + this.Name.GetHashCode(); + if (this.SignMessageWithX509Certificate != null) + hash = hash * 59 + this.SignMessageWithX509Certificate.GetHashCode(); + if (this.IncludeOAuth != null) + hash = hash * 59 + this.IncludeOAuth.GetHashCode(); + if (this.IncludeHMAC != null) + hash = hash * 59 + this.IncludeHMAC.GetHashCode(); + if (this.PausePublish != null) + hash = hash * 59 + this.PausePublish.GetHashCode(); + if (this.EventData != null) + hash = hash * 59 + this.EventData.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectHmacSecretsResponse.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectHmacSecretsResponse.cs new file mode 100644 index 0000000..ebb990c --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectHmacSecretsResponse.cs @@ -0,0 +1,123 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectHmacSecretsResponse + /// + [DataContract] + public partial class OrganizationConnectHmacSecretsResponse : IEquatable, IValidatableObject + { + public OrganizationConnectHmacSecretsResponse() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// Secrets. + public OrganizationConnectHmacSecretsResponse(List Secrets = default(List)) + { + this.Secrets = Secrets; + } + + /// + /// Gets or Sets Secrets + /// + [DataMember(Name="secrets", EmitDefaultValue=false)] + public List Secrets { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectHmacSecretsResponse {\n"); + sb.Append(" Secrets: ").Append(Secrets).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectHmacSecretsResponse); + } + + /// + /// Returns true if OrganizationConnectHmacSecretsResponse instances are equal + /// + /// Instance of OrganizationConnectHmacSecretsResponse to be compared + /// Boolean + public bool Equals(OrganizationConnectHmacSecretsResponse other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.Secrets == other.Secrets || + this.Secrets != null && + this.Secrets.SequenceEqual(other.Secrets) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.Secrets != null) + hash = hash * 59 + this.Secrets.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationConnectOAuthConfiguration.cs b/sdk/src/DocuSign.Admin/Model/OrganizationConnectOAuthConfiguration.cs new file mode 100644 index 0000000..79eff97 --- /dev/null +++ b/sdk/src/DocuSign.Admin/Model/OrganizationConnectOAuthConfiguration.cs @@ -0,0 +1,183 @@ +/* + * Docusign Admin API + * + * An API for an organization administrator to manage organizations, accounts and users + * + * OpenAPI spec version: v2.1 + * Contact: devcenter@docusign.com + * Generated by: https://github.com/swagger-api/swagger-codegen.git + */ + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; + +namespace DocuSign.Admin.Model +{ + /// + /// OrganizationConnectOAuthConfiguration + /// + [DataContract] + public partial class OrganizationConnectOAuthConfiguration : IEquatable, IValidatableObject + { + public OrganizationConnectOAuthConfiguration() + { + // Empty Constructor + } + + /// + /// Initializes a new instance of the class. + /// + /// AuthorizationServerUrl. + /// ClientId. + /// ClientSecret. + /// Scope. + /// CustomParameter. + public OrganizationConnectOAuthConfiguration(string AuthorizationServerUrl = default(string), string ClientId = default(string), string ClientSecret = default(string), string Scope = default(string), Dictionary CustomParameter = default(Dictionary)) + { + this.AuthorizationServerUrl = AuthorizationServerUrl; + this.ClientId = ClientId; + this.ClientSecret = ClientSecret; + this.Scope = Scope; + this.CustomParameter = CustomParameter; + } + + /// + /// Gets or Sets AuthorizationServerUrl + /// + [DataMember(Name="authorizationServerUrl", EmitDefaultValue=false)] + public string AuthorizationServerUrl { get; set; } + /// + /// Gets or Sets ClientId + /// + [DataMember(Name="clientId", EmitDefaultValue=false)] + public string ClientId { get; set; } + /// + /// Gets or Sets ClientSecret + /// + [DataMember(Name="clientSecret", EmitDefaultValue=false)] + public string ClientSecret { get; set; } + /// + /// Gets or Sets Scope + /// + [DataMember(Name="scope", EmitDefaultValue=false)] + public string Scope { get; set; } + /// + /// Gets or Sets CustomParameter + /// + [DataMember(Name="customParameter", EmitDefaultValue=false)] + public Dictionary CustomParameter { get; set; } + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class OrganizationConnectOAuthConfiguration {\n"); + sb.Append(" AuthorizationServerUrl: ").Append(AuthorizationServerUrl).Append("\n"); + sb.Append(" ClientId: ").Append(ClientId).Append("\n"); + sb.Append(" ClientSecret: ").Append(ClientSecret).Append("\n"); + sb.Append(" Scope: ").Append(Scope).Append("\n"); + sb.Append(" CustomParameter: ").Append(CustomParameter).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object obj) + { + // credit: http://stackoverflow.com/a/10454552/677735 + return this.Equals(obj as OrganizationConnectOAuthConfiguration); + } + + /// + /// Returns true if OrganizationConnectOAuthConfiguration instances are equal + /// + /// Instance of OrganizationConnectOAuthConfiguration to be compared + /// Boolean + public bool Equals(OrganizationConnectOAuthConfiguration other) + { + // credit: http://stackoverflow.com/a/10454552/677735 + if (other == null) + return false; + + return + ( + this.AuthorizationServerUrl == other.AuthorizationServerUrl || + this.AuthorizationServerUrl != null && + this.AuthorizationServerUrl.Equals(other.AuthorizationServerUrl) + ) && + ( + this.ClientId == other.ClientId || + this.ClientId != null && + this.ClientId.Equals(other.ClientId) + ) && + ( + this.ClientSecret == other.ClientSecret || + this.ClientSecret != null && + this.ClientSecret.Equals(other.ClientSecret) + ) && + ( + this.Scope == other.Scope || + this.Scope != null && + this.Scope.Equals(other.Scope) + ) && + ( + this.CustomParameter == other.CustomParameter || + this.CustomParameter != null && + this.CustomParameter.SequenceEqual(other.CustomParameter) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + // credit: http://stackoverflow.com/a/263416/677735 + unchecked // Overflow is fine, just wrap + { + int hash = 41; + // Suitable nullity checks etc, of course :) + if (this.AuthorizationServerUrl != null) + hash = hash * 59 + this.AuthorizationServerUrl.GetHashCode(); + if (this.ClientId != null) + hash = hash * 59 + this.ClientId.GetHashCode(); + if (this.ClientSecret != null) + hash = hash * 59 + this.ClientSecret.GetHashCode(); + if (this.Scope != null) + hash = hash * 59 + this.Scope.GetHashCode(); + if (this.CustomParameter != null) + hash = hash * 59 + this.CustomParameter.GetHashCode(); + return hash; + } + } + + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } +} diff --git a/sdk/src/DocuSign.Admin/Model/OrganizationUserResponse.cs b/sdk/src/DocuSign.Admin/Model/OrganizationUserResponse.cs index 3493b6f..be63a1a 100644 --- a/sdk/src/DocuSign.Admin/Model/OrganizationUserResponse.cs +++ b/sdk/src/DocuSign.Admin/Model/OrganizationUserResponse.cs @@ -43,10 +43,17 @@ public OrganizationUserResponse() /// MembershipStatus. /// Email. /// CreatedOn. + /// ClosedOn. /// MembershipCreatedOn. + /// MembershipClosedOn. /// DsGroups. /// MembershipId. - public OrganizationUserResponse(Guid? Id = default(Guid?), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string UserStatus = default(string), string MembershipStatus = default(string), string Email = default(string), DateTime? CreatedOn = default(DateTime?), DateTime? MembershipCreatedOn = default(DateTime?), List DsGroups = default(List), Guid? MembershipId = default(Guid?)) + /// IsMembershipManagedByScim. + /// IsManagedByScim. + /// LicenseType. + /// SubscriptionId. + /// PlanName. + public OrganizationUserResponse(Guid? Id = default(Guid?), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string UserStatus = default(string), string MembershipStatus = default(string), string Email = default(string), DateTime? CreatedOn = default(DateTime?), DateTime? ClosedOn = default(DateTime?), DateTime? MembershipCreatedOn = default(DateTime?), DateTime? MembershipClosedOn = default(DateTime?), List DsGroups = default(List), Guid? MembershipId = default(Guid?), bool? IsMembershipManagedByScim = default(bool?), bool? IsManagedByScim = default(bool?), string LicenseType = default(string), string SubscriptionId = default(string), string PlanName = default(string)) { this.Id = Id; this.UserName = UserName; @@ -56,9 +63,16 @@ public OrganizationUserResponse() this.MembershipStatus = MembershipStatus; this.Email = Email; this.CreatedOn = CreatedOn; + this.ClosedOn = ClosedOn; this.MembershipCreatedOn = MembershipCreatedOn; + this.MembershipClosedOn = MembershipClosedOn; this.DsGroups = DsGroups; this.MembershipId = MembershipId; + this.IsMembershipManagedByScim = IsMembershipManagedByScim; + this.IsManagedByScim = IsManagedByScim; + this.LicenseType = LicenseType; + this.SubscriptionId = SubscriptionId; + this.PlanName = PlanName; } /// @@ -102,11 +116,21 @@ public OrganizationUserResponse() [DataMember(Name="created_on", EmitDefaultValue=false)] public DateTime? CreatedOn { get; set; } /// + /// Gets or Sets ClosedOn + /// + [DataMember(Name="closed_on", EmitDefaultValue=false)] + public DateTime? ClosedOn { get; set; } + /// /// Gets or Sets MembershipCreatedOn /// [DataMember(Name="membership_created_on", EmitDefaultValue=false)] public DateTime? MembershipCreatedOn { get; set; } /// + /// Gets or Sets MembershipClosedOn + /// + [DataMember(Name="membership_closed_on", EmitDefaultValue=false)] + public DateTime? MembershipClosedOn { get; set; } + /// /// Gets or Sets DsGroups /// [DataMember(Name="ds_groups", EmitDefaultValue=false)] @@ -117,6 +141,31 @@ public OrganizationUserResponse() [DataMember(Name="membership_id", EmitDefaultValue=false)] public Guid? MembershipId { get; set; } /// + /// Gets or Sets IsMembershipManagedByScim + /// + [DataMember(Name="is_membership_managed_by_scim", EmitDefaultValue=false)] + public bool? IsMembershipManagedByScim { get; set; } + /// + /// Gets or Sets IsManagedByScim + /// + [DataMember(Name="is_managed_by_scim", EmitDefaultValue=false)] + public bool? IsManagedByScim { get; set; } + /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// + /// Gets or Sets SubscriptionId + /// + [DataMember(Name="subscription_id", EmitDefaultValue=false)] + public string SubscriptionId { get; set; } + /// + /// Gets or Sets PlanName + /// + [DataMember(Name="plan_name", EmitDefaultValue=false)] + public string PlanName { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -132,9 +181,16 @@ public override string ToString() sb.Append(" MembershipStatus: ").Append(MembershipStatus).Append("\n"); sb.Append(" Email: ").Append(Email).Append("\n"); sb.Append(" CreatedOn: ").Append(CreatedOn).Append("\n"); + sb.Append(" ClosedOn: ").Append(ClosedOn).Append("\n"); sb.Append(" MembershipCreatedOn: ").Append(MembershipCreatedOn).Append("\n"); + sb.Append(" MembershipClosedOn: ").Append(MembershipClosedOn).Append("\n"); sb.Append(" DsGroups: ").Append(DsGroups).Append("\n"); sb.Append(" MembershipId: ").Append(MembershipId).Append("\n"); + sb.Append(" IsMembershipManagedByScim: ").Append(IsMembershipManagedByScim).Append("\n"); + sb.Append(" IsManagedByScim: ").Append(IsManagedByScim).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); + sb.Append(" SubscriptionId: ").Append(SubscriptionId).Append("\n"); + sb.Append(" PlanName: ").Append(PlanName).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -211,11 +267,21 @@ public bool Equals(OrganizationUserResponse other) this.CreatedOn != null && this.CreatedOn.Equals(other.CreatedOn) ) && + ( + this.ClosedOn == other.ClosedOn || + this.ClosedOn != null && + this.ClosedOn.Equals(other.ClosedOn) + ) && ( this.MembershipCreatedOn == other.MembershipCreatedOn || this.MembershipCreatedOn != null && this.MembershipCreatedOn.Equals(other.MembershipCreatedOn) ) && + ( + this.MembershipClosedOn == other.MembershipClosedOn || + this.MembershipClosedOn != null && + this.MembershipClosedOn.Equals(other.MembershipClosedOn) + ) && ( this.DsGroups == other.DsGroups || this.DsGroups != null && @@ -225,6 +291,31 @@ public bool Equals(OrganizationUserResponse other) this.MembershipId == other.MembershipId || this.MembershipId != null && this.MembershipId.Equals(other.MembershipId) + ) && + ( + this.IsMembershipManagedByScim == other.IsMembershipManagedByScim || + this.IsMembershipManagedByScim != null && + this.IsMembershipManagedByScim.Equals(other.IsMembershipManagedByScim) + ) && + ( + this.IsManagedByScim == other.IsManagedByScim || + this.IsManagedByScim != null && + this.IsManagedByScim.Equals(other.IsManagedByScim) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) + ) && + ( + this.SubscriptionId == other.SubscriptionId || + this.SubscriptionId != null && + this.SubscriptionId.Equals(other.SubscriptionId) + ) && + ( + this.PlanName == other.PlanName || + this.PlanName != null && + this.PlanName.Equals(other.PlanName) ); } @@ -255,12 +346,26 @@ public override int GetHashCode() hash = hash * 59 + this.Email.GetHashCode(); if (this.CreatedOn != null) hash = hash * 59 + this.CreatedOn.GetHashCode(); + if (this.ClosedOn != null) + hash = hash * 59 + this.ClosedOn.GetHashCode(); if (this.MembershipCreatedOn != null) hash = hash * 59 + this.MembershipCreatedOn.GetHashCode(); + if (this.MembershipClosedOn != null) + hash = hash * 59 + this.MembershipClosedOn.GetHashCode(); if (this.DsGroups != null) hash = hash * 59 + this.DsGroups.GetHashCode(); if (this.MembershipId != null) hash = hash * 59 + this.MembershipId.GetHashCode(); + if (this.IsMembershipManagedByScim != null) + hash = hash * 59 + this.IsMembershipManagedByScim.GetHashCode(); + if (this.IsManagedByScim != null) + hash = hash * 59 + this.IsManagedByScim.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); + if (this.SubscriptionId != null) + hash = hash * 59 + this.SubscriptionId.GetHashCode(); + if (this.PlanName != null) + hash = hash * 59 + this.PlanName.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/UpdateMembershipRequest.cs b/sdk/src/DocuSign.Admin/Model/UpdateMembershipRequest.cs index c1c9ecb..3788cd7 100644 --- a/sdk/src/DocuSign.Admin/Model/UpdateMembershipRequest.cs +++ b/sdk/src/DocuSign.Admin/Model/UpdateMembershipRequest.cs @@ -42,7 +42,8 @@ public UpdateMembershipRequest() /// JobTitle. /// SendActivation. /// AccessCode. - public UpdateMembershipRequest(Guid? AccountId = default(Guid?), PermissionProfileRequest PermissionProfile = default(PermissionProfileRequest), List Groups = default(List), string CompanyName = default(string), string JobTitle = default(string), bool? SendActivation = default(bool?), string AccessCode = default(string)) + /// LicenseType. + public UpdateMembershipRequest(Guid? AccountId = default(Guid?), PermissionProfileRequest PermissionProfile = default(PermissionProfileRequest), List Groups = default(List), string CompanyName = default(string), string JobTitle = default(string), bool? SendActivation = default(bool?), string AccessCode = default(string), string LicenseType = default(string)) { // to ensure "AccountId" is required (not null) if (AccountId == null) @@ -59,6 +60,7 @@ public UpdateMembershipRequest() this.JobTitle = JobTitle; this.SendActivation = SendActivation; this.AccessCode = AccessCode; + this.LicenseType = LicenseType; } /// @@ -97,6 +99,11 @@ public UpdateMembershipRequest() [DataMember(Name="access_code", EmitDefaultValue=false)] public string AccessCode { get; set; } /// + /// Gets or Sets LicenseType + /// + [DataMember(Name="license_type", EmitDefaultValue=false)] + public string LicenseType { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -111,6 +118,7 @@ public override string ToString() sb.Append(" JobTitle: ").Append(JobTitle).Append("\n"); sb.Append(" SendActivation: ").Append(SendActivation).Append("\n"); sb.Append(" AccessCode: ").Append(AccessCode).Append("\n"); + sb.Append(" LicenseType: ").Append(LicenseType).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -181,6 +189,11 @@ public bool Equals(UpdateMembershipRequest other) this.AccessCode == other.AccessCode || this.AccessCode != null && this.AccessCode.Equals(other.AccessCode) + ) && + ( + this.LicenseType == other.LicenseType || + this.LicenseType != null && + this.LicenseType.Equals(other.LicenseType) ); } @@ -209,6 +222,8 @@ public override int GetHashCode() hash = hash * 59 + this.SendActivation.GetHashCode(); if (this.AccessCode != null) hash = hash * 59 + this.AccessCode.GetHashCode(); + if (this.LicenseType != null) + hash = hash * 59 + this.LicenseType.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Model/UserDrilldownResponse.cs b/sdk/src/DocuSign.Admin/Model/UserDrilldownResponse.cs index a751de9..f7d442a 100644 --- a/sdk/src/DocuSign.Admin/Model/UserDrilldownResponse.cs +++ b/sdk/src/DocuSign.Admin/Model/UserDrilldownResponse.cs @@ -53,7 +53,11 @@ public UserDrilldownResponse() /// Memberships. /// Identities. /// DeviceVerificationEnabled. - public UserDrilldownResponse(Guid? Id = default(Guid?), int? SiteId = default(int?), string SiteName = default(string), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string UserStatus = default(string), Guid? DefaultAccountId = default(Guid?), string DefaultAccountName = default(string), string LanguageCulture = default(string), string SelectedLanguages = default(string), string FederatedStatus = default(string), bool? IsOrganizationAdmin = default(bool?), DateTime? CreatedOn = default(DateTime?), DateTime? LastLogin = default(DateTime?), List Memberships = default(List), List Identities = default(List), bool? DeviceVerificationEnabled = default(bool?)) + /// RequireTwoStepVerification. + /// AllowTwoStepVerificationSnooze. + /// AllowExtendOrgAdminRightsToSelf. + /// IsManagedByScim. + public UserDrilldownResponse(Guid? Id = default(Guid?), int? SiteId = default(int?), string SiteName = default(string), string UserName = default(string), string FirstName = default(string), string LastName = default(string), string UserStatus = default(string), Guid? DefaultAccountId = default(Guid?), string DefaultAccountName = default(string), string LanguageCulture = default(string), string SelectedLanguages = default(string), string FederatedStatus = default(string), bool? IsOrganizationAdmin = default(bool?), DateTime? CreatedOn = default(DateTime?), DateTime? LastLogin = default(DateTime?), List Memberships = default(List), List Identities = default(List), bool? DeviceVerificationEnabled = default(bool?), bool? RequireTwoStepVerification = default(bool?), bool? AllowTwoStepVerificationSnooze = default(bool?), bool? AllowExtendOrgAdminRightsToSelf = default(bool?), bool? IsManagedByScim = default(bool?)) { this.Id = Id; this.SiteId = SiteId; @@ -73,6 +77,10 @@ public UserDrilldownResponse() this.Memberships = Memberships; this.Identities = Identities; this.DeviceVerificationEnabled = DeviceVerificationEnabled; + this.RequireTwoStepVerification = RequireTwoStepVerification; + this.AllowTwoStepVerificationSnooze = AllowTwoStepVerificationSnooze; + this.AllowExtendOrgAdminRightsToSelf = AllowExtendOrgAdminRightsToSelf; + this.IsManagedByScim = IsManagedByScim; } /// @@ -166,6 +174,26 @@ public UserDrilldownResponse() [DataMember(Name="device_verification_enabled", EmitDefaultValue=false)] public bool? DeviceVerificationEnabled { get; set; } /// + /// Gets or Sets RequireTwoStepVerification + /// + [DataMember(Name="require_two_step_verification", EmitDefaultValue=false)] + public bool? RequireTwoStepVerification { get; set; } + /// + /// Gets or Sets AllowTwoStepVerificationSnooze + /// + [DataMember(Name="allow_two_step_verification_snooze", EmitDefaultValue=false)] + public bool? AllowTwoStepVerificationSnooze { get; set; } + /// + /// Gets or Sets AllowExtendOrgAdminRightsToSelf + /// + [DataMember(Name="allow_extend_org_admin_rights_to_self", EmitDefaultValue=false)] + public bool? AllowExtendOrgAdminRightsToSelf { get; set; } + /// + /// Gets or Sets IsManagedByScim + /// + [DataMember(Name="is_managed_by_scim", EmitDefaultValue=false)] + public bool? IsManagedByScim { get; set; } + /// /// Returns the string presentation of the object /// /// String presentation of the object @@ -191,6 +219,10 @@ public override string ToString() sb.Append(" Memberships: ").Append(Memberships).Append("\n"); sb.Append(" Identities: ").Append(Identities).Append("\n"); sb.Append(" DeviceVerificationEnabled: ").Append(DeviceVerificationEnabled).Append("\n"); + sb.Append(" RequireTwoStepVerification: ").Append(RequireTwoStepVerification).Append("\n"); + sb.Append(" AllowTwoStepVerificationSnooze: ").Append(AllowTwoStepVerificationSnooze).Append("\n"); + sb.Append(" AllowExtendOrgAdminRightsToSelf: ").Append(AllowExtendOrgAdminRightsToSelf).Append("\n"); + sb.Append(" IsManagedByScim: ").Append(IsManagedByScim).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -316,6 +348,26 @@ public bool Equals(UserDrilldownResponse other) this.DeviceVerificationEnabled == other.DeviceVerificationEnabled || this.DeviceVerificationEnabled != null && this.DeviceVerificationEnabled.Equals(other.DeviceVerificationEnabled) + ) && + ( + this.RequireTwoStepVerification == other.RequireTwoStepVerification || + this.RequireTwoStepVerification != null && + this.RequireTwoStepVerification.Equals(other.RequireTwoStepVerification) + ) && + ( + this.AllowTwoStepVerificationSnooze == other.AllowTwoStepVerificationSnooze || + this.AllowTwoStepVerificationSnooze != null && + this.AllowTwoStepVerificationSnooze.Equals(other.AllowTwoStepVerificationSnooze) + ) && + ( + this.AllowExtendOrgAdminRightsToSelf == other.AllowExtendOrgAdminRightsToSelf || + this.AllowExtendOrgAdminRightsToSelf != null && + this.AllowExtendOrgAdminRightsToSelf.Equals(other.AllowExtendOrgAdminRightsToSelf) + ) && + ( + this.IsManagedByScim == other.IsManagedByScim || + this.IsManagedByScim != null && + this.IsManagedByScim.Equals(other.IsManagedByScim) ); } @@ -366,6 +418,14 @@ public override int GetHashCode() hash = hash * 59 + this.Identities.GetHashCode(); if (this.DeviceVerificationEnabled != null) hash = hash * 59 + this.DeviceVerificationEnabled.GetHashCode(); + if (this.RequireTwoStepVerification != null) + hash = hash * 59 + this.RequireTwoStepVerification.GetHashCode(); + if (this.AllowTwoStepVerificationSnooze != null) + hash = hash * 59 + this.AllowTwoStepVerificationSnooze.GetHashCode(); + if (this.AllowExtendOrgAdminRightsToSelf != null) + hash = hash * 59 + this.AllowExtendOrgAdminRightsToSelf.GetHashCode(); + if (this.IsManagedByScim != null) + hash = hash * 59 + this.IsManagedByScim.GetHashCode(); return hash; } } diff --git a/sdk/src/DocuSign.Admin/Properties/AssemblyInfo.cs b/sdk/src/DocuSign.Admin/Properties/AssemblyInfo.cs index 1302137..8c7df2d 100644 --- a/sdk/src/DocuSign.Admin/Properties/AssemblyInfo.cs +++ b/sdk/src/DocuSign.Admin/Properties/AssemblyInfo.cs @@ -22,5 +22,5 @@ // [assembly: AssemblyVersion("1.0.*")] internal class AssemblyInformation { - public const string AssemblyInformationalVersion = "2.0.2"; + public const string AssemblyInformationalVersion = "2.1.0"; } \ No newline at end of file