docs(openapi): document backupFlags/restoreFlags on destination create/update (#1536) (#1538)

This commit is contained in:
Björn Strausmann authored and GitHub committed 2026-09-06 17:06:49 +05:30
1 parent 54fbf5205f
commit 4663aa6d2a
4 files changed
+26 -2

No files matched your search

+12
View File
@@ -3603,6 +3603,12 @@
"flags": {
"type": "string"
},
"backupFlags": {
"type": "string"
},
"restoreFlags": {
"type": "string"
},
"hostPath": {
"type": "string"
},
@@ -3741,6 +3747,12 @@
"flags": {
"type": "string"
},
"backupFlags": {
"type": "string"
},
"restoreFlags": {
"type": "string"
},
"hostPath": {
"type": "string"
},
@@ -65,7 +65,7 @@ export const GET: RequestHandler = async ({ cookies }) => {
* @openapi
* summary: Create a restic backup destination, auto-initialize and test the repository, and register its default maintenance schedules
* description: Permission denial (403, "backups:manage") is produced by the shared requireBackups route guard.
* body: {name:string!, repository:string!, password:string!, envVars:{}, flags:string, hostPath:string, cacert:string, tlsClientCert:string, policies:string}
* body: {name:string!, repository:string!, password:string!, envVars:{}, flags:string, backupFlags:string, restoreFlags:string, hostPath:string, cacert:string, tlsClientCert:string, policies:string}
* body-example: {"name":"S3 Offsite","repository":"s3:s3.amazonaws.com/my-bucket/restic","password":"***","envVars":{"AWS_ACCESS_KEY_ID":"***","AWS_SECRET_ACCESS_KEY":"***"}}
* resp-201: The created backup destination object (includes decrypted envVars since the caller just supplied them; password is stripped)
* resp-400: Invalid input — missing name/repository/password, unsupported/SSRF-blocked repository, invalid restic flags, or an invalid cron schedule in the policies
@@ -79,7 +79,7 @@ export const GET: RequestHandler = async ({ params, cookies }) => {
* summary: Update a backup destination, re-validating repository and flags when supplied and re-registering maintenance schedules when policies change
* description: Permission denial (403, "backups:manage") is produced by the shared requireBackups route guard.
* path: id:integer! Backup destination id (from GET /api/backup/destinations)
* body: {name:string, repository:string, password:string, envVars:{}, flags:string, hostPath:string, cacert:string, tlsClientCert:string, policies:string}
* body: {name:string, repository:string, password:string, envVars:{}, flags:string, backupFlags:string, restoreFlags:string, hostPath:string, cacert:string, tlsClientCert:string, policies:string}
* body-example: {"name":"S3 Offsite (renamed)","policies":"{\"pruneEnabled\":true,\"pruneSchedule\":\"0 0 1 * *\"}"}
* resp-200: The updated backup destination object (password stripped, envVars echoed back to the managing caller)
* resp-400: Invalid input — invalid id, unsupported/SSRF-blocked repository, invalid restic flags, invalid policy cron, or switching to a local repository used by a remote-environment config
+12
View File
@@ -3603,6 +3603,12 @@
"flags": {
"type": "string"
},
"backupFlags": {
"type": "string"
},
"restoreFlags": {
"type": "string"
},
"hostPath": {
"type": "string"
},
@@ -3741,6 +3747,12 @@
"flags": {
"type": "string"
},
"backupFlags": {
"type": "string"
},
"restoreFlags": {
"type": "string"
},
"hostPath": {
"type": "string"
},