diff --git a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.cs b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.cs index b8e7e4c..a62af31 100644 --- a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.cs +++ b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.cs @@ -4725,18 +4725,18 @@ public string BaseUrl /// Success /// A server side error occurred. - public virtual System.Threading.Tasks.Task UserHasExistsByUsernameAsync(UserHasExistsByUsernameRequestContract body) + public virtual System.Threading.Tasks.Task GetUserByUserNameAsync(GetUserByUserNameRequestContract body) { - return UserHasExistsByUsernameAsync(body, System.Threading.CancellationToken.None); + return GetUserByUserNameAsync(body, System.Threading.CancellationToken.None); } /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// Success /// A server side error occurred. - public virtual async System.Threading.Tasks.Task UserHasExistsByUsernameAsync(UserHasExistsByUsernameRequestContract body, System.Threading.CancellationToken cancellationToken) + public virtual async System.Threading.Tasks.Task GetUserByUserNameAsync(GetUserByUserNameRequestContract body, System.Threading.CancellationToken cancellationToken) { var urlBuilder_ = new System.Text.StringBuilder(); - urlBuilder_.Append(BaseUrl != null ? BaseUrl.TrimEnd('/') : "").Append("/api/Users/UserHasExistsByUsername"); + urlBuilder_.Append(BaseUrl != null ? BaseUrl.TrimEnd('/') : "").Append("/api/Users/GetUserByUserName"); var client_ = _httpClient; var disposeClient_ = false; @@ -6898,6 +6898,36 @@ public enum GetUniqueIdentityType } + [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "13.19.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.3.0))")] + public partial class GetUserByUserNameRequestContract : System.ComponentModel.INotifyPropertyChanged + { + private string _username; + + [Newtonsoft.Json.JsonProperty("username", Required = Newtonsoft.Json.Required.Default, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)] + public string Username + { + get { return _username; } + + set + { + if (_username != value) + { + _username = value; + RaisePropertyChanged(); + } + } + } + + public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged; + + protected virtual void RaisePropertyChanged([System.Runtime.CompilerServices.CallerMemberName] string propertyName = null) + { + var handler = PropertyChanged; + if (handler != null) + handler(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName)); + } + } + [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "13.19.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.3.0))")] public partial class Int64DeleteBulkRequestContract : System.ComponentModel.INotifyPropertyChanged { @@ -8606,36 +8636,6 @@ protected virtual void RaisePropertyChanged([System.Runtime.CompilerServices.Cal } } - [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "13.19.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.3.0))")] - public partial class UserHasExistsByUsernameRequestContract : System.ComponentModel.INotifyPropertyChanged - { - private string _username; - - [Newtonsoft.Json.JsonProperty("username", Required = Newtonsoft.Json.Required.Default, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)] - public string Username - { - get { return _username; } - - set - { - if (_username != value) - { - _username = value; - RaisePropertyChanged(); - } - } - } - - public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged; - - protected virtual void RaisePropertyChanged([System.Runtime.CompilerServices.CallerMemberName] string propertyName = null) - { - var handler = PropertyChanged; - if (handler != null) - handler(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName)); - } - } - [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "13.19.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.3.0))")] public partial class UserRoleContract : System.ComponentModel.INotifyPropertyChanged { diff --git a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.nswag.json b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.nswag.json index d52bf06..1e9bae0 100644 --- a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.nswag.json +++ b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/Connected Services/AuthenticationsGeneratedServices/OpenAPI.nswag.json @@ -2526,27 +2526,27 @@ } } }, - "/api/Users/UserHasExistsByUsername": { + "/api/Users/GetUserByUserName": { "post": { "tags": [ "Users" ], - "operationId": "UserHasExistsByUsername", + "operationId": "GetUserByUserName", "requestBody": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/UserHasExistsByUsernameRequestContract" + "$ref": "#/components/schemas/GetUserByUserNameRequestContract" } }, "text/json": { "schema": { - "$ref": "#/components/schemas/UserHasExistsByUsernameRequestContract" + "$ref": "#/components/schemas/GetUserByUserNameRequestContract" } }, "application/*+json": { "schema": { - "$ref": "#/components/schemas/UserHasExistsByUsernameRequestContract" + "$ref": "#/components/schemas/GetUserByUserNameRequestContract" } } } @@ -3623,6 +3623,16 @@ 7 ] }, + "GetUserByUserNameRequestContract": { + "type": "object", + "additionalProperties": false, + "properties": { + "username": { + "type": "string", + "nullable": true + } + } + }, "Int64DeleteBulkRequestContract": { "title": "DeleteBulkRequestContract", "type": "object", @@ -4145,16 +4155,6 @@ } } }, - "UserHasExistsByUsernameRequestContract": { - "type": "object", - "additionalProperties": false, - "properties": { - "username": { - "type": "string", - "nullable": true - } - } - }, "UserRoleContract": { "type": "object", "additionalProperties": false, diff --git a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/EasyMicroservices.AuthenticationsMicroservice.Clients.csproj b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/EasyMicroservices.AuthenticationsMicroservice.Clients.csproj index a8e697a..d71b1b8 100644 --- a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/EasyMicroservices.AuthenticationsMicroservice.Clients.csproj +++ b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Clients/EasyMicroservices.AuthenticationsMicroservice.Clients.csproj @@ -5,7 +5,7 @@ AnyCPU;x64;x86 EasyMicroservices true - 0.0.0.12 + 0.0.0.13 client generated code. EasyMicroservices@gmail.com microservice,auth,authentication,client diff --git a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/UserHasExistsByUsernameRequestContract.cs b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/GetUserByUserNameRequestContract.cs similarity index 82% rename from src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/UserHasExistsByUsernameRequestContract.cs rename to src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/GetUserByUserNameRequestContract.cs index 74943a5..da1cb01 100644 --- a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/UserHasExistsByUsernameRequestContract.cs +++ b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.Domain/Contracts/Requests/GetUserByUserNameRequestContract.cs @@ -6,7 +6,7 @@ namespace EasyMicroservices.AuthenticationsMicroservice.Contracts.Requests { - public class UserHasExistsByUsernameRequestContract + public class GetUserByUserNameRequestContract { public string Username { get; set; } } diff --git a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.WebApi/Controllers/UserController.cs b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.WebApi/Controllers/UserController.cs index a06d002..a58f62a 100644 --- a/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.WebApi/Controllers/UserController.cs +++ b/src/CSharp/EasyMicroservices.AuthenticationsMicroservice.WebApi/Controllers/UserController.cs @@ -24,7 +24,7 @@ public UsersController(IUnitOfWork unitOfWork/*, IJWTManager jwtManager*/) : bas } [HttpPost] - public async Task> UserHasExistsByUsername(UserHasExistsByUsernameRequestContract request) + public async Task> GetUserByUserName(GetUserByUserNameRequestContract request) { return await _unitOfWork.GetContractLogic().GetBy(x => x.UserName == request.Username); }