This commit is contained in:
40
docs/docs.go
40
docs/docs.go
@@ -115,6 +115,46 @@ const docTemplate = `{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"/map/{id}/snfm": {
|
||||||
|
"get": {
|
||||||
|
"security": [
|
||||||
|
{
|
||||||
|
"ApiKeyAuth": []
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "Redirects to a signed download URL for a map's SNFM file",
|
||||||
|
"tags": [
|
||||||
|
"maps"
|
||||||
|
],
|
||||||
|
"summary": "Download SNFM file",
|
||||||
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "integer",
|
||||||
|
"description": "Map ID",
|
||||||
|
"name": "id",
|
||||||
|
"in": "path",
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"responses": {
|
||||||
|
"307": {
|
||||||
|
"description": "Redirect to signed S3 URL"
|
||||||
|
},
|
||||||
|
"404": {
|
||||||
|
"description": "Map not found",
|
||||||
|
"schema": {
|
||||||
|
"$ref": "#/definitions/Error"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"default": {
|
||||||
|
"description": "General error response",
|
||||||
|
"schema": {
|
||||||
|
"$ref": "#/definitions/Error"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"definitions": {
|
"definitions": {
|
||||||
|
|||||||
@@ -108,6 +108,46 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"/map/{id}/snfm": {
|
||||||
|
"get": {
|
||||||
|
"security": [
|
||||||
|
{
|
||||||
|
"ApiKeyAuth": []
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "Redirects to a signed download URL for a map's SNFM file",
|
||||||
|
"tags": [
|
||||||
|
"maps"
|
||||||
|
],
|
||||||
|
"summary": "Download SNFM file",
|
||||||
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "integer",
|
||||||
|
"description": "Map ID",
|
||||||
|
"name": "id",
|
||||||
|
"in": "path",
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"responses": {
|
||||||
|
"307": {
|
||||||
|
"description": "Redirect to signed S3 URL"
|
||||||
|
},
|
||||||
|
"404": {
|
||||||
|
"description": "Map not found",
|
||||||
|
"schema": {
|
||||||
|
"$ref": "#/definitions/Error"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"default": {
|
||||||
|
"description": "General error response",
|
||||||
|
"schema": {
|
||||||
|
"$ref": "#/definitions/Error"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"definitions": {
|
"definitions": {
|
||||||
|
|||||||
@@ -133,6 +133,31 @@ paths:
|
|||||||
summary: Get map by ID
|
summary: Get map by ID
|
||||||
tags:
|
tags:
|
||||||
- maps
|
- maps
|
||||||
|
/map/{id}/snfm:
|
||||||
|
get:
|
||||||
|
description: Redirects to a signed download URL for a map's SNFM file
|
||||||
|
parameters:
|
||||||
|
- description: Map ID
|
||||||
|
in: path
|
||||||
|
name: id
|
||||||
|
required: true
|
||||||
|
type: integer
|
||||||
|
responses:
|
||||||
|
"307":
|
||||||
|
description: Redirect to signed S3 URL
|
||||||
|
"404":
|
||||||
|
description: Map not found
|
||||||
|
schema:
|
||||||
|
$ref: '#/definitions/Error'
|
||||||
|
default:
|
||||||
|
description: General error response
|
||||||
|
schema:
|
||||||
|
$ref: '#/definitions/Error'
|
||||||
|
security:
|
||||||
|
- ApiKeyAuth: []
|
||||||
|
summary: Download SNFM file
|
||||||
|
tags:
|
||||||
|
- maps
|
||||||
securityDefinitions:
|
securityDefinitions:
|
||||||
ApiKeyAuth:
|
ApiKeyAuth:
|
||||||
in: header
|
in: header
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
//go:generate swag init -g ./cmd/maps-service/service.go
|
//go:generate go run github.com/swaggo/swag/cmd/swag@latest init -g ./cmd/maps-service/service.go
|
||||||
//go:generate go run github.com/ogen-go/ogen/cmd/ogen@latest --target pkg/api --clean openapi.yaml
|
//go:generate go run github.com/ogen-go/ogen/cmd/ogen@latest --target pkg/api --clean openapi.yaml
|
||||||
|
|||||||
Reference in New Issue
Block a user