Create image function throwing form data error

I am using ts SDK in react native application and getting following error.
{“data”: undefined, “error”: [TypeError: formData.getAll is not a function. (In ‘formData.getAll(‘files’)’, ‘formData.getAll’ is undefined)], “loading”: false, “origin”: “server”}

Hi @harshit can you please try this code to create img File Handling - Amity Docs

Please note that before you attach files in messages, posts user and community avatars, you need to create the file first using the createFile, createImage or createVideo methods. In case you’re using sdk with React Native you should use

yes now it is uploading but the image quality is too low so what parameter is required to increase image quality?

@harshit Please append ?size=large to get bigger size and better quality

1 Like