Create or Edit Salesforce data with custom form
The Submit Salesforce Form Workflow Step can be used to create or edit Salesforce record data in a custom modal form. This step uses the Salesforce Connection of the user who runs the Workflow Step or as a fixed Automation User as indicated when saving the Step. This allows Slack internal or external users (via Slack connect) to modify Salesforce data even if they do not have a login to Salesforce by utilizing the Automation user connection. Warning: this will allow any workflow user to create/edit data in Salesforce as the specified Salesforce user. If the form contains a lookup field the workflow user will be able to search and view the names of internal records using the sharing rules of the connected Salesforce user.
The Submit Salesforce Form step will send a user an ephemeral message only they can see (shown above) allowing the user to edit and submit data in a modal form by clicking the message "Open Form" button. The fields that are displayed to the user are configurable when editing the step. Fields may be displayed to the user, or they can be hidden from the user to set a field value to a default (i.e. for a Record Type or Status field).
Add fields using the "Add Field" picker in the workflow step and move fields in the order they should be displayed or move fields to bottom to hide the field. Set default values for fields by inserting Workflow variables or specifying a constant value using the appropriate data-type formatting. Date fields should be formatted using ISO 8601 format, Picklists should use appropriate API names, lookups should specify a Salesforce Record Id of expected type, and strings and numbers should be in a format they can be parsed to expected length and type.
Editing existing records and specifying hidden values
To edit an existing Salesforce Record, specify the Record Id value as a hidden field by adding the field and moving it to the bottom of the Workflow step modal. When the Record Id is specified, values will be populated using the existing Salesforce data unless overridden in the Workflow step by a variable. Specifying a Record Type by adding the RecordType field as a hidden value enables Record Type specific Picklist values to be respected.