mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-18 03:31:03 +01:00
feat(openapi): refactor into indiv. files to match API & tpl routing
This commit is contained in:
35
public/openapi/api/admin/upload/file.yaml
Normal file
35
public/openapi/api/admin/upload/file.yaml
Normal file
@@ -0,0 +1,35 @@
|
||||
post:
|
||||
tags:
|
||||
- admin
|
||||
summary: Upload a file
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
folder:
|
||||
type: string
|
||||
description: The folder to upload the files to (relative to `public/uploads/`)
|
||||
files:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
format: binary
|
||||
required:
|
||||
- files
|
||||
responses:
|
||||
"200":
|
||||
description: "File uploaded"
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
description: The filename
|
||||
url:
|
||||
type: string
|
||||
description: URL of the uploaded file for use client-side
|
||||
Reference in New Issue
Block a user