[BUG] convert data to json instead of sending as form data
[TEST] use connection class in PUT tests