<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>office file processing on Document Processing REST APIs | GroupDocs Cloud</title>
    <link>https://blog-qa.groupdocs.cloud/tag/office-file-processing/</link>
    <description>Recent content in office file processing on Document Processing REST APIs | GroupDocs Cloud</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Mon, 14 Sep 2026 14:29:18 +0000</lastBuildDate><atom:link href="https://blog-qa.groupdocs.cloud/tag/office-file-processing/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>How to Combine Multiple Word Documents in Java</title>
      <link>https://blog-qa.groupdocs.cloud/merger/how-to-combine-multiple-word-documents-in-java/</link>
      <pubDate>Mon, 14 Sep 2026 14:29:18 +0000</pubDate>
      
      <guid>https://blog-qa.groupdocs.cloud/merger/how-to-combine-multiple-word-documents-in-java/</guid>
      <description>Combine multiple Word docs in Java using GroupDocs.Merger Cloud SDK. Follow this step-by-step guide for code, cURL calls, setup, and best practices.</description>
      <content:encoded><![CDATA[<p>Combining Word files programmatically is a frequent requirement when building document‑centric applications, especially for generating reports or consolidating contracts. <a href="https://products.groupdocs.cloud/merger/java/">GroupDocs.Merger Cloud SDK for Java</a> provides a simple, cloud‑based library that lets you merge <a href="https://docs.fileformat.com/word-processing/docx/">DOCX</a> files without dealing with low‑level file handling. In this guide you will learn how to combine multiple Word documents in Java, see a complete code example, explore equivalent cURL calls, and understand the required setup. By the end you&rsquo;ll be ready to integrate document merging into your own Java projects.</p>
<h2 id="full-working-example-to-combine-multiple-word-documents-in-java">Full Working Example to Combine Multiple Word Documents in Java</h2>
<p>This example demonstrates how to combine multiple Word documents in Java using the Merger API.</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span><span style="color:#f92672">import</span> com.groupdocs.merger.cloud.client.ApiClient<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> com.groupdocs.merger.cloud.client.ApiException<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> com.groupdocs.merger.cloud.api.MergerApi<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> com.groupdocs.merger.cloud.model.FileInfo<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> com.groupdocs.merger.cloud.model.MergeOptions<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> java.util.ArrayList<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">import</span> java.util.List<span style="color:#f92672">;</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">public</span> <span style="color:#66d9ef">class</span> <span style="color:#a6e22e">CombineWordDocuments</span> <span style="color:#f92672">{</span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">public</span> <span style="color:#66d9ef">static</span> <span style="color:#66d9ef">void</span> <span style="color:#a6e22e">main</span><span style="color:#f92672">(</span>String<span style="color:#f92672">[]</span> args<span style="color:#f92672">)</span> <span style="color:#f92672">{</span>
</span></span><span style="display:flex;"><span>        <span style="color:#75715e">// Initialize the API client with your credentials
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>        ApiClient apiClient <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> ApiClient<span style="color:#f92672">(</span><span style="color:#e6db74">&#34;YOUR_CLIENT_ID&#34;</span><span style="color:#f92672">,</span> <span style="color:#e6db74">&#34;YOUR_CLIENT_SECRET&#34;</span><span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>        MergerApi mergerApi <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> MergerApi<span style="color:#f92672">(</span>apiClient<span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">try</span> <span style="color:#f92672">{</span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// List of Word documents to combine
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>            List<span style="color:#f92672">&lt;</span>FileInfo<span style="color:#f92672">&gt;</span> sourceFiles <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> ArrayList<span style="color:#f92672">&lt;&gt;();</span>
</span></span><span style="display:flex;"><span>            sourceFiles<span style="color:#f92672">.</span><span style="color:#a6e22e">add</span><span style="color:#f92672">(</span><span style="color:#66d9ef">new</span> FileInfo<span style="color:#f92672">().</span><span style="color:#a6e22e">setFilePath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;input1.docx&#34;</span><span style="color:#f92672">));</span>
</span></span><span style="display:flex;"><span>            sourceFiles<span style="color:#f92672">.</span><span style="color:#a6e22e">add</span><span style="color:#f92672">(</span><span style="color:#66d9ef">new</span> FileInfo<span style="color:#f92672">().</span><span style="color:#a6e22e">setFilePath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;input2.docx&#34;</span><span style="color:#f92672">));</span>
</span></span><span style="display:flex;"><span>            sourceFiles<span style="color:#f92672">.</span><span style="color:#a6e22e">add</span><span style="color:#f92672">(</span><span style="color:#66d9ef">new</span> FileInfo<span style="color:#f92672">().</span><span style="color:#a6e22e">setFilePath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;input3.docx&#34;</span><span style="color:#f92672">));</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Configure merge options
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>            MergeOptions mergeOptions <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> MergeOptions<span style="color:#f92672">();</span>
</span></span><span style="display:flex;"><span>            mergeOptions<span style="color:#f92672">.</span><span style="color:#a6e22e">setOutputPath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;merged_output.docx&#34;</span><span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>            mergeOptions<span style="color:#f92672">.</span><span style="color:#a6e22e">setFileInfos</span><span style="color:#f92672">(</span>sourceFiles<span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Execute the merge operation
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>            FileInfo result <span style="color:#f92672">=</span> mergerApi<span style="color:#f92672">.</span><span style="color:#a6e22e">merge</span><span style="color:#f92672">(</span>mergeOptions<span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            System<span style="color:#f92672">.</span><span style="color:#a6e22e">out</span><span style="color:#f92672">.</span><span style="color:#a6e22e">println</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;Merge completed successfully. Output file: &#34;</span> <span style="color:#f92672">+</span> result<span style="color:#f92672">.</span><span style="color:#a6e22e">getFilePath</span><span style="color:#f92672">());</span>
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">}</span> <span style="color:#66d9ef">catch</span> <span style="color:#f92672">(</span>ApiException e<span style="color:#f92672">)</span> <span style="color:#f92672">{</span>
</span></span><span style="display:flex;"><span>            System<span style="color:#f92672">.</span><span style="color:#a6e22e">err</span><span style="color:#f92672">.</span><span style="color:#a6e22e">println</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;An error occurred while merging documents: &#34;</span> <span style="color:#f92672">+</span> e<span style="color:#f92672">.</span><span style="color:#a6e22e">getMessage</span><span style="color:#f92672">());</span>
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">}</span>
</span></span><span style="display:flex;"><span>    <span style="color:#f92672">}</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">}</span>
</span></span></code></pre></div><blockquote>
<p><strong>Note:</strong> This code example demonstrates the core functionality. Before using it in your project, make sure to update any file paths and configuration values to match your actual environment, verify that all required dependencies are properly installed, and test thoroughly in your development environment. If you encounter any issues, please refer to the <a href="https://docs.groupdocs.cloud/merger/">official documentation</a> or reach out to the <a href="https://forum.groupdocs.cloud/c/merger/18">support team</a> for assistance.</p>
</blockquote>
<h2 id="merge-word-files-via-rest-api-using-curl">Merge Word Files via REST API Using cURL</h2>
<p>If you prefer a pure REST approach, the same merge operation can be performed with cURL calls. The steps below show how to obtain an access token, upload source files, request the merge, and download the result.</p>
<p>Authenticate and obtain an access token:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/auth/token&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -d <span style="color:#e6db74">&#39;{&#34;client_id&#34;:&#34;YOUR_CLIENT_ID&#34;,&#34;client_secret&#34;:&#34;YOUR_CLIENT_SECRET&#34;}&#39;</span>
</span></span></code></pre></div><p>Upload each DOCX file to your cloud storage (replace <strong>YOUR_ACCESS_TOKEN</strong> with the token from the previous step):</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X PUT <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/file/input1.docx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Content-Type: application/vnd.openxmlformats-officedocument.wordprocessingml.document&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     --data-binary @input1.docx
</span></span></code></pre></div><p>Repeat the upload command for <code>input2.docx</code> and <code>input3.docx</code>.</p>
<p>Create the merge request:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/merger/merge&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -d <span style="color:#e6db74">&#39;{
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           &#34;outputPath&#34;:&#34;merged_output.docx&#34;,
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           &#34;fileInfos&#34;:[
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">               {&#34;filePath&#34;:&#34;input1.docx&#34;},
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">               {&#34;filePath&#34;:&#34;input2.docx&#34;},
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">               {&#34;filePath&#34;:&#34;input3.docx&#34;}
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           ]
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">         }&#39;</span>
</span></span></code></pre></div><p>Download the merged document:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X GET <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/file/merged_output.docx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -o merged_output.docx
</span></span></code></pre></div><p>For more details on request parameters, see the <a href="https://reference.groupdocs.cloud/merger/">official API documentation</a>.</p>
<h2 id="understanding-the-process-of-combining-word-documents-in-java">Understanding the Process of Combining Word Documents in Java</h2>
<p>Below is a step‑by‑step breakdown of the code shown earlier.</p>
<ol>
<li><strong>Create an ApiClient</strong> - <code>new ApiClient(&quot;YOUR_CLIENT_ID&quot;, &quot;YOUR_CLIENT_SECRET&quot;)</code> establishes a connection to the GroupDocs cloud service.
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span>ApiClient apiClient <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> ApiClient<span style="color:#f92672">(</span><span style="color:#e6db74">&#34;YOUR_CLIENT_ID&#34;</span><span style="color:#f92672">,</span> <span style="color:#e6db74">&#34;YOUR_CLIENT_SECRET&#34;</span><span style="color:#f92672">);</span>
</span></span></code></pre></div></li>
<li><strong>Instantiate MergerApi</strong> - <code>new MergerApi(apiClient)</code> gives access to merge‑related endpoints.
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span>MergerApi mergerApi <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> MergerApi<span style="color:#f92672">(</span>apiClient<span style="color:#f92672">);</span>
</span></span></code></pre></div></li>
<li><strong>Prepare source file list</strong> - Each <code>FileInfo</code> object points to a DOCX file stored in the cloud. The list is passed to <code>MergeOptions</code>.
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span>List<span style="color:#f92672">&lt;</span>FileInfo<span style="color:#f92672">&gt;</span> sourceFiles <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> ArrayList<span style="color:#f92672">&lt;&gt;();</span>
</span></span><span style="display:flex;"><span>sourceFiles<span style="color:#f92672">.</span><span style="color:#a6e22e">add</span><span style="color:#f92672">(</span><span style="color:#66d9ef">new</span> FileInfo<span style="color:#f92672">().</span><span style="color:#a6e22e">setFilePath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;input1.docx&#34;</span><span style="color:#f92672">));</span>
</span></span></code></pre></div></li>
<li><strong>Configure MergeOptions</strong> - Set the desired output path and attach the list of source files.
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span>MergeOptions mergeOptions <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> MergeOptions<span style="color:#f92672">();</span>
</span></span><span style="display:flex;"><span>mergeOptions<span style="color:#f92672">.</span><span style="color:#a6e22e">setOutputPath</span><span style="color:#f92672">(</span><span style="color:#e6db74">&#34;merged_output.docx&#34;</span><span style="color:#f92672">);</span>
</span></span><span style="display:flex;"><span>mergeOptions<span style="color:#f92672">.</span><span style="color:#a6e22e">setFileInfos</span><span style="color:#f92672">(</span>sourceFiles<span style="color:#f92672">);</span>
</span></span></code></pre></div></li>
<li><strong>Execute merge</strong> - <code>mergerApi.merge(mergeOptions)</code> sends the request and returns a <code>FileInfo</code> for the merged document.
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span>FileInfo result <span style="color:#f92672">=</span> mergerApi<span style="color:#f92672">.</span><span style="color:#a6e22e">merge</span><span style="color:#f92672">(</span>mergeOptions<span style="color:#f92672">);</span>
</span></span></code></pre></div></li>
</ol>
<p>For a full list of available properties, refer to the <a href="https://reference.groupdocs.cloud/merger/">API reference</a>.</p>
<h2 id="prerequisites-and-setup-for-groupdocsmerger-cloud-sdk">Prerequisites and Setup for GroupDocs.Merger Cloud SDK</h2>
<p>Before you can run the code, add the Maven dependency to your project and ensure you have a valid GroupDocs account.</p>
<p>Add the SDK to your <code>pom.xml</code>:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-xml" data-lang="xml"><span style="display:flex;"><span><span style="color:#f92672">&lt;dependency&gt;</span>
</span></span><span style="display:flex;"><span>    <span style="color:#f92672">&lt;groupId&gt;</span>com.groupdocs<span style="color:#f92672">&lt;/groupId&gt;</span>
</span></span><span style="display:flex;"><span>    <span style="color:#f92672">&lt;artifactId&gt;</span>groupdocs-merger-cloud<span style="color:#f92672">&lt;/artifactId&gt;</span>
</span></span><span style="display:flex;"><span>    <span style="color:#f92672">&lt;version&gt;</span>25.11<span style="color:#f92672">&lt;/version&gt;</span>
</span></span><span style="display:flex;"><span><span style="color:#f92672">&lt;/dependency&gt;</span>
</span></span></code></pre></div><p>Download the latest JARs and source from the <a href="https://releases.groupdocs.cloud/merger/java/">download page</a>.<br>
You will also need Java 8 or higher and internet access for the cloud calls.<br>
Create a GroupDocs account, obtain your <strong>Client ID</strong> and <strong>Client Secret</strong>, and keep them secure.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Merging DOCX files programmatically is now straightforward with the <a href="https://products.groupdocs.cloud/merger/java/">GroupDocs.Merger Cloud SDK for Java</a>. The example code and cURL snippets illustrate two flexible ways to combine multiple Word documents in Java, whether you prefer a native library or direct REST calls. Remember to configure your credentials, handle large files by streaming if needed, and test the merge operation with representative documents. For production deployments you will need a paid license; pricing details are available on the product page and you can request a temporary license for evaluation from the <a href="https://purchase.groupdocs.cloud/temporary-license/">temporary license page</a>.</p>
<h2 id="faqs">FAQs</h2>
<ul>
<li>
<p><strong>How do I combine multiple Word documents in Java without writing custom file‑handling code?</strong><br>
Use the <a href="https://products.groupdocs.cloud/merger/java/">GroupDocs.Merger Cloud SDK for Java</a>. The SDK abstracts all low‑level operations and lets you merge DOCX files with a few API calls.</p>
</li>
<li>
<p><strong>Is it possible to merge documents that are stored in different cloud folders?</strong><br>
Yes. Provide the full cloud file paths in the <code>FileInfo</code> objects, and the merge operation will fetch each file from its location before combining them.</p>
</li>
<li>
<p><strong>What should I do if the merge fails with an ApiException?</strong><br>
Check the exception message for details such as missing files or permission issues. Ensure the file paths are correct and that your account has read/write access to the storage. Consult the <a href="https://docs.groupdocs.cloud/merger/">official documentation</a> for error codes.</p>
</li>
<li>
<p><strong>Do I need a separate license for each environment (development, staging, production)?</strong><br>
A single license covers all environments, but you must respect the usage limits defined in your license agreement. For testing you can use the temporary license linked above.</p>
</li>
</ul>
<h2 id="read-more">Read More</h2>
<ul>
<li><a href="https://blog.groupdocs.cloud/merger/password-protect-zip-file-using-password-protection-software/">Password-Protect ZIP File using Password Protection Software</a></li>
<li><a href="https://blog.groupdocs.cloud/merger/password-protect-excel-using-password-protection-service/">Password-Protect Excel using Password Protection Service</a></li>
<li><a href="https://blog.groupdocs.cloud/merger/combine-word-documents-in-csharp/">Combine Word Documents in C#</a></li>
</ul>
]]></content:encoded>
    </item>
    
    <item>
      <title>Edit Powerpoint Presentations in C#</title>
      <link>https://blog-qa.groupdocs.cloud/editor/edit-powerpoint-presentations-in-csharp/</link>
      <pubDate>Wed, 09 Sep 2026 12:31:52 +0000</pubDate>
      
      <guid>https://blog-qa.groupdocs.cloud/editor/edit-powerpoint-presentations-in-csharp/</guid>
      <description>Edit PowerPoint presentations in C# using GroupDocs.Editor Cloud SDK for .NET. This guide covers setup, running code, cURL REST calls, and tweaks slide editing.</description>
      <content:encoded><![CDATA[<p>Editing PowerPoint presentations in C# is a frequent need for developers building dynamic slide decks. <a href="https://products.groupdocs.cloud/editor/net/">GroupDocs.Editor Cloud SDK for .NET</a> provides a powerful API that lets you modify <a href="https://docs.fileformat.com/presentation/pptx/">PPTX</a> files directly from your .NET application. In this guide you will learn how to set up the SDK, replace placeholder texts, run the edit operation, and fine‑tune options, plus see a full code sample and matching cURL REST workflow.</p>
<h2 id="what-powerpoint-automation-in-c-requires">What PowerPoint Automation in C# Requires</h2>
<p>Enterprises often generate slide decks from templates where titles, subtitles, or data fields need to be updated automatically. The requirements for a robust solution include:</p>
<ul>
<li>Ability to locate and replace specific text strings inside PPTX files.</li>
<li>Support for cloud‑based processing so the code runs on any server without installing Office.</li>
<li>Clear error handling and easy configuration of input and output paths.</li>
</ul>
<p>Manual editing or using generic file‑system scripts cannot guarantee consistency across dozens of presentations, especially when the content changes frequently.</p>
<h2 id="the-approach-cloudbased-powerpoint-editing">The Approach: Cloud‑Based PowerPoint Editing</h2>
<p><a href="https://products.groupdocs.cloud/editor/net/">GroupDocs.Editor Cloud SDK for .NET</a> addresses these needs with a REST‑driven API that works entirely in the cloud. Key capabilities include:</p>
<ul>
<li><strong>EditDocument</strong> - Replace text, images, or shapes in PPTX files without downloading the whole document.</li>
<li><strong>FileInfo</strong> - Specify source files stored in GroupDocs Cloud storage.</li>
<li><strong>EditDocumentOptions</strong> - Define output location and a list of text replacements.</li>
</ul>
<p>The SDK handles authentication, file streaming, and format‑preserving edits, allowing you to focus on business logic. Detailed documentation is available at the <a href="https://docs.groupdocs.cloud/editor/">official documentation</a>.</p>
<h2 id="implementing-edit-powerpoint-presentations-in-c-with-groupdocseditor-cloud">Implementing edit PowerPoint Presentations in C# with GroupDocs.Editor Cloud</h2>
<p>Below is a step‑by‑step walkthrough. Each step includes a short code excerpt taken directly from the full example.</p>
<h3 id="install-the-sdk-and-add-the-nuget-package">Install the SDK and Add the NuGet Package</h3>
<p>First, add the library to your project.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>dotnet add package GroupDocs.editor-Cloud
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>You can also download the latest release from the <a href="https://releases.groupdocs.cloud/editor/net/">download page</a>.</p>
<h3 id="configure-api-credentials">Configure API Credentials</h3>
<p>Create a <code>Configuration</code> object with your client ID and secret.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-csharp" data-lang="csharp"><span style="display:flex;"><span><span style="color:#66d9ef">var</span> config = <span style="color:#66d9ef">new</span> Configuration
</span></span><span style="display:flex;"><span>{
</span></span><span style="display:flex;"><span>    ClientId = <span style="color:#e6db74">&#34;YOUR_CLIENT_ID&#34;</span>,
</span></span><span style="display:flex;"><span>    ClientSecret = <span style="color:#e6db74">&#34;YOUR_CLIENT_SECRET&#34;</span>
</span></span><span style="display:flex;"><span>};
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>The <code>Configuration</code> class is described in the <a href="https://reference.groupdocs.cloud/editor/">API reference</a>.</p>
<h3 id="initialize-the-editor-api">Initialize the Editor API</h3>
<p>Instantiate <code>EditorApi</code> using the configuration.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-csharp" data-lang="csharp"><span style="display:flex;"><span><span style="color:#66d9ef">var</span> editorApi = <span style="color:#66d9ef">new</span> EditorApi(config);
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>This object provides all editing operations.</p>
<h3 id="define-editing-options-replace-placeholder-texts">Define Editing Options (Replace Placeholder Texts)</h3>
<p>Set the source file, output path, and the text replacements you need.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-csharp" data-lang="csharp"><span style="display:flex;"><span><span style="color:#66d9ef">var</span> editOptions = <span style="color:#66d9ef">new</span> EditDocumentOptions
</span></span><span style="display:flex;"><span>{
</span></span><span style="display:flex;"><span>    FileInfo = <span style="color:#66d9ef">new</span> FileInfo { FilePath = <span style="color:#e6db74">&#34;sample.pptx&#34;</span> },
</span></span><span style="display:flex;"><span>    OutputPath = <span style="color:#e6db74">&#34;sample_edited.pptx&#34;</span>,
</span></span><span style="display:flex;"><span>    EditTexts = <span style="color:#66d9ef">new</span> List&lt;EditText&gt;
</span></span><span style="display:flex;"><span>    {
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">new</span> EditText { Text = <span style="color:#e6db74">&#34;OldTitle&#34;</span>, NewText = <span style="color:#e6db74">&#34;New Title&#34;</span> },
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">new</span> EditText { Text = <span style="color:#e6db74">&#34;OldSubtitle&#34;</span>, NewText = <span style="color:#e6db74">&#34;Updated Subtitle&#34;</span> }
</span></span><span style="display:flex;"><span>    }
</span></span><span style="display:flex;"><span>};
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>The <code>EditTexts</code> collection lets you replace any number of placeholders in one call.</p>
<h3 id="execute-the-edit-operation-and-handle-the-response">Execute the Edit Operation and Handle the Response</h3>
<p>Create the request and call <code>EditDocument</code>.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-csharp" data-lang="csharp"><span style="display:flex;"><span><span style="color:#66d9ef">var</span> request = <span style="color:#66d9ef">new</span> EditDocumentRequest(editOptions);
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">var</span> response = editorApi.EditDocument(request);
</span></span><span style="display:flex;"><span>Console.WriteLine(<span style="color:#e6db74">$&#34;Edited PowerPoint saved to: {response.Path}&#34;</span>);
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>The response contains the path to the edited file in cloud storage.</p>
<h2 id="complete-code-example-edit-powerpoint-presentations-in-c---full-workflow">Complete Code Example: edit PowerPoint Presentations in C# - Full Workflow</h2>
<p>The following code demonstrates the entire process from start to finish.</p>
<!--[COMPLETE_CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-csharp" data-lang="csharp"><span style="display:flex;"><span><span style="color:#66d9ef">using</span> System;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">using</span> System.Collections.Generic;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">using</span> GroupDocs.Editor.Cloud.Sdk.Api;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">using</span> GroupDocs.Editor.Cloud.Sdk.Client;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">using</span> GroupDocs.Editor.Cloud.Sdk.Model;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">using</span> GroupDocs.Editor.Cloud.Sdk.Model.Requests;
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">namespace</span> GroupDocsEditorDemo
</span></span><span style="display:flex;"><span>{
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">class</span> <span style="color:#a6e22e">Program</span>
</span></span><span style="display:flex;"><span>    {
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">static</span> <span style="color:#66d9ef">void</span> Main(<span style="color:#66d9ef">string</span>[] args)
</span></span><span style="display:flex;"><span>        {
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Configure API credentials</span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">var</span> config = <span style="color:#66d9ef">new</span> Configuration
</span></span><span style="display:flex;"><span>            {
</span></span><span style="display:flex;"><span>                ClientId = <span style="color:#e6db74">&#34;YOUR_CLIENT_ID&#34;</span>,
</span></span><span style="display:flex;"><span>                ClientSecret = <span style="color:#e6db74">&#34;YOUR_CLIENT_SECRET&#34;</span>
</span></span><span style="display:flex;"><span>            };
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Initialize the Editor API</span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">var</span> editorApi = <span style="color:#66d9ef">new</span> EditorApi(config);
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Define input and output PowerPoint files</span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">string</span> inputFilePath = <span style="color:#e6db74">&#34;sample.pptx&#34;</span>;
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">string</span> outputFilePath = <span style="color:#e6db74">&#34;sample_edited.pptx&#34;</span>;
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Set up editing options (replace placeholder texts)</span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">var</span> editOptions = <span style="color:#66d9ef">new</span> EditDocumentOptions
</span></span><span style="display:flex;"><span>            {
</span></span><span style="display:flex;"><span>                FileInfo = <span style="color:#66d9ef">new</span> FileInfo { FilePath = inputFilePath },
</span></span><span style="display:flex;"><span>                OutputPath = outputFilePath,
</span></span><span style="display:flex;"><span>                EditTexts = <span style="color:#66d9ef">new</span> List&lt;EditText&gt;
</span></span><span style="display:flex;"><span>                {
</span></span><span style="display:flex;"><span>                    <span style="color:#66d9ef">new</span> EditText { Text = <span style="color:#e6db74">&#34;OldTitle&#34;</span>, NewText = <span style="color:#e6db74">&#34;New Title&#34;</span> },
</span></span><span style="display:flex;"><span>                    <span style="color:#66d9ef">new</span> EditText { Text = <span style="color:#e6db74">&#34;OldSubtitle&#34;</span>, NewText = <span style="color:#e6db74">&#34;Updated Subtitle&#34;</span> }
</span></span><span style="display:flex;"><span>                }
</span></span><span style="display:flex;"><span>            };
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#75715e">// Create the request</span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">var</span> request = <span style="color:#66d9ef">new</span> EditDocumentRequest(editOptions);
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">try</span>
</span></span><span style="display:flex;"><span>            {
</span></span><span style="display:flex;"><span>                <span style="color:#75715e">// Perform the edit operation</span>
</span></span><span style="display:flex;"><span>                <span style="color:#66d9ef">var</span> response = editorApi.EditDocument(request);
</span></span><span style="display:flex;"><span>                Console.WriteLine(<span style="color:#e6db74">$&#34;Edited PowerPoint saved to: {response.Path}&#34;</span>);
</span></span><span style="display:flex;"><span>            }
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">catch</span> (ApiException apiEx)
</span></span><span style="display:flex;"><span>            {
</span></span><span style="display:flex;"><span>                Console.WriteLine(<span style="color:#e6db74">$&#34;API error ({apiEx.ErrorCode}): {apiEx.Message}&#34;</span>);
</span></span><span style="display:flex;"><span>            }
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">catch</span> (Exception ex)
</span></span><span style="display:flex;"><span>            {
</span></span><span style="display:flex;"><span>                Console.WriteLine(<span style="color:#e6db74">$&#34;Unexpected error: {ex.Message}&#34;</span>);
</span></span><span style="display:flex;"><span>            }
</span></span><span style="display:flex;"><span>        }
</span></span><span style="display:flex;"><span>    }
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div><!--[COMPLETE_CODE_SNIPPET_END]-->
<blockquote>
<p><strong>Note:</strong> This code example demonstrates the core functionality. Before using it in your project, make sure to update any file paths and configuration values to match your actual environment, verify that all required dependencies are properly installed, and test thoroughly in your development environment. If you encounter any issues, please refer to the <a href="https://docs.groupdocs.cloud/editor/">official documentation</a> or reach out to the <a href="https://forum.groupdocs.cloud/c/editor/20">support team</a> for assistance.</p>
</blockquote>
<h2 id="powerpoint-editing-with-curl-and-the-rest-api">PowerPoint Editing with cURL and the REST API</h2>
<p>If you prefer a language‑agnostic approach, you can perform the same edit operation with cURL calls.</p>
<ol>
<li><strong>Authenticate and obtain an access token</strong></li>
</ol>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/auth/token&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -d <span style="color:#e6db74">&#39;{&#34;client_id&#34;:&#34;YOUR_CLIENT_ID&#34;,&#34;client_secret&#34;:&#34;YOUR_CLIENT_SECRET&#34;}&#39;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<ol start="2">
<li><strong>Upload the source PPTX file</strong></li>
</ol>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/upload/sample.pptx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -F <span style="color:#e6db74">&#34;file=@sample.pptx&#34;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<ol start="3">
<li><strong>Execute the edit operation</strong></li>
</ol>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/editor/edit&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -d <span style="color:#e6db74">&#39;{
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           &#34;fileInfo&#34;: { &#34;filePath&#34;: &#34;sample.pptx&#34; },
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           &#34;outputPath&#34;: &#34;sample_edited.pptx&#34;,
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           &#34;editTexts&#34;: [
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">               { &#34;text&#34;: &#34;OldTitle&#34;, &#34;newText&#34;: &#34;New Title&#34; },
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">               { &#34;text&#34;: &#34;OldSubtitle&#34;, &#34;newText&#34;: &#34;Updated Subtitle&#34; }
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">           ]
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">         }&#39;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<ol start="4">
<li><strong>Download the edited PPTX file</strong></li>
</ol>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X GET <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/download/sample_edited.pptx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>     -o sample_edited.pptx
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>For more details on request payloads, see the <a href="https://reference.groupdocs.cloud/editor/">API reference</a>.</p>
<h2 id="finetuning-powerpoint-editing-options">Fine‑Tuning PowerPoint Editing Options</h2>
<p>The SDK offers additional parameters you can adjust:</p>
<ul>
<li><strong>OutputPath</strong> - Choose a different folder or file name for the edited presentation.</li>
<li><strong>EditTexts</strong> - Add as many <code>EditText</code> objects as needed to replace multiple placeholders.</li>
<li><strong>FileInfo.StorageName</strong> - Specify a custom storage location if you use multiple cloud storages.</li>
</ul>
<p>These options are part of the <code>EditDocumentOptions</code> class referenced in the <a href="https://reference.groupdocs.cloud/editor/">API reference</a>.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Editing PowerPoint presentations in C# becomes straightforward with the GroupDocs.Editor Cloud SDK for .NET. The library handles authentication, file management, and text replacement, letting you focus on business logic. Remember to obtain a proper license for production use; you can start with a temporary license from the <a href="https://purchase.groupdocs.cloud/temporary-license/">temporary license page</a>. With the code sample and cURL workflow provided, you&rsquo;re ready to integrate dynamic slide editing into any .NET application.</p>
<h2 id="faqs">FAQs</h2>
<p><strong>How do I edit Powerpoint presentations in C# using GroupDocs.Editor Cloud?</strong><br>
Use the <code>EditDocument</code> method after configuring <code>EditDocumentOptions</code> with your source file, output path, and a list of <code>EditText</code> replacements. The full example is shown earlier in this guide.</p>
<p><strong>Can I replace multiple placeholders in a single PowerPoint file?</strong><br>
Yes. Populate the <code>EditTexts</code> collection with as many <code>EditText</code> objects as required; the SDK will process all replacements in one request.</p>
<p><strong>What should I do if the edited file is not generated?</strong><br>
Check that <code>OutputPath</code> is correctly set and that the API response contains a valid <code>Path</code>. Also verify your credentials and storage permissions via the GroupDocs portal.</p>
<p><strong>Do I need a license for production deployments?</strong><br>
A valid license is required for production. You can obtain a temporary license from the <a href="https://purchase.groupdocs.cloud/temporary-license/">temporary license page</a> while evaluating the SDK.</p>
<h2 id="read-more">Read More</h2>
<ul>
<li><a href="https://blog.groupdocs.cloud/editor/edit-powerpoint-presentations-using-python/">Edit PowerPoint Presentations using Python</a></li>
<li><a href="https://blog.groupdocs.cloud/editor/edit-powerpoint-files-using-java-library/">Edit PowerPoint Files Using Java Library</a></li>
<li><a href="https://blog.groupdocs.cloud/editor/best-practices-for-csv-editor-development-in-java/">Best Practices for CSV Editor Development in Java</a></li>
</ul>
]]></content:encoded>
    </item>
    
    <item>
      <title>How to Combine Multiple Word Documents in Node.JS</title>
      <link>https://blog-qa.groupdocs.cloud/merger/how-to-combine-multiple-word-documents-in-nodejs/</link>
      <pubDate>Wed, 19 Aug 2026 10:37:27 +0000</pubDate>
      
      <guid>https://blog-qa.groupdocs.cloud/merger/how-to-combine-multiple-word-documents-in-nodejs/</guid>
      <description>Learn how to combine Word documents in Node.JS with GroupDocs.Merger Cloud SDK. This guide provides code, cURL examples, and setup steps for easy merging.</description>
      <content:encoded><![CDATA[<p>Many developers need to combine multiple Word documents in Node.JS to generate consolidated reports or packages. <a href="https://products.groupdocs.cloud/merger/nodejs/">GroupDocs.Merger Cloud SDK for Node.js</a> provides a powerful API that handles Word merging on the server side without complex file‑handling code. In this guide you will see a complete implementation, equivalent cURL calls, installation steps, and best‑practice tips to get your documents merged quickly.</p>
<h2 id="combine-multiple-word-documents-in-nodejs---complete-code-example">Combine Multiple Word Documents in Node.JS - Complete Code Example</h2>
<p>This example demonstrates how to merge three <a href="https://docs.fileformat.com/word-processing/docx/">DOCX</a> files into a single document using the GroupDocs.Merger Cloud SDK for Node.js.</p>
<!--[COMPLETE_CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span> <span style="color:#f92672">=</span> <span style="color:#a6e22e">require</span>(<span style="color:#e6db74">&#34;@groupdocs/merger-cloud&#34;</span>);
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#75715e">// ==== Configuration ====
</span></span></span><span style="display:flex;"><span><span style="color:#75715e">// Replace with your actual credentials
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">clientId</span> <span style="color:#f92672">=</span> <span style="color:#e6db74">&#34;YOUR_CLIENT_ID&#34;</span>;
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">clientSecret</span> <span style="color:#f92672">=</span> <span style="color:#e6db74">&#34;YOUR_CLIENT_SECRET&#34;</span>;
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">config</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Configuration</span>(<span style="color:#a6e22e">clientId</span>, <span style="color:#a6e22e">clientSecret</span>);
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">mergeApi</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">MergeApi</span>(<span style="color:#a6e22e">config</span>);
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#75715e">// ==== Input / Output paths ====
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">inputFiles</span> <span style="color:#f92672">=</span> [
</span></span><span style="display:flex;"><span>    <span style="color:#e6db74">&#34;documents/input1.docx&#34;</span>,
</span></span><span style="display:flex;"><span>    <span style="color:#e6db74">&#34;documents/input2.docx&#34;</span>,
</span></span><span style="display:flex;"><span>    <span style="color:#e6db74">&#34;documents/input3.docx&#34;</span>
</span></span><span style="display:flex;"><span>];
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">outputFile</span> <span style="color:#f92672">=</span> <span style="color:#e6db74">&#34;documents/combined_output.docx&#34;</span>;
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#75715e">// ==== Build request ====
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">documentEntries</span> <span style="color:#f92672">=</span> <span style="color:#a6e22e">inputFiles</span>.<span style="color:#a6e22e">map</span>(<span style="color:#a6e22e">path</span> =&gt; {
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">return</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">DocumentEntry</span>({
</span></span><span style="display:flex;"><span>        <span style="color:#a6e22e">fileInfo</span><span style="color:#f92672">:</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">FileInfo</span>({
</span></span><span style="display:flex;"><span>            <span style="color:#a6e22e">filePath</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">path</span>
</span></span><span style="display:flex;"><span>        })
</span></span><span style="display:flex;"><span>    });
</span></span><span style="display:flex;"><span>});
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">mergeRequest</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">MergeDocumentsRequest</span>({
</span></span><span style="display:flex;"><span>    <span style="color:#a6e22e">documents</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">documentEntries</span>,
</span></span><span style="display:flex;"><span>    <span style="color:#a6e22e">outputPath</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">outputFile</span>
</span></span><span style="display:flex;"><span>});
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#75715e">// ==== Execute merge ====
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>(<span style="color:#66d9ef">async</span> () =&gt; {
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">try</span> {
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">const</span> <span style="color:#a6e22e">result</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">await</span> <span style="color:#a6e22e">mergeApi</span>.<span style="color:#a6e22e">mergeDocuments</span>(<span style="color:#a6e22e">mergeRequest</span>);
</span></span><span style="display:flex;"><span>        <span style="color:#a6e22e">console</span>.<span style="color:#a6e22e">log</span>(<span style="color:#e6db74">`Merge completed successfully. Output file: </span><span style="color:#e6db74">${</span><span style="color:#a6e22e">result</span>.<span style="color:#a6e22e">path</span><span style="color:#e6db74">}</span><span style="color:#e6db74">`</span>);
</span></span><span style="display:flex;"><span>    } <span style="color:#66d9ef">catch</span> (<span style="color:#a6e22e">error</span>) {
</span></span><span style="display:flex;"><span>        <span style="color:#a6e22e">console</span>.<span style="color:#a6e22e">error</span>(<span style="color:#e6db74">&#34;Error during merging:&#34;</span>, <span style="color:#a6e22e">error</span>);
</span></span><span style="display:flex;"><span>    }
</span></span><span style="display:flex;"><span>})();
</span></span></code></pre></div><!--[COMPLETE_CODE_SNIPPET_END]-->
<blockquote>
<p><strong>Note:</strong> This code example demonstrates the core functionality. Before using it in your project, make sure to update the file paths (<code>input1.docx</code>, <code>combined_output.docx</code>, etc.) to match your actual file locations, verify that all required dependencies are properly installed, and test thoroughly in your development environment. If you encounter any issues, please refer to the <a href="https://docs.groupdocs.cloud/merger/">official documentation</a> or reach out to the <a href="https://forum.groupdocs.cloud/c/merger/18">support team</a> for assistance.</p>
</blockquote>
<h2 id="merging-word-documents-via-rest-api-using-curl">Merging Word Documents via REST API Using cURL</h2>
<p>If you prefer a pure REST approach, the same merge operation can be performed with cURL commands. Below is a concise workflow that authenticates, uploads source files, runs the merge, and downloads the result.</p>
<h3 id="1-authenticate-and-get-access-token">1. Authenticate and Get Access Token</h3>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/merger/authenticate&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-d <span style="color:#e6db74">&#39;{&#34;client_id&#34;:&#34;YOUR_CLIENT_ID&#34;,&#34;client_secret&#34;:&#34;YOUR_CLIENT_SECRET&#34;}&#39;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>The response contains an <code>access_token</code> used in subsequent calls.</p>
<h3 id="2-upload-the-source-files">2. Upload the Source Files</h3>
<p>Repeat this step for each DOCX file you want to merge.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/file/upload?path=documents/input1.docx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Content-Type: application/octet-stream&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>--data-binary <span style="color:#e6db74">&#34;@path/to/input1.docx&#34;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<h3 id="3-execute-the-merge-operation">3. Execute the Merge Operation</h3>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X POST <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/merger/merge&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Content-Type: application/json&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-d <span style="color:#e6db74">&#39;{
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    &#34;documents&#34;: [
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">        {&#34;fileInfo&#34;: {&#34;filePath&#34;: &#34;documents/input1.docx&#34;}},
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">        {&#34;fileInfo&#34;: {&#34;filePath&#34;: &#34;documents/input2.docx&#34;}},
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">        {&#34;fileInfo&#34;: {&#34;filePath&#34;: &#34;documents/input3.docx&#34;}}
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    ],
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    &#34;outputPath&#34;: &#34;documents/combined_output.docx&#34;
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">}&#39;</span>
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>The API returns the path of the merged file.</p>
<h3 id="4-download-the-merged-document">4. Download the Merged Document</h3>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>curl -X GET <span style="color:#e6db74">&#34;https://api.groupdocs.cloud/v2.0/storage/file/download?path=documents/combined_output.docx&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-H <span style="color:#e6db74">&#34;Authorization: Bearer YOUR_ACCESS_TOKEN&#34;</span> <span style="color:#ae81ff">\
</span></span></span><span style="display:flex;"><span><span style="color:#ae81ff"></span>-o combined_output.docx
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
<p>For more details on request payloads and options, see the <a href="https://docs.groupdocs.cloud/merger/">official API documentation</a>.</p>
<h2 id="how-merge-multiple-word-documents-in-nodejs-works">How Merge Multiple Word Documents in Node.JS Works</h2>
<p>The SDK abstracts the merge process into a few logical steps:</p>
<ol>
<li>
<p><strong>Configuration Creation</strong> - <code>new GroupDocsMergerCloud.Configuration(clientId, clientSecret)</code> builds the authentication context. See the class reference in the <a href="https://reference.groupdocs.cloud/merger/">API Reference</a>.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">config</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Configuration</span>(<span style="color:#a6e22e">clientId</span>, <span style="color:#a6e22e">clientSecret</span>);
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
</li>
<li>
<p><strong>API Instance</strong> - <code>new GroupDocsMergerCloud.MergeApi(config)</code> provides access to merge operations.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">mergeApi</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">MergeApi</span>(<span style="color:#a6e22e">config</span>);
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
</li>
<li>
<p><strong>Document Entries</strong> - Each source file is wrapped in a <code>DocumentEntry</code> that contains a <code>FileInfo</code> with the file path.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">documentEntries</span> <span style="color:#f92672">=</span> <span style="color:#a6e22e">inputFiles</span>.<span style="color:#a6e22e">map</span>(<span style="color:#a6e22e">path</span> =&gt; {
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">return</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">DocumentEntry</span>({
</span></span><span style="display:flex;"><span>        <span style="color:#a6e22e">fileInfo</span><span style="color:#f92672">:</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">FileInfo</span>({ <span style="color:#a6e22e">filePath</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">path</span> })
</span></span><span style="display:flex;"><span>    });
</span></span><span style="display:flex;"><span>});
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
</li>
<li>
<p><strong>Merge Request</strong> - <code>MergeDocumentsRequest</code> bundles the entries and the desired output path.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">mergeRequest</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">new</span> <span style="color:#a6e22e">GroupDocsMergerCloud</span>.<span style="color:#a6e22e">Models</span>.<span style="color:#a6e22e">MergeDocumentsRequest</span>({
</span></span><span style="display:flex;"><span>    <span style="color:#a6e22e">documents</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">documentEntries</span>,
</span></span><span style="display:flex;"><span>    <span style="color:#a6e22e">outputPath</span><span style="color:#f92672">:</span> <span style="color:#a6e22e">outputFile</span>
</span></span><span style="display:flex;"><span>});
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
</li>
<li>
<p><strong>Execution</strong> - <code>mergeApi.mergeDocuments(mergeRequest)</code> sends the request to the cloud service. The promise resolves with a result object containing the output file path.</p>
<!--[CODE_SNIPPET_START]-->
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#66d9ef">const</span> <span style="color:#a6e22e">result</span> <span style="color:#f92672">=</span> <span style="color:#66d9ef">await</span> <span style="color:#a6e22e">mergeApi</span>.<span style="color:#a6e22e">mergeDocuments</span>(<span style="color:#a6e22e">mergeRequest</span>);
</span></span><span style="display:flex;"><span><span style="color:#a6e22e">console</span>.<span style="color:#a6e22e">log</span>(<span style="color:#e6db74">`Merge completed successfully. Output file: </span><span style="color:#e6db74">${</span><span style="color:#a6e22e">result</span>.<span style="color:#a6e22e">path</span><span style="color:#e6db74">}</span><span style="color:#e6db74">`</span>);
</span></span></code></pre></div><!--[CODE_SNIPPET_END]-->
</li>
</ol>
<p>These steps together enable you to combine multiple Word documents efficiently without handling low‑level file streams.</p>
<h2 id="getting-the-environment-ready-for-groupdocsmerger">Getting the Environment Ready for GroupDocs.Merger</h2>
<ol>
<li>
<p><strong>Install the SDK</strong></p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>npm install groupdocs-merger-cloud
</span></span></code></pre></div><p>The package is available from the official <a href="https://releases.groupdocs.cloud/merger/nodejs/">download page</a>.</p>
</li>
<li>
<p><strong>Node.js Version</strong> - Ensure you are running Node.js 12 or later.</p>
</li>
<li>
<p><strong>Configure Credentials</strong> - Replace <code>YOUR_CLIENT_ID</code> and <code>YOUR_CLIENT_SECRET</code> in the code with the values from your GroupDocs Cloud account.</p>
</li>
<li>
<p><strong>Create a Project Folder</strong> - Place the source DOCX files in a <code>documents/</code> subfolder as shown in the example.</p>
</li>
</ol>
<p>With these steps completed, you are ready to run the merge script or invoke the REST endpoints.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Combining multiple Word documents in Node.JS becomes straightforward with the <a href="https://products.groupdocs.cloud/merger/nodejs/">GroupDocs.Merger Cloud SDK for Node.js</a>. The SDK handles file uploads, merging logic, and output generation, allowing you to focus on business logic rather than low‑level file manipulation. Remember to secure a proper license for production use; you can start with a <a href="https://purchase.groupdocs.cloud/temporary-license/">temporary license</a> and upgrade to a full subscription as your needs grow. Start merging today and streamline your document workflows.</p>
<h2 id="faqs">FAQs</h2>
<ul>
<li>
<p><strong>How do I combine multiple Word documents in Node.JS using the SDK?</strong><br>
Use the <code>MergeApi</code> class to create a <code>MergeDocumentsRequest</code> that lists each DOCX file as a <code>DocumentEntry</code>. The SDK merges them in the order provided and saves the result to the specified output path.</p>
</li>
<li>
<p><strong>Is it possible to merge PDFs together with the same SDK?</strong><br>
Yes, the Merger SDK supports <a href="https://docs.fileformat.com/pdf">PDF</a>, DOCX, <a href="https://docs.fileformat.com/word-processing/odt/">ODT</a>, and several other formats. Simply change the file extensions in the <code>inputFiles</code> array and the SDK will handle the conversion automatically. See the <a href="https://docs.groupdocs.cloud/merger/">official documentation</a> for format details.</p>
</li>
<li>
<p><strong>What are the limits on the number of documents I can merge in a single request?</strong><br>
The cloud service imposes a size limit rather than a strict count. As long as the combined size stays within your account&rsquo;s quota, you can merge dozens of files. For very large batches, consider uploading files to GroupDocs storage first and referencing them by ID.</p>
</li>
<li>
<p><strong>Do I need to worry about licensing for development versus production?</strong><br>
Development and testing can use a temporary license obtained from the <a href="https://purchase.groupdocs.cloud/temporary-license/">temporary license page</a>. For production deployments, purchase a full license to unlock unlimited merges and priority support.</p>
</li>
</ul>
<h2 id="read-more">Read More</h2>
<ul>
<li><a href="https://blog.groupdocs.cloud/merger/password-protect-zip-file-using-password-protection-software/">Password-Protect ZIP File using Password Protection Software</a></li>
<li><a href="https://blog.groupdocs.cloud/merger/password-protect-excel-using-password-protection-service/">Password-Protect Excel using Password Protection Service</a></li>
<li><a href="https://blog.groupdocs.cloud/merger/combine-word-documents-in-csharp/">Combine Word Documents in C#</a></li>
</ul>
]]></content:encoded>
    </item>
    
  </channel>
</rss>
