Hi,
I’m having an issue in running this create_scheduled_plan. I am trying to basically have a CSV sheet read in with a list of schedules, and run a script that iterates over each row, and creates a schedule for each row based on the defined specifications (in each column).
I have all the IDs as variables and it seems like it pulls everything correctly.
However, when I get to this part of the code, based on the example given and another Looker community question, I keep getting an error.
schedule = sdk.create_scheduled_plan(body=models40.WriteScheduledPlan(name=schedule_title, dashboard_id=dashboard_id, look_id=look_id, user_id=user_id, filters_string=filter_string,run_as_recipient= True, datagroup=datagroup, scheduled_plan_destination = [models40.ScheduledPlanDestination(format=format, apply_formatting=True, apply_vis=True, address=email, type="email", message=message)]))
The error I receive is:
NameError: name 'models40' is not defined
And it’s directly copied from the example linked also above. Any help appreciated! Thank you very much!