Summary Retrieve a resource or its URL by ID. Resource IDs can be found in the JSON response of POST requests.
Examples curl -X GET "YOUR_DOMAIN_HERE/resource/0950b9bdf-0465-4d3f-8ea3-d2894f1ae839?format=file" --output "@PATH_TO_FILE/output_file.pdf"
curl -X GET "YOUR_DOMAIN_HERE/resource/112f7ea0d-0e56-44bc-a3d2-42fdff96d993?format=url"
Path Parameters
Name | Description | Default | Required |
id | Alphanumeric ID (UUID) of the resource to return
Accepts: Any valid resource ID returned by a POST request
Example: 0950b9bdf-0465-4d3f-8ea3-d2894f1ae839 | None | Yes |
format | Specify whether to return the file directly, URL to the file, or information about the file
Accepts:
- file - return the file itself
- url - return JSON containing the URL of the resource file
- info - return JSON containing detailed information about the file:
- resource ID
- file name
- url
- file type
- file size (bytes)
- last modified datetime
| None | Yes |
Responses
Response Status Code | Description | JSON Response Example |
200 | OK | {
"url": "YOUR_DOMAIN_HERE/resource/0950b9bdf-0465-4d3f-8ea3-d2894f1ae839?format=file" } |
200 | OK (format = info) | { "id":"2e523af74-7de9-492a-b7c6-c96eacd18a3a", "name":"smallword.doc", "url":"YOUR_DOMAIN_HERE/resource/2e523af74-7de9-492a-b7c6-c96eacd18a3a?format=file", "type":"application/msword", "size":22528, "modified":"2023-05-19T16:22:56.780Z" } |
400 | Bad Request | {
"error": "Invalid Request" } |
404 | Not Found | {
"error": "That file does not exist" } |
Summary Converts a PDF to a Microsoft Word document
Examples curl -X POST "YOUR_DOMAIN_HERE/word" -H "Accept: application/json" -H "Content-Type: multipart/form-data" -F "file=@/path/to/file"
curl -X POST "YOUR_DOMAIN_HERE/word" -H "accept: application/json" -H "Content-Type: multipart/form-data" -F "id=0950b9bdf-0465-4d3f-8ea3-d2894f1ae839" -F "output=example_output"
Required Headers Accept: application/json
Content-Type: multipart/form-data
Body Parameters
Name | Description | Default | Required |
file | File to be uploaded and processed
Accepts: Any PDF file
Example: @PATH_TO_FILE/example_file.pdf | None | One of: |
id | Alphanumeric ID (UUID) of existing file on server to be processed
Accepts: Any valid resource ID returned by a POST request
Example: 0950b9bdf-0465-4d3f-8ea3-d2894f1ae839 | None | One of: |
output | Name of the generated output file, without extension
Accepts: Any valid file name
Example: example_out | [INPUT_FILE_NAME]_pdfrest_word | No |
Responses
Response Status Code | Description | JSON Response Example |
200 | OK | {
"outputUrl": "YOUR_DOMAIN_HERE/resource/01240b25a-8936-4437-8652-8410130f1199?format=file"
"outputId": "01240b25a-8936-4437-8652-8410130f1199"
"inputId": "112f7ea0d-0e56-44bc-a3d2-42fdff96d993" } |
400 | Bad Request | {
"error": "This route will only accept a File or an ID, not both." } |
Summary Converts a PDF to a Microsoft Excel document
Examples curl -X POST "YOUR_DOMAIN_HERE/excel" -H "Accept: application/json" -H "Content-Type: multipart/form-data" -F "file=@/path/to/file"
curl -X POST "YOUR_DOMAIN_HERE/excel" -H "accept: application/json" -H "Content-Type: multipart/form-data" -F "id=0950b9bdf-0465-4d3f-8ea3-d2894f1ae839" -F "output=example_output"
Required Headers Accept: application/json
Content-Type: multipart/form-data
Body Parameters
Name | Description | Default | Required |
file | File to be uploaded and processed
Accepts: Any PDF file
Example: @PATH_TO_FILE/example_file.pdf | None | One of: |
id | Alphanumeric ID (UUID) of existing file on server to be processed
Accepts: Any valid resource ID returned by a POST request
Example: 0950b9bdf-0465-4d3f-8ea3-d2894f1ae839 | None | One of: |
output | Name of the generated output file, without extension
Accepts: Any valid file name
Example: example_out | [INPUT_FILE_NAME]_pdfrest_excel | No |
Responses
Response Status Code | Description | JSON Response Example |
200 | OK | {
"outputUrl": "YOUR_DOMAIN_HERE/resource/01240b25a-8936-4437-8652-8410130f1199?format=file"
"outputId": "01240b25a-8936-4437-8652-8410130f1199"
"inputId": "112f7ea0d-0e56-44bc-a3d2-42fdff96d993" } |
400 | Bad Request | {
"error": "This route will only accept a File or an ID, not both." } |
Summary Converts a PDF to a Microsoft PowerPoint document
Examples curl -X POST "YOUR_DOMAIN_HERE/powerpoint" -H "Accept: application/json" -H "Content-Type: multipart/form-data" -F "file=@/path/to/file"
curl -X POST "YOUR_DOMAIN_HERE/powerpoint" -H "accept: application/json" -H "Content-Type: multipart/form-data" -F "id=0950b9bdf-0465-4d3f-8ea3-d2894f1ae839" -F "output=example_output"
Required Headers Accept: application/json
Content-Type: multipart/form-data
Body Parameters
Name | Description | Default | Required |
file | File to be uploaded and processed
Accepts: Any PDF file
Example: @PATH_TO_FILE/example_file.pdf | None | One of: |
id | Alphanumeric ID (UUID) of existing file on server to be processed
Accepts: Any valid resource ID returned by a POST request
Example: 0950b9bdf-0465-4d3f-8ea3-d2894f1ae839 | None | One of: |
output | Name of the generated output file, without extension
Accepts: Any valid file name
Example: example_out | [INPUT_FILE_NAME]_pdfrest_powerpoint | No |
Responses
Response Status Code | Description | JSON Response Example |
200 | OK | {
"outputUrl": "YOUR_DOMAIN_HERE/resource/01240b25a-8936-4437-8652-8410130f1199?format=file"
"outputId": "01240b25a-8936-4437-8652-8410130f1199"
"inputId": "112f7ea0d-0e56-44bc-a3d2-42fdff96d993" } |
400 | Bad Request | {
"error": "This route will only accept a File or an ID, not both." } |