FileUpload Embeddable
The FileUpload
embeddable provides a simple, UI-driven way to start pipeline executions by uploading files via an upload area. All you need to do is specify the input connector to use for the upload — it must be an input connector with node.type
set to MANUAL.
Configure the component based on your specific use case
Add the code snippet below and insert the component on the page where you want it to appear:
Fields
accessToken
Add here your access token
inputConnectorId
Add here the ID of the manual input connector (node.type
== MANUAL) you want to use for uploading files.
settings
i18nOverrides
Allows you to override each text element in the interface
language
Defines the language of the flow. So far we only support English ("en"
)
modal
Defines whether the component is shown inline (false
) or within a modal view (true
)
allowedFileTypes
Defines which file types can be uploaded. If the list is empty all file types (CSV, TSV, XLS, XLSX, JSON, XML) are allowed.
onExecutionView
Runs after the user has clicked the "View" button for one execution
onClose
Runs when the user trys to close the modal by using the "X" button or clicking outside the modal
Component
<FileUploader
accessToken=string
inputConnectorId=string
settings={{
i18nOverrides: {},
language: "en",
modal: boolean (default: true),
allowedFileTypes: [] (default: ["csv", "tsv", "xls", "xlsx", "json", "xml"])
}}
onExecutionView={({execution}) => {
// runs when the user selects an execution from the list of triggered pipelines
// execution: the id of the selected execution
}}
onClose={() => {
//runs when the creation workflow is closed via the "Cancel"-button of the Setup page or the X button of all steps is used
}}
/>