static void Main(string[] args) { var docxmerge = new Docxmerge.Docxmerge("API_KEY"); var output = docxmerge.RenderTemplate( "hello-world", new Dictionary <string, object> { { "name", "James Bond" }, { "logo", "https://docxmerge.com/assets/android-chrome-512x512.png" } }, "PDF", "latest" // version, can be ommited, just for reference ).Result; using (var ms = new MemoryStream()) { output.CopyTo(ms); var outputFile = "./hello_world_template_dotnet.pdf"; File.WriteAllBytes(outputFile, ms.ToArray()); System.Console.WriteLine($"Check {outputFile}"); } }