Many of these urls should be defined as variables/constants at the top of the script, instead of being embedded into these functions.  Users who care about security will definitely look at this script before they actually execute it.   A nicely constructed script that gives clear visibility into what it is doing will automatically win over trust on a user's part.  A complex script will do the exact opposite and can increase the chance of it not being used.