Add support for attachment upload and update request dependency

Added support for file attachment. Checks if there is an attachment parameter passed and if so, sets the formData.