The API is actually looking at request.args to see if there are 'clearcache' or 'updatedb' in the ?query. So we actually want it to add those to the $path (e.g. ?clearcache=1) only if they are to be run. If they aren't to be run, don't add them.