Skip to content
+1-888-319-3663

COMMUNITY FORUM

Using REST Service Provider, trying to use a parameter as part of the url

Ken asked 2 months ago

Hi Everyone,

Like the title says, I am trying to pass a parameter as part of the url string, but it does not seem to be working.  The reason for this is a changing date/time parameter.  If I ‘hard code’ it, the url passes and I get a response.  However, if I try to pass the same value into the parameter, it does not seem happy.

Example of hardcode url: https://api.kyklo.co/v1/shop/152/orders.json?token=<xxxxxx>&from=2022-09-28-11-38-34&to=2022-09-28-12-38-34

Example of parameter url: https://api.kyklo.co/v1/shop/152/orders.json?token=<xxxxxx>&from={date_range}

Does the url field accept the parameter logic the same way the method body does?

 

Thanks!

Ken replied 2 months ago

I did some more testing – the parameter does work within the url, where it is tripping up, is trying to pass a value to the parameter using a task script that runs before the map. Any tips on passing a dynamic value to the parameter before the map runs? My script tries updating a global variable tied to the parameter. If I set a static value tot he global variable it works, but if I try using the task script, the global does not update.


If you would like to submit an answer or comment, please sign in to the eOne portal.