RESTful API

Using weather REST API ..

Use Case - Weather API

CDE weather dashboard

Follow the steps outlined below to activate CDE and test the API call with Postman.

Postman

To activate the Community Dashboard Editor (CDE) plugin, you will need to change the configuration of several .xml files in the Pentaho solutions folder as described below. Verify that you have the appropriate permissions to read, write, and execute commands in the specified directories in the instructions.

  1. Ensure the Pentaho Server is stopped.

cd
cd /opt/pentaho/server/pentaho-server
sudo ./stop-pentaho.sh
  1. Uncomment the following lines:

/opt/pentaho/server/pentaho-server/pentaho-solutions/system/pentaho-cdf-dd/plugin.xml

cd
cd /opt/pentaho/server/pentaho-server/pentaho-solutions/system/pentaho-cdf-dd
sudo nano plugin.xml
  1. Locate the following two commented blocks in this file and remove the comment tags from these blocks.

<operation>
    <id>EDIT</id>
    <perspective>wcdf.edit</perspective>
</operation>
<overlays>
    <overlay id="launch" resourcebundle="content/pentaho-cdf-dd/lang/messages">
        <button id="launch_new_cde" label="${Launcher.CDE}" command="Home.openFile('${Launcher.CDE}', '${Launcher.CDE_TOOLTIP}', 'api/repos/wcdf/new');$('#btnCreateNew').popover('hide');"/>
    </overlay>
    <overlay id="startup.cde_dashboard"  resourcebundle="content/pentaho-cdf-dd/lang/messages" priority="1">
        <menubar id="newmenu">
            <menuitem id="new-cde_dashboard" label="${Launcher.CDE}" command="mantleXulHandler.openUrl('${Launcher.CDE}','${Launcher.CDE_TOOLTIP}','api/repos/wcdf/new')" />
        </menubar>
    </overlay>
</overlays>
  1. Save.

CTRL + O
Enter
CTRL + X
  1. Uncomment the following lines:

/opt/pentaho/server/pentaho-server/pentaho-solutions/system/pentaho-cdf-dd/settings.xml

cd
cd /opt/pentaho/server/pentaho-server/pentaho-solutions/system/pentaho-cdf-dd
sudo nano settings.xml
  1. Locate the block at end of the file, 'Defining the new-toolbar-button' and remove the comments tags from this block

<new-toolbar-button>1,New CDE Dashboard,CDE Dashboard,api/repos/wcdf/new</new-toolbar-button>
  1. Locate the block at end of the file, 'Defining the new-toolbar-button' and remove the comments tags from this block.

  2. Save.

CTRL + O
Enter
CTRL + X
  1. Save your changes.

  2. Restart the Pentaho Server.

cd
cd /opt/pentaho/server/pentaho-server
sudo ./start-pentaho.sh

Community Dashboard Editor (CDE)

To verify CDE is activated, do the following.

  1. Log on to the Pentaho User Console.

  2. From the Home page, click the Create New button.

  3. From the menu that displays, select the New CDE Dashboard option. You can now begin creating your first CDE dashboard.

CDE Dashboard

Resources

REST API documentation API information for building custom solutions of Pentaho products.

Link to Pentaho Pro Suite API

CDF API Pentaho Data Integration and Analytics CDF API documentation.

Link to Pentaho CDF API

Pentaho Data Integration and Analytics Platform JavaScript API.

Link to Pentaho Javascript API

Last updated

Was this helpful?