mirror of
https://github.com/photoprism/photoprism.git
synced 2025-12-12 00:34:13 +01:00
Backend: Add security-focused tests, harden WebDAV and use safe.Download
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
@@ -15,7 +15,16 @@ import (
|
||||
|
||||
// Connect confirms external service accounts using a token.
|
||||
//
|
||||
// PUT /api/v1/connect/:name
|
||||
// @Summary confirm external service accounts using a token
|
||||
// @Id ConnectService
|
||||
// @Tags Config
|
||||
// @Accept json
|
||||
// @Produce json
|
||||
// @Param name path string true "service name (e.g., hub)"
|
||||
// @Param connect body form.Connect true "connection token"
|
||||
// @Success 200 {object} gin.H
|
||||
// @Failure 400,401,403 {object} i18n.Response
|
||||
// @Router /api/v1/connect/{name} [put]
|
||||
func Connect(router *gin.RouterGroup) {
|
||||
router.PUT("/connect/:name", func(c *gin.Context) {
|
||||
name := clean.ID(c.Param("name"))
|
||||
|
||||
Reference in New Issue
Block a user