Hi, I want to save in the database the views of a specific page (that i am getting through plausible API) with the following data fields:
- page name (which is PAGE as data type)
- date
- number of views
I want to set an automatic workflow to run every midnight that creates a row for everyday total page views for every page.
So if i have 50 pages, i need to create 50 new data rows every day. If the next day i add 30 new pages, then the workflow would add 80 new rows.
Can anyone help me with this?
Thank you!
Somewhere in youâre app youâll need a list of pages. You could do this by having a âPageâ table which just has âpageURLâ (text).
Then, have a âPage Viewsâ data type. It has a date, number of views, and Page.
Whenever you create a page, add the page to the database.
Have a recurring daily workflow in the backend. Schedule an API workflow on a list (Do a search for Pages). In that API workflow, get the views for This Page, and create a âPage Viewâ thing which will be saved to the DB.
I already have a separate data type called pages.
The data type that i want to create is called Analytics and it is connected to the pages through the data field âpageâ. So I need to create rows for the data type Analytics.
@georgecollier you mean that i should add a backend workflow as ânew recurring eventâ?
How do i tell the system that i want to add a number of multiple things and how do i start the event for the first time?
Schedule API workflow on list
Create a button on an admin page that will initiate it
1 Like