0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-30 20:33:54 -05:00

refactor(core): add base url to swagger json (#5057)

This commit is contained in:
Gao Sun 2023-12-05 11:46:39 +08:00 committed by GitHub
parent 774de5cc7b
commit e4def14e71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -200,6 +200,12 @@ export default function swaggerRoutes<T extends AnonymousRouter, R extends Route
const baseDocument: OpenAPIV3.Document = {
openapi: '3.0.1',
servers: [
{
url: EnvSet.values.isCloud ? 'https://[tenant_id].logto.app/' : ctx.request.origin,
description: 'Logto endpoint address.',
},
],
info: {
title: 'Logto API references',
description: