Upload File
Use the Upload File action to upload a file to a ThingWorx repository.
Complete the following steps to use the Upload File action in your workflow:
1. Drag the Upload File action under ThingWorx to the canvas, place the pointer on the action, and then click or double-click the action. The Upload File window opens.
2. Edit the Label, if needed. By default, the label name is the same as the action name.
3. To add a ThingWorx connector type, refer to Supported ThingWorx Connector Types.
If you previously added a connector type, select the appropriate Connector Type, and under Connector Name, select the connector.
4. Click TEST to validate the connector.
5. Click MAP CONNECTOR to execute the action using a connector that is different from the one that you are using to populate the input fields. In the Runtime Connector field, provide a valid ThingWorx connector name. For more information about MAP CONNECTOR, see Using Map Connector.
6. Under the Source group, in the Type list, select one of the following options, and do the following:
Select File and do the following:
1. In the File Path field, map the output of a previous action to provide the path to a file.
2. In the Format list, select the correct file format.
Select Buffer and do the following:
1. In the Buffer field, map a data stream output of a previous action.
2. In the Encoding list, select the file encoding type.
Select String, and in the Data field, enter data or map a string output of a previous action that you want to write to the file that you want to upload.
7. Under the Destination group, do the following:
a. In the Repository list, select or specify the ThingWorx destination repository where you want to upload the file.
b. In the File Path list, select or specify the file path within the repository.
c. In the File Name field, enter the name of the file that you want to upload. This name can be different from the file that you mapped from a previous action.
8. Click Done.
Output schema
The Upload File action returns a message string.
Was this helpful?