Get function not working sometimes

Hi Community,

I came across something strange. I ahve the following JSON that has 2 arrays: positive_sentiment and negative_sentiment.

each of those phrases need to be sent to webflow as paragraph, so I use the following GET method to grab them from the JSOn

The problem is that sometimes it works and sometimes it doesn’t. I have explored all previous parameters to see if anything is different, but the fact that they sometimes work and not other times is also happening for the same request.

I am looking for a solution that makes sure that it works all the time.

I have previously tried set variables right after the JSOn, but i get the same results.

Can anyone please help?

Hi @Halim,

What do you mean exactly with sometimes it works and sometimes it doesn’t? And why did you map the 1 item of the positive_sentiment array twice?

Cheers,
Henk

1 Like

My goal is to get the positive sentiment phrases, each as a paragraph that will go to webflow rich text field. The maximum number of phrases the JSON is in charge is 10, and that’s why I have in webflow 10 paragraphs with GET for positive sentiment, and 10 in negative sentiment.

I meant by sometimes it works and sometimes it doesn’t that if I run tout he scenario with a similar input, the output is sometimes picked up by webflow, and somethines not (the purple fiels become white as inactive)

Yes, but what is the purpose of adding it twice here:

We would really need to see an instance of it not working, before we can troubleshoot better.
Please, follow these steps when asking a question, and you’ll be more likely to get a helpful answer:

:writing_hand: Give us a detailed explanation of what you’re trying to achieve

:footprints: Tell us about any steps you’ve tried so far

:camera_flash: Include screenshots of:

  • your scenario flow and setup (functions, mappings, variables, etc.)

  • module configurations and outputs

  • any error messages you are getting

:card_file_box: Share the blueprint of the scenario you are asking a question about. (this does not contain any connection or personal information)

Henk
Certified Make Expert and Partner
Book a consult with me

1 Like

@Henk-Operative that’s a typo, thanks for pointing that.

In general, is using the GET formula to get data from that JSON to webflow the right solution?

Welcome to the Make community!

You’ll probably want to use the built-in function join on the entire array.

e.g.:

<p>{{join(63.positive_sentiment; "</p><p>")}}</p>

For more information, see the function documentation in the Help Center.

Here are some useful links and guides you can use to learn more on how to use the Make platform, apps, and app modules. I found these useful when I was learning Make, and hope they might benefit you too —

General

Help Center Basics

Articles & Videos

samliewrequest private consultation

Join the unofficial Make Discord server to chat with other makers!

4 Likes

Thanks @samliew it seems that the JOIN is better suited.

I have run the scenario 3 times, it worked for the first and third play, but not for the second.

Here’s how it looks like for the scenario play that failed to capture the data

they should be purple.

Any idea why it might not work? note that the phrases for both positive and negative can be up to 10. in our failed instance, there was 7 positives and 0 negatives. (side note: the JOIN worked for the other two where we had also a mixture of positives and negatives.)

Looks correct to me. Any error messages?

samliewrequest private consultation

Join the unofficial Make Discord server to chat with us!

1 Like

hey @samliew your are a star. I tried again the same data and it’s working.

Thanks for your help

1 Like

No problem, glad I could help!

1. If anyone has a new question in the future, please start a new thread. This makes it easier for others with the same problem to search for the answers to specific questions, and you are more likely to receive help since newer questions are monitored closely.

2. The Make Community guidelines encourages users to try to mark helpful replies as solutions to help keep the Community organized.

This marks the topic as solved, so that:

  • others can save time when catching up with the latest activity here, and
  • allows others to quickly jump to the solution if they come across the same problem

To do this, simply click the checkbox at the bottom of the post that answers your question:
Screenshot_2023-10-04_161049

3. Don’t forget to like and bookmark this topic so you can get back to it easily in future!

4. Do join the unofficial Make Discord server for live chat and video assistance

samliewrequest private consultation

Join the unofficial Make Discord server to chat with other makers!

1 Like