%windir%\system32\inetsrv\appcmd list site > c:\sites-list.txt
To optimize SEO, the most common requirement is to redirect all non-www requests to www requests. i.e. redirect example.com.au to www.example.com.au. However, when you setup this 301 redirect in IIS, the querystring will be strip out. However, we can simply solve this by using IIS magic placeholder "$S$Q". For example, set the redirect destination to "www.example.com.au$S$Q".
So what $S$Q does?
IIS will replace $S with the subdirectory location i.e. /tickets and will replace $Q with querystring i.e. ?token=xyz
NOTE, you will need to tick the option "The exact URL entered above"