Combine PDFs
Purpose
Using this API, you will be able to combine two PDF documents.
HTTP Request URL
https://{api.office-integrator_domain}/writer/officeapi/v1/documents/pdf/combine
Body Parameters
Parameter | Data Type | Description |
Mandatory Parameters | ||
apikey | 423s***** | Uniquely identifies the web application which initiates the document combine request. |
files | File | To upload the input files from your local drive or desktop. Note:
|
Optional Parameters | ||
output_settings | { | Specify a unique name for the merged or combined output file . By default, the output file name will be "output.pdf". |
input_options | { | It is possible to combine selected pages or a specific range pages in a document. To combine selectedpages, you will have to pass the respective page numbers with comma separated (say 3,5,7,etc.,). To combine a specific range of pages, you will have to pass the page ranges with a hypen (say 1-3). |
Sample Request
Copiedcurl --location --request POST "https://api.office-integrator.com/writer/officeapi/v1/documents/pdf/combine?apikey=423s*****" \
--header "content-type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW" \
--form 'output_settings="{\"name\":\"CombinedFile.pdf\"}"' \
--form 'files=@"/Users/username/Documents/Sample1.pdf"' \
--form 'files=@"/Users/username/Documents/Sample2.pdf"' \
--form 'input_options="{\"1\":{\"page_ranges\":\"3,5,6\"},\"2\":{\"page_ranges\":\"1-3,6\"}}"'