Link File to Record
salesforce.link_file
ActionCRM & salesconnection required
Calls the Salesforce REST API at the connection's instance URL.
Share an uploaded file with a record by creating a ContentDocumentLink.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- OAuth 2.0
- Providers
- Salesforce
- Secret shape
- {"client_id", "client_secret", "refresh_token"}
- Config it needs
- login_url, api_version
- Resolved by
- config.connection_id, else node.connection_id
Configuration
4 fields, 2 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
content_document_id ContentDocumentId from salesforce.upload_file. Supports {{ }}. | string | Yes | — | — | — |
linked_entity_id Id of the record (Account, Case, custom object…) to attach the file to. | string | Yes | — | — | — |
share_type V = viewer, C = collaborator, I = permission inferred from the record. | string | No | V | one of "V", "C", "I" | — |
visibility Who can see the link. | string | No | AllUsers | one of "AllUsers", "InternalUsers", "SharedUsers" | — |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"share_type": "V",
"visibility": "AllUsers"
}Output
One shape.
result
| Field | Type | Example |
|---|---|---|
id The new ContentDocumentLink id. | string | — |
content_document_id The file that was linked. | string | — |
linked_entity_id The record it was linked to. | string | — |
success True when Salesforce accepted the link. | boolean | — |
{
"content_document_id": "",
"id": "",
"linked_entity_id": "",
"success": false
}Notes
- Linking the same document to the same record twice is a duplicate-value error.
Templates that use Salesforce
Solutions with Salesforce
See Link File to Record run in a workflow.
In a technical demo we add the Salesforce connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.