A couple of questions about scripting automation on a Mac

I have been writing scripts in AutoIT for windows based systems and now I need to duplicate those scripts for use on Macs (M1 and M2). AutoIT is windows only so that will not work. I haven't written scripts for Macs before.

I need to be able to retrieve basic system information, create a simple UI for the script, open apps, manipulate the UI by sending keystrokes and/or mouse clicks, get start and end times for tasks performed (I was able to detect the end of a task on Windows system by checking pixel changes on the screen), and output times and system info to a CSV file.

Is Applescript a good tool for this? Should I look into Python or something else? Any recommendations would be helpful.

Originally, AppleScript invoked an application's internal functionality through an AppleScript dictionary of terms. Operations such as clicking buttons and operating menus depend on the state of the application being operated, so various know-how is required.

It's normal to write out system information as CSV data.

All the know-how about GUI Scripting is summarized in an e-book, so it may be helpful.

https://piyomarusoft.booth.pm/items/4230018

A couple of questions about scripting automation on a Mac
 
 
Q