From a8e18e0e22415c97ffedaa26dd69ee008eada0c2 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 23 Feb 2019 14:57:05 +0900 Subject: [PATCH] Add source code link --- src/server/api/gen-openapi-spec.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/server/api/gen-openapi-spec.ts b/src/server/api/gen-openapi-spec.ts index 3b0669087..fe960e251 100644 --- a/src/server/api/gen-openapi-spec.ts +++ b/src/server/api/gen-openapi-spec.ts @@ -392,6 +392,10 @@ export function genOpenapiSpec(lang = 'ja-JP') { const info = { summary: endpoint.name, description: endpoint.meta.desc ? endpoint.meta.desc[lang] : 'No description provided.', + externalDocs: { + description: 'Source code', + url: `https://github.com/syuilo/misskey/blob/develop/src/server/api/endpoints/${endpoint.name}.ts` + }, ...(endpoint.meta.tags ? { tags: endpoint.meta.tags } : {}),