It's a pity Microsoft doesn't provide some documentation, but through very hard googling I found something that is working for me:
"/api/file": {
"post": {
"consumes": [
"multipart/form-data",
"application/json"
],
"produces": [
"application/json"
],
"responses": {
"204": {
"description": "OK"
}
},
"summary": "File upload",
"description": "Uploads a file",
"operationId": "FileUpload",
"parameters": [
{
"description": "File contents and name",
"in": "formData",
"name": "file",
"type": "file",
"required": true,
"x-ms-summary": "File contents"
}
]
}
}