Automatic activity scheduling, based on templates.

Hi, I'm working on a small module that allows me through an automation to schedule activities automatically in a table, based on preconfigured lists.

I have a table that allows me to create templates with activities by type of project, when creating a project and selecting the type, my objective is that the activities for that project are scheduled in another table based on the type of project.

I am using an automation through a bot and the Appsheets API to create the records using the templates, however when I have templates with more than 9 activities the bot says I can't make that many API calls and only creates the first 9 activities.

Can you think of a way to do this without using the API?

0 1 137
1 REPLY 1

I suspect you have setup your automation to call an API task 9+ separate times - once for each activity?

You can setup an API Task to use an expression to pull in a set of rows to operate on. Say you have 15 activities to operate on and generate 15 new rows in your Scheduled Activities table.  You can add an expression to pull in the 15 source activity row ID's that are then cycled through to perform the Add Task - all in a single API call.

Example JSON would look like this (Activity here is NOT the same as your activity๐Ÿ˜ž

{
"Action": "Add",
"Properties": {
"Locale": "en-US",
"Location": "<<42.80890903597787, -71.6389241275992>>",
"Timezone": "Eastern Standard Time",
},
"Rows": [
<<START:[Add_Products][REC_Products_ID]>>
{
"Activity": "<<[Activity]>>",
"Farm": "<<[Farm]>>",
"Activity_Farm": "<<[Activity_Farm_ID]>>",
"Product": "<<[REC_Products_ID]>>"
}
<<END>>
]
}

 The expression in the START/END function is PRE-processed to generate into the FINAL JSON a set of add row requests.  All done in a single API call.

NOTE: that the first three columns are pulled from the "Main" row sent in the API call.  The "REC_Products_ID" column is retrieved from each iteration of the START function.

 

I hope this helps!

Top Labels in this Space