The following example adds multiple Virtual Services with default settings:

Note: The first five arguments are: LoadMaster IP address, username, password, port and protocol, followed by the addresses of the Virtual Services to add, for example bash addvs.sh 20.200.50.50 bal 1fourall 80 tcp 20.200.50.10 20.200.50.11 …
for var in "${@:6}"
do
   curl -k "https://$2:$3@$1/access/addvs?vs=$var&port=$4&prot=$5"
done