diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2019-02-23 11:20:58 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-02-23 11:20:58 +0900 |
| commit | 52774bbe6402aee076b2e0648bd1f4764924da8a (patch) | |
| tree | a0e3f34ce6d000dd880a6a6c152e98e139076a14 /src/server/api/endpoints/drive/files/create.ts | |
| parent | 投稿を削除したときにお気に入りからも削除するように (diff) | |
| download | sharkey-52774bbe6402aee076b2e0648bd1f4764924da8a.tar.gz sharkey-52774bbe6402aee076b2e0648bd1f4764924da8a.tar.bz2 sharkey-52774bbe6402aee076b2e0648bd1f4764924da8a.zip | |
Introduce OpenAPI specs (#4351)
* wip
* wip
* wip
* Update index.ts
* Update gen-openapi-spec.ts
* Update api.ja-JP.md
* Fix
* Improve doc
* Update gen-openapi-spec.ts
* Update redoc.html
* Improve doc
* Update gen-openapi-spec.ts
* Improve doc
* Update CHANGELOG.md
Diffstat (limited to 'src/server/api/endpoints/drive/files/create.ts')
| -rw-r--r-- | src/server/api/endpoints/drive/files/create.ts | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/server/api/endpoints/drive/files/create.ts b/src/server/api/endpoints/drive/files/create.ts index c96e4bbf19..b2979c4888 100644 --- a/src/server/api/endpoints/drive/files/create.ts +++ b/src/server/api/endpoints/drive/files/create.ts @@ -13,6 +13,8 @@ export const meta = { 'en-US': 'Upload a file to drive.' }, + tags: ['drive'], + requireCredential: true, limit: { @@ -35,7 +37,7 @@ export const meta = { }, isSensitive: { - validator: $.optional.or($.bool, $.str), + validator: $.optional.either($.bool, $.str), default: false, transform: (v: any): boolean => v === true || v === 'true', desc: { @@ -45,7 +47,7 @@ export const meta = { }, force: { - validator: $.optional.or($.bool, $.str), + validator: $.optional.either($.bool, $.str), default: false, transform: (v: any): boolean => v === true || v === 'true', desc: { @@ -54,6 +56,10 @@ export const meta = { } }, + res: { + type: 'DriveFile', + }, + errors: { invalidFileName: { message: 'Invalid file name.', |