HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Upload image using v2 Media endpoint from Javascript
Hello,
The project I am currently working is for a mobile react native app that will use the v2 APIs to create new discussions. I want to be able to upload images using a API v2 /media POST. All the documentation says is that we only need to pass "file": "string". However the code is looking for an instance of a PHP class UploadedFile.
Is there a way to use the /media endpoint to upload an image without using PHP?
Thanks
0
Comments
The endpoint needs an actual file passed to. This is our utilization of in from our javascript frontend:
https://github.com/vanilla/vanilla/blob/master/library/src/scripts/apiv2.ts