summaryrefslogtreecommitdiffstats
path: root/routers/web/misc/swagger-forgejo.go
blob: 2f539e955c0c9b55d8196f84e4465afa946f5ae7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Copyright 2017 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT

package misc

import (
	"net/http"

	"code.gitea.io/gitea/modules/base"
	"code.gitea.io/gitea/modules/context"
)

// tplSwagger swagger page template
const tplForgejoSwagger base.TplName = "swagger/forgejo-ui"

func SwaggerForgejo(ctx *context.Context) {
	ctx.Data["APIVersion"] = "v1"
	ctx.HTML(http.StatusOK, tplForgejoSwagger)
}