Upload attachment
Upload a local file and link it to a record as a Salesforce File, or upload it as a new version of an existing file.
Command in the Salesforce toolkit · id ooa.salesforce/upload_attachment · 9 inputs (1 required), 2 outputs
Inputs
| Input | Type | Required | Default | What it is |
|---|---|---|---|---|
| Instance address (URL) | String | No | Instance URL, e.g. https://yourcompany.my.salesforce.com. | |
| Access token | Credential | No | OAuth access token from the vault. Or leave it empty and choose a connection that signs in, which gets and renews the token. | |
| Record ID | String | No | Id of the record to attach the file to. Not needed when content_document_id is filled in. | |
| Path | File | Yes | File to upload. | |
| Title | String | No | Title shown in Salesforce; the file name when empty. | |
| API version | String | No | v61.0 | REST API version. |
| Visibility | String | No | Who can see the file on the record (AllUsers includes community users); Salesforce's default when empty, AllUsers for new steps. Not used for a new version, which keeps the file's sharing (G6). | |
| Description | String | No | Description stored with the file. | |
| Content document ID | String | No | Id of an existing file (starts with 069); the upload becomes its new version and keeps the file's links and sharing. |
Outputs
| Output | Type | What it is |
|---|---|---|
| content_version_id | String | Id of the new file version. |
| content_document_id | String | Id of the file itself (filled when visibility or content_document_id is set). |