using DXPBLL.Party; using DXPDAL.Common; using DXPSL.Common; using DXPSL.Parameters.Party; using GB5Shared.DTO.Framework.Enum; using GB5Shared.DTO.Framework.ResponseStandard; namespace DXPSL.Endpoints.Party; // Dedup lookup used during onboarding — the "network effect" instant-match. POST+payload // per the multi-criteria list convention, even though this one isn't paged. public class FindByIdentityHash : DXPBaseEndpoint> { private readonly IPartyBLL _bll; private readonly IDXPSystemContext _systemContext; public FindByIdentityHash(IPartyBLL bll, IDXPSystemContext systemContext) { _bll = bll; _systemContext = systemContext; } public override void Configure() => Post("/DXP/Party/FindByIdentityHash"); protected override async Task> ExecuteAsync( FindByIdentityHashParameters req, DXPCallerContext caller, CancellationToken ct) { var matches = await _bll.FindByIdentityHashAsync( req.GstinHash, req.PanHash, req.MobileHash, req.EmailHash, _systemContext.GetSystemLogin(caller.DxpUserId), ct); return new ResponseStandardDTO { Status = FrameworkEnumDTO.ResponseStatus.Ok, Body = matches }; } }