IBM Watson™ Ideas

Welcome to the IBM Watson™ Ideas Portal


We welcome and appreciate your feedback on IBM Watson™ Products to help make them even better than they are today!


If you are looking for troubleshooting help or wondering how to use our products and services, please check the IBM Watson™ documentation. Please do not use the Ideas Portal for reporting bugs - we ask that you report bugs or issues with the product by contacting IBM support.


Before you submit an idea, please perform a search first as a similar idea may have already been reported in the portal.


If a related idea is not yet listed, please create a new idea and include with it a description which includes expected behavior as well as why having this feature would improve the service and how it would address your use case.

Implement Support for iterator().forEachRemaining() or forEach() on JSONArrays

Loops are always good, to allow the use of arrays with dynamic length.

Currently it is only possible to interact with elements in an array, that has a predefined length.

 

Just imagine you ask your customer for multiple appointments in a slot. Now you could use forEach on sys-date.values to change every date format and save it to context like this:

"context": {

  "appointments": "<? @sys-date.values.forEach(val => val.reformatDateTime('dd.MM.jjjj')) ?>"

}

Then you can print the array with $appointments.join(', ') anywhere in dialog in the correct format.

I also added this idea, that allows customers to add an dynamic amount of pizzas to one order: https://ibm-data-and-ai.ideas.aha.io/ideas/ASSISTANT-I-220
Looping through the pizzas array for further processing would be great.

Please implement the support for iterator().forEachRemaining() or forEach() on JSONArrays.
It would make the use of arrays much easier and allow developers to use dynamic customer data.

  • Robert
  • Sep 6 2019
  • Needs review
Why is it useful?
Who would benefit from this IDEA? Every Watson Assistant Developer and Customer
How should it work?
Idea Priority
Priority Justification
Customer Name
Submitting Organization
Submitter Tags
  • Attach files