fixed minor typo

compat.code should be err.code
changed upload/delete to json to avoid CSRF
Explicit JSON format request
Version bump