Skip to content

Commit

Permalink
docs(swag): update swagger docs
Browse files Browse the repository at this point in the history
  • Loading branch information
powerfooI committed Feb 22, 2024
1 parent c7269b8 commit 133f9d4
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 23 deletions.
25 changes: 16 additions & 9 deletions distribution/dashboard/docs/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -2354,16 +2354,12 @@ const docTemplate = `{
},
"param.ChangeTenantRole": {
"type": "object",
"required": [
"tenantRole"
],
"properties": {
"switchover": {
"failover": {
"type": "boolean"
},
"tenantRole": {
"description": "Enum: Primary, Standby",
"type": "string"
"switchover": {
"type": "boolean"
}
}
},
Expand All @@ -2386,6 +2382,8 @@ const docTemplate = `{
"param.CreateBackupPolicy": {
"type": "object",
"required": [
"archivePath",
"bakDataPath",
"destType"
],
"properties": {
Expand Down Expand Up @@ -2680,7 +2678,8 @@ const docTemplate = `{
"type": "object",
"properties": {
"timestamp": {
"type": "string"
"type": "string",
"example": "2024-02-23 17:47:00"
},
"unlimited": {
"type": "boolean"
Expand All @@ -2707,6 +2706,11 @@ const docTemplate = `{
},
"param.RestoreSourceSpec": {
"type": "object",
"required": [
"archiveSource",
"bakDataSource",
"type"
],
"properties": {
"archiveSource": {
"type": "string"
Expand Down Expand Up @@ -2736,7 +2740,8 @@ const docTemplate = `{
"type": "object",
"properties": {
"timestamp": {
"type": "string"
"type": "string",
"example": "2024-02-23 17:47:00"
},
"unlimited": {
"type": "boolean"
Expand Down Expand Up @@ -2927,6 +2932,8 @@ const docTemplate = `{
"response.BackupPolicy": {
"type": "object",
"required": [
"archivePath",
"bakDataPath",
"destType"
],
"properties": {
Expand Down
25 changes: 16 additions & 9 deletions distribution/dashboard/docs/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -2347,16 +2347,12 @@
},
"param.ChangeTenantRole": {
"type": "object",
"required": [
"tenantRole"
],
"properties": {
"switchover": {
"failover": {
"type": "boolean"
},
"tenantRole": {
"description": "Enum: Primary, Standby",
"type": "string"
"switchover": {
"type": "boolean"
}
}
},
Expand All @@ -2379,6 +2375,8 @@
"param.CreateBackupPolicy": {
"type": "object",
"required": [
"archivePath",
"bakDataPath",
"destType"
],
"properties": {
Expand Down Expand Up @@ -2673,7 +2671,8 @@
"type": "object",
"properties": {
"timestamp": {
"type": "string"
"type": "string",
"example": "2024-02-23 17:47:00"
},
"unlimited": {
"type": "boolean"
Expand All @@ -2700,6 +2699,11 @@
},
"param.RestoreSourceSpec": {
"type": "object",
"required": [
"archiveSource",
"bakDataSource",
"type"
],
"properties": {
"archiveSource": {
"type": "string"
Expand Down Expand Up @@ -2729,7 +2733,8 @@
"type": "object",
"properties": {
"timestamp": {
"type": "string"
"type": "string",
"example": "2024-02-23 17:47:00"
},
"unlimited": {
"type": "boolean"
Expand Down Expand Up @@ -2920,6 +2925,8 @@
"response.BackupPolicy": {
"type": "object",
"required": [
"archivePath",
"bakDataPath",
"destType"
],
"properties": {
Expand Down
17 changes: 12 additions & 5 deletions distribution/dashboard/docs/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,10 @@ definitions:
type: object
param.ChangeTenantRole:
properties:
failover:
type: boolean
switchover:
type: boolean
tenantRole:
description: 'Enum: Primary, Standby'
type: string
required:
- tenantRole
type: object
param.ChangeUserPassword:
properties:
Expand Down Expand Up @@ -86,6 +83,8 @@ definitions:
example: Weekly
type: string
required:
- archivePath
- bakDataPath
- destType
type: object
param.CreateNamespaceParam:
Expand Down Expand Up @@ -246,6 +245,7 @@ definitions:
param.ReplayStandbyLog:
properties:
timestamp:
example: "2024-02-23 17:47:00"
type: string
unlimited:
type: boolean
Expand Down Expand Up @@ -279,10 +279,15 @@ definitions:
type: string
until:
$ref: '#/definitions/param.RestoreUntilConfig'
required:
- archiveSource
- bakDataSource
- type
type: object
param.RestoreUntilConfig:
properties:
timestamp:
example: "2024-02-23 17:47:00"
type: string
unlimited:
type: boolean
Expand Down Expand Up @@ -459,6 +464,8 @@ definitions:
tenantName:
type: string
required:
- archivePath
- bakDataPath
- destType
type: object
response.DashboardInfo:
Expand Down

0 comments on commit 133f9d4

Please sign in to comment.