summaryrefslogtreecommitdiff
path: root/packages/backend/src/server/api/openapi
diff options
context:
space:
mode:
Diffstat (limited to 'packages/backend/src/server/api/openapi')
-rw-r--r--packages/backend/src/server/api/openapi/gen-spec.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/packages/backend/src/server/api/openapi/gen-spec.ts b/packages/backend/src/server/api/openapi/gen-spec.ts
index 30bf6b8b3e..0e71510b48 100644
--- a/packages/backend/src/server/api/openapi/gen-spec.ts
+++ b/packages/backend/src/server/api/openapi/gen-spec.ts
@@ -43,7 +43,7 @@ export function genOpenapiSpec(config: Config) {
// 書き換えたりするのでディープコピーしておく。そのまま編集するとメモリ上の値が汚れて次回以降の出力に影響する
const copiedEndpoints = JSON.parse(JSON.stringify(endpoints)) as IEndpoint[];
- for (const endpoint of copiedEndpoints.filter(ep => !ep.meta.secure)) {
+ for (const endpoint of copiedEndpoints) {
const errors = {} as any;
if (endpoint.meta.errors) {
@@ -59,6 +59,11 @@ export function genOpenapiSpec(config: Config) {
const resSchema = endpoint.meta.res ? convertSchemaToOpenApiSchema(endpoint.meta.res) : {};
let desc = (endpoint.meta.description ? endpoint.meta.description : 'No description provided.') + '\n\n';
+
+ if (endpoint.meta.secure) {
+ desc += '**Internal Endpoint**: This endpoint is an API for the misskey mainframe and is not intended for use by third parties.\n';
+ }
+
desc += `**Credential required**: *${endpoint.meta.requireCredential ? 'Yes' : 'No'}*`;
if (endpoint.meta.kind) {
const kind = endpoint.meta.kind;