Is there somekind of possibilty to change rest api data source end point.
I have a button which should call some data source by checking user personal data.
method1 = "http://page1.com/api"
method2 = "http://page2.com/api"
If(user.id == 0 )
invoke data source method (method1)
invoke data source method (method2)
Hope You can understand my question.
There are two ways to do that at the moment:
- The first doesn't require custom code - you need to have two identical data sources that differ by URL. Then use two similar Invoke Data Source Method actions and set the Condition to determine which one will execute.
- The second method requires custom code. Something like step 3 from this tutorial (shows how to make HTTP request via custom method in the Angular component).
Thank you again !
I duplicate scheme of first one, but changed url.
I put condition for first end point and the second end point, so code decided which condition is good one.