-
-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Swagger.v1.json template #3572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swagger.v1.json template #3572
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
public/ | ||
templates/swagger/v1_json.tmpl | ||
|
||
themes/ |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package routers | ||
|
||
import ( | ||
"code.gitea.io/gitea/modules/base" | ||
"code.gitea.io/gitea/modules/context" | ||
) | ||
|
||
// tplSwaggerV1Json swagger v1 json template | ||
const tplSwaggerV1Json base.TplName = "swagger/v1_json" | ||
|
||
// SwaggerV1Json render swagger v1 json | ||
func SwaggerV1Json(ctx *context.Context) { | ||
ctx.HTML(200, tplSwaggerV1Json) | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ | |
}, | ||
"version": "1.1.1" | ||
|
||
}, | ||
"basePath": "/api/v1", | ||
"basePath": "{{AppSubUrl}}/api/v1", | ||
"paths": { | ||
"/admin/users": { | ||
"post": { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not against this change but it will need to be indicated as breaking. So we need to add the label kind/breaking on PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup.