TC2.22 - Exploiting Twitter Vigilance as External Service, in Dashboard, and as RestCall as MicroService in IOT applications

Test Case Title

TC2.22 - Exploiting Twitter Vigilance as External Service, in Dashboard, and as RestCall as MicroService in IOT applications

Goal

I can

Prerequisites

The user is logged in the system

Using a PC or Mobile with a web browser.

following functionalities are available only for specific Snap4city users with specific privileges.

Expected successful result

Twitter Vigilance accessible as Widgets from the Dashboards

Twitter Vigilance accessible as a Microservice in the Resource Manager

Steps

 

 

Case 1: Twitter Vigilance is an external service that can be easily embed into a dashboard.

External Services are visible in the main application by clicking on left main menu column External Services

Twitter Vigilance

 

Twitter Vigilance Real Time

 

Twitter vigilance and Twitter Vigilance Real Time can be embedded into dashboards using the Wizard.

  • Access in the Wizard by creating a New Dashboard or editing an existing one.
  • In case of creation of a new dashboard, in the Dashboard features page, select the Fully custom (1) template and add a title in the Dashboard Title field (2) and click the Confirm Button

  • In the Data Source list, High-Level type column, untick all and select only External Services;
  • In the Subnature column, click and select Twitter Vigilance and/or Twitter Vigilance Real Time

 

  • In the Single Data widget preview icons, click the second one “Single embedded webpage”, highlighted in the following image

  • Click the Confirm button to add the widget in the dashboard. The result is similar to the following image.

 

  • The user has to edit the two widgets to change dimensions and all the visual parameters as prefer.

Case 2: Twitter Vigilance can be registered as external MicroService via API REST. In the following is explained the process.

Users roles for which this test case is available: AreaManager, AreaManager, ToolAdmin, RootAdmin

User used to describe this Examples: ‘snap4city’ (role: AreaManager)

  • Make the login on the snap4city portal 
  • Click on the ‘Resource Manager: Process Loader > Resources’ menu to view all own resources and the related metadata. In this page each user can see the details and can: A) Upload; B) modify; C) publish its own resources.

Case A) Upload a new resource

  • Click on the Button (‘Upload New Resource’) button

Fig: Upload button.

  • A pop up will open: fill the fields and press the ‘Confirm’ button. For example, if you want to create a Microservice:
    • App Type: Microservice
    • Description: Retrieve last tweets related to a channel
    • Nature: Services
    • Sub-Nature: Social Media
    • Micro Service Title: twitter-last-channel
    • Help: Retrieve last tweets related to a channel
    • url: https://www.disit.org/rttv/query/TwLastChannel.php
    • parameter: channel
    • Method: GET
    • Authentication: No

Fig: Upload new resource form.

  • After the ‘Confirm’, the resource its available as private resource (visible only to its owner and to the ToolAdmin or RootAdmin, in this case the owner is the ‘snap4city’ user) on the table (list).

 

Fig: Manage a resource.

Case B) Modify own resources

  • To modify the metadata related to each own resource, click on the ‘EDIT’ button in the column ‘Metadata’ of the resource and fill/modify all the metadata. In the viewed example ‘twitter-last-channel’ MicroService:

Fig: Edit a resource.

Case C) Publish (share) own resources:

Note that to publish a Resource you have to fill the Licence field, see case B (that have to be changed for example from ‘Private’ to ‘https://creativecommons.org/licenses/by/4.0’)

  • If the resource is private and you want to share it will all the snap4city users (publish it on the web): Click on the button ‘NO’, column ‘Published’
    • As result the resource is visible in the menu ‘View Resources’ for All the snap4city users (EXAMPLE 2)
  • If the resource is private and you want to share it will all the sna4city users (unpublish it): Click on the button ‘NO’, column ‘Published’
    • As result the resource is visible in the menu ‘View Resources’ ONLY for All the snap4city users the author and for the users with the role ‘ToolAdmin’ or ‘RootAdmin’