This tutorial will show you how to connect two web service blocks. For instance an Excel file with all countries and a web service to Wikipedia showing information about the selected country. Or displaying a category and the products.


Requirements



Connecting two web service blocks


  1. Add both web service blocks to the App;
  2. Select the child block (in this case 'products');
  3. Go to the Advanced tab;
  4. Select the Advanced section;
  5. We will use a filter to filter out related data, in this case the filter should be:
    id_category_default.value = "{data:id1}"
  6. Now the link between the two blocks is enabled.
  7. In the app you should be able to click from parent to child and see a list or, when the result is only one item, see the details.


Using Input parameter filtering


In this case I used an API from movieDB to get data about films from Morgan Freeman. This results in a list with films where he played in. The other blocks ar placed a childs from the movie block.


 


In the data in the My Movies and Movie Details streams is a field called ImdbId so I can link those fields together.



  • Add {imdbid} as a default value. 


Now both blocks are linked together.


Frequently asked questions


Is it possible to add more layers?


Yes it is. As long as to blocks can be linked by a common field you can add more blocks as a child of another block.