public GetProductListByIdentifierMessage(GetProductListByIdentifierRequest MyRequest)
        {
            _Environment = MyRequest._EnvironmentSelected;
            GetService(MyRequest);
            _IdentifierRequest = new IdentifierRequest();
            _IdentifierRequest.IdentifierType = IdentifierTypeEnum.EAN;
            _IdentifierRequest.ValueList      = MyRequest._Parameters["EAN"].Split(';');
            _ProductListByIdentifierMessage2  = _MarketplaceAPIService.GetProductListByIdentifierAsync(MyRequest._HeaderMessage, _IdentifierRequest);
            XmlSerializer xmlSerializer = new XmlSerializer(_ProductListByIdentifierMessage2.Result.GetType());

            _RequestXML = _RequestInterceptor.LastRequestXML;
            _MessageXML = _RequestInterceptor.LastResponseXML;
        }
        public async Task <GetProductListByIdentifierMessage> GetMessage(GetProductListByIdentifierRequest MyRequest, IWebHostEnvironment env)
        {
            try
            {
                _env = env;
                if (string.IsNullOrWhiteSpace(_env.WebRootPath))
                {
                    _env.WebRootPath = Path.Combine(Directory.GetCurrentDirectory(), "wwwroot");
                }
                _Environment = MyRequest._EnvironmentSelected;
                GetService(MyRequest);
                _IdentifierRequest = new IdentifierRequest();
                _IdentifierRequest.IdentifierType = IdentifierTypeEnum.EAN;
                _IdentifierRequest.ValueList      = MyRequest._Parameters["EAN"].Split(';');
                _ProductListByIdentifierMessage   = await _MarketplaceAPIService.GetProductListByIdentifierAsync(MyRequest._HeaderMessage, _IdentifierRequest);

                if (_ProductListByIdentifierMessage != null)
                {
                    _ProductListByIdentifierMessage.TokenId = MyRequest._HeaderMessage.Security.TokenId.Substring(0, 10);
                    CreateProductListReport();
                }
                _RequestXML = _RequestInterceptor.LastRequestXML;
                _MessageXML = _RequestInterceptor.LastResponseXML;
            }
            catch (System.AggregateException aggex)
            {
                if (_ProductListByIdentifierMessage.ErrorMessage != null)
                {
                    _InnerErrorMessage = _ProductListByIdentifierMessage.ErrorMessage;
                }
                _OperationSuccess = false;
                _ErrorMessage     = aggex.Message;
                _ErrorType        = aggex.HelpLink;
                _RequestXML       = _RequestInterceptor.LastRequestXML;
                _MessageXML       = _RequestInterceptor.LastResponseXML;
            }
            catch (System.Exception ex)
            {
                /*       if (_OrderListMessage.Exception.InnerException != null)
                 *          _InnerErrorMessage = _OrderListMessage.Exception.InnerException.Message;*/
                _OperationSuccess = false;
                _ErrorMessage     = ex.Message;
                _ErrorType        = ex.HelpLink;
                _RequestXML       = _RequestInterceptor.LastRequestXML;
                _MessageXML       = _RequestInterceptor.LastResponseXML;
            }
            return(this);
        }