internal static MemoryStream RenderRequest(DeleteInvoiceRequest request)
        {
            const string path      = "deleteInvoiceRequest.sbn";
            var          template  = Template.Parse(File.ReadAllText(path), path);
            var          xmlString = template.Render(new { Request = request });

            return(CreateMemoryStream(xmlString));
        }
Esempio n. 2
0
        public async Task <DeleteInvoiceResponse> DeleteProFormaInvoice(DeleteInvoiceRequest request)
        {
            using (var xmlStream = XMLRenderer.RenderRequest(request))
            {
                using (var requestStream = CompressXmlStream(xmlStream))
                {
                    var doc = await HttpUploadXmlFile("https://www.szamlazz.hu/szamla/", requestStream.ToArray(), "action-szamla_agent_dijbekero_torlese");

                    return(XmlParser.ParseDeleteInvoiceResponse(doc));
                }
            }
        }