Backend Workflow/API Endpoint - Help

Hi,

I have a backend API endpoint that creates about ~1500 entries at 3AM everyday into my Bubble app. My issue is that I want to delete all the entries of that data type prior to the new entries being entered.

Timeline:
2:55 - Delete all entries for the data type (How should I do this?)
3:00 - Backend API Endpoint is triggered and new entries start being entered (I’ve done this through an external service)

Any suggestions?

Create new Backend workflow with today date (if you need)
Use Delete list of things option, to delete those searched things.

image

Hi Ethan,

Maybe you could mark those created thinks in some way (a new YES/NO field called “backend created” or something), or use the creation date field, then add a condition to the deleting action (“only when DATE CREATION is …”) ?

Michel

EDIT sorry, didn’t see previous answer

Hi Michel,

I’m struggling to create the deletion workflow so that it can recognize when entry was created.

Basically I’m trying to do this in a workflow:
Delete all entries for a datatype, but only entries that were made on today’s date - 1 day.

Any ideas of what that would look like? I’ve tried so many setups using ‘Created Date’ and I can’t find a way to get it to work.

I’m new to bubble, but I’m doing something similar(not delete through) and I have a workflow that schedules itself. You can schedule from a list and the list you use can be a query with something created > 1 day.

Bubble has an option to override the old list with a new list. It should be :set list

1 Like

Yeah, my endpoint creates individual entries however. Not a list. (It needs to create individual entries for other functionality)

Entries: https://gyazo.com/215db8a8af83eaec3ffaa5c4bc71138d

I’m basically just trying to delete all the entries at 2:55AM everyday. I can’t figure out how to do it on a recurring schedule.

Try using list shifter plugin and schedule the iteration. It will iterate over your list and you can then delete each iteration item.

You can also add all of the values inside one list, by making a relational database entry using a list of items. Not sure how to explain this while typing on mobile :slight_smile:

This topic was automatically closed after 70 days. New replies are no longer allowed.