The Create Folder smart service allows you to create a folder to store files within the Appian file system. The Modify Folder Security Smart Service allows you to specify user rights for the folder.
To use the
Create Folder smart service, select the activity and drag it onto the canvas to add it to your process model.
The General tab allows you to name and describe the Create Folder smart service. Additional options are enabled when viewing the activity in the Process Designer view.
The Data tab displays all the input and output parameters of the smart service. You can add additional input and output parameters, if needed. The default inputs that are generated for the Create Folder smart service are:
|Parent Knowledge Center
|New Folder Name
Configuring the Inputs
- On the
Inputs property sheet, specify values for either the
Parent Knowledge Center node input, or the
Parent Folder node input. You cannot specify both.
- Either manually enter data into the text-field, or create the value using the Expression Editor.
- When using the Expression Editor, you can select or modify process variables. Process variables can then be used to populate node inputs.
- The Expression Editor can be accessed by selecting Expression… from the drop-down menu under the Value column. The Value list displays all process variables that have the same data type as the node input.
Capturing the Output
Create Folder smart service returns the folder object that was created.
- To reference the newly created folder elsewhere in the process model, save the activity's output to a process variable.
- On the Data tab, select the Outputs tab.
- On the Results list, select the output named The created folder (Folder). The
Result Properties are displayed, listing the
AC!NewFolder result and its save options.
- Save the
AC!NewFolder result into an existing process variable that holds a Folder data type on the Target list.create a new process variable to store the folder by clicking the New process variable button.
The Create Folder smart service is available as an expression function that can be executed inside a saveInto on a SAIL component or as part of a Web API.
a!createFolder(name, parentFolder, parentKnowledgeCenter, onSuccess, onError)
- name (Text): The name of the new folder.
- parentFolder (Folder): When present, the new folder will be created in this Folder.
- parentKnowledgeCenter (Knowledge Center): When present, the new folder will be created in this Knowledge Center.
- onSuccess (Any Type): A list of saves or an HTTP response to execute after the smart service executes successfully. Created with
a!httpResponse(). The following function variable is available when configuring this input:
- fv!folder (Folder): The folder that was created.
- onError (Any Type): A list of saves or an HTTP response to execute when the smart service does not execute successfully. Created with
- Folder Names cannot contain the following characters.
\ / ; : " | ? ' > < * ]
- If a folder is created with an invalid name, an alert is sent to configured alert recipients indicating that the node failed to execute due to an invalid folder name. See also: Alerts Tab
- When run as an unattended activity, alert recipients are notified that the amount of time allocated for the completion of the unattended activity was insufficient. In such a scenario, you must change the name of the folder and re-execute the unattended create folder node. See Edit Process and Process Details for additional information.