# DestinationPDF

Export the automation's output to PDF into a Drive folder (converter).

What gets converted depends on the automation's other destinations: with a
`document` destination the generated documents are converted; with a file
destination the file written by the automation is converted; with neither,
the automation's source files are.

Type: object

Fields typed as another model are documented on that model's page; fetch it before filling the field.

| Field | Type | Required | Description | Allowed values / default / constraints |
| --- | --- | --- | --- | --- |
| `type` | string | yes | Generates a **PDF** per row, by converting the merged document. | const: `"pdf"` |
| `provider` | string | no | Storage provider. Generated documents and PDFs are Google Drive only. | const: `"drive"`; default: `"drive"` |
| `id` | string, nullable | no | Id of an existing folder to write into. Provide this or `folder_name`. |  |
| `folder_name` | string, nullable | no | Name of a new folder to create instead of using an existing one. Provide this or `id`. |  |
| `parent_id` | string, nullable | no | Folder to create `folder_name` inside. Defaults to the drive root. Only valid together with `folder_name`. |  |
| `paper_size` | [PaperSize](https://dev-api.sheetgo.com/rest/reference/models/PaperSize.md) | no | Page size of the generated PDF. | default: `"letter"` |
| `page_orientation` | [PageOrientation](https://dev-api.sheetgo.com/rest/reference/models/PageOrientation.md) | no | Page orientation of the generated PDF. | default: `"portrait"` |
| `scale` | integer | no | Fit-to-page scaling: 1 normal, 2 fit to width, 3 fit to height, 4 fit to page. | one of: `1`, `2`, `3`, `4`; default: `1` |
| `merge_files` | boolean | no | Combine every generated PDF into a single file. | default: `false` |

## Used by

- [GET /rest/beta/automations/](https://dev-api.sheetgo.com/rest/reference/automations.md#get-rest-beta-automations)
- [GET /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#get-rest-beta-automations-id)
- [GET /rest/beta/workflows/](https://dev-api.sheetgo.com/rest/reference/workflows.md#get-rest-beta-workflows)
- [GET /rest/beta/workflows/{id}](https://dev-api.sheetgo.com/rest/reference/workflows.md#get-rest-beta-workflows-id)
- [PATCH /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#patch-rest-beta-automations-id)
- [PATCH /rest/beta/workflows/{id}](https://dev-api.sheetgo.com/rest/reference/workflows.md#patch-rest-beta-workflows-id)
- [POST /rest/beta/automations/](https://dev-api.sheetgo.com/rest/reference/automations.md#post-rest-beta-automations)
- [POST /rest/beta/workflows/](https://dev-api.sheetgo.com/rest/reference/workflows.md#post-rest-beta-workflows)
- [PUT /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#put-rest-beta-automations-id)
- [AutomationCreate](https://dev-api.sheetgo.com/rest/reference/models/AutomationCreate.md)
- [AutomationModel](https://dev-api.sheetgo.com/rest/reference/models/AutomationModel.md)
- [AutomationReplace](https://dev-api.sheetgo.com/rest/reference/models/AutomationReplace.md)
- [WorkflowAutomationModel](https://dev-api.sheetgo.com/rest/reference/models/WorkflowAutomationModel.md)

---

More: start page https://dev-api.sheetgo.com/rest/reference.md, everything in one file https://dev-api.sheetgo.com/rest/llms-full.txt, OpenAPI https://dev-api.sheetgo.com/rest/openapi.json.
