Back

function POST request is changing to GET

  • 1
  • Functions
Alex Bourg
23 Jun, 2024, 21:20

Hi, I created a simple python function, I am trying to POST a file to the function, to be processed, but it seems to only accept certain file types as POST.. when I change the file to docx, then the request become GET for some reason.

TypeScript
def main(context):
    return context.res.json({"method": context.req.method})
TL;DR
Developers are experiencing an issue where their POST request is changing to GET when trying to send a docx file to a Python function for processing. A potential solution could be to ensure that the content type of the request is set correctly when sending the file.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more