Dynamic QueryParameter Names and Values

Hi everyone,

I'm developing an integration with a tool called e-goi and I need to send information about users inside query parameter. 
I need to do this dynamically since I can have multiple users being sent at one time. I already did some tests that went well in postman, and I needed the URL to look like this:

"functionOptions[subscribers][0][status]=&functionOptions[subscribers][0][form]=&functionOptions[subscribers][0][lang]=&functionOptions[subscribers][0][email]=example1@example1.com&functionOptions[subscribers][0][validate_phone]=&functionOptions[subscribers][0][cellphone]=&functionOptions[subscribers][0][telephone]=&functionOptions[subscribers][0][fax]=&functionOptions[subscribers][0][first_name]=&functionOptions[subscribers][0][last_name]=&functionOptions[subscribers][0][birth_date]=&functionOptions[subscribers][0][tags]=&functionOptions[subscribers][0][formID]=&functionOptions[subscribers][1][status]=&functionOptions[subscribers][1][form]=&functionOptions[subscribers][1][lang]=&functionOptions[subscribers][1][email]=example2@example2.com&functionOptions[subscribers][1][validate_phone]=&functionOptions[subscribers][1][cellphone]=&functionOptions[subscribers][1][telephone]=&functionOptions[subscribers][1][fax]=&functionOptions[subscribers][1][first_name]=&functionOptions[subscribers][1][last_name]=&functionOptions[subscribers][1][birth_date]=&functionOptions[subscribers][1][tags]=&functionOptions[subscribers][1][formID]="


I have also tried to do this in a fixed way in Appian, but Appian encodes the final URL and gives error when calling the API. Is there a way to solve this?

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer
    I'm making the assumption you are calling e-goi from Appian, though that's not clear to me from your post.

    Can e-goi receive POSTs? You could then put this into the body of your integration. Given the potential length of this URL, this may be a more robust solution anyways if you hit URL length limits.

    If not, then try to append your options directly in the URL of the integration object, rather than the Query Parameters fields (and you have no other parameters defined), I think Appian skips encoding based on the quick tests I did. However, this is not a great solution as encoding is a best practice in my mind. To me, the ideal state is for e-goi would be made to support encoded requests.
  • Hi Justin, thanks for replying.

    Yes, I am calling E-goi from Appian, and E-goi can receive posts, but the parameters are received as queryParameters, as you can see here api-docs.e-goi.com/.../

    Thanks for your help, I did not remember that the URL can be edited as an expression
Reply Children
No Data