Forum Academy Marketplace Showcase Pricing Features

Question about API Workflow on a List

Hey all,

I’ve got a silly question that I really should know the answer to, but it’s stumping me. I have a list of users that I want to send emails to. Right now, it’s sending emails to everybody in the list, but if there are 10 people in the list, it sends the email 10 times to everybody. The app will be open for edit until I get it resolved, here’s the URL: https://bubble.io/page?type=page&name=create-project&id=enscope&tab=tabs-1

You’re looking at the API Workflow, as well as the logic on the “create-project” page.

To get into the demo and see the behavior, do this:

There’s nothing else there, so there aren’t any features or anything you can do after inviting people. Thanks in advance!

In page create-project, there is the “Send Invitation” workflow that invites a single person, are you wanting it to run your API workflow?

What does a typical POST JSON body look like? On the API workflow, have you tried marking the key “user” as a list?

Possibly the API workflow actions are being run for each record in the POST, and treating the whole list of users as a single “to” string (automatically joining them with commas, which works for email).

There are two different types navigation buttons. One invites a user to join the app, while the other invites an existing user to this specific project. The first option happens as soon as a user clicks the invite button. The second option, though, doesn’t do anything until the user finishes the entire project creation step.

I believe you are correct about it treating the whole list of users as a single comma separated value in the “to” field. That is certainly the behavior. I have not tried making the key a list, I’ll give that a shot. Thanks for looking!