Error Invalid tab id 1 when running as a cron job

Hi:
I do not understand your solution. Let me explain what I am doing.
I am running the following shell script on Ubuntu Linux via a cron job

#!/bin/bash
/usr/bin/firefox “file:///root/Downloads/desktop.html?direct=1&macro=skype” &
sleep 60
/usr/bin/killall firefox

Now, skype is the name of the macro. The first line of the macro is
XRun /root/skype2.sh

And skype2.sh is
#!/bin/bash
/usr/bin/skypeforlinux &

Now, what do you want me to do?
How can I just run firefox without the url that contains the skype macro?

If I just run firefox, pause, and then again run firefox with skype macro in the url, I will get the error message saying “firefox is already running. Close it.”

I hope you understand my problem. So, how can I start the browser first, and then the RPA command line?

Thanks,
Samir