
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2020 05:22 AM
I want to build a component to retrieve data but the rest api requires some parameters to be passed as json in the request body.
I am looking at the documentation for createHttpEffect and I cannot figure out how to send a json body with the request.
Does anybody know what parameters this should be passed in?
Solved! Go to Solution.
- Labels:
-
Now Experience UI Framework

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2020 02:09 PM
Hi Tommy,
I'll do a little digging and see if I can find something outside of the docs on developer. That being said, one of the things we demonstrated on last week's shows was using a Flow Designer action to consume an external API, then calling that action from a scripted rest API, and consuming the SRAPI from our component. That way we can abstract things from the component a bit and do any heavy lifting in the SRAPI. If you are looking to consume an external API from your component, that might be an architecture to look at either way.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2020 07:57 AM
Hi Tommy,
You can refer the below link
Hope this helps!
-Hemant

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2020 09:07 AM
Nope no help. I have read all that. And the example only use a url with query parameters.
I need to send a JSON body with the request.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2020 01:39 PM
I have tried lots of ways to send a body via the dataParams property but cannot figure out the proper way of providing a json body with the http request. I use putsreq.com to catch the sent request.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2020 02:09 PM
Hi Tommy,
I'll do a little digging and see if I can find something outside of the docs on developer. That being said, one of the things we demonstrated on last week's shows was using a Flow Designer action to consume an external API, then calling that action from a scripted rest API, and consuming the SRAPI from our component. That way we can abstract things from the component a bit and do any heavy lifting in the SRAPI. If you are looking to consume an external API from your component, that might be an architecture to look at either way.