Hear from Salesforce leaders on how to create and deploy Agentforce agents.
Contact Us 1-800-596-4880

Tableau Connector 1.1 Examples - Mule 4

Before You Begin

  • Java 8 or 11

  • Anypoint Studio 7.5 and later

  • Mule runtime engine (Mule) 4.3.0 and later

  • DataWeave

Create Hyper File - Hyper Configuration

This Mule flow creates a hyper file with specified table properties.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Create hyper file
    Creates an empty hyper file based on the column definition provided by the user

  • Transform Message
    Outputs the results of the Create hyper file operation in JSON format

Studio flow for the Create Hyper File operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/create-hyper-file-from-csvLeaving the Site.

Insert Data to Hyper File from CSV - Hyper Configuration

This Mule flow creates a hyper table and populates the table with data from a CSV file. To use this flow, run the Create Hyper File flow to create the hyper table and then use the src/main/resources/customers.csv file to populate the table.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Insert data to hyper file from csv
    Populates a hyper file from an existing CSV document

  • Transform Message
    Outputs the results of the Insert data to hyper file from csv operation in JSON format

Studio flow for the Insert Data to Hyper File from CSV operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081//create-hyper-fileLeaving the Site.

Insert Data to Hyper File - Hyper Configuration

This Mule flow inserts data into a table that belongs to a hyper file. To use this flow, run the Create Hyper File flow to create the hyper table and then use the SQL provided to insert the data.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Insert data to hyper file
    Inserts data into a table that belongs to a hyper file

  • Transform Message
    Outputs the results of the Insert data to hyper file operation in JSON format

Studio flow for the Insert Data to Hyper File operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/insert-data-to-hyper-fileLeaving the Site.

Query Data from Hyper File - Hyper Configuration

This Mule flow queries data from tables belonging to a hyper file. To use this flow, run the Create Hyper File flow to populate the table with data. This flow returns all of the data in the specified hyper table.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Query data from hyper file
    Queries data from tables belonging to a hyper file

  • Transform Message
    Outputs the results of the Query data from hyper file operation in JSON format

Studio flow for the Query Data from Hyper File operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/query-data-from-hyper-fileLeaving the Site.

Update Data from Hyper File - Hyper Configuration

This Mule flow updates data from tables into a .hyper file by sending SQL queries. To use this flow, run the Create Hyper File flow and Insert Data to Hyper File flow to create the hyper table and insert the data into the table. The flow updates the data that was previously inserted into the table.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Update data from hyper file
    Updates data from tables into a .hyper file by sending SQL queries

  • Transform Message
    Outputs the results of the Update data from hyper file operation in JSON format

Studio flow for the Update Data from Hyper File operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/update-data-from-hyper-fileLeaving the Site.

Append to File Upload - Rest Configuration

This Mule flow uploads a block of data and appends it to the data that is already uploaded. To get an Upload Session Id, run the Initiate file upload operation.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Read
    Reads a file

  • Transform Message
    Transforms the HTTP input

  • Append to file upload
    Uploads a block of data and appends it to the data that is already uploaded

  • Transform Message
    Outputs the results of the Append to file upload operation in JSON format

Studio flow for the Append to File Upload operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/append-to-file-uploadLeaving the Site.

Create Project - Rest Configuration

This Mule flow creates a project on the specified site.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Create project
    Creates a project on the site

  • Transform Message
    Outputs the results of the Create project operation in JSON format

Studio flow for the Create Project operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/create-projectLeaving the Site.

Delete Project - Rest Configuration

This Mule flow deletes a project from the specified site. When a project is deleted, all of its assets are also deleted, such as its associated workbooks, data sources, project view options, and rights. Use this operation with caution.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Delete project
    Deletes a project from the site

  • Transform Message
    Outputs the results of the Delete project operation in JSON format

Studio flow for the Delete Project operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/delete-projectLeaving the Site.

Initiate File Upload - Rest Configuration

This Mule flow initiates the upload process for a file.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Initiate file upload
    Initiates the upload process for a file

  • Transform Message
    Outputs the results of the Initiate file upload operation in JSON format

Studio flow for the Initiate File Upload operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/initiate-file-uploadLeaving the Site.

Publish Datasource - Rest Configuration

This Mule flow publishes a data source on the specified site, or appends data to an existing data source. You can use customers.hyper as an example of a datasource to upload.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Read
    Reads a file

  • Transform Message
    Transforms the HTTP input

  • Transform Message
    Transforms the datasource into Java format

  • Publish datasource
    Publishes a data source on the site, or appends data to an existing data source

  • Transform Message
    Outputs the results of the Publish datasource operation in JSON format

Studio flow for the Publish Datasource operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/publish-datasourceLeaving the Site.

Publish Workbook - Rest Configuration

This Mule flow publishes a workbook on the specified site.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Read
    Reads a file

  • Transform Message
    Transforms the HTTP input

  • Transform Message
    Transforms the datasource into Java format

  • Publish workbook
    Publishes a workbook on the site

  • Transform Message
    Outputs the results of the Publish workbook operation in JSON format

Studio flow for the Publish Workbook operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/publish-workbookLeaving the Site.

Query Projects - Rest Configuration

This Mule flow returns a list of projects from the specified site. It uses optional parameters to page large results.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Query projects
    Returns a list of projects from the site

  • Transform Message
    Outputs the results of the Query projects operation in JSON format

Studio flow for the Query Projects operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/query-projectsLeaving the Site.

Update Project - Rest Configuration

This Mule flow updates a project on the specified site.

This example uses the following operations:

  • HTTP Listener
    Accepts data from HTTP requests

  • Update project
    Updates a project on the site

  • Transform Message
    Outputs the results of the Update project operation in JSON format

Studio flow for the Update Project operation

XML for This Example

Paste this code into the Studio XML editor to quickly load the flow for this example into your Mule app:

Steps for Running This Example

  1. Verify that your connector is configured.

  2. Save the project.

  3. From a web browser, test the application by entering http://localhost:8081/update-projectLeaving the Site.

View on GitHub