filmov
tv
flask api endpoint part 6 graphene file upload

Показать описание
in this part we shall be covering file upload in graphene using flask and postman, the file upload part in postman is not specific to flask and so you can use it in any graphql project eg. django, nodejs etc...
the product query I used in postman:
operations:
{ "query": "mutation($file: Upload!) { createProduct( input_: { image: $file, name:\"paroduct creaeted with img in postman\",description:\"ert hhh rt\", quantity:10,price:200, categoryId:1 }) { success, error, product{\n id\n path \n}}}", "variables": { "file": null }}
please consider subscribing to my channel it doesn't hurt but it helps me a lot... thanks
the product query I used in postman:
operations:
{ "query": "mutation($file: Upload!) { createProduct( input_: { image: $file, name:\"paroduct creaeted with img in postman\",description:\"ert hhh rt\", quantity:10,price:200, categoryId:1 }) { success, error, product{\n id\n path \n}}}", "variables": { "file": null }}
please consider subscribing to my channel it doesn't hurt but it helps me a lot... thanks