graphql-python / graphql-python/flask-graphql

File Upload

Abierto
#33 7 comentarios 1 reacción 0 asignados Ver en GitHub
Lenguaje dominante
Python
Estrellas
1.3k
Forks
139
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

I'm working on an [example repo](https://github.com/savovs/flask-graphene-hello) and was wondering, what would be the simplest way to implement that? This is what I tried without GraphQL:

```python
@app.route('/upload', methods=['POST'])
def uploadFile():
for key in request.files:
file = request.files[key]
file.save(os.path.join(UPLOAD_FOLDER, file.filename))

return 'uploaded'
```

[This is what](https://github.com/jaydenseric/apollo-upload-server) I used in Node.js, would love to do something like that for Flask in Python.

If it's not supported by flask-graphql I'd be happy to work on a pull request. Also, how would you test this without a browser, using Graphiql, Postman or something like that?

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.