diff --git a/api-docs/openapi/v3_0/aggregated.json b/api-docs/openapi/v3_0/aggregated.json index 52399b4ce..b4d669903 100644 --- a/api-docs/openapi/v3_0/aggregated.json +++ b/api-docs/openapi/v3_0/aggregated.json @@ -174,6 +174,45 @@ "v1alpha1/AnnotationSetting" ] }, + "patch": { + "description": "Patch v1alpha1/AnnotationSetting", + "operationId": "Patch/v1alpha1/AnnotationSetting", + "parameters": [ + { + "description": "Name of annotationsetting", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/AnnotationSetting" + } + } + }, + "description": "Response annotationsetting patched just now" + } + }, + "tags": [ + "v1alpha1/AnnotationSetting" + ] + }, "put": { "description": "Update v1alpha1/AnnotationSetting", "operationId": "Update/v1alpha1/AnnotationSetting", @@ -372,6 +411,45 @@ "v1alpha1/ConfigMap" ] }, + "patch": { + "description": "Patch v1alpha1/ConfigMap", + "operationId": "Patch/v1alpha1/ConfigMap", + "parameters": [ + { + "description": "Name of configmap", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/ConfigMap" + } + } + }, + "description": "Response configmap patched just now" + } + }, + "tags": [ + "v1alpha1/ConfigMap" + ] + }, "put": { "description": "Update v1alpha1/ConfigMap", "operationId": "Update/v1alpha1/ConfigMap", @@ -570,6 +648,45 @@ "v1alpha1/MenuItem" ] }, + "patch": { + "description": "Patch v1alpha1/MenuItem", + "operationId": "Patch/v1alpha1/MenuItem", + "parameters": [ + { + "description": "Name of menuitem", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/MenuItem" + } + } + }, + "description": "Response menuitem patched just now" + } + }, + "tags": [ + "v1alpha1/MenuItem" + ] + }, "put": { "description": "Update v1alpha1/MenuItem", "operationId": "Update/v1alpha1/MenuItem", @@ -768,6 +885,45 @@ "v1alpha1/Menu" ] }, + "patch": { + "description": "Patch v1alpha1/Menu", + "operationId": "Patch/v1alpha1/Menu", + "parameters": [ + { + "description": "Name of menu", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Menu" + } + } + }, + "description": "Response menu patched just now" + } + }, + "tags": [ + "v1alpha1/Menu" + ] + }, "put": { "description": "Update v1alpha1/Menu", "operationId": "Update/v1alpha1/Menu", @@ -966,6 +1122,45 @@ "v1alpha1/RoleBinding" ] }, + "patch": { + "description": "Patch v1alpha1/RoleBinding", + "operationId": "Patch/v1alpha1/RoleBinding", + "parameters": [ + { + "description": "Name of rolebinding", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/RoleBinding" + } + } + }, + "description": "Response rolebinding patched just now" + } + }, + "tags": [ + "v1alpha1/RoleBinding" + ] + }, "put": { "description": "Update v1alpha1/RoleBinding", "operationId": "Update/v1alpha1/RoleBinding", @@ -1164,6 +1359,45 @@ "v1alpha1/Role" ] }, + "patch": { + "description": "Patch v1alpha1/Role", + "operationId": "Patch/v1alpha1/Role", + "parameters": [ + { + "description": "Name of role", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Role" + } + } + }, + "description": "Response role patched just now" + } + }, + "tags": [ + "v1alpha1/Role" + ] + }, "put": { "description": "Update v1alpha1/Role", "operationId": "Update/v1alpha1/Role", @@ -1362,6 +1596,45 @@ "v1alpha1/Secret" ] }, + "patch": { + "description": "Patch v1alpha1/Secret", + "operationId": "Patch/v1alpha1/Secret", + "parameters": [ + { + "description": "Name of secret", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Secret" + } + } + }, + "description": "Response secret patched just now" + } + }, + "tags": [ + "v1alpha1/Secret" + ] + }, "put": { "description": "Update v1alpha1/Secret", "operationId": "Update/v1alpha1/Secret", @@ -1560,6 +1833,45 @@ "v1alpha1/Setting" ] }, + "patch": { + "description": "Patch v1alpha1/Setting", + "operationId": "Patch/v1alpha1/Setting", + "parameters": [ + { + "description": "Name of setting", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Setting" + } + } + }, + "description": "Response setting patched just now" + } + }, + "tags": [ + "v1alpha1/Setting" + ] + }, "put": { "description": "Update v1alpha1/Setting", "operationId": "Update/v1alpha1/Setting", @@ -1758,6 +2070,45 @@ "v1alpha1/User" ] }, + "patch": { + "description": "Patch v1alpha1/User", + "operationId": "Patch/v1alpha1/User", + "parameters": [ + { + "description": "Name of user", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/User" + } + } + }, + "description": "Response user patched just now" + } + }, + "tags": [ + "v1alpha1/User" + ] + }, "put": { "description": "Update v1alpha1/User", "operationId": "Update/v1alpha1/User", @@ -7017,6 +7368,45 @@ "auth.halo.run/v1alpha1/AuthProvider" ] }, + "patch": { + "description": "Patch auth.halo.run/v1alpha1/AuthProvider", + "operationId": "Patch/auth.halo.run/v1alpha1/AuthProvider", + "parameters": [ + { + "description": "Name of authprovider", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/AuthProvider" + } + } + }, + "description": "Response authprovider patched just now" + } + }, + "tags": [ + "auth.halo.run/v1alpha1/AuthProvider" + ] + }, "put": { "description": "Update auth.halo.run/v1alpha1/AuthProvider", "operationId": "Update/auth.halo.run/v1alpha1/AuthProvider", @@ -7215,6 +7605,45 @@ "auth.halo.run/v1alpha1/UserConnection" ] }, + "patch": { + "description": "Patch auth.halo.run/v1alpha1/UserConnection", + "operationId": "Patch/auth.halo.run/v1alpha1/UserConnection", + "parameters": [ + { + "description": "Name of userconnection", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/UserConnection" + } + } + }, + "description": "Response userconnection patched just now" + } + }, + "tags": [ + "auth.halo.run/v1alpha1/UserConnection" + ] + }, "put": { "description": "Update auth.halo.run/v1alpha1/UserConnection", "operationId": "Update/auth.halo.run/v1alpha1/UserConnection", @@ -7438,6 +7867,45 @@ "content.halo.run/v1alpha1/Category" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Category", + "operationId": "Patch/content.halo.run/v1alpha1/Category", + "parameters": [ + { + "description": "Name of category", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Category" + } + } + }, + "description": "Response category patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Category" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Category", "operationId": "Update/content.halo.run/v1alpha1/Category", @@ -7636,6 +8104,45 @@ "content.halo.run/v1alpha1/Comment" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Comment", + "operationId": "Patch/content.halo.run/v1alpha1/Comment", + "parameters": [ + { + "description": "Name of comment", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Comment" + } + } + }, + "description": "Response comment patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Comment" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Comment", "operationId": "Update/content.halo.run/v1alpha1/Comment", @@ -7834,6 +8341,45 @@ "content.halo.run/v1alpha1/Post" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Post", + "operationId": "Patch/content.halo.run/v1alpha1/Post", + "parameters": [ + { + "description": "Name of post", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Post" + } + } + }, + "description": "Response post patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Post" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Post", "operationId": "Update/content.halo.run/v1alpha1/Post", @@ -8032,6 +8578,45 @@ "content.halo.run/v1alpha1/Reply" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Reply", + "operationId": "Patch/content.halo.run/v1alpha1/Reply", + "parameters": [ + { + "description": "Name of reply", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Reply" + } + } + }, + "description": "Response reply patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Reply" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Reply", "operationId": "Update/content.halo.run/v1alpha1/Reply", @@ -8230,6 +8815,45 @@ "content.halo.run/v1alpha1/SinglePage" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/SinglePage", + "operationId": "Patch/content.halo.run/v1alpha1/SinglePage", + "parameters": [ + { + "description": "Name of singlepage", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/SinglePage" + } + } + }, + "description": "Response singlepage patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/SinglePage" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/SinglePage", "operationId": "Update/content.halo.run/v1alpha1/SinglePage", @@ -8428,6 +9052,45 @@ "content.halo.run/v1alpha1/Snapshot" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Snapshot", + "operationId": "Patch/content.halo.run/v1alpha1/Snapshot", + "parameters": [ + { + "description": "Name of snapshot", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Snapshot" + } + } + }, + "description": "Response snapshot patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Snapshot" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Snapshot", "operationId": "Update/content.halo.run/v1alpha1/Snapshot", @@ -8626,6 +9289,45 @@ "content.halo.run/v1alpha1/Tag" ] }, + "patch": { + "description": "Patch content.halo.run/v1alpha1/Tag", + "operationId": "Patch/content.halo.run/v1alpha1/Tag", + "parameters": [ + { + "description": "Name of tag", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Tag" + } + } + }, + "description": "Response tag patched just now" + } + }, + "tags": [ + "content.halo.run/v1alpha1/Tag" + ] + }, "put": { "description": "Update content.halo.run/v1alpha1/Tag", "operationId": "Update/content.halo.run/v1alpha1/Tag", @@ -8824,6 +9526,45 @@ "metrics.halo.run/v1alpha1/Counter" ] }, + "patch": { + "description": "Patch metrics.halo.run/v1alpha1/Counter", + "operationId": "Patch/metrics.halo.run/v1alpha1/Counter", + "parameters": [ + { + "description": "Name of counter", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Counter" + } + } + }, + "description": "Response counter patched just now" + } + }, + "tags": [ + "metrics.halo.run/v1alpha1/Counter" + ] + }, "put": { "description": "Update metrics.halo.run/v1alpha1/Counter", "operationId": "Update/metrics.halo.run/v1alpha1/Counter", @@ -9022,6 +9763,45 @@ "migration.halo.run/v1alpha1/Backup" ] }, + "patch": { + "description": "Patch migration.halo.run/v1alpha1/Backup", + "operationId": "Patch/migration.halo.run/v1alpha1/Backup", + "parameters": [ + { + "description": "Name of backup", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Backup" + } + } + }, + "description": "Response backup patched just now" + } + }, + "tags": [ + "migration.halo.run/v1alpha1/Backup" + ] + }, "put": { "description": "Update migration.halo.run/v1alpha1/Backup", "operationId": "Update/migration.halo.run/v1alpha1/Backup", @@ -9220,6 +10000,45 @@ "notification.halo.run/v1alpha1/Notification" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/Notification", + "operationId": "Patch/notification.halo.run/v1alpha1/Notification", + "parameters": [ + { + "description": "Name of notification", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Notification" + } + } + }, + "description": "Response notification patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/Notification" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/Notification", "operationId": "Update/notification.halo.run/v1alpha1/Notification", @@ -9418,6 +10237,45 @@ "notification.halo.run/v1alpha1/NotificationTemplate" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/NotificationTemplate", + "operationId": "Patch/notification.halo.run/v1alpha1/NotificationTemplate", + "parameters": [ + { + "description": "Name of notificationtemplate", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/NotificationTemplate" + } + } + }, + "description": "Response notificationtemplate patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/NotificationTemplate" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/NotificationTemplate", "operationId": "Update/notification.halo.run/v1alpha1/NotificationTemplate", @@ -9616,6 +10474,45 @@ "notification.halo.run/v1alpha1/NotifierDescriptor" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/NotifierDescriptor", + "operationId": "Patch/notification.halo.run/v1alpha1/NotifierDescriptor", + "parameters": [ + { + "description": "Name of notifierDescriptor", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/NotifierDescriptor" + } + } + }, + "description": "Response notifierDescriptor patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/NotifierDescriptor" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/NotifierDescriptor", "operationId": "Update/notification.halo.run/v1alpha1/NotifierDescriptor", @@ -9814,6 +10711,45 @@ "notification.halo.run/v1alpha1/Reason" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/Reason", + "operationId": "Patch/notification.halo.run/v1alpha1/Reason", + "parameters": [ + { + "description": "Name of reason", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Reason" + } + } + }, + "description": "Response reason patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/Reason" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/Reason", "operationId": "Update/notification.halo.run/v1alpha1/Reason", @@ -10012,6 +10948,45 @@ "notification.halo.run/v1alpha1/ReasonType" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/ReasonType", + "operationId": "Patch/notification.halo.run/v1alpha1/ReasonType", + "parameters": [ + { + "description": "Name of reasontype", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/ReasonType" + } + } + }, + "description": "Response reasontype patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/ReasonType" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/ReasonType", "operationId": "Update/notification.halo.run/v1alpha1/ReasonType", @@ -10210,6 +11185,45 @@ "notification.halo.run/v1alpha1/Subscription" ] }, + "patch": { + "description": "Patch notification.halo.run/v1alpha1/Subscription", + "operationId": "Patch/notification.halo.run/v1alpha1/Subscription", + "parameters": [ + { + "description": "Name of subscription", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Subscription" + } + } + }, + "description": "Response subscription patched just now" + } + }, + "tags": [ + "notification.halo.run/v1alpha1/Subscription" + ] + }, "put": { "description": "Update notification.halo.run/v1alpha1/Subscription", "operationId": "Update/notification.halo.run/v1alpha1/Subscription", @@ -10408,6 +11422,45 @@ "plugin.halo.run/v1alpha1/ExtensionDefinition" ] }, + "patch": { + "description": "Patch plugin.halo.run/v1alpha1/ExtensionDefinition", + "operationId": "Patch/plugin.halo.run/v1alpha1/ExtensionDefinition", + "parameters": [ + { + "description": "Name of extensiondefinition", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/ExtensionDefinition" + } + } + }, + "description": "Response extensiondefinition patched just now" + } + }, + "tags": [ + "plugin.halo.run/v1alpha1/ExtensionDefinition" + ] + }, "put": { "description": "Update plugin.halo.run/v1alpha1/ExtensionDefinition", "operationId": "Update/plugin.halo.run/v1alpha1/ExtensionDefinition", @@ -10606,6 +11659,45 @@ "plugin.halo.run/v1alpha1/ExtensionPointDefinition" ] }, + "patch": { + "description": "Patch plugin.halo.run/v1alpha1/ExtensionPointDefinition", + "operationId": "Patch/plugin.halo.run/v1alpha1/ExtensionPointDefinition", + "parameters": [ + { + "description": "Name of extensionpointdefinition", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/ExtensionPointDefinition" + } + } + }, + "description": "Response extensionpointdefinition patched just now" + } + }, + "tags": [ + "plugin.halo.run/v1alpha1/ExtensionPointDefinition" + ] + }, "put": { "description": "Update plugin.halo.run/v1alpha1/ExtensionPointDefinition", "operationId": "Update/plugin.halo.run/v1alpha1/ExtensionPointDefinition", @@ -10804,6 +11896,45 @@ "plugin.halo.run/v1alpha1/Plugin" ] }, + "patch": { + "description": "Patch plugin.halo.run/v1alpha1/Plugin", + "operationId": "Patch/plugin.halo.run/v1alpha1/Plugin", + "parameters": [ + { + "description": "Name of plugin", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Plugin" + } + } + }, + "description": "Response plugin patched just now" + } + }, + "tags": [ + "plugin.halo.run/v1alpha1/Plugin" + ] + }, "put": { "description": "Update plugin.halo.run/v1alpha1/Plugin", "operationId": "Update/plugin.halo.run/v1alpha1/Plugin", @@ -11002,6 +12133,45 @@ "plugin.halo.run/v1alpha1/ReverseProxy" ] }, + "patch": { + "description": "Patch plugin.halo.run/v1alpha1/ReverseProxy", + "operationId": "Patch/plugin.halo.run/v1alpha1/ReverseProxy", + "parameters": [ + { + "description": "Name of reverseproxy", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/ReverseProxy" + } + } + }, + "description": "Response reverseproxy patched just now" + } + }, + "tags": [ + "plugin.halo.run/v1alpha1/ReverseProxy" + ] + }, "put": { "description": "Update plugin.halo.run/v1alpha1/ReverseProxy", "operationId": "Update/plugin.halo.run/v1alpha1/ReverseProxy", @@ -11200,6 +12370,45 @@ "plugin.halo.run/v1alpha1/SearchEngine" ] }, + "patch": { + "description": "Patch plugin.halo.run/v1alpha1/SearchEngine", + "operationId": "Patch/plugin.halo.run/v1alpha1/SearchEngine", + "parameters": [ + { + "description": "Name of searchengine", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/SearchEngine" + } + } + }, + "description": "Response searchengine patched just now" + } + }, + "tags": [ + "plugin.halo.run/v1alpha1/SearchEngine" + ] + }, "put": { "description": "Update plugin.halo.run/v1alpha1/SearchEngine", "operationId": "Update/plugin.halo.run/v1alpha1/SearchEngine", @@ -11398,6 +12607,45 @@ "security.halo.run/v1alpha1/PersonalAccessToken" ] }, + "patch": { + "description": "Patch security.halo.run/v1alpha1/PersonalAccessToken", + "operationId": "Patch/security.halo.run/v1alpha1/PersonalAccessToken", + "parameters": [ + { + "description": "Name of personalaccesstoken", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/PersonalAccessToken" + } + } + }, + "description": "Response personalaccesstoken patched just now" + } + }, + "tags": [ + "security.halo.run/v1alpha1/PersonalAccessToken" + ] + }, "put": { "description": "Update security.halo.run/v1alpha1/PersonalAccessToken", "operationId": "Update/security.halo.run/v1alpha1/PersonalAccessToken", @@ -11596,6 +12844,45 @@ "storage.halo.run/v1alpha1/Attachment" ] }, + "patch": { + "description": "Patch storage.halo.run/v1alpha1/Attachment", + "operationId": "Patch/storage.halo.run/v1alpha1/Attachment", + "parameters": [ + { + "description": "Name of attachment", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Attachment" + } + } + }, + "description": "Response attachment patched just now" + } + }, + "tags": [ + "storage.halo.run/v1alpha1/Attachment" + ] + }, "put": { "description": "Update storage.halo.run/v1alpha1/Attachment", "operationId": "Update/storage.halo.run/v1alpha1/Attachment", @@ -11794,6 +13081,45 @@ "storage.halo.run/v1alpha1/Group" ] }, + "patch": { + "description": "Patch storage.halo.run/v1alpha1/Group", + "operationId": "Patch/storage.halo.run/v1alpha1/Group", + "parameters": [ + { + "description": "Name of group", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Group" + } + } + }, + "description": "Response group patched just now" + } + }, + "tags": [ + "storage.halo.run/v1alpha1/Group" + ] + }, "put": { "description": "Update storage.halo.run/v1alpha1/Group", "operationId": "Update/storage.halo.run/v1alpha1/Group", @@ -11992,6 +13318,45 @@ "storage.halo.run/v1alpha1/Policy" ] }, + "patch": { + "description": "Patch storage.halo.run/v1alpha1/Policy", + "operationId": "Patch/storage.halo.run/v1alpha1/Policy", + "parameters": [ + { + "description": "Name of policy", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Policy" + } + } + }, + "description": "Response policy patched just now" + } + }, + "tags": [ + "storage.halo.run/v1alpha1/Policy" + ] + }, "put": { "description": "Update storage.halo.run/v1alpha1/Policy", "operationId": "Update/storage.halo.run/v1alpha1/Policy", @@ -12190,6 +13555,45 @@ "storage.halo.run/v1alpha1/PolicyTemplate" ] }, + "patch": { + "description": "Patch storage.halo.run/v1alpha1/PolicyTemplate", + "operationId": "Patch/storage.halo.run/v1alpha1/PolicyTemplate", + "parameters": [ + { + "description": "Name of policytemplate", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/PolicyTemplate" + } + } + }, + "description": "Response policytemplate patched just now" + } + }, + "tags": [ + "storage.halo.run/v1alpha1/PolicyTemplate" + ] + }, "put": { "description": "Update storage.halo.run/v1alpha1/PolicyTemplate", "operationId": "Update/storage.halo.run/v1alpha1/PolicyTemplate", @@ -12388,6 +13792,45 @@ "theme.halo.run/v1alpha1/Theme" ] }, + "patch": { + "description": "Patch theme.halo.run/v1alpha1/Theme", + "operationId": "Patch/theme.halo.run/v1alpha1/Theme", + "parameters": [ + { + "description": "Name of theme", + "in": "path", + "name": "name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json-patch+json": { + "schema": { + "$ref": "#/components/schemas/JsonPatch" + } + } + } + }, + "responses": { + "200": { + "content": { + "*/*": { + "schema": { + "$ref": "#/components/schemas/Theme" + } + } + }, + "description": "Response theme patched just now" + } + }, + "tags": [ + "theme.halo.run/v1alpha1/Theme" + ] + }, "put": { "description": "Update theme.halo.run/v1alpha1/Theme", "operationId": "Update/theme.halo.run/v1alpha1/Theme", @@ -12880,6 +14323,31 @@ }, "components": { "schemas": { + "AddOperation": { + "required": [ + "op", + "path", + "value" + ], + "type": "object", + "properties": { + "op": { + "type": "string", + "enum": [ + "add" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + }, + "value": { + "description": "Value can be any JSON value" + } + } + }, "AnnotationSetting": { "required": [ "apiVersion", @@ -14323,6 +15791,34 @@ } } }, + "CopyOperation": { + "required": [ + "op", + "from", + "path" + ], + "type": "object", + "properties": { + "from": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + }, + "op": { + "type": "string", + "enum": [ + "copy" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + } + } + }, "Counter": { "required": [ "apiVersion", @@ -15088,6 +16584,34 @@ }, "description": "The subject name of reason type to be interested in" }, + "JsonPatch": { + "minItems": 1, + "uniqueItems": true, + "type": "array", + "description": "JSON schema for JSONPatch operations", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/AddOperation" + }, + { + "$ref": "#/components/schemas/ReplaceOperation" + }, + { + "$ref": "#/components/schemas/TestOperation" + }, + { + "$ref": "#/components/schemas/RemoveOperation" + }, + { + "$ref": "#/components/schemas/MoveOperation" + }, + { + "$ref": "#/components/schemas/CopyOperation" + } + ] + } + }, "License": { "type": "object", "properties": { @@ -15941,7 +17465,6 @@ "type": "object", "properties": { "children": { - "uniqueItems": true, "type": "array", "description": "Children of this menu item", "items": { @@ -16085,7 +17608,6 @@ "description": "The display name of the menu." }, "menuItems": { - "uniqueItems": true, "type": "array", "description": "Names of menu children below this menu.", "items": { @@ -16168,6 +17690,34 @@ } } }, + "MoveOperation": { + "required": [ + "op", + "from", + "path" + ], + "type": "object", + "properties": { + "from": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + }, + "op": { + "type": "string", + "enum": [ + "move" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + } + } + }, "NavigationPostVo": { "type": "object", "properties": { @@ -17953,6 +19503,52 @@ } } }, + "RemoveOperation": { + "required": [ + "op", + "path" + ], + "type": "object", + "properties": { + "op": { + "type": "string", + "enum": [ + "remove" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + } + } + }, + "ReplaceOperation": { + "required": [ + "op", + "path", + "value" + ], + "type": "object", + "properties": { + "op": { + "type": "string", + "enum": [ + "replace" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + }, + "value": { + "description": "Value can be any JSON value" + } + } + }, "Reply": { "required": [ "apiVersion", @@ -19784,6 +21380,31 @@ } } }, + "TestOperation": { + "required": [ + "op", + "path", + "value" + ], + "type": "object", + "properties": { + "op": { + "type": "string", + "enum": [ + "test" + ] + }, + "path": { + "pattern": "^(/[^/~]*(~[01][^/~]*)*)*$", + "type": "string", + "description": "A JSON Pointer path pointing to the location to move/copy from.", + "example": "/a/b/c" + }, + "value": { + "description": "Value can be any JSON value" + } + } + }, "Theme": { "required": [ "apiVersion", diff --git a/api/src/main/java/run/halo/app/extension/JsonExtension.java b/api/src/main/java/run/halo/app/extension/JsonExtension.java index 2bcfec3cd..c140df328 100644 --- a/api/src/main/java/run/halo/app/extension/JsonExtension.java +++ b/api/src/main/java/run/halo/app/extension/JsonExtension.java @@ -28,7 +28,7 @@ import java.util.Set; */ @JsonSerialize(using = JsonExtension.ObjectNodeExtensionSerializer.class) @JsonDeserialize(using = JsonExtension.ObjectNodeExtensionDeSerializer.class) -class JsonExtension implements Extension { +public class JsonExtension implements Extension { private final ObjectMapper objectMapper; @@ -112,6 +112,15 @@ class JsonExtension implements Extension { return objectNode; } + /** + * Get object mapper. + * + * @return object mapper + */ + public ObjectMapper getObjectMapper() { + return objectMapper; + } + public MetadataOperator getMetadataOrCreate() { var metadataNode = objectMapper.createObjectNode(); objectNode.set("metadata", metadataNode); diff --git a/api/src/main/java/run/halo/app/extension/ReactiveExtensionClient.java b/api/src/main/java/run/halo/app/extension/ReactiveExtensionClient.java index 021d4ca29..586f713d7 100644 --- a/api/src/main/java/run/halo/app/extension/ReactiveExtensionClient.java +++ b/api/src/main/java/run/halo/app/extension/ReactiveExtensionClient.java @@ -60,6 +60,8 @@ public interface ReactiveExtensionClient { Mono get(Class type, String name); + Mono getJsonExtension(GroupVersionKind gvk, String name); + /** * Creates an Extension. * diff --git a/api/src/main/java/run/halo/app/extension/index/FunctionalIndexAttribute.java b/api/src/main/java/run/halo/app/extension/index/FunctionalIndexAttribute.java index 2f9d54231..c33f0cde7 100644 --- a/api/src/main/java/run/halo/app/extension/index/FunctionalIndexAttribute.java +++ b/api/src/main/java/run/halo/app/extension/index/FunctionalIndexAttribute.java @@ -6,7 +6,6 @@ import lombok.EqualsAndHashCode; import org.springframework.lang.Nullable; import org.springframework.util.Assert; import run.halo.app.extension.Extension; -import run.halo.app.extension.Unstructured; @EqualsAndHashCode(callSuper = true) public class FunctionalIndexAttribute @@ -42,10 +41,6 @@ public class FunctionalIndexAttribute */ @Nullable public String getValue(Extension object) { - if (object instanceof Unstructured unstructured) { - var ext = Unstructured.OBJECT_MAPPER.convertValue(unstructured, getObjectType()); - return valueFunc.apply(ext); - } if (getObjectType().isInstance(object)) { return valueFunc.apply(getObjectType().cast(object)); } diff --git a/api/src/main/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttribute.java b/api/src/main/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttribute.java index 367284693..adbc52904 100644 --- a/api/src/main/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttribute.java +++ b/api/src/main/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttribute.java @@ -5,7 +5,6 @@ import java.util.function.Function; import lombok.EqualsAndHashCode; import org.springframework.util.Assert; import run.halo.app.extension.Extension; -import run.halo.app.extension.Unstructured; @EqualsAndHashCode(callSuper = true) public class FunctionalMultiValueIndexAttribute @@ -29,10 +28,6 @@ public class FunctionalMultiValueIndexAttribute @Override public Set getValues(Extension object) { - if (object instanceof Unstructured unstructured) { - var ext = Unstructured.OBJECT_MAPPER.convertValue(unstructured, getObjectType()); - return getNonNullValues(ext); - } if (getObjectType().isInstance(object)) { return getNonNullValues(getObjectType().cast(object)); } diff --git a/api/src/test/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttributeTest.java b/api/src/test/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttributeTest.java index f12dababa..7fd91f6a1 100644 --- a/api/src/test/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttributeTest.java +++ b/api/src/test/java/run/halo/app/extension/index/FunctionalMultiValueIndexAttributeTest.java @@ -35,7 +35,9 @@ class FunctionalMultiValueIndexAttributeTest { assertThat(attribute.getValues(fake)).isEqualTo(fake.getCategories()); var unstructured = Unstructured.OBJECT_MAPPER.convertValue(fake, Unstructured.class); - assertThat(attribute.getValues(unstructured)).isEqualTo(fake.getCategories()); + assertThatThrownBy(() -> attribute.getValues(unstructured)) + .isInstanceOf(IllegalArgumentException.class) + .hasMessageContaining("Object type does not match"); var demoExt = new DemoExtension(); assertThatThrownBy(() -> attribute.getValues(demoExt)) diff --git a/application/src/main/java/run/halo/app/config/SwaggerConfig.java b/application/src/main/java/run/halo/app/config/SwaggerConfig.java index ec36f7b22..d8307a94a 100644 --- a/application/src/main/java/run/halo/app/config/SwaggerConfig.java +++ b/application/src/main/java/run/halo/app/config/SwaggerConfig.java @@ -12,6 +12,7 @@ import io.swagger.v3.oas.models.info.Info; import io.swagger.v3.oas.models.security.SecurityRequirement; import io.swagger.v3.oas.models.security.SecurityScheme; import java.util.Set; +import org.springdoc.core.customizers.OpenApiCustomizer; import org.springdoc.core.models.GroupedOpenApi; import org.springdoc.core.providers.ObjectMapperProvider; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; @@ -20,6 +21,7 @@ import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.core.Ordered; import org.springframework.core.annotation.Order; +import run.halo.app.extension.router.JsonPatch; @Configuration @ConditionalOnProperty(name = SPRINGDOC_ENABLED, matchIfMissing = true) @@ -37,8 +39,11 @@ public class SwaggerConfig { .type(SecurityScheme.Type.HTTP).scheme("bearer").bearerFormat("JWT")) ) .addSecurityItem(new SecurityRequirement().addList("BasicAuth").addList("BearerAuth")) - .info(new Info().title("Halo Next API") - .version("2.0.0")); + .info(new Info().title("Halo Next API").version("2.0.0")); + } + + OpenApiCustomizer openApiCustomizer() { + return openApi -> JsonPatch.addSchema(openApi.getComponents()); } @Bean @@ -47,6 +52,7 @@ public class SwaggerConfig { .group("core-api") .displayName("Core APIs") .pathsToMatch("/api/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -58,6 +64,7 @@ public class SwaggerConfig { .pathsToMatch("/apis/**") .pathsToExclude("/apis/api.console.halo.run/**", "/apis/api.halo.run/**", "/apis/api.plugin.halo.run/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -67,6 +74,7 @@ public class SwaggerConfig { .group("core-custom-api") .displayName("Custom APIs in Core") .pathsToMatch("/apis/api.console.halo.run/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -76,6 +84,7 @@ public class SwaggerConfig { .group("api.halo.run") .displayName("api.halo.run") .pathsToMatch("/apis/api.halo.run/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -85,6 +94,7 @@ public class SwaggerConfig { .group("plugin-custom-api") .displayName("Custom APIs in Plugin") .pathsToMatch("/apis/api.plugin.halo.run/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -94,6 +104,7 @@ public class SwaggerConfig { .group("uc.api") .displayName("User center APIs.") .pathsToMatch("/apis/uc.api.*/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } @@ -103,6 +114,7 @@ public class SwaggerConfig { .group("all-api") .displayName("All APIs") .pathsToMatch("/api/**", "/apis/**", "/login/**") + .addOpenApiCustomizer(openApiCustomizer()) .build(); } diff --git a/application/src/main/java/run/halo/app/extension/ReactiveExtensionClientImpl.java b/application/src/main/java/run/halo/app/extension/ReactiveExtensionClientImpl.java index e6f11098d..a634fc42b 100644 --- a/application/src/main/java/run/halo/app/extension/ReactiveExtensionClientImpl.java +++ b/application/src/main/java/run/halo/app/extension/ReactiveExtensionClientImpl.java @@ -155,6 +155,12 @@ public class ReactiveExtensionClientImpl implements ReactiveExtensionClient { .map(extensionStore -> converter.convertFrom(Unstructured.class, extensionStore)); } + private Mono fetchJsonExtension(GroupVersionKind gvk, String name) { + var storeName = ExtensionStoreUtil.buildStoreName(schemeManager.get(gvk), name); + return client.fetchByName(storeName) + .map(extensionStore -> converter.convertFrom(JsonExtension.class, extensionStore)); + } + @Override public Mono get(Class type, String name) { return fetch(type, name) @@ -169,6 +175,13 @@ public class ReactiveExtensionClientImpl implements ReactiveExtensionClient { .switchIfEmpty(Mono.error(() -> new ExtensionNotFoundException(gvk, name))); } + @Override + public Mono getJsonExtension(GroupVersionKind gvk, String name) { + return fetchJsonExtension(gvk, name) + .switchIfEmpty(Mono.error(() -> new ExtensionNotFoundException(gvk, name))); + } + + @Override public Mono create(E extension) { checkClientWritable(extension); @@ -238,8 +251,14 @@ public class ReactiveExtensionClientImpl implements ReactiveExtensionClient { } private Mono getLatest(Extension extension) { - if (extension instanceof Unstructured unstructured) { - return get(unstructured.groupVersionKind(), unstructured.getMetadata().getName()); + if (extension instanceof Unstructured) { + return get(extension.groupVersionKind(), extension.getMetadata().getName()); + } + if (extension instanceof JsonExtension) { + return getJsonExtension( + extension.groupVersionKind(), + extension.getMetadata().getName() + ); } return get(extension.getClass(), extension.getMetadata().getName()); } @@ -268,7 +287,7 @@ public class ReactiveExtensionClientImpl implements ReactiveExtensionClient { var indexer = indexerFactory.getIndexer(gvk); return client.create(name, data) .map(created -> converter.convertFrom(type, created)) - .doOnNext(indexer::indexRecord) + .doOnNext(extension -> indexer.indexRecord(convertToRealExtension(extension))) .as(transactionalOperator::transactional); }); } @@ -280,11 +299,23 @@ public class ReactiveExtensionClientImpl implements ReactiveExtensionClient { var indexer = indexerFactory.getIndexer(oldExtension.groupVersionKind()); return client.update(name, version, data) .map(updated -> converter.convertFrom(type, updated)) - .doOnNext(indexer::updateRecord) + .doOnNext(extension -> indexer.updateRecord(convertToRealExtension(extension))) .as(transactionalOperator::transactional); }); } + private Extension convertToRealExtension(Extension extension) { + var gvk = extension.groupVersionKind(); + var realType = schemeManager.get(gvk).type(); + Extension realExtension = extension; + if (extension instanceof Unstructured) { + realExtension = Unstructured.OBJECT_MAPPER.convertValue(extension, realType); + } else if (extension instanceof JsonExtension jsonExtension) { + realExtension = jsonExtension.getObjectMapper().convertValue(jsonExtension, realType); + } + return realExtension; + } + /** * If the extension is being updated, we should the index is not building index for the * extension, otherwise the {@link IllegalStateException} will be thrown. diff --git a/application/src/main/java/run/halo/app/extension/router/ExtensionPatchHandler.java b/application/src/main/java/run/halo/app/extension/router/ExtensionPatchHandler.java new file mode 100644 index 000000000..6f5f1fd49 --- /dev/null +++ b/application/src/main/java/run/halo/app/extension/router/ExtensionPatchHandler.java @@ -0,0 +1,80 @@ +package run.halo.app.extension.router; + +import static run.halo.app.extension.router.ExtensionRouterFunctionFactory.PathPatternGenerator.buildExtensionPathPattern; + +import com.fasterxml.jackson.databind.node.ObjectNode; +import com.github.fge.jsonpatch.JsonPatch; +import com.github.fge.jsonpatch.JsonPatchException; +import java.util.List; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.server.ServerRequest; +import org.springframework.web.reactive.function.server.ServerResponse; +import org.springframework.web.server.ServerWebInputException; +import org.springframework.web.server.UnsupportedMediaTypeStatusException; +import reactor.core.publisher.Mono; +import run.halo.app.extension.JsonExtension; +import run.halo.app.extension.ReactiveExtensionClient; +import run.halo.app.extension.Scheme; +import run.halo.app.extension.router.ExtensionRouterFunctionFactory.PatchHandler; + +/** + * Handler for patching extension. + * + * @author johnniang + */ +public class ExtensionPatchHandler implements PatchHandler { + + private static final MediaType JSON_PATCH_MEDIA_TYPE = + MediaType.valueOf("application/json-patch+json"); + + private final Scheme scheme; + + private final ReactiveExtensionClient client; + + public ExtensionPatchHandler(Scheme scheme, ReactiveExtensionClient client) { + this.scheme = scheme; + this.client = client; + } + + @Override + public Mono handle(ServerRequest request) { + var name = request.pathVariable("name"); + var contentTypeOpt = request.headers().contentType(); + if (contentTypeOpt.isEmpty()) { + return Mono.error( + new UnsupportedMediaTypeStatusException((MediaType) null, + List.of(JSON_PATCH_MEDIA_TYPE)) + ); + } + var contentType = contentTypeOpt.get(); + if (!contentType.isCompatibleWith(JSON_PATCH_MEDIA_TYPE)) { + return Mono.error( + new UnsupportedMediaTypeStatusException(contentType, List.of(JSON_PATCH_MEDIA_TYPE)) + ); + } + + return request.bodyToMono(JsonPatch.class) + .switchIfEmpty(Mono.error(() -> new ServerWebInputException("Request body required."))) + .flatMap(jsonPatch -> client.getJsonExtension(scheme.groupVersionKind(), name) + .flatMap(jsonExtension -> { + try { + // apply the patch + var appliedJsonNode = + (ObjectNode) jsonPatch.apply(jsonExtension.getInternal()); + var patchedExtension = + new JsonExtension(jsonExtension.getObjectMapper(), appliedJsonNode); + // update the patched extension + return client.update(patchedExtension); + } catch (JsonPatchException e) { + return Mono.error(e); + } + })) + .flatMap(updated -> ServerResponse.ok().bodyValue(updated)); + } + + @Override + public String pathPattern() { + return buildExtensionPathPattern(scheme) + "/{name}"; + } + +} diff --git a/application/src/main/java/run/halo/app/extension/router/ExtensionRouterFunctionFactory.java b/application/src/main/java/run/halo/app/extension/router/ExtensionRouterFunctionFactory.java index acf525437..43fe464bd 100644 --- a/application/src/main/java/run/halo/app/extension/router/ExtensionRouterFunctionFactory.java +++ b/application/src/main/java/run/halo/app/extension/router/ExtensionRouterFunctionFactory.java @@ -1,9 +1,12 @@ package run.halo.app.extension.router; import static org.springdoc.core.fn.builders.apiresponse.Builder.responseBuilder; +import static org.springdoc.core.fn.builders.content.Builder.contentBuilder; import static org.springdoc.core.fn.builders.parameter.Builder.parameterBuilder; import static org.springdoc.core.fn.builders.requestbody.Builder.requestBodyBuilder; +import static org.springdoc.core.fn.builders.schema.Builder.schemaBuilder; +import io.swagger.v3.core.util.RefUtils; import io.swagger.v3.oas.annotations.enums.ParameterIn; import org.springdoc.webflux.core.fn.SpringdocRouteBuilder; import org.springframework.lang.NonNull; @@ -32,6 +35,7 @@ public class ExtensionRouterFunctionFactory { var createHandler = new ExtensionCreateHandler(scheme, client); var updateHandler = new ExtensionUpdateHandler(scheme, client); var deleteHandler = new ExtensionDeleteHandler(scheme, client); + var patchHandler = new ExtensionPatchHandler(scheme, client); // TODO More handlers here var gvk = scheme.groupVersionKind(); var tagName = gvk.toString(); @@ -79,6 +83,26 @@ public class ExtensionRouterFunctionFactory { .response(responseBuilder().responseCode("200") .description("Response " + scheme.plural() + " updated just now") .implementation(scheme.type()))) + .PATCH(patchHandler.pathPattern(), patchHandler, + builder -> builder.operationId("Patch/" + gvk) + .description("Patch " + gvk) + .tag(tagName) + .parameter(parameterBuilder().in(ParameterIn.PATH) + .name("name") + .description("Name of " + scheme.singular())) + .requestBody(requestBodyBuilder() + .content(contentBuilder() + .mediaType("application/json-patch+json") + .schema( + schemaBuilder().ref(RefUtils.constructRef(JsonPatch.SCHEMA_NAME)) + ) + ) + ) + .response(responseBuilder().responseCode("200") + .description("Response " + scheme.singular() + " patched just now") + .implementation(scheme.type()) + ) + ) .DELETE(deleteHandler.pathPattern(), deleteHandler, builder -> builder.operationId("Delete/" + gvk) .description("Delete " + gvk) @@ -128,4 +152,8 @@ public class ExtensionRouterFunctionFactory { } + interface PatchHandler extends HandlerFunction, PathPatternGenerator { + + } + } diff --git a/application/src/main/java/run/halo/app/extension/router/JsonPatch.java b/application/src/main/java/run/halo/app/extension/router/JsonPatch.java new file mode 100644 index 000000000..55b3bf51b --- /dev/null +++ b/application/src/main/java/run/halo/app/extension/router/JsonPatch.java @@ -0,0 +1,104 @@ +package run.halo.app.extension.router; + +import static io.swagger.v3.oas.models.Components.COMPONENTS_SCHEMAS_REF; + +import io.swagger.v3.oas.models.Components; +import io.swagger.v3.oas.models.media.Schema; +import io.swagger.v3.oas.models.media.StringSchema; +import java.util.List; +import java.util.Map; +import java.util.function.Function; + +/** + * JSON schema for JSONPatch operations. + * + * @author johnniang + */ +public final class JsonPatch { + + private JsonPatch() {} + + public static final String SCHEMA_NAME = "JsonPatch"; + + public static void addSchema(Components components) { + Function> opSchemaFunc = + op -> new StringSchema()._enum(List.of(op)).type("string"); + var pathSchema = new StringSchema() + .description("A JSON Pointer path") + .pattern("^(/[^/~]*(~[01][^/~]*)*)*$") + .example("/a/b/c"); + var valueSchema = new Schema<>().description("Value can be any JSON value"); + var operationSchema = new io.swagger.v3.oas.models.media.Schema<>() + .oneOf(List.of( + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "AddOperation"), + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "ReplaceOperation"), + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "TestOperation"), + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "RemoveOperation"), + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "MoveOperation"), + new io.swagger.v3.oas.models.media.Schema<>() + .$ref(COMPONENTS_SCHEMAS_REF + "CopyOperation") + )); + + components.addSchemas("AddOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "path", "value")) + .properties(Map.of( + "op", opSchemaFunc.apply("add"), + "path", pathSchema, + "value", valueSchema + ))) + ; + components.addSchemas("ReplaceOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "path", "value")) + .properties(Map.of( + "op", opSchemaFunc.apply("replace"), + "path", pathSchema, + "value", valueSchema + ))) + ; + components.addSchemas("TestOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "path", "value")) + .properties(Map.of( + "op", opSchemaFunc.apply("test"), + "path", pathSchema, + "value", valueSchema + ))) + ; + components.addSchemas("RemoveOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "path")) + .properties(Map.of( + "op", opSchemaFunc.apply("remove"), + "path", pathSchema + ))) + ; + components.addSchemas("MoveOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "from", "path")) + .properties(Map.of( + "op", opSchemaFunc.apply("move"), + "from", pathSchema + .description("A JSON Pointer path pointing to the location to move/copy from."), + "path", pathSchema + ))) + ; + components.addSchemas("CopyOperation", new io.swagger.v3.oas.models.media.ObjectSchema() + .required(List.of("op", "from", "path")) + .properties(Map.of( + "op", opSchemaFunc.apply("copy"), + "from", pathSchema + .description("A JSON Pointer path pointing to the location to move/copy from."), + "path", pathSchema + ))) + ; + components.addSchemas(SCHEMA_NAME, new io.swagger.v3.oas.models.media.ArraySchema() + .description("JSON schema for JSONPatch operations") + .uniqueItems(true) + .minItems(1) + .items(operationSchema) + ); + } + +} diff --git a/application/src/test/java/run/halo/app/extension/ReactiveExtensionClientTest.java b/application/src/test/java/run/halo/app/extension/ReactiveExtensionClientTest.java index 259e54532..892184c28 100644 --- a/application/src/test/java/run/halo/app/extension/ReactiveExtensionClientTest.java +++ b/application/src/test/java/run/halo/app/extension/ReactiveExtensionClientTest.java @@ -3,11 +3,14 @@ package run.halo.app.extension; import static java.util.Collections.emptyList; import static java.util.Collections.reverseOrder; import static java.util.Comparator.comparing; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertInstanceOf; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertThrows; import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.argThat; +import static org.mockito.ArgumentMatchers.assertArg; import static org.mockito.ArgumentMatchers.eq; import static org.mockito.ArgumentMatchers.isA; import static org.mockito.ArgumentMatchers.same; @@ -428,7 +431,11 @@ class ReactiveExtensionClientTest { verify(converter, times(1)).convertTo(eq(fake)); verify(storeClient, times(1)).create(eq("/registry/fake.halo.run/fakes/fake"), any()); assertNotNull(fake.getMetadata().getCreationTimestamp()); - verify(indexer).indexRecord(eq(fake)); + + verify(indexer).indexRecord(assertArg(ext -> { + assertInstanceOf(FakeExtension.class, ext); + assertEquals("fake", ext.getMetadata().getName()); + })); } @Test @@ -581,7 +588,10 @@ class ReactiveExtensionClientTest { verify(converter, times(2)).convertFrom(same(Unstructured.class), any()); verify(storeClient) .update(eq("/registry/fake.halo.run/fakes/fake"), eq(12345L), any()); - verify(indexer).updateRecord(eq(updatedFake)); + verify(indexer).updateRecord(assertArg(ext -> { + assertInstanceOf(FakeExtension.class, ext); + assertEquals("fake", ext.getMetadata().getName()); + })); } @Test @@ -606,6 +616,29 @@ class ReactiveExtensionClientTest { verify(indexer).updateRecord(eq(fake)); } + @Test + void shouldGetJsonExtension() { + var storeName = "/registry/fake.halo.run/fakes/fake"; + when(storeClient.fetchByName(storeName)).thenReturn( + Mono.just(createExtensionStore(storeName))); + + var fake = createFakeExtension("fake", 1L); + var expectedJsonExt = objectMapper.convertValue(fake, JsonExtension.class); + + when(converter.convertFrom(JsonExtension.class, createExtensionStore(storeName))) + .thenReturn(expectedJsonExt); + + var gvk = Scheme.buildFromType(FakeExtension.class).groupVersionKind(); + StepVerifier.create(client.getJsonExtension(gvk, "fake")) + .expectNext(expectedJsonExt) + .verifyComplete(); + + verify(storeClient, times(1)).fetchByName(eq(storeName)); + verify(converter, times(1)).convertFrom(eq(JsonExtension.class), + eq(createExtensionStore(storeName))); + } + + @Nested @DisplayName("Extension watcher test") class WatcherTest { diff --git a/application/src/test/java/run/halo/app/extension/router/ExtensionRouterFunctionFactoryTest.java b/application/src/test/java/run/halo/app/extension/router/ExtensionRouterFunctionFactoryTest.java index 41060d568..78a43b5c6 100644 --- a/application/src/test/java/run/halo/app/extension/router/ExtensionRouterFunctionFactoryTest.java +++ b/application/src/test/java/run/halo/app/extension/router/ExtensionRouterFunctionFactoryTest.java @@ -1,21 +1,43 @@ package run.halo.app.extension.router; +import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertInstanceOf; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.assertArg; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; +import com.fasterxml.jackson.databind.node.JsonNodeFactory; +import com.github.fge.jackson.jsonpointer.JsonPointer; +import com.github.fge.jsonpatch.AddOperation; +import com.github.fge.jsonpatch.JsonPatch; import java.util.List; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Nested; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; +import org.mockito.InjectMocks; import org.mockito.Mock; +import org.mockito.Spy; import org.mockito.junit.jupiter.MockitoExtension; +import org.springframework.http.HttpHeaders; +import org.springframework.http.HttpMethod; +import org.springframework.http.HttpStatus; +import org.springframework.http.MediaType; import org.springframework.http.codec.HttpMessageReader; +import org.springframework.http.converter.json.Jackson2ObjectMapperBuilder; import org.springframework.mock.http.server.reactive.MockServerHttpRequest; import org.springframework.mock.web.server.MockServerWebExchange; +import org.springframework.test.web.reactive.server.WebTestClient; import org.springframework.web.reactive.function.server.HandlerFunction; import org.springframework.web.reactive.function.server.HandlerStrategies; import org.springframework.web.reactive.function.server.ServerRequest; import org.springframework.web.reactive.function.server.ServerResponse; import org.springframework.web.server.ServerWebExchange; +import reactor.core.publisher.Mono; import run.halo.app.extension.FakeExtension; +import run.halo.app.extension.JsonExtension; +import run.halo.app.extension.Metadata; import run.halo.app.extension.ReactiveExtensionClient; import run.halo.app.extension.Scheme; import run.halo.app.extension.router.ExtensionRouterFunctionFactory.CreateHandler; @@ -29,11 +51,94 @@ class ExtensionRouterFunctionFactoryTest { @Mock ReactiveExtensionClient client; + @Spy + Scheme scheme = Scheme.buildFromType(FakeExtension.class); + + @InjectMocks + ExtensionRouterFunctionFactory factory; + + WebTestClient webClient; + + @BeforeEach + void setUp() { + webClient = WebTestClient.bindToRouterFunction(factory.create()).build(); + } + + @Nested + class PatchTest { + + @Test + void shouldResponse404IfMethodNotPatch() { + webClient.method(HttpMethod.POST) + .uri("/apis/fake.halo.run/v1alpha1/fakes/my-fake") + .exchange() + .expectStatus().isNotFound(); + } + + @Test + void shouldResponse415IfMediaTypeIsInsufficient() { + webClient.method(HttpMethod.PATCH) + .uri("/apis/fake.halo.run/v1alpha1/fakes/my-fake") + .exchange() + .expectStatus().isEqualTo(HttpStatus.UNSUPPORTED_MEDIA_TYPE); + + webClient.method(HttpMethod.PATCH) + .uri("/apis/fake.halo.run/v1alpha1/fakes/my-fake") + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON.toString()) + .exchange() + .expectStatus().isEqualTo(HttpStatus.UNSUPPORTED_MEDIA_TYPE); + } + + @Test + void shouldResponseBadRequestIfNoPatchBody() { + webClient.method(HttpMethod.PATCH) + .uri("/apis/fake.halo.run/v1alpha1/fakes/my-fake") + .header(HttpHeaders.CONTENT_TYPE, "application/json-patch+json") + .exchange() + .expectStatus().isBadRequest(); + } + + @Test + void shouldPatchCorrectly() { + var fake = new FakeExtension(); + var metadata = new Metadata(); + metadata.setName("my-fake"); + fake.setMetadata(metadata); + var mapper = Jackson2ObjectMapperBuilder.json().build(); + var jsonExt = mapper.convertValue(fake, JsonExtension.class); + + when(client.getJsonExtension(scheme.groupVersionKind(), "my-fake")) + .thenReturn(Mono.just(jsonExt)); + + var status = new FakeExtension.FakeStatus(); + status.setState("running"); + fake.setStatus(status); + var updatedExt = mapper.convertValue(fake, JsonExtension.class); + when(client.update(any(JsonExtension.class))).thenReturn(Mono.just(updatedExt)); + + var stateNode = JsonNodeFactory.instance.textNode("running"); + var jsonPatch = new JsonPatch(List.of( + new AddOperation(JsonPointer.of("status", "state"), stateNode) + )); + webClient.method(HttpMethod.PATCH) + .uri("/apis/fake.halo.run/v1alpha1/fakes/my-fake") + .header(HttpHeaders.CONTENT_TYPE, "application/json-patch+json") + .bodyValue(jsonPatch) + .exchange() + .expectStatus().isOk() + .expectBody(JsonExtension.class).isEqualTo(updatedExt); + + verify(client).update(assertArg(ext -> { + var state = ext.getInternal().get("status").get("state") + .asText(); + assertEquals("running", state); + })); + } + } + + @Test void shouldCreateSuccessfully() { - var scheme = Scheme.buildFromType(FakeExtension.class); - var factory = new ExtensionRouterFunctionFactory(scheme, client); - var routerFunction = factory.create(); testCases().forEach(testCase -> { diff --git a/ui/packages/api-client/src/.openapi-generator/FILES b/ui/packages/api-client/src/.openapi-generator/FILES index 75f44ff38..569961a5c 100644 --- a/ui/packages/api-client/src/.openapi-generator/FILES +++ b/ui/packages/api-client/src/.openapi-generator/FILES @@ -1,5 +1,6 @@ .gitignore .npmignore +.openapi-generator-ignore api.ts api/api-console-halo-run-v1alpha1-attachment-api.ts api/api-console-halo-run-v1alpha1-auth-provider-api.ts @@ -80,6 +81,7 @@ common.ts configuration.ts git_push.sh index.ts +models/add-operation.ts models/annotation-setting-list.ts models/annotation-setting-spec.ts models/annotation-setting.ts @@ -126,6 +128,7 @@ models/content-wrapper.ts models/content.ts models/contributor-vo.ts models/contributor.ts +models/copy-operation.ts models/counter-list.ts models/counter-request.ts models/counter.ts @@ -154,6 +157,7 @@ models/index.ts models/install-from-uri-request.ts models/interest-reason-subject.ts models/interest-reason.ts +models/json-patch-inner.ts models/license.ts models/list-result-reply-vo.ts models/listed-auth-provider.ts @@ -184,6 +188,7 @@ models/menu-spec.ts models/menu-vo.ts models/menu.ts models/metadata.ts +models/move-operation.ts models/navigation-post-vo.ts models/notification-list.ts models/notification-spec.ts @@ -240,6 +245,8 @@ models/reason-type.ts models/reason.ts models/ref.ts models/register-verify-email-request.ts +models/remove-operation.ts +models/replace-operation.ts models/reply-list.ts models/reply-request.ts models/reply-spec.ts @@ -295,6 +302,7 @@ models/tag-vo.ts models/tag.ts models/template-content.ts models/template-descriptor.ts +models/test-operation.ts models/theme-list.ts models/theme-spec.ts models/theme-status.ts diff --git a/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-auth-provider-api.ts b/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-auth-provider-api.ts index 6b0e13b82..4c7561359 100644 --- a/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-auth-provider-api.ts +++ b/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-auth-provider-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { AuthProvider } from '../models'; // @ts-ignore import { AuthProviderList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * AuthHaloRunV1alpha1AuthProviderApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const AuthHaloRunV1alpha1AuthProviderApiAxiosParamCreator = function (con options: localVarRequestOptions, }; }, + /** + * Patch auth.halo.run/v1alpha1/AuthProvider + * @param {string} name Name of authprovider + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchAuthHaloRunV1alpha1AuthProvider: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchAuthHaloRunV1alpha1AuthProvider', 'name', name) + const localVarPath = `/apis/auth.halo.run/v1alpha1/authproviders/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update auth.halo.run/v1alpha1/AuthProvider * @param {string} name Name of authprovider @@ -323,6 +370,19 @@ export const AuthHaloRunV1alpha1AuthProviderApiFp = function(configuration?: Con const localVarOperationServerBasePath = operationServerMap['AuthHaloRunV1alpha1AuthProviderApi.listAuthHaloRunV1alpha1AuthProvider']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch auth.halo.run/v1alpha1/AuthProvider + * @param {string} name Name of authprovider + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchAuthHaloRunV1alpha1AuthProvider(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchAuthHaloRunV1alpha1AuthProvider(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['AuthHaloRunV1alpha1AuthProviderApi.patchAuthHaloRunV1alpha1AuthProvider']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update auth.halo.run/v1alpha1/AuthProvider * @param {string} name Name of authprovider @@ -382,6 +442,15 @@ export const AuthHaloRunV1alpha1AuthProviderApiFactory = function (configuration listAuthHaloRunV1alpha1AuthProvider(requestParameters: AuthHaloRunV1alpha1AuthProviderApiListAuthHaloRunV1alpha1AuthProviderRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listAuthHaloRunV1alpha1AuthProvider(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch auth.halo.run/v1alpha1/AuthProvider + * @param {AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchAuthHaloRunV1alpha1AuthProvider(requestParameters: AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchAuthHaloRunV1alpha1AuthProvider(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update auth.halo.run/v1alpha1/AuthProvider * @param {AuthHaloRunV1alpha1AuthProviderApiUpdateAuthHaloRunV1alpha1AuthProviderRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface AuthHaloRunV1alpha1AuthProviderApiListAuthHaloRunV1alpha1AuthPr readonly sort?: Array } +/** + * Request parameters for patchAuthHaloRunV1alpha1AuthProvider operation in AuthHaloRunV1alpha1AuthProviderApi. + * @export + * @interface AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest + */ +export interface AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest { + /** + * Name of authprovider + * @type {string} + * @memberof AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProvider + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProvider + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateAuthHaloRunV1alpha1AuthProvider operation in AuthHaloRunV1alpha1AuthProviderApi. * @export @@ -550,6 +640,17 @@ export class AuthHaloRunV1alpha1AuthProviderApi extends BaseAPI { return AuthHaloRunV1alpha1AuthProviderApiFp(this.configuration).listAuthHaloRunV1alpha1AuthProvider(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch auth.halo.run/v1alpha1/AuthProvider + * @param {AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AuthHaloRunV1alpha1AuthProviderApi + */ + public patchAuthHaloRunV1alpha1AuthProvider(requestParameters: AuthHaloRunV1alpha1AuthProviderApiPatchAuthHaloRunV1alpha1AuthProviderRequest, options?: RawAxiosRequestConfig) { + return AuthHaloRunV1alpha1AuthProviderApiFp(this.configuration).patchAuthHaloRunV1alpha1AuthProvider(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update auth.halo.run/v1alpha1/AuthProvider * @param {AuthHaloRunV1alpha1AuthProviderApiUpdateAuthHaloRunV1alpha1AuthProviderRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-user-connection-api.ts b/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-user-connection-api.ts index f484a8d23..4c975372a 100644 --- a/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-user-connection-api.ts +++ b/ui/packages/api-client/src/api/auth-halo-run-v1alpha1-user-connection-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { UserConnection } from '../models'; // @ts-ignore import { UserConnectionList } from '../models'; @@ -216,6 +218,51 @@ export const AuthHaloRunV1alpha1UserConnectionApiAxiosParamCreator = function (c options: localVarRequestOptions, }; }, + /** + * Patch auth.halo.run/v1alpha1/UserConnection + * @param {string} name Name of userconnection + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchAuthHaloRunV1alpha1UserConnection: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchAuthHaloRunV1alpha1UserConnection', 'name', name) + const localVarPath = `/apis/auth.halo.run/v1alpha1/userconnections/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update auth.halo.run/v1alpha1/UserConnection * @param {string} name Name of userconnection @@ -323,6 +370,19 @@ export const AuthHaloRunV1alpha1UserConnectionApiFp = function(configuration?: C const localVarOperationServerBasePath = operationServerMap['AuthHaloRunV1alpha1UserConnectionApi.listAuthHaloRunV1alpha1UserConnection']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch auth.halo.run/v1alpha1/UserConnection + * @param {string} name Name of userconnection + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchAuthHaloRunV1alpha1UserConnection(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchAuthHaloRunV1alpha1UserConnection(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['AuthHaloRunV1alpha1UserConnectionApi.patchAuthHaloRunV1alpha1UserConnection']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update auth.halo.run/v1alpha1/UserConnection * @param {string} name Name of userconnection @@ -382,6 +442,15 @@ export const AuthHaloRunV1alpha1UserConnectionApiFactory = function (configurati listAuthHaloRunV1alpha1UserConnection(requestParameters: AuthHaloRunV1alpha1UserConnectionApiListAuthHaloRunV1alpha1UserConnectionRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listAuthHaloRunV1alpha1UserConnection(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch auth.halo.run/v1alpha1/UserConnection + * @param {AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchAuthHaloRunV1alpha1UserConnection(requestParameters: AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchAuthHaloRunV1alpha1UserConnection(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update auth.halo.run/v1alpha1/UserConnection * @param {AuthHaloRunV1alpha1UserConnectionApiUpdateAuthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface AuthHaloRunV1alpha1UserConnectionApiListAuthHaloRunV1alpha1User readonly sort?: Array } +/** + * Request parameters for patchAuthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi. + * @export + * @interface AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest + */ +export interface AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest { + /** + * Name of userconnection + * @type {string} + * @memberof AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnection + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnection + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateAuthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi. * @export @@ -550,6 +640,17 @@ export class AuthHaloRunV1alpha1UserConnectionApi extends BaseAPI { return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration).listAuthHaloRunV1alpha1UserConnection(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch auth.halo.run/v1alpha1/UserConnection + * @param {AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof AuthHaloRunV1alpha1UserConnectionApi + */ + public patchAuthHaloRunV1alpha1UserConnection(requestParameters: AuthHaloRunV1alpha1UserConnectionApiPatchAuthHaloRunV1alpha1UserConnectionRequest, options?: RawAxiosRequestConfig) { + return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration).patchAuthHaloRunV1alpha1UserConnection(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update auth.halo.run/v1alpha1/UserConnection * @param {AuthHaloRunV1alpha1UserConnectionApiUpdateAuthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-category-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-category-api.ts index c74628b20..5eae5f5f3 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-category-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-category-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Category } from '../models'; // @ts-ignore import { CategoryList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * ContentHaloRunV1alpha1CategoryApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1CategoryApiAxiosParamCreator = function (conf options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Category + * @param {string} name Name of category + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Category: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Category', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/categories/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Category * @param {string} name Name of category @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1CategoryApiFp = function(configuration?: Conf const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1CategoryApi.listContentHaloRunV1alpha1Category']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Category + * @param {string} name Name of category + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Category(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Category(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1CategoryApi.patchContentHaloRunV1alpha1Category']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Category * @param {string} name Name of category @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1CategoryApiFactory = function (configuration? listContentHaloRunV1alpha1Category(requestParameters: ContentHaloRunV1alpha1CategoryApiListContentHaloRunV1alpha1CategoryRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Category(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Category + * @param {ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Category(requestParameters: ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Category(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Category * @param {ContentHaloRunV1alpha1CategoryApiUpdateContentHaloRunV1alpha1CategoryRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1CategoryApiListContentHaloRunV1alpha1Cate readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Category operation in ContentHaloRunV1alpha1CategoryApi. + * @export + * @interface ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest + */ +export interface ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest { + /** + * Name of category + * @type {string} + * @memberof ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1Category + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1Category + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Category operation in ContentHaloRunV1alpha1CategoryApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1CategoryApi extends BaseAPI { return ContentHaloRunV1alpha1CategoryApiFp(this.configuration).listContentHaloRunV1alpha1Category(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Category + * @param {ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1CategoryApi + */ + public patchContentHaloRunV1alpha1Category(requestParameters: ContentHaloRunV1alpha1CategoryApiPatchContentHaloRunV1alpha1CategoryRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1CategoryApiFp(this.configuration).patchContentHaloRunV1alpha1Category(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Category * @param {ContentHaloRunV1alpha1CategoryApiUpdateContentHaloRunV1alpha1CategoryRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-comment-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-comment-api.ts index b109854f9..64d17e16e 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-comment-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-comment-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Comment } from '../models'; // @ts-ignore import { CommentList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * ContentHaloRunV1alpha1CommentApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1CommentApiAxiosParamCreator = function (confi options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Comment + * @param {string} name Name of comment + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Comment: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Comment', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/comments/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Comment * @param {string} name Name of comment @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1CommentApiFp = function(configuration?: Confi const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1CommentApi.listContentHaloRunV1alpha1Comment']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Comment + * @param {string} name Name of comment + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Comment(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Comment(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1CommentApi.patchContentHaloRunV1alpha1Comment']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Comment * @param {string} name Name of comment @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1CommentApiFactory = function (configuration?: listContentHaloRunV1alpha1Comment(requestParameters: ContentHaloRunV1alpha1CommentApiListContentHaloRunV1alpha1CommentRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Comment(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Comment + * @param {ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Comment(requestParameters: ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Comment(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Comment * @param {ContentHaloRunV1alpha1CommentApiUpdateContentHaloRunV1alpha1CommentRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1CommentApiListContentHaloRunV1alpha1Comme readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Comment operation in ContentHaloRunV1alpha1CommentApi. + * @export + * @interface ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest + */ +export interface ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest { + /** + * Name of comment + * @type {string} + * @memberof ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1Comment + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1Comment + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Comment operation in ContentHaloRunV1alpha1CommentApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1CommentApi extends BaseAPI { return ContentHaloRunV1alpha1CommentApiFp(this.configuration).listContentHaloRunV1alpha1Comment(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Comment + * @param {ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1CommentApi + */ + public patchContentHaloRunV1alpha1Comment(requestParameters: ContentHaloRunV1alpha1CommentApiPatchContentHaloRunV1alpha1CommentRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1CommentApiFp(this.configuration).patchContentHaloRunV1alpha1Comment(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Comment * @param {ContentHaloRunV1alpha1CommentApiUpdateContentHaloRunV1alpha1CommentRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-post-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-post-api.ts index 3b7ece9d8..ce9feba2e 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-post-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-post-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Post } from '../models'; // @ts-ignore import { PostList } from '../models'; @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1PostApiAxiosParamCreator = function (configur options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Post + * @param {string} name Name of post + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Post: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Post', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/posts/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Post * @param {string} name Name of post @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1PostApiFp = function(configuration?: Configur const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1PostApi.listContentHaloRunV1alpha1Post']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Post + * @param {string} name Name of post + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Post(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Post(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1PostApi.patchContentHaloRunV1alpha1Post']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Post * @param {string} name Name of post @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1PostApiFactory = function (configuration?: Co listContentHaloRunV1alpha1Post(requestParameters: ContentHaloRunV1alpha1PostApiListContentHaloRunV1alpha1PostRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Post(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Post + * @param {ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Post(requestParameters: ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Post(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Post * @param {ContentHaloRunV1alpha1PostApiUpdateContentHaloRunV1alpha1PostRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1PostApiListContentHaloRunV1alpha1PostRequ readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Post operation in ContentHaloRunV1alpha1PostApi. + * @export + * @interface ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest + */ +export interface ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest { + /** + * Name of post + * @type {string} + * @memberof ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1Post + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1Post + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Post operation in ContentHaloRunV1alpha1PostApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1PostApi extends BaseAPI { return ContentHaloRunV1alpha1PostApiFp(this.configuration).listContentHaloRunV1alpha1Post(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Post + * @param {ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1PostApi + */ + public patchContentHaloRunV1alpha1Post(requestParameters: ContentHaloRunV1alpha1PostApiPatchContentHaloRunV1alpha1PostRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1PostApiFp(this.configuration).patchContentHaloRunV1alpha1Post(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Post * @param {ContentHaloRunV1alpha1PostApiUpdateContentHaloRunV1alpha1PostRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-reply-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-reply-api.ts index cc2404b0c..382ba12ad 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-reply-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-reply-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Reply } from '../models'; // @ts-ignore import { ReplyList } from '../models'; @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1ReplyApiAxiosParamCreator = function (configu options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Reply + * @param {string} name Name of reply + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Reply: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Reply', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/replies/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Reply * @param {string} name Name of reply @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1ReplyApiFp = function(configuration?: Configu const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1ReplyApi.listContentHaloRunV1alpha1Reply']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Reply + * @param {string} name Name of reply + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Reply(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Reply(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1ReplyApi.patchContentHaloRunV1alpha1Reply']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Reply * @param {string} name Name of reply @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1ReplyApiFactory = function (configuration?: C listContentHaloRunV1alpha1Reply(requestParameters: ContentHaloRunV1alpha1ReplyApiListContentHaloRunV1alpha1ReplyRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Reply(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Reply + * @param {ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Reply(requestParameters: ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Reply(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Reply * @param {ContentHaloRunV1alpha1ReplyApiUpdateContentHaloRunV1alpha1ReplyRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1ReplyApiListContentHaloRunV1alpha1ReplyRe readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Reply operation in ContentHaloRunV1alpha1ReplyApi. + * @export + * @interface ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest + */ +export interface ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest { + /** + * Name of reply + * @type {string} + * @memberof ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1Reply + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1Reply + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Reply operation in ContentHaloRunV1alpha1ReplyApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1ReplyApi extends BaseAPI { return ContentHaloRunV1alpha1ReplyApiFp(this.configuration).listContentHaloRunV1alpha1Reply(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Reply + * @param {ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1ReplyApi + */ + public patchContentHaloRunV1alpha1Reply(requestParameters: ContentHaloRunV1alpha1ReplyApiPatchContentHaloRunV1alpha1ReplyRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1ReplyApiFp(this.configuration).patchContentHaloRunV1alpha1Reply(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Reply * @param {ContentHaloRunV1alpha1ReplyApiUpdateContentHaloRunV1alpha1ReplyRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-single-page-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-single-page-api.ts index 0e57f2e76..e1938e0ef 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-single-page-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-single-page-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { SinglePage } from '../models'; // @ts-ignore import { SinglePageList } from '../models'; @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1SinglePageApiAxiosParamCreator = function (co options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/SinglePage + * @param {string} name Name of singlepage + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1SinglePage: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1SinglePage', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/singlepages/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/SinglePage * @param {string} name Name of singlepage @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1SinglePageApiFp = function(configuration?: Co const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1SinglePageApi.listContentHaloRunV1alpha1SinglePage']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/SinglePage + * @param {string} name Name of singlepage + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1SinglePage(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1SinglePage(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1SinglePageApi.patchContentHaloRunV1alpha1SinglePage']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/SinglePage * @param {string} name Name of singlepage @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1SinglePageApiFactory = function (configuratio listContentHaloRunV1alpha1SinglePage(requestParameters: ContentHaloRunV1alpha1SinglePageApiListContentHaloRunV1alpha1SinglePageRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1SinglePage(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/SinglePage + * @param {ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1SinglePage(requestParameters: ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1SinglePage(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/SinglePage * @param {ContentHaloRunV1alpha1SinglePageApiUpdateContentHaloRunV1alpha1SinglePageRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1SinglePageApiListContentHaloRunV1alpha1Si readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1SinglePage operation in ContentHaloRunV1alpha1SinglePageApi. + * @export + * @interface ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest + */ +export interface ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest { + /** + * Name of singlepage + * @type {string} + * @memberof ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePage + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePage + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1SinglePage operation in ContentHaloRunV1alpha1SinglePageApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1SinglePageApi extends BaseAPI { return ContentHaloRunV1alpha1SinglePageApiFp(this.configuration).listContentHaloRunV1alpha1SinglePage(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/SinglePage + * @param {ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1SinglePageApi + */ + public patchContentHaloRunV1alpha1SinglePage(requestParameters: ContentHaloRunV1alpha1SinglePageApiPatchContentHaloRunV1alpha1SinglePageRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1SinglePageApiFp(this.configuration).patchContentHaloRunV1alpha1SinglePage(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/SinglePage * @param {ContentHaloRunV1alpha1SinglePageApiUpdateContentHaloRunV1alpha1SinglePageRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-snapshot-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-snapshot-api.ts index 2d0111354..88a5df7eb 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-snapshot-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-snapshot-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Snapshot } from '../models'; // @ts-ignore import { SnapshotList } from '../models'; @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1SnapshotApiAxiosParamCreator = function (conf options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Snapshot + * @param {string} name Name of snapshot + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Snapshot: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Snapshot', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/snapshots/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Snapshot * @param {string} name Name of snapshot @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1SnapshotApiFp = function(configuration?: Conf const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1SnapshotApi.listContentHaloRunV1alpha1Snapshot']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Snapshot + * @param {string} name Name of snapshot + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Snapshot(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Snapshot(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1SnapshotApi.patchContentHaloRunV1alpha1Snapshot']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Snapshot * @param {string} name Name of snapshot @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1SnapshotApiFactory = function (configuration? listContentHaloRunV1alpha1Snapshot(requestParameters: ContentHaloRunV1alpha1SnapshotApiListContentHaloRunV1alpha1SnapshotRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Snapshot(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Snapshot + * @param {ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Snapshot(requestParameters: ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Snapshot(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Snapshot * @param {ContentHaloRunV1alpha1SnapshotApiUpdateContentHaloRunV1alpha1SnapshotRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1SnapshotApiListContentHaloRunV1alpha1Snap readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Snapshot operation in ContentHaloRunV1alpha1SnapshotApi. + * @export + * @interface ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest + */ +export interface ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest { + /** + * Name of snapshot + * @type {string} + * @memberof ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1Snapshot + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1Snapshot + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Snapshot operation in ContentHaloRunV1alpha1SnapshotApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1SnapshotApi extends BaseAPI { return ContentHaloRunV1alpha1SnapshotApiFp(this.configuration).listContentHaloRunV1alpha1Snapshot(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Snapshot + * @param {ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1SnapshotApi + */ + public patchContentHaloRunV1alpha1Snapshot(requestParameters: ContentHaloRunV1alpha1SnapshotApiPatchContentHaloRunV1alpha1SnapshotRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1SnapshotApiFp(this.configuration).patchContentHaloRunV1alpha1Snapshot(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Snapshot * @param {ContentHaloRunV1alpha1SnapshotApiUpdateContentHaloRunV1alpha1SnapshotRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-tag-api.ts b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-tag-api.ts index f2057d02c..6d8fb86d3 100644 --- a/ui/packages/api-client/src/api/content-halo-run-v1alpha1-tag-api.ts +++ b/ui/packages/api-client/src/api/content-halo-run-v1alpha1-tag-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Tag } from '../models'; // @ts-ignore import { TagList } from '../models'; @@ -216,6 +218,51 @@ export const ContentHaloRunV1alpha1TagApiAxiosParamCreator = function (configura options: localVarRequestOptions, }; }, + /** + * Patch content.halo.run/v1alpha1/Tag + * @param {string} name Name of tag + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Tag: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchContentHaloRunV1alpha1Tag', 'name', name) + const localVarPath = `/apis/content.halo.run/v1alpha1/tags/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update content.halo.run/v1alpha1/Tag * @param {string} name Name of tag @@ -323,6 +370,19 @@ export const ContentHaloRunV1alpha1TagApiFp = function(configuration?: Configura const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1TagApi.listContentHaloRunV1alpha1Tag']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch content.halo.run/v1alpha1/Tag + * @param {string} name Name of tag + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchContentHaloRunV1alpha1Tag(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchContentHaloRunV1alpha1Tag(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ContentHaloRunV1alpha1TagApi.patchContentHaloRunV1alpha1Tag']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update content.halo.run/v1alpha1/Tag * @param {string} name Name of tag @@ -382,6 +442,15 @@ export const ContentHaloRunV1alpha1TagApiFactory = function (configuration?: Con listContentHaloRunV1alpha1Tag(requestParameters: ContentHaloRunV1alpha1TagApiListContentHaloRunV1alpha1TagRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listContentHaloRunV1alpha1Tag(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch content.halo.run/v1alpha1/Tag + * @param {ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchContentHaloRunV1alpha1Tag(requestParameters: ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchContentHaloRunV1alpha1Tag(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update content.halo.run/v1alpha1/Tag * @param {ContentHaloRunV1alpha1TagApiUpdateContentHaloRunV1alpha1TagRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ContentHaloRunV1alpha1TagApiListContentHaloRunV1alpha1TagReques readonly sort?: Array } +/** + * Request parameters for patchContentHaloRunV1alpha1Tag operation in ContentHaloRunV1alpha1TagApi. + * @export + * @interface ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest + */ +export interface ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest { + /** + * Name of tag + * @type {string} + * @memberof ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1Tag + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1Tag + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateContentHaloRunV1alpha1Tag operation in ContentHaloRunV1alpha1TagApi. * @export @@ -550,6 +640,17 @@ export class ContentHaloRunV1alpha1TagApi extends BaseAPI { return ContentHaloRunV1alpha1TagApiFp(this.configuration).listContentHaloRunV1alpha1Tag(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch content.halo.run/v1alpha1/Tag + * @param {ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ContentHaloRunV1alpha1TagApi + */ + public patchContentHaloRunV1alpha1Tag(requestParameters: ContentHaloRunV1alpha1TagApiPatchContentHaloRunV1alpha1TagRequest, options?: RawAxiosRequestConfig) { + return ContentHaloRunV1alpha1TagApiFp(this.configuration).patchContentHaloRunV1alpha1Tag(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update content.halo.run/v1alpha1/Tag * @param {ContentHaloRunV1alpha1TagApiUpdateContentHaloRunV1alpha1TagRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/metrics-halo-run-v1alpha1-counter-api.ts b/ui/packages/api-client/src/api/metrics-halo-run-v1alpha1-counter-api.ts index 261dd2f6e..2e6fa4269 100644 --- a/ui/packages/api-client/src/api/metrics-halo-run-v1alpha1-counter-api.ts +++ b/ui/packages/api-client/src/api/metrics-halo-run-v1alpha1-counter-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Counter } from '../models'; // @ts-ignore import { CounterList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * MetricsHaloRunV1alpha1CounterApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const MetricsHaloRunV1alpha1CounterApiAxiosParamCreator = function (confi options: localVarRequestOptions, }; }, + /** + * Patch metrics.halo.run/v1alpha1/Counter + * @param {string} name Name of counter + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchMetricsHaloRunV1alpha1Counter: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchMetricsHaloRunV1alpha1Counter', 'name', name) + const localVarPath = `/apis/metrics.halo.run/v1alpha1/counters/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update metrics.halo.run/v1alpha1/Counter * @param {string} name Name of counter @@ -323,6 +370,19 @@ export const MetricsHaloRunV1alpha1CounterApiFp = function(configuration?: Confi const localVarOperationServerBasePath = operationServerMap['MetricsHaloRunV1alpha1CounterApi.listMetricsHaloRunV1alpha1Counter']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch metrics.halo.run/v1alpha1/Counter + * @param {string} name Name of counter + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchMetricsHaloRunV1alpha1Counter(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchMetricsHaloRunV1alpha1Counter(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['MetricsHaloRunV1alpha1CounterApi.patchMetricsHaloRunV1alpha1Counter']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update metrics.halo.run/v1alpha1/Counter * @param {string} name Name of counter @@ -382,6 +442,15 @@ export const MetricsHaloRunV1alpha1CounterApiFactory = function (configuration?: listMetricsHaloRunV1alpha1Counter(requestParameters: MetricsHaloRunV1alpha1CounterApiListMetricsHaloRunV1alpha1CounterRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listMetricsHaloRunV1alpha1Counter(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch metrics.halo.run/v1alpha1/Counter + * @param {MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchMetricsHaloRunV1alpha1Counter(requestParameters: MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchMetricsHaloRunV1alpha1Counter(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update metrics.halo.run/v1alpha1/Counter * @param {MetricsHaloRunV1alpha1CounterApiUpdateMetricsHaloRunV1alpha1CounterRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface MetricsHaloRunV1alpha1CounterApiListMetricsHaloRunV1alpha1Count readonly sort?: Array } +/** + * Request parameters for patchMetricsHaloRunV1alpha1Counter operation in MetricsHaloRunV1alpha1CounterApi. + * @export + * @interface MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest + */ +export interface MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest { + /** + * Name of counter + * @type {string} + * @memberof MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1Counter + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1Counter + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateMetricsHaloRunV1alpha1Counter operation in MetricsHaloRunV1alpha1CounterApi. * @export @@ -550,6 +640,17 @@ export class MetricsHaloRunV1alpha1CounterApi extends BaseAPI { return MetricsHaloRunV1alpha1CounterApiFp(this.configuration).listMetricsHaloRunV1alpha1Counter(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch metrics.halo.run/v1alpha1/Counter + * @param {MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MetricsHaloRunV1alpha1CounterApi + */ + public patchMetricsHaloRunV1alpha1Counter(requestParameters: MetricsHaloRunV1alpha1CounterApiPatchMetricsHaloRunV1alpha1CounterRequest, options?: RawAxiosRequestConfig) { + return MetricsHaloRunV1alpha1CounterApiFp(this.configuration).patchMetricsHaloRunV1alpha1Counter(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update metrics.halo.run/v1alpha1/Counter * @param {MetricsHaloRunV1alpha1CounterApiUpdateMetricsHaloRunV1alpha1CounterRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/migration-halo-run-v1alpha1-backup-api.ts b/ui/packages/api-client/src/api/migration-halo-run-v1alpha1-backup-api.ts index 012904e6e..f442fb063 100644 --- a/ui/packages/api-client/src/api/migration-halo-run-v1alpha1-backup-api.ts +++ b/ui/packages/api-client/src/api/migration-halo-run-v1alpha1-backup-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Backup } from '../models'; // @ts-ignore import { BackupList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * MigrationHaloRunV1alpha1BackupApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const MigrationHaloRunV1alpha1BackupApiAxiosParamCreator = function (conf options: localVarRequestOptions, }; }, + /** + * Patch migration.halo.run/v1alpha1/Backup + * @param {string} name Name of backup + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchMigrationHaloRunV1alpha1Backup: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchMigrationHaloRunV1alpha1Backup', 'name', name) + const localVarPath = `/apis/migration.halo.run/v1alpha1/backups/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update migration.halo.run/v1alpha1/Backup * @param {string} name Name of backup @@ -323,6 +370,19 @@ export const MigrationHaloRunV1alpha1BackupApiFp = function(configuration?: Conf const localVarOperationServerBasePath = operationServerMap['MigrationHaloRunV1alpha1BackupApi.listMigrationHaloRunV1alpha1Backup']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch migration.halo.run/v1alpha1/Backup + * @param {string} name Name of backup + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchMigrationHaloRunV1alpha1Backup(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchMigrationHaloRunV1alpha1Backup(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['MigrationHaloRunV1alpha1BackupApi.patchMigrationHaloRunV1alpha1Backup']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update migration.halo.run/v1alpha1/Backup * @param {string} name Name of backup @@ -382,6 +442,15 @@ export const MigrationHaloRunV1alpha1BackupApiFactory = function (configuration? listMigrationHaloRunV1alpha1Backup(requestParameters: MigrationHaloRunV1alpha1BackupApiListMigrationHaloRunV1alpha1BackupRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listMigrationHaloRunV1alpha1Backup(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch migration.halo.run/v1alpha1/Backup + * @param {MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchMigrationHaloRunV1alpha1Backup(requestParameters: MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchMigrationHaloRunV1alpha1Backup(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update migration.halo.run/v1alpha1/Backup * @param {MigrationHaloRunV1alpha1BackupApiUpdateMigrationHaloRunV1alpha1BackupRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface MigrationHaloRunV1alpha1BackupApiListMigrationHaloRunV1alpha1Ba readonly sort?: Array } +/** + * Request parameters for patchMigrationHaloRunV1alpha1Backup operation in MigrationHaloRunV1alpha1BackupApi. + * @export + * @interface MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest + */ +export interface MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest { + /** + * Name of backup + * @type {string} + * @memberof MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1Backup + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1Backup + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateMigrationHaloRunV1alpha1Backup operation in MigrationHaloRunV1alpha1BackupApi. * @export @@ -550,6 +640,17 @@ export class MigrationHaloRunV1alpha1BackupApi extends BaseAPI { return MigrationHaloRunV1alpha1BackupApiFp(this.configuration).listMigrationHaloRunV1alpha1Backup(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch migration.halo.run/v1alpha1/Backup + * @param {MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof MigrationHaloRunV1alpha1BackupApi + */ + public patchMigrationHaloRunV1alpha1Backup(requestParameters: MigrationHaloRunV1alpha1BackupApiPatchMigrationHaloRunV1alpha1BackupRequest, options?: RawAxiosRequestConfig) { + return MigrationHaloRunV1alpha1BackupApiFp(this.configuration).patchMigrationHaloRunV1alpha1Backup(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update migration.halo.run/v1alpha1/Backup * @param {MigrationHaloRunV1alpha1BackupApiUpdateMigrationHaloRunV1alpha1BackupRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-api.ts index a52825922..be27f095a 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Notification } from '../models'; // @ts-ignore import { NotificationList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1NotificationApiAxiosParamCreator = funct options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/Notification + * @param {string} name Name of notification + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Notification: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1Notification', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/notifications/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/Notification * @param {string} name Name of notification @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1NotificationApiFp = function(configurati const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotificationApi.listNotificationHaloRunV1alpha1Notification']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/Notification + * @param {string} name Name of notification + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1Notification(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1Notification(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotificationApi.patchNotificationHaloRunV1alpha1Notification']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/Notification * @param {string} name Name of notification @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1NotificationApiFactory = function (confi listNotificationHaloRunV1alpha1Notification(requestParameters: NotificationHaloRunV1alpha1NotificationApiListNotificationHaloRunV1alpha1NotificationRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1Notification(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/Notification + * @param {NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Notification(requestParameters: NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1Notification(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/Notification * @param {NotificationHaloRunV1alpha1NotificationApiUpdateNotificationHaloRunV1alpha1NotificationRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1NotificationApiListNotificationHaloR readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1Notification operation in NotificationHaloRunV1alpha1NotificationApi. + * @export + * @interface NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest + */ +export interface NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest { + /** + * Name of notification + * @type {string} + * @memberof NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1Notification + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1Notification + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1Notification operation in NotificationHaloRunV1alpha1NotificationApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1NotificationApi extends BaseAPI { return NotificationHaloRunV1alpha1NotificationApiFp(this.configuration).listNotificationHaloRunV1alpha1Notification(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/Notification + * @param {NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1NotificationApi + */ + public patchNotificationHaloRunV1alpha1Notification(requestParameters: NotificationHaloRunV1alpha1NotificationApiPatchNotificationHaloRunV1alpha1NotificationRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1NotificationApiFp(this.configuration).patchNotificationHaloRunV1alpha1Notification(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/Notification * @param {NotificationHaloRunV1alpha1NotificationApiUpdateNotificationHaloRunV1alpha1NotificationRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-template-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-template-api.ts index 1fd0d743a..96a7eb382 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-template-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notification-template-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { NotificationTemplate } from '../models'; // @ts-ignore import { NotificationTemplateList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1NotificationTemplateApiAxiosParamCreator options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/NotificationTemplate + * @param {string} name Name of notificationtemplate + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1NotificationTemplate: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1NotificationTemplate', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/notificationtemplates/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/NotificationTemplate * @param {string} name Name of notificationtemplate @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1NotificationTemplateApiFp = function(con const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotificationTemplateApi.listNotificationHaloRunV1alpha1NotificationTemplate']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/NotificationTemplate + * @param {string} name Name of notificationtemplate + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1NotificationTemplate(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1NotificationTemplate(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotificationTemplateApi.patchNotificationHaloRunV1alpha1NotificationTemplate']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/NotificationTemplate * @param {string} name Name of notificationtemplate @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1NotificationTemplateApiFactory = functio listNotificationHaloRunV1alpha1NotificationTemplate(requestParameters: NotificationHaloRunV1alpha1NotificationTemplateApiListNotificationHaloRunV1alpha1NotificationTemplateRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1NotificationTemplate(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/NotificationTemplate + * @param {NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1NotificationTemplate(requestParameters: NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1NotificationTemplate(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/NotificationTemplate * @param {NotificationHaloRunV1alpha1NotificationTemplateApiUpdateNotificationHaloRunV1alpha1NotificationTemplateRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1NotificationTemplateApiListNotificat readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1NotificationTemplate operation in NotificationHaloRunV1alpha1NotificationTemplateApi. + * @export + * @interface NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest + */ +export interface NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest { + /** + * Name of notificationtemplate + * @type {string} + * @memberof NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplate + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplate + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1NotificationTemplate operation in NotificationHaloRunV1alpha1NotificationTemplateApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1NotificationTemplateApi extends BaseAPI return NotificationHaloRunV1alpha1NotificationTemplateApiFp(this.configuration).listNotificationHaloRunV1alpha1NotificationTemplate(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/NotificationTemplate + * @param {NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1NotificationTemplateApi + */ + public patchNotificationHaloRunV1alpha1NotificationTemplate(requestParameters: NotificationHaloRunV1alpha1NotificationTemplateApiPatchNotificationHaloRunV1alpha1NotificationTemplateRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1NotificationTemplateApiFp(this.configuration).patchNotificationHaloRunV1alpha1NotificationTemplate(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/NotificationTemplate * @param {NotificationHaloRunV1alpha1NotificationTemplateApiUpdateNotificationHaloRunV1alpha1NotificationTemplateRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notifier-descriptor-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notifier-descriptor-api.ts index b5fae1d86..778391e6c 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notifier-descriptor-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-notifier-descriptor-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { NotifierDescriptor } from '../models'; // @ts-ignore import { NotifierDescriptorList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1NotifierDescriptorApiAxiosParamCreator = options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/NotifierDescriptor + * @param {string} name Name of notifierDescriptor + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1NotifierDescriptor: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1NotifierDescriptor', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/notifierDescriptors/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/NotifierDescriptor * @param {string} name Name of notifierDescriptor @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1NotifierDescriptorApiFp = function(confi const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotifierDescriptorApi.listNotificationHaloRunV1alpha1NotifierDescriptor']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/NotifierDescriptor + * @param {string} name Name of notifierDescriptor + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1NotifierDescriptor(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1NotifierDescriptor(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1NotifierDescriptorApi.patchNotificationHaloRunV1alpha1NotifierDescriptor']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/NotifierDescriptor * @param {string} name Name of notifierDescriptor @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1NotifierDescriptorApiFactory = function listNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters: NotificationHaloRunV1alpha1NotifierDescriptorApiListNotificationHaloRunV1alpha1NotifierDescriptorRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/NotifierDescriptor + * @param {NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters: NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/NotifierDescriptor * @param {NotificationHaloRunV1alpha1NotifierDescriptorApiUpdateNotificationHaloRunV1alpha1NotifierDescriptorRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1NotifierDescriptorApiListNotificatio readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1NotifierDescriptor operation in NotificationHaloRunV1alpha1NotifierDescriptorApi. + * @export + * @interface NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest + */ +export interface NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest { + /** + * Name of notifierDescriptor + * @type {string} + * @memberof NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptor + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptor + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1NotifierDescriptor operation in NotificationHaloRunV1alpha1NotifierDescriptorApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1NotifierDescriptorApi extends BaseAPI { return NotificationHaloRunV1alpha1NotifierDescriptorApiFp(this.configuration).listNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/NotifierDescriptor + * @param {NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1NotifierDescriptorApi + */ + public patchNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters: NotificationHaloRunV1alpha1NotifierDescriptorApiPatchNotificationHaloRunV1alpha1NotifierDescriptorRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1NotifierDescriptorApiFp(this.configuration).patchNotificationHaloRunV1alpha1NotifierDescriptor(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/NotifierDescriptor * @param {NotificationHaloRunV1alpha1NotifierDescriptorApiUpdateNotificationHaloRunV1alpha1NotifierDescriptorRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-api.ts index dbed93fbc..2795af900 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Reason } from '../models'; // @ts-ignore import { ReasonList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1ReasonApiAxiosParamCreator = function (c options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/Reason + * @param {string} name Name of reason + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Reason: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1Reason', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/reasons/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/Reason * @param {string} name Name of reason @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1ReasonApiFp = function(configuration?: C const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1ReasonApi.listNotificationHaloRunV1alpha1Reason']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/Reason + * @param {string} name Name of reason + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1Reason(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1Reason(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1ReasonApi.patchNotificationHaloRunV1alpha1Reason']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/Reason * @param {string} name Name of reason @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1ReasonApiFactory = function (configurati listNotificationHaloRunV1alpha1Reason(requestParameters: NotificationHaloRunV1alpha1ReasonApiListNotificationHaloRunV1alpha1ReasonRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1Reason(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/Reason + * @param {NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Reason(requestParameters: NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1Reason(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/Reason * @param {NotificationHaloRunV1alpha1ReasonApiUpdateNotificationHaloRunV1alpha1ReasonRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1ReasonApiListNotificationHaloRunV1al readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1Reason operation in NotificationHaloRunV1alpha1ReasonApi. + * @export + * @interface NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest + */ +export interface NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest { + /** + * Name of reason + * @type {string} + * @memberof NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1Reason + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1Reason + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1Reason operation in NotificationHaloRunV1alpha1ReasonApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1ReasonApi extends BaseAPI { return NotificationHaloRunV1alpha1ReasonApiFp(this.configuration).listNotificationHaloRunV1alpha1Reason(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/Reason + * @param {NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1ReasonApi + */ + public patchNotificationHaloRunV1alpha1Reason(requestParameters: NotificationHaloRunV1alpha1ReasonApiPatchNotificationHaloRunV1alpha1ReasonRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1ReasonApiFp(this.configuration).patchNotificationHaloRunV1alpha1Reason(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/Reason * @param {NotificationHaloRunV1alpha1ReasonApiUpdateNotificationHaloRunV1alpha1ReasonRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-type-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-type-api.ts index 34fdbb073..e2d5fe35f 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-type-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-reason-type-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { ReasonType } from '../models'; // @ts-ignore import { ReasonTypeList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1ReasonTypeApiAxiosParamCreator = functio options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/ReasonType + * @param {string} name Name of reasontype + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1ReasonType: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1ReasonType', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/reasontypes/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/ReasonType * @param {string} name Name of reasontype @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1ReasonTypeApiFp = function(configuration const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1ReasonTypeApi.listNotificationHaloRunV1alpha1ReasonType']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/ReasonType + * @param {string} name Name of reasontype + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1ReasonType(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1ReasonType(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1ReasonTypeApi.patchNotificationHaloRunV1alpha1ReasonType']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/ReasonType * @param {string} name Name of reasontype @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1ReasonTypeApiFactory = function (configu listNotificationHaloRunV1alpha1ReasonType(requestParameters: NotificationHaloRunV1alpha1ReasonTypeApiListNotificationHaloRunV1alpha1ReasonTypeRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1ReasonType(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/ReasonType + * @param {NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1ReasonType(requestParameters: NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1ReasonType(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/ReasonType * @param {NotificationHaloRunV1alpha1ReasonTypeApiUpdateNotificationHaloRunV1alpha1ReasonTypeRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1ReasonTypeApiListNotificationHaloRun readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1ReasonType operation in NotificationHaloRunV1alpha1ReasonTypeApi. + * @export + * @interface NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest + */ +export interface NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest { + /** + * Name of reasontype + * @type {string} + * @memberof NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonType + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonType + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1ReasonType operation in NotificationHaloRunV1alpha1ReasonTypeApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1ReasonTypeApi extends BaseAPI { return NotificationHaloRunV1alpha1ReasonTypeApiFp(this.configuration).listNotificationHaloRunV1alpha1ReasonType(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/ReasonType + * @param {NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1ReasonTypeApi + */ + public patchNotificationHaloRunV1alpha1ReasonType(requestParameters: NotificationHaloRunV1alpha1ReasonTypeApiPatchNotificationHaloRunV1alpha1ReasonTypeRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1ReasonTypeApiFp(this.configuration).patchNotificationHaloRunV1alpha1ReasonType(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/ReasonType * @param {NotificationHaloRunV1alpha1ReasonTypeApiUpdateNotificationHaloRunV1alpha1ReasonTypeRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-subscription-api.ts b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-subscription-api.ts index 71de35003..0cfadacd9 100644 --- a/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-subscription-api.ts +++ b/ui/packages/api-client/src/api/notification-halo-run-v1alpha1-subscription-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Subscription } from '../models'; // @ts-ignore import { SubscriptionList } from '../models'; @@ -216,6 +218,51 @@ export const NotificationHaloRunV1alpha1SubscriptionApiAxiosParamCreator = funct options: localVarRequestOptions, }; }, + /** + * Patch notification.halo.run/v1alpha1/Subscription + * @param {string} name Name of subscription + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Subscription: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchNotificationHaloRunV1alpha1Subscription', 'name', name) + const localVarPath = `/apis/notification.halo.run/v1alpha1/subscriptions/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update notification.halo.run/v1alpha1/Subscription * @param {string} name Name of subscription @@ -323,6 +370,19 @@ export const NotificationHaloRunV1alpha1SubscriptionApiFp = function(configurati const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1SubscriptionApi.listNotificationHaloRunV1alpha1Subscription']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch notification.halo.run/v1alpha1/Subscription + * @param {string} name Name of subscription + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchNotificationHaloRunV1alpha1Subscription(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchNotificationHaloRunV1alpha1Subscription(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['NotificationHaloRunV1alpha1SubscriptionApi.patchNotificationHaloRunV1alpha1Subscription']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update notification.halo.run/v1alpha1/Subscription * @param {string} name Name of subscription @@ -382,6 +442,15 @@ export const NotificationHaloRunV1alpha1SubscriptionApiFactory = function (confi listNotificationHaloRunV1alpha1Subscription(requestParameters: NotificationHaloRunV1alpha1SubscriptionApiListNotificationHaloRunV1alpha1SubscriptionRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listNotificationHaloRunV1alpha1Subscription(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch notification.halo.run/v1alpha1/Subscription + * @param {NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchNotificationHaloRunV1alpha1Subscription(requestParameters: NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchNotificationHaloRunV1alpha1Subscription(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update notification.halo.run/v1alpha1/Subscription * @param {NotificationHaloRunV1alpha1SubscriptionApiUpdateNotificationHaloRunV1alpha1SubscriptionRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface NotificationHaloRunV1alpha1SubscriptionApiListNotificationHaloR readonly sort?: Array } +/** + * Request parameters for patchNotificationHaloRunV1alpha1Subscription operation in NotificationHaloRunV1alpha1SubscriptionApi. + * @export + * @interface NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest + */ +export interface NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest { + /** + * Name of subscription + * @type {string} + * @memberof NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1Subscription + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1Subscription + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateNotificationHaloRunV1alpha1Subscription operation in NotificationHaloRunV1alpha1SubscriptionApi. * @export @@ -550,6 +640,17 @@ export class NotificationHaloRunV1alpha1SubscriptionApi extends BaseAPI { return NotificationHaloRunV1alpha1SubscriptionApiFp(this.configuration).listNotificationHaloRunV1alpha1Subscription(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch notification.halo.run/v1alpha1/Subscription + * @param {NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof NotificationHaloRunV1alpha1SubscriptionApi + */ + public patchNotificationHaloRunV1alpha1Subscription(requestParameters: NotificationHaloRunV1alpha1SubscriptionApiPatchNotificationHaloRunV1alpha1SubscriptionRequest, options?: RawAxiosRequestConfig) { + return NotificationHaloRunV1alpha1SubscriptionApiFp(this.configuration).patchNotificationHaloRunV1alpha1Subscription(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update notification.halo.run/v1alpha1/Subscription * @param {NotificationHaloRunV1alpha1SubscriptionApiUpdateNotificationHaloRunV1alpha1SubscriptionRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-definition-api.ts b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-definition-api.ts index 92c77be0f..4d3997a8d 100644 --- a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-definition-api.ts +++ b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-definition-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { ExtensionDefinition } from '../models'; // @ts-ignore import { ExtensionDefinitionList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * PluginHaloRunV1alpha1ExtensionDefinitionApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const PluginHaloRunV1alpha1ExtensionDefinitionApiAxiosParamCreator = func options: localVarRequestOptions, }; }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionDefinition + * @param {string} name Name of extensiondefinition + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ExtensionDefinition: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchPluginHaloRunV1alpha1ExtensionDefinition', 'name', name) + const localVarPath = `/apis/plugin.halo.run/v1alpha1/extensiondefinitions/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update plugin.halo.run/v1alpha1/ExtensionDefinition * @param {string} name Name of extensiondefinition @@ -323,6 +370,19 @@ export const PluginHaloRunV1alpha1ExtensionDefinitionApiFp = function(configurat const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ExtensionDefinitionApi.listPluginHaloRunV1alpha1ExtensionDefinition']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionDefinition + * @param {string} name Name of extensiondefinition + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchPluginHaloRunV1alpha1ExtensionDefinition(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchPluginHaloRunV1alpha1ExtensionDefinition(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ExtensionDefinitionApi.patchPluginHaloRunV1alpha1ExtensionDefinition']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update plugin.halo.run/v1alpha1/ExtensionDefinition * @param {string} name Name of extensiondefinition @@ -382,6 +442,15 @@ export const PluginHaloRunV1alpha1ExtensionDefinitionApiFactory = function (conf listPluginHaloRunV1alpha1ExtensionDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionDefinitionApiListPluginHaloRunV1alpha1ExtensionDefinitionRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listPluginHaloRunV1alpha1ExtensionDefinition(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionDefinition + * @param {PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ExtensionDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchPluginHaloRunV1alpha1ExtensionDefinition(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update plugin.halo.run/v1alpha1/ExtensionDefinition * @param {PluginHaloRunV1alpha1ExtensionDefinitionApiUpdatePluginHaloRunV1alpha1ExtensionDefinitionRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface PluginHaloRunV1alpha1ExtensionDefinitionApiListPluginHaloRunV1a readonly sort?: Array } +/** + * Request parameters for patchPluginHaloRunV1alpha1ExtensionDefinition operation in PluginHaloRunV1alpha1ExtensionDefinitionApi. + * @export + * @interface PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest + */ +export interface PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest { + /** + * Name of extensiondefinition + * @type {string} + * @memberof PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinition + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinition + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updatePluginHaloRunV1alpha1ExtensionDefinition operation in PluginHaloRunV1alpha1ExtensionDefinitionApi. * @export @@ -550,6 +640,17 @@ export class PluginHaloRunV1alpha1ExtensionDefinitionApi extends BaseAPI { return PluginHaloRunV1alpha1ExtensionDefinitionApiFp(this.configuration).listPluginHaloRunV1alpha1ExtensionDefinition(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch plugin.halo.run/v1alpha1/ExtensionDefinition + * @param {PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof PluginHaloRunV1alpha1ExtensionDefinitionApi + */ + public patchPluginHaloRunV1alpha1ExtensionDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionDefinitionApiPatchPluginHaloRunV1alpha1ExtensionDefinitionRequest, options?: RawAxiosRequestConfig) { + return PluginHaloRunV1alpha1ExtensionDefinitionApiFp(this.configuration).patchPluginHaloRunV1alpha1ExtensionDefinition(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update plugin.halo.run/v1alpha1/ExtensionDefinition * @param {PluginHaloRunV1alpha1ExtensionDefinitionApiUpdatePluginHaloRunV1alpha1ExtensionDefinitionRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-point-definition-api.ts b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-point-definition-api.ts index 438c20da4..9d2e342fd 100644 --- a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-point-definition-api.ts +++ b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-extension-point-definition-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { ExtensionPointDefinition } from '../models'; // @ts-ignore import { ExtensionPointDefinitionList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * PluginHaloRunV1alpha1ExtensionPointDefinitionApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiAxiosParamCreator = options: localVarRequestOptions, }; }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionPointDefinition + * @param {string} name Name of extensionpointdefinition + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ExtensionPointDefinition: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchPluginHaloRunV1alpha1ExtensionPointDefinition', 'name', name) + const localVarPath = `/apis/plugin.halo.run/v1alpha1/extensionpointdefinitions/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition * @param {string} name Name of extensionpointdefinition @@ -323,6 +370,19 @@ export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp = function(confi const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ExtensionPointDefinitionApi.listPluginHaloRunV1alpha1ExtensionPointDefinition']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionPointDefinition + * @param {string} name Name of extensionpointdefinition + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchPluginHaloRunV1alpha1ExtensionPointDefinition(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchPluginHaloRunV1alpha1ExtensionPointDefinition(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ExtensionPointDefinitionApi.patchPluginHaloRunV1alpha1ExtensionPointDefinition']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition * @param {string} name Name of extensionpointdefinition @@ -382,6 +442,15 @@ export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiFactory = function listPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiListPluginHaloRunV1alpha1ExtensionPointDefinitionRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch plugin.halo.run/v1alpha1/ExtensionPointDefinition + * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatePluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiListPluginHaloR readonly sort?: Array } +/** + * Request parameters for patchPluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi. + * @export + * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest + */ +export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest { + /** + * Name of extensionpointdefinition + * @type {string} + * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinition + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinition + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updatePluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi. * @export @@ -550,6 +640,17 @@ export class PluginHaloRunV1alpha1ExtensionPointDefinitionApi extends BaseAPI { return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(this.configuration).listPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch plugin.halo.run/v1alpha1/ExtensionPointDefinition + * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi + */ + public patchPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiPatchPluginHaloRunV1alpha1ExtensionPointDefinitionRequest, options?: RawAxiosRequestConfig) { + return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(this.configuration).patchPluginHaloRunV1alpha1ExtensionPointDefinition(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatePluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-plugin-api.ts b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-plugin-api.ts index 8e2096b11..e46e07f5f 100644 --- a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-plugin-api.ts +++ b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-plugin-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Plugin } from '../models'; // @ts-ignore import { PluginList } from '../models'; @@ -216,6 +218,51 @@ export const PluginHaloRunV1alpha1PluginApiAxiosParamCreator = function (configu options: localVarRequestOptions, }; }, + /** + * Patch plugin.halo.run/v1alpha1/Plugin + * @param {string} name Name of plugin + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1Plugin: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchPluginHaloRunV1alpha1Plugin', 'name', name) + const localVarPath = `/apis/plugin.halo.run/v1alpha1/plugins/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update plugin.halo.run/v1alpha1/Plugin * @param {string} name Name of plugin @@ -323,6 +370,19 @@ export const PluginHaloRunV1alpha1PluginApiFp = function(configuration?: Configu const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1PluginApi.listPluginHaloRunV1alpha1Plugin']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch plugin.halo.run/v1alpha1/Plugin + * @param {string} name Name of plugin + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchPluginHaloRunV1alpha1Plugin(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchPluginHaloRunV1alpha1Plugin(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1PluginApi.patchPluginHaloRunV1alpha1Plugin']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update plugin.halo.run/v1alpha1/Plugin * @param {string} name Name of plugin @@ -382,6 +442,15 @@ export const PluginHaloRunV1alpha1PluginApiFactory = function (configuration?: C listPluginHaloRunV1alpha1Plugin(requestParameters: PluginHaloRunV1alpha1PluginApiListPluginHaloRunV1alpha1PluginRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listPluginHaloRunV1alpha1Plugin(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch plugin.halo.run/v1alpha1/Plugin + * @param {PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1Plugin(requestParameters: PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchPluginHaloRunV1alpha1Plugin(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update plugin.halo.run/v1alpha1/Plugin * @param {PluginHaloRunV1alpha1PluginApiUpdatePluginHaloRunV1alpha1PluginRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface PluginHaloRunV1alpha1PluginApiListPluginHaloRunV1alpha1PluginRe readonly sort?: Array } +/** + * Request parameters for patchPluginHaloRunV1alpha1Plugin operation in PluginHaloRunV1alpha1PluginApi. + * @export + * @interface PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest + */ +export interface PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest { + /** + * Name of plugin + * @type {string} + * @memberof PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1Plugin + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1Plugin + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updatePluginHaloRunV1alpha1Plugin operation in PluginHaloRunV1alpha1PluginApi. * @export @@ -550,6 +640,17 @@ export class PluginHaloRunV1alpha1PluginApi extends BaseAPI { return PluginHaloRunV1alpha1PluginApiFp(this.configuration).listPluginHaloRunV1alpha1Plugin(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch plugin.halo.run/v1alpha1/Plugin + * @param {PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof PluginHaloRunV1alpha1PluginApi + */ + public patchPluginHaloRunV1alpha1Plugin(requestParameters: PluginHaloRunV1alpha1PluginApiPatchPluginHaloRunV1alpha1PluginRequest, options?: RawAxiosRequestConfig) { + return PluginHaloRunV1alpha1PluginApiFp(this.configuration).patchPluginHaloRunV1alpha1Plugin(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update plugin.halo.run/v1alpha1/Plugin * @param {PluginHaloRunV1alpha1PluginApiUpdatePluginHaloRunV1alpha1PluginRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-reverse-proxy-api.ts b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-reverse-proxy-api.ts index b70f6191e..f74c2894f 100644 --- a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-reverse-proxy-api.ts +++ b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-reverse-proxy-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { ReverseProxy } from '../models'; // @ts-ignore import { ReverseProxyList } from '../models'; @@ -216,6 +218,51 @@ export const PluginHaloRunV1alpha1ReverseProxyApiAxiosParamCreator = function (c options: localVarRequestOptions, }; }, + /** + * Patch plugin.halo.run/v1alpha1/ReverseProxy + * @param {string} name Name of reverseproxy + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ReverseProxy: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchPluginHaloRunV1alpha1ReverseProxy', 'name', name) + const localVarPath = `/apis/plugin.halo.run/v1alpha1/reverseproxies/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update plugin.halo.run/v1alpha1/ReverseProxy * @param {string} name Name of reverseproxy @@ -323,6 +370,19 @@ export const PluginHaloRunV1alpha1ReverseProxyApiFp = function(configuration?: C const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ReverseProxyApi.listPluginHaloRunV1alpha1ReverseProxy']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch plugin.halo.run/v1alpha1/ReverseProxy + * @param {string} name Name of reverseproxy + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchPluginHaloRunV1alpha1ReverseProxy(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchPluginHaloRunV1alpha1ReverseProxy(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1ReverseProxyApi.patchPluginHaloRunV1alpha1ReverseProxy']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update plugin.halo.run/v1alpha1/ReverseProxy * @param {string} name Name of reverseproxy @@ -382,6 +442,15 @@ export const PluginHaloRunV1alpha1ReverseProxyApiFactory = function (configurati listPluginHaloRunV1alpha1ReverseProxy(requestParameters: PluginHaloRunV1alpha1ReverseProxyApiListPluginHaloRunV1alpha1ReverseProxyRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listPluginHaloRunV1alpha1ReverseProxy(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch plugin.halo.run/v1alpha1/ReverseProxy + * @param {PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1ReverseProxy(requestParameters: PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchPluginHaloRunV1alpha1ReverseProxy(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update plugin.halo.run/v1alpha1/ReverseProxy * @param {PluginHaloRunV1alpha1ReverseProxyApiUpdatePluginHaloRunV1alpha1ReverseProxyRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface PluginHaloRunV1alpha1ReverseProxyApiListPluginHaloRunV1alpha1Re readonly sort?: Array } +/** + * Request parameters for patchPluginHaloRunV1alpha1ReverseProxy operation in PluginHaloRunV1alpha1ReverseProxyApi. + * @export + * @interface PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest + */ +export interface PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest { + /** + * Name of reverseproxy + * @type {string} + * @memberof PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxy + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxy + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updatePluginHaloRunV1alpha1ReverseProxy operation in PluginHaloRunV1alpha1ReverseProxyApi. * @export @@ -550,6 +640,17 @@ export class PluginHaloRunV1alpha1ReverseProxyApi extends BaseAPI { return PluginHaloRunV1alpha1ReverseProxyApiFp(this.configuration).listPluginHaloRunV1alpha1ReverseProxy(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch plugin.halo.run/v1alpha1/ReverseProxy + * @param {PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof PluginHaloRunV1alpha1ReverseProxyApi + */ + public patchPluginHaloRunV1alpha1ReverseProxy(requestParameters: PluginHaloRunV1alpha1ReverseProxyApiPatchPluginHaloRunV1alpha1ReverseProxyRequest, options?: RawAxiosRequestConfig) { + return PluginHaloRunV1alpha1ReverseProxyApiFp(this.configuration).patchPluginHaloRunV1alpha1ReverseProxy(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update plugin.halo.run/v1alpha1/ReverseProxy * @param {PluginHaloRunV1alpha1ReverseProxyApiUpdatePluginHaloRunV1alpha1ReverseProxyRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-search-engine-api.ts b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-search-engine-api.ts index 2fbd73ce7..853af4616 100644 --- a/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-search-engine-api.ts +++ b/ui/packages/api-client/src/api/plugin-halo-run-v1alpha1-search-engine-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { SearchEngine } from '../models'; // @ts-ignore import { SearchEngineList } from '../models'; @@ -216,6 +218,51 @@ export const PluginHaloRunV1alpha1SearchEngineApiAxiosParamCreator = function (c options: localVarRequestOptions, }; }, + /** + * Patch plugin.halo.run/v1alpha1/SearchEngine + * @param {string} name Name of searchengine + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1SearchEngine: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchPluginHaloRunV1alpha1SearchEngine', 'name', name) + const localVarPath = `/apis/plugin.halo.run/v1alpha1/searchengines/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update plugin.halo.run/v1alpha1/SearchEngine * @param {string} name Name of searchengine @@ -323,6 +370,19 @@ export const PluginHaloRunV1alpha1SearchEngineApiFp = function(configuration?: C const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1SearchEngineApi.listPluginHaloRunV1alpha1SearchEngine']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch plugin.halo.run/v1alpha1/SearchEngine + * @param {string} name Name of searchengine + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchPluginHaloRunV1alpha1SearchEngine(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchPluginHaloRunV1alpha1SearchEngine(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['PluginHaloRunV1alpha1SearchEngineApi.patchPluginHaloRunV1alpha1SearchEngine']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update plugin.halo.run/v1alpha1/SearchEngine * @param {string} name Name of searchengine @@ -382,6 +442,15 @@ export const PluginHaloRunV1alpha1SearchEngineApiFactory = function (configurati listPluginHaloRunV1alpha1SearchEngine(requestParameters: PluginHaloRunV1alpha1SearchEngineApiListPluginHaloRunV1alpha1SearchEngineRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listPluginHaloRunV1alpha1SearchEngine(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch plugin.halo.run/v1alpha1/SearchEngine + * @param {PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchPluginHaloRunV1alpha1SearchEngine(requestParameters: PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchPluginHaloRunV1alpha1SearchEngine(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update plugin.halo.run/v1alpha1/SearchEngine * @param {PluginHaloRunV1alpha1SearchEngineApiUpdatePluginHaloRunV1alpha1SearchEngineRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface PluginHaloRunV1alpha1SearchEngineApiListPluginHaloRunV1alpha1Se readonly sort?: Array } +/** + * Request parameters for patchPluginHaloRunV1alpha1SearchEngine operation in PluginHaloRunV1alpha1SearchEngineApi. + * @export + * @interface PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest + */ +export interface PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest { + /** + * Name of searchengine + * @type {string} + * @memberof PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngine + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngine + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updatePluginHaloRunV1alpha1SearchEngine operation in PluginHaloRunV1alpha1SearchEngineApi. * @export @@ -550,6 +640,17 @@ export class PluginHaloRunV1alpha1SearchEngineApi extends BaseAPI { return PluginHaloRunV1alpha1SearchEngineApiFp(this.configuration).listPluginHaloRunV1alpha1SearchEngine(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch plugin.halo.run/v1alpha1/SearchEngine + * @param {PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof PluginHaloRunV1alpha1SearchEngineApi + */ + public patchPluginHaloRunV1alpha1SearchEngine(requestParameters: PluginHaloRunV1alpha1SearchEngineApiPatchPluginHaloRunV1alpha1SearchEngineRequest, options?: RawAxiosRequestConfig) { + return PluginHaloRunV1alpha1SearchEngineApiFp(this.configuration).patchPluginHaloRunV1alpha1SearchEngine(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update plugin.halo.run/v1alpha1/SearchEngine * @param {PluginHaloRunV1alpha1SearchEngineApiUpdatePluginHaloRunV1alpha1SearchEngineRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/security-halo-run-v1alpha1-personal-access-token-api.ts b/ui/packages/api-client/src/api/security-halo-run-v1alpha1-personal-access-token-api.ts index be5c89d7e..29bc3614a 100644 --- a/ui/packages/api-client/src/api/security-halo-run-v1alpha1-personal-access-token-api.ts +++ b/ui/packages/api-client/src/api/security-halo-run-v1alpha1-personal-access-token-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { PersonalAccessToken } from '../models'; // @ts-ignore import { PersonalAccessTokenList } from '../models'; @@ -216,6 +218,51 @@ export const SecurityHaloRunV1alpha1PersonalAccessTokenApiAxiosParamCreator = fu options: localVarRequestOptions, }; }, + /** + * Patch security.halo.run/v1alpha1/PersonalAccessToken + * @param {string} name Name of personalaccesstoken + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchSecurityHaloRunV1alpha1PersonalAccessToken: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchSecurityHaloRunV1alpha1PersonalAccessToken', 'name', name) + const localVarPath = `/apis/security.halo.run/v1alpha1/personalaccesstokens/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update security.halo.run/v1alpha1/PersonalAccessToken * @param {string} name Name of personalaccesstoken @@ -323,6 +370,19 @@ export const SecurityHaloRunV1alpha1PersonalAccessTokenApiFp = function(configur const localVarOperationServerBasePath = operationServerMap['SecurityHaloRunV1alpha1PersonalAccessTokenApi.listSecurityHaloRunV1alpha1PersonalAccessToken']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch security.halo.run/v1alpha1/PersonalAccessToken + * @param {string} name Name of personalaccesstoken + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchSecurityHaloRunV1alpha1PersonalAccessToken(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchSecurityHaloRunV1alpha1PersonalAccessToken(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['SecurityHaloRunV1alpha1PersonalAccessTokenApi.patchSecurityHaloRunV1alpha1PersonalAccessToken']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update security.halo.run/v1alpha1/PersonalAccessToken * @param {string} name Name of personalaccesstoken @@ -382,6 +442,15 @@ export const SecurityHaloRunV1alpha1PersonalAccessTokenApiFactory = function (co listSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters: SecurityHaloRunV1alpha1PersonalAccessTokenApiListSecurityHaloRunV1alpha1PersonalAccessTokenRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch security.halo.run/v1alpha1/PersonalAccessToken + * @param {SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters: SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update security.halo.run/v1alpha1/PersonalAccessToken * @param {SecurityHaloRunV1alpha1PersonalAccessTokenApiUpdateSecurityHaloRunV1alpha1PersonalAccessTokenRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface SecurityHaloRunV1alpha1PersonalAccessTokenApiListSecurityHaloRu readonly sort?: Array } +/** + * Request parameters for patchSecurityHaloRunV1alpha1PersonalAccessToken operation in SecurityHaloRunV1alpha1PersonalAccessTokenApi. + * @export + * @interface SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest + */ +export interface SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest { + /** + * Name of personalaccesstoken + * @type {string} + * @memberof SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessToken + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessToken + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateSecurityHaloRunV1alpha1PersonalAccessToken operation in SecurityHaloRunV1alpha1PersonalAccessTokenApi. * @export @@ -550,6 +640,17 @@ export class SecurityHaloRunV1alpha1PersonalAccessTokenApi extends BaseAPI { return SecurityHaloRunV1alpha1PersonalAccessTokenApiFp(this.configuration).listSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch security.halo.run/v1alpha1/PersonalAccessToken + * @param {SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof SecurityHaloRunV1alpha1PersonalAccessTokenApi + */ + public patchSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters: SecurityHaloRunV1alpha1PersonalAccessTokenApiPatchSecurityHaloRunV1alpha1PersonalAccessTokenRequest, options?: RawAxiosRequestConfig) { + return SecurityHaloRunV1alpha1PersonalAccessTokenApiFp(this.configuration).patchSecurityHaloRunV1alpha1PersonalAccessToken(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update security.halo.run/v1alpha1/PersonalAccessToken * @param {SecurityHaloRunV1alpha1PersonalAccessTokenApiUpdateSecurityHaloRunV1alpha1PersonalAccessTokenRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-attachment-api.ts b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-attachment-api.ts index c63164914..3fa4eecf4 100644 --- a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-attachment-api.ts +++ b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-attachment-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Attachment } from '../models'; // @ts-ignore import { AttachmentList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * StorageHaloRunV1alpha1AttachmentApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const StorageHaloRunV1alpha1AttachmentApiAxiosParamCreator = function (co options: localVarRequestOptions, }; }, + /** + * Patch storage.halo.run/v1alpha1/Attachment + * @param {string} name Name of attachment + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Attachment: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchStorageHaloRunV1alpha1Attachment', 'name', name) + const localVarPath = `/apis/storage.halo.run/v1alpha1/attachments/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update storage.halo.run/v1alpha1/Attachment * @param {string} name Name of attachment @@ -323,6 +370,19 @@ export const StorageHaloRunV1alpha1AttachmentApiFp = function(configuration?: Co const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1AttachmentApi.listStorageHaloRunV1alpha1Attachment']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch storage.halo.run/v1alpha1/Attachment + * @param {string} name Name of attachment + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchStorageHaloRunV1alpha1Attachment(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchStorageHaloRunV1alpha1Attachment(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1AttachmentApi.patchStorageHaloRunV1alpha1Attachment']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update storage.halo.run/v1alpha1/Attachment * @param {string} name Name of attachment @@ -382,6 +442,15 @@ export const StorageHaloRunV1alpha1AttachmentApiFactory = function (configuratio listStorageHaloRunV1alpha1Attachment(requestParameters: StorageHaloRunV1alpha1AttachmentApiListStorageHaloRunV1alpha1AttachmentRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listStorageHaloRunV1alpha1Attachment(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch storage.halo.run/v1alpha1/Attachment + * @param {StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Attachment(requestParameters: StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchStorageHaloRunV1alpha1Attachment(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update storage.halo.run/v1alpha1/Attachment * @param {StorageHaloRunV1alpha1AttachmentApiUpdateStorageHaloRunV1alpha1AttachmentRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface StorageHaloRunV1alpha1AttachmentApiListStorageHaloRunV1alpha1At readonly sort?: Array } +/** + * Request parameters for patchStorageHaloRunV1alpha1Attachment operation in StorageHaloRunV1alpha1AttachmentApi. + * @export + * @interface StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest + */ +export interface StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest { + /** + * Name of attachment + * @type {string} + * @memberof StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1Attachment + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1Attachment + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateStorageHaloRunV1alpha1Attachment operation in StorageHaloRunV1alpha1AttachmentApi. * @export @@ -550,6 +640,17 @@ export class StorageHaloRunV1alpha1AttachmentApi extends BaseAPI { return StorageHaloRunV1alpha1AttachmentApiFp(this.configuration).listStorageHaloRunV1alpha1Attachment(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch storage.halo.run/v1alpha1/Attachment + * @param {StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StorageHaloRunV1alpha1AttachmentApi + */ + public patchStorageHaloRunV1alpha1Attachment(requestParameters: StorageHaloRunV1alpha1AttachmentApiPatchStorageHaloRunV1alpha1AttachmentRequest, options?: RawAxiosRequestConfig) { + return StorageHaloRunV1alpha1AttachmentApiFp(this.configuration).patchStorageHaloRunV1alpha1Attachment(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update storage.halo.run/v1alpha1/Attachment * @param {StorageHaloRunV1alpha1AttachmentApiUpdateStorageHaloRunV1alpha1AttachmentRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-group-api.ts b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-group-api.ts index 7430024f4..4e32adc26 100644 --- a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-group-api.ts +++ b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-group-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { Group } from '../models'; // @ts-ignore import { GroupList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * StorageHaloRunV1alpha1GroupApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const StorageHaloRunV1alpha1GroupApiAxiosParamCreator = function (configu options: localVarRequestOptions, }; }, + /** + * Patch storage.halo.run/v1alpha1/Group + * @param {string} name Name of group + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Group: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchStorageHaloRunV1alpha1Group', 'name', name) + const localVarPath = `/apis/storage.halo.run/v1alpha1/groups/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update storage.halo.run/v1alpha1/Group * @param {string} name Name of group @@ -323,6 +370,19 @@ export const StorageHaloRunV1alpha1GroupApiFp = function(configuration?: Configu const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1GroupApi.listStorageHaloRunV1alpha1Group']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch storage.halo.run/v1alpha1/Group + * @param {string} name Name of group + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchStorageHaloRunV1alpha1Group(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchStorageHaloRunV1alpha1Group(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1GroupApi.patchStorageHaloRunV1alpha1Group']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update storage.halo.run/v1alpha1/Group * @param {string} name Name of group @@ -382,6 +442,15 @@ export const StorageHaloRunV1alpha1GroupApiFactory = function (configuration?: C listStorageHaloRunV1alpha1Group(requestParameters: StorageHaloRunV1alpha1GroupApiListStorageHaloRunV1alpha1GroupRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listStorageHaloRunV1alpha1Group(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch storage.halo.run/v1alpha1/Group + * @param {StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Group(requestParameters: StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchStorageHaloRunV1alpha1Group(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update storage.halo.run/v1alpha1/Group * @param {StorageHaloRunV1alpha1GroupApiUpdateStorageHaloRunV1alpha1GroupRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface StorageHaloRunV1alpha1GroupApiListStorageHaloRunV1alpha1GroupRe readonly sort?: Array } +/** + * Request parameters for patchStorageHaloRunV1alpha1Group operation in StorageHaloRunV1alpha1GroupApi. + * @export + * @interface StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest + */ +export interface StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest { + /** + * Name of group + * @type {string} + * @memberof StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1Group + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1Group + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateStorageHaloRunV1alpha1Group operation in StorageHaloRunV1alpha1GroupApi. * @export @@ -550,6 +640,17 @@ export class StorageHaloRunV1alpha1GroupApi extends BaseAPI { return StorageHaloRunV1alpha1GroupApiFp(this.configuration).listStorageHaloRunV1alpha1Group(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch storage.halo.run/v1alpha1/Group + * @param {StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StorageHaloRunV1alpha1GroupApi + */ + public patchStorageHaloRunV1alpha1Group(requestParameters: StorageHaloRunV1alpha1GroupApiPatchStorageHaloRunV1alpha1GroupRequest, options?: RawAxiosRequestConfig) { + return StorageHaloRunV1alpha1GroupApiFp(this.configuration).patchStorageHaloRunV1alpha1Group(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update storage.halo.run/v1alpha1/Group * @param {StorageHaloRunV1alpha1GroupApiUpdateStorageHaloRunV1alpha1GroupRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-api.ts b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-api.ts index 4d0ebc2c1..d5cde4f3a 100644 --- a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-api.ts +++ b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Policy } from '../models'; // @ts-ignore import { PolicyList } from '../models'; @@ -216,6 +218,51 @@ export const StorageHaloRunV1alpha1PolicyApiAxiosParamCreator = function (config options: localVarRequestOptions, }; }, + /** + * Patch storage.halo.run/v1alpha1/Policy + * @param {string} name Name of policy + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Policy: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchStorageHaloRunV1alpha1Policy', 'name', name) + const localVarPath = `/apis/storage.halo.run/v1alpha1/policies/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update storage.halo.run/v1alpha1/Policy * @param {string} name Name of policy @@ -323,6 +370,19 @@ export const StorageHaloRunV1alpha1PolicyApiFp = function(configuration?: Config const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1PolicyApi.listStorageHaloRunV1alpha1Policy']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch storage.halo.run/v1alpha1/Policy + * @param {string} name Name of policy + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchStorageHaloRunV1alpha1Policy(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchStorageHaloRunV1alpha1Policy(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1PolicyApi.patchStorageHaloRunV1alpha1Policy']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update storage.halo.run/v1alpha1/Policy * @param {string} name Name of policy @@ -382,6 +442,15 @@ export const StorageHaloRunV1alpha1PolicyApiFactory = function (configuration?: listStorageHaloRunV1alpha1Policy(requestParameters: StorageHaloRunV1alpha1PolicyApiListStorageHaloRunV1alpha1PolicyRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listStorageHaloRunV1alpha1Policy(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch storage.halo.run/v1alpha1/Policy + * @param {StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1Policy(requestParameters: StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchStorageHaloRunV1alpha1Policy(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update storage.halo.run/v1alpha1/Policy * @param {StorageHaloRunV1alpha1PolicyApiUpdateStorageHaloRunV1alpha1PolicyRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface StorageHaloRunV1alpha1PolicyApiListStorageHaloRunV1alpha1Policy readonly sort?: Array } +/** + * Request parameters for patchStorageHaloRunV1alpha1Policy operation in StorageHaloRunV1alpha1PolicyApi. + * @export + * @interface StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest + */ +export interface StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest { + /** + * Name of policy + * @type {string} + * @memberof StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1Policy + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1Policy + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateStorageHaloRunV1alpha1Policy operation in StorageHaloRunV1alpha1PolicyApi. * @export @@ -550,6 +640,17 @@ export class StorageHaloRunV1alpha1PolicyApi extends BaseAPI { return StorageHaloRunV1alpha1PolicyApiFp(this.configuration).listStorageHaloRunV1alpha1Policy(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch storage.halo.run/v1alpha1/Policy + * @param {StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StorageHaloRunV1alpha1PolicyApi + */ + public patchStorageHaloRunV1alpha1Policy(requestParameters: StorageHaloRunV1alpha1PolicyApiPatchStorageHaloRunV1alpha1PolicyRequest, options?: RawAxiosRequestConfig) { + return StorageHaloRunV1alpha1PolicyApiFp(this.configuration).patchStorageHaloRunV1alpha1Policy(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update storage.halo.run/v1alpha1/Policy * @param {StorageHaloRunV1alpha1PolicyApiUpdateStorageHaloRunV1alpha1PolicyRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-template-api.ts b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-template-api.ts index 61f43c4bf..afb7dbecf 100644 --- a/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-template-api.ts +++ b/ui/packages/api-client/src/api/storage-halo-run-v1alpha1-policy-template-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { PolicyTemplate } from '../models'; // @ts-ignore import { PolicyTemplateList } from '../models'; @@ -216,6 +218,51 @@ export const StorageHaloRunV1alpha1PolicyTemplateApiAxiosParamCreator = function options: localVarRequestOptions, }; }, + /** + * Patch storage.halo.run/v1alpha1/PolicyTemplate + * @param {string} name Name of policytemplate + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1PolicyTemplate: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchStorageHaloRunV1alpha1PolicyTemplate', 'name', name) + const localVarPath = `/apis/storage.halo.run/v1alpha1/policytemplates/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update storage.halo.run/v1alpha1/PolicyTemplate * @param {string} name Name of policytemplate @@ -323,6 +370,19 @@ export const StorageHaloRunV1alpha1PolicyTemplateApiFp = function(configuration? const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1PolicyTemplateApi.listStorageHaloRunV1alpha1PolicyTemplate']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch storage.halo.run/v1alpha1/PolicyTemplate + * @param {string} name Name of policytemplate + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchStorageHaloRunV1alpha1PolicyTemplate(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchStorageHaloRunV1alpha1PolicyTemplate(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['StorageHaloRunV1alpha1PolicyTemplateApi.patchStorageHaloRunV1alpha1PolicyTemplate']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update storage.halo.run/v1alpha1/PolicyTemplate * @param {string} name Name of policytemplate @@ -382,6 +442,15 @@ export const StorageHaloRunV1alpha1PolicyTemplateApiFactory = function (configur listStorageHaloRunV1alpha1PolicyTemplate(requestParameters: StorageHaloRunV1alpha1PolicyTemplateApiListStorageHaloRunV1alpha1PolicyTemplateRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listStorageHaloRunV1alpha1PolicyTemplate(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch storage.halo.run/v1alpha1/PolicyTemplate + * @param {StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchStorageHaloRunV1alpha1PolicyTemplate(requestParameters: StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchStorageHaloRunV1alpha1PolicyTemplate(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update storage.halo.run/v1alpha1/PolicyTemplate * @param {StorageHaloRunV1alpha1PolicyTemplateApiUpdateStorageHaloRunV1alpha1PolicyTemplateRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface StorageHaloRunV1alpha1PolicyTemplateApiListStorageHaloRunV1alph readonly sort?: Array } +/** + * Request parameters for patchStorageHaloRunV1alpha1PolicyTemplate operation in StorageHaloRunV1alpha1PolicyTemplateApi. + * @export + * @interface StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest + */ +export interface StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest { + /** + * Name of policytemplate + * @type {string} + * @memberof StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplate + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplate + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateStorageHaloRunV1alpha1PolicyTemplate operation in StorageHaloRunV1alpha1PolicyTemplateApi. * @export @@ -550,6 +640,17 @@ export class StorageHaloRunV1alpha1PolicyTemplateApi extends BaseAPI { return StorageHaloRunV1alpha1PolicyTemplateApiFp(this.configuration).listStorageHaloRunV1alpha1PolicyTemplate(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch storage.halo.run/v1alpha1/PolicyTemplate + * @param {StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof StorageHaloRunV1alpha1PolicyTemplateApi + */ + public patchStorageHaloRunV1alpha1PolicyTemplate(requestParameters: StorageHaloRunV1alpha1PolicyTemplateApiPatchStorageHaloRunV1alpha1PolicyTemplateRequest, options?: RawAxiosRequestConfig) { + return StorageHaloRunV1alpha1PolicyTemplateApiFp(this.configuration).patchStorageHaloRunV1alpha1PolicyTemplate(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update storage.halo.run/v1alpha1/PolicyTemplate * @param {StorageHaloRunV1alpha1PolicyTemplateApiUpdateStorageHaloRunV1alpha1PolicyTemplateRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/theme-halo-run-v1alpha1-theme-api.ts b/ui/packages/api-client/src/api/theme-halo-run-v1alpha1-theme-api.ts index f3ff575cd..e60a121d8 100644 --- a/ui/packages/api-client/src/api/theme-halo-run-v1alpha1-theme-api.ts +++ b/ui/packages/api-client/src/api/theme-halo-run-v1alpha1-theme-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Theme } from '../models'; // @ts-ignore import { ThemeList } from '../models'; @@ -216,6 +218,51 @@ export const ThemeHaloRunV1alpha1ThemeApiAxiosParamCreator = function (configura options: localVarRequestOptions, }; }, + /** + * Patch theme.halo.run/v1alpha1/Theme + * @param {string} name Name of theme + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchThemeHaloRunV1alpha1Theme: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchThemeHaloRunV1alpha1Theme', 'name', name) + const localVarPath = `/apis/theme.halo.run/v1alpha1/themes/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update theme.halo.run/v1alpha1/Theme * @param {string} name Name of theme @@ -323,6 +370,19 @@ export const ThemeHaloRunV1alpha1ThemeApiFp = function(configuration?: Configura const localVarOperationServerBasePath = operationServerMap['ThemeHaloRunV1alpha1ThemeApi.listThemeHaloRunV1alpha1Theme']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch theme.halo.run/v1alpha1/Theme + * @param {string} name Name of theme + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchThemeHaloRunV1alpha1Theme(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchThemeHaloRunV1alpha1Theme(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['ThemeHaloRunV1alpha1ThemeApi.patchThemeHaloRunV1alpha1Theme']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update theme.halo.run/v1alpha1/Theme * @param {string} name Name of theme @@ -382,6 +442,15 @@ export const ThemeHaloRunV1alpha1ThemeApiFactory = function (configuration?: Con listThemeHaloRunV1alpha1Theme(requestParameters: ThemeHaloRunV1alpha1ThemeApiListThemeHaloRunV1alpha1ThemeRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listThemeHaloRunV1alpha1Theme(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch theme.halo.run/v1alpha1/Theme + * @param {ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchThemeHaloRunV1alpha1Theme(requestParameters: ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchThemeHaloRunV1alpha1Theme(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update theme.halo.run/v1alpha1/Theme * @param {ThemeHaloRunV1alpha1ThemeApiUpdateThemeHaloRunV1alpha1ThemeRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface ThemeHaloRunV1alpha1ThemeApiListThemeHaloRunV1alpha1ThemeReques readonly sort?: Array } +/** + * Request parameters for patchThemeHaloRunV1alpha1Theme operation in ThemeHaloRunV1alpha1ThemeApi. + * @export + * @interface ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest + */ +export interface ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest { + /** + * Name of theme + * @type {string} + * @memberof ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1Theme + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1Theme + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateThemeHaloRunV1alpha1Theme operation in ThemeHaloRunV1alpha1ThemeApi. * @export @@ -550,6 +640,17 @@ export class ThemeHaloRunV1alpha1ThemeApi extends BaseAPI { return ThemeHaloRunV1alpha1ThemeApiFp(this.configuration).listThemeHaloRunV1alpha1Theme(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch theme.halo.run/v1alpha1/Theme + * @param {ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof ThemeHaloRunV1alpha1ThemeApi + */ + public patchThemeHaloRunV1alpha1Theme(requestParameters: ThemeHaloRunV1alpha1ThemeApiPatchThemeHaloRunV1alpha1ThemeRequest, options?: RawAxiosRequestConfig) { + return ThemeHaloRunV1alpha1ThemeApiFp(this.configuration).patchThemeHaloRunV1alpha1Theme(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update theme.halo.run/v1alpha1/Theme * @param {ThemeHaloRunV1alpha1ThemeApiUpdateThemeHaloRunV1alpha1ThemeRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-annotation-setting-api.ts b/ui/packages/api-client/src/api/v1alpha1-annotation-setting-api.ts index 5719d58c8..2c29e0cca 100644 --- a/ui/packages/api-client/src/api/v1alpha1-annotation-setting-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-annotation-setting-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { AnnotationSetting } from '../models'; // @ts-ignore import { AnnotationSettingList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * V1alpha1AnnotationSettingApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const V1alpha1AnnotationSettingApiAxiosParamCreator = function (configura options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/AnnotationSetting + * @param {string} name Name of annotationsetting + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1AnnotationSetting: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1AnnotationSetting', 'name', name) + const localVarPath = `/api/v1alpha1/annotationsettings/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/AnnotationSetting * @param {string} name Name of annotationsetting @@ -323,6 +370,19 @@ export const V1alpha1AnnotationSettingApiFp = function(configuration?: Configura const localVarOperationServerBasePath = operationServerMap['V1alpha1AnnotationSettingApi.listV1alpha1AnnotationSetting']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/AnnotationSetting + * @param {string} name Name of annotationsetting + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1AnnotationSetting(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1AnnotationSetting(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1AnnotationSettingApi.patchV1alpha1AnnotationSetting']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/AnnotationSetting * @param {string} name Name of annotationsetting @@ -382,6 +442,15 @@ export const V1alpha1AnnotationSettingApiFactory = function (configuration?: Con listV1alpha1AnnotationSetting(requestParameters: V1alpha1AnnotationSettingApiListV1alpha1AnnotationSettingRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1AnnotationSetting(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/AnnotationSetting + * @param {V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1AnnotationSetting(requestParameters: V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1AnnotationSetting(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/AnnotationSetting * @param {V1alpha1AnnotationSettingApiUpdateV1alpha1AnnotationSettingRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1AnnotationSettingApiListV1alpha1AnnotationSettingReques readonly sort?: Array } +/** + * Request parameters for patchV1alpha1AnnotationSetting operation in V1alpha1AnnotationSettingApi. + * @export + * @interface V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest + */ +export interface V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest { + /** + * Name of annotationsetting + * @type {string} + * @memberof V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSetting + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSetting + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1AnnotationSetting operation in V1alpha1AnnotationSettingApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1AnnotationSettingApi extends BaseAPI { return V1alpha1AnnotationSettingApiFp(this.configuration).listV1alpha1AnnotationSetting(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/AnnotationSetting + * @param {V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1AnnotationSettingApi + */ + public patchV1alpha1AnnotationSetting(requestParameters: V1alpha1AnnotationSettingApiPatchV1alpha1AnnotationSettingRequest, options?: RawAxiosRequestConfig) { + return V1alpha1AnnotationSettingApiFp(this.configuration).patchV1alpha1AnnotationSetting(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/AnnotationSetting * @param {V1alpha1AnnotationSettingApiUpdateV1alpha1AnnotationSettingRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-config-map-api.ts b/ui/packages/api-client/src/api/v1alpha1-config-map-api.ts index de5c673ce..f05b54e97 100644 --- a/ui/packages/api-client/src/api/v1alpha1-config-map-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-config-map-api.ts @@ -25,6 +25,8 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, ope import { ConfigMap } from '../models'; // @ts-ignore import { ConfigMapList } from '../models'; +// @ts-ignore +import { JsonPatchInner } from '../models'; /** * V1alpha1ConfigMapApi - axios parameter creator * @export @@ -216,6 +218,51 @@ export const V1alpha1ConfigMapApiAxiosParamCreator = function (configuration?: C options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/ConfigMap + * @param {string} name Name of configmap + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1ConfigMap: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1ConfigMap', 'name', name) + const localVarPath = `/api/v1alpha1/configmaps/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/ConfigMap * @param {string} name Name of configmap @@ -323,6 +370,19 @@ export const V1alpha1ConfigMapApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1ConfigMapApi.listV1alpha1ConfigMap']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/ConfigMap + * @param {string} name Name of configmap + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1ConfigMap(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1ConfigMap(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1ConfigMapApi.patchV1alpha1ConfigMap']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/ConfigMap * @param {string} name Name of configmap @@ -382,6 +442,15 @@ export const V1alpha1ConfigMapApiFactory = function (configuration?: Configurati listV1alpha1ConfigMap(requestParameters: V1alpha1ConfigMapApiListV1alpha1ConfigMapRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1ConfigMap(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/ConfigMap + * @param {V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1ConfigMap(requestParameters: V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1ConfigMap(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/ConfigMap * @param {V1alpha1ConfigMapApiUpdateV1alpha1ConfigMapRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1ConfigMapApiListV1alpha1ConfigMapRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1ConfigMap operation in V1alpha1ConfigMapApi. + * @export + * @interface V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest + */ +export interface V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest { + /** + * Name of configmap + * @type {string} + * @memberof V1alpha1ConfigMapApiPatchV1alpha1ConfigMap + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1ConfigMapApiPatchV1alpha1ConfigMap + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1ConfigMap operation in V1alpha1ConfigMapApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1ConfigMapApi extends BaseAPI { return V1alpha1ConfigMapApiFp(this.configuration).listV1alpha1ConfigMap(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/ConfigMap + * @param {V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1ConfigMapApi + */ + public patchV1alpha1ConfigMap(requestParameters: V1alpha1ConfigMapApiPatchV1alpha1ConfigMapRequest, options?: RawAxiosRequestConfig) { + return V1alpha1ConfigMapApiFp(this.configuration).patchV1alpha1ConfigMap(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/ConfigMap * @param {V1alpha1ConfigMapApiUpdateV1alpha1ConfigMapRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-menu-api.ts b/ui/packages/api-client/src/api/v1alpha1-menu-api.ts index 0098d2852..3628d59d0 100644 --- a/ui/packages/api-client/src/api/v1alpha1-menu-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-menu-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Menu } from '../models'; // @ts-ignore import { MenuList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1MenuApiAxiosParamCreator = function (configuration?: Config options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/Menu + * @param {string} name Name of menu + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Menu: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1Menu', 'name', name) + const localVarPath = `/api/v1alpha1/menus/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/Menu * @param {string} name Name of menu @@ -323,6 +370,19 @@ export const V1alpha1MenuApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1MenuApi.listV1alpha1Menu']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/Menu + * @param {string} name Name of menu + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1Menu(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1Menu(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1MenuApi.patchV1alpha1Menu']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/Menu * @param {string} name Name of menu @@ -382,6 +442,15 @@ export const V1alpha1MenuApiFactory = function (configuration?: Configuration, b listV1alpha1Menu(requestParameters: V1alpha1MenuApiListV1alpha1MenuRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1Menu(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/Menu + * @param {V1alpha1MenuApiPatchV1alpha1MenuRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Menu(requestParameters: V1alpha1MenuApiPatchV1alpha1MenuRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1Menu(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/Menu * @param {V1alpha1MenuApiUpdateV1alpha1MenuRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1MenuApiListV1alpha1MenuRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1Menu operation in V1alpha1MenuApi. + * @export + * @interface V1alpha1MenuApiPatchV1alpha1MenuRequest + */ +export interface V1alpha1MenuApiPatchV1alpha1MenuRequest { + /** + * Name of menu + * @type {string} + * @memberof V1alpha1MenuApiPatchV1alpha1Menu + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1MenuApiPatchV1alpha1Menu + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1Menu operation in V1alpha1MenuApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1MenuApi extends BaseAPI { return V1alpha1MenuApiFp(this.configuration).listV1alpha1Menu(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/Menu + * @param {V1alpha1MenuApiPatchV1alpha1MenuRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1MenuApi + */ + public patchV1alpha1Menu(requestParameters: V1alpha1MenuApiPatchV1alpha1MenuRequest, options?: RawAxiosRequestConfig) { + return V1alpha1MenuApiFp(this.configuration).patchV1alpha1Menu(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/Menu * @param {V1alpha1MenuApiUpdateV1alpha1MenuRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-menu-item-api.ts b/ui/packages/api-client/src/api/v1alpha1-menu-item-api.ts index dbf2254bf..1ebc6bd76 100644 --- a/ui/packages/api-client/src/api/v1alpha1-menu-item-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-menu-item-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { MenuItem } from '../models'; // @ts-ignore import { MenuItemList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1MenuItemApiAxiosParamCreator = function (configuration?: Co options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/MenuItem + * @param {string} name Name of menuitem + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1MenuItem: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1MenuItem', 'name', name) + const localVarPath = `/api/v1alpha1/menuitems/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/MenuItem * @param {string} name Name of menuitem @@ -323,6 +370,19 @@ export const V1alpha1MenuItemApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1MenuItemApi.listV1alpha1MenuItem']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/MenuItem + * @param {string} name Name of menuitem + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1MenuItem(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1MenuItem(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1MenuItemApi.patchV1alpha1MenuItem']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/MenuItem * @param {string} name Name of menuitem @@ -382,6 +442,15 @@ export const V1alpha1MenuItemApiFactory = function (configuration?: Configuratio listV1alpha1MenuItem(requestParameters: V1alpha1MenuItemApiListV1alpha1MenuItemRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1MenuItem(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/MenuItem + * @param {V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1MenuItem(requestParameters: V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1MenuItem(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/MenuItem * @param {V1alpha1MenuItemApiUpdateV1alpha1MenuItemRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1MenuItemApiListV1alpha1MenuItemRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1MenuItem operation in V1alpha1MenuItemApi. + * @export + * @interface V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest + */ +export interface V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest { + /** + * Name of menuitem + * @type {string} + * @memberof V1alpha1MenuItemApiPatchV1alpha1MenuItem + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1MenuItemApiPatchV1alpha1MenuItem + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1MenuItem operation in V1alpha1MenuItemApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1MenuItemApi extends BaseAPI { return V1alpha1MenuItemApiFp(this.configuration).listV1alpha1MenuItem(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/MenuItem + * @param {V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1MenuItemApi + */ + public patchV1alpha1MenuItem(requestParameters: V1alpha1MenuItemApiPatchV1alpha1MenuItemRequest, options?: RawAxiosRequestConfig) { + return V1alpha1MenuItemApiFp(this.configuration).patchV1alpha1MenuItem(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/MenuItem * @param {V1alpha1MenuItemApiUpdateV1alpha1MenuItemRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-role-api.ts b/ui/packages/api-client/src/api/v1alpha1-role-api.ts index 771a4ddd0..55ef9a546 100644 --- a/ui/packages/api-client/src/api/v1alpha1-role-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-role-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Role } from '../models'; // @ts-ignore import { RoleList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1RoleApiAxiosParamCreator = function (configuration?: Config options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/Role + * @param {string} name Name of role + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Role: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1Role', 'name', name) + const localVarPath = `/api/v1alpha1/roles/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/Role * @param {string} name Name of role @@ -323,6 +370,19 @@ export const V1alpha1RoleApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1RoleApi.listV1alpha1Role']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/Role + * @param {string} name Name of role + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1Role(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1Role(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1RoleApi.patchV1alpha1Role']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/Role * @param {string} name Name of role @@ -382,6 +442,15 @@ export const V1alpha1RoleApiFactory = function (configuration?: Configuration, b listV1alpha1Role(requestParameters: V1alpha1RoleApiListV1alpha1RoleRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1Role(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/Role + * @param {V1alpha1RoleApiPatchV1alpha1RoleRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Role(requestParameters: V1alpha1RoleApiPatchV1alpha1RoleRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1Role(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/Role * @param {V1alpha1RoleApiUpdateV1alpha1RoleRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1RoleApiListV1alpha1RoleRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1Role operation in V1alpha1RoleApi. + * @export + * @interface V1alpha1RoleApiPatchV1alpha1RoleRequest + */ +export interface V1alpha1RoleApiPatchV1alpha1RoleRequest { + /** + * Name of role + * @type {string} + * @memberof V1alpha1RoleApiPatchV1alpha1Role + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1RoleApiPatchV1alpha1Role + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1Role operation in V1alpha1RoleApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1RoleApi extends BaseAPI { return V1alpha1RoleApiFp(this.configuration).listV1alpha1Role(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/Role + * @param {V1alpha1RoleApiPatchV1alpha1RoleRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1RoleApi + */ + public patchV1alpha1Role(requestParameters: V1alpha1RoleApiPatchV1alpha1RoleRequest, options?: RawAxiosRequestConfig) { + return V1alpha1RoleApiFp(this.configuration).patchV1alpha1Role(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/Role * @param {V1alpha1RoleApiUpdateV1alpha1RoleRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-role-binding-api.ts b/ui/packages/api-client/src/api/v1alpha1-role-binding-api.ts index 9b7fa1cb8..00e0214bc 100644 --- a/ui/packages/api-client/src/api/v1alpha1-role-binding-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-role-binding-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { RoleBinding } from '../models'; // @ts-ignore import { RoleBindingList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1RoleBindingApiAxiosParamCreator = function (configuration?: options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/RoleBinding + * @param {string} name Name of rolebinding + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1RoleBinding: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1RoleBinding', 'name', name) + const localVarPath = `/api/v1alpha1/rolebindings/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/RoleBinding * @param {string} name Name of rolebinding @@ -323,6 +370,19 @@ export const V1alpha1RoleBindingApiFp = function(configuration?: Configuration) const localVarOperationServerBasePath = operationServerMap['V1alpha1RoleBindingApi.listV1alpha1RoleBinding']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/RoleBinding + * @param {string} name Name of rolebinding + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1RoleBinding(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1RoleBinding(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1RoleBindingApi.patchV1alpha1RoleBinding']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/RoleBinding * @param {string} name Name of rolebinding @@ -382,6 +442,15 @@ export const V1alpha1RoleBindingApiFactory = function (configuration?: Configura listV1alpha1RoleBinding(requestParameters: V1alpha1RoleBindingApiListV1alpha1RoleBindingRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1RoleBinding(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/RoleBinding + * @param {V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1RoleBinding(requestParameters: V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1RoleBinding(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/RoleBinding * @param {V1alpha1RoleBindingApiUpdateV1alpha1RoleBindingRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1RoleBindingApiListV1alpha1RoleBindingRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1RoleBinding operation in V1alpha1RoleBindingApi. + * @export + * @interface V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest + */ +export interface V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest { + /** + * Name of rolebinding + * @type {string} + * @memberof V1alpha1RoleBindingApiPatchV1alpha1RoleBinding + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1RoleBindingApiPatchV1alpha1RoleBinding + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1RoleBinding operation in V1alpha1RoleBindingApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1RoleBindingApi extends BaseAPI { return V1alpha1RoleBindingApiFp(this.configuration).listV1alpha1RoleBinding(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/RoleBinding + * @param {V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1RoleBindingApi + */ + public patchV1alpha1RoleBinding(requestParameters: V1alpha1RoleBindingApiPatchV1alpha1RoleBindingRequest, options?: RawAxiosRequestConfig) { + return V1alpha1RoleBindingApiFp(this.configuration).patchV1alpha1RoleBinding(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/RoleBinding * @param {V1alpha1RoleBindingApiUpdateV1alpha1RoleBindingRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-secret-api.ts b/ui/packages/api-client/src/api/v1alpha1-secret-api.ts index 5b7b4dd93..a7e9fdb03 100644 --- a/ui/packages/api-client/src/api/v1alpha1-secret-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-secret-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Secret } from '../models'; // @ts-ignore import { SecretList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1SecretApiAxiosParamCreator = function (configuration?: Conf options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/Secret + * @param {string} name Name of secret + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Secret: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1Secret', 'name', name) + const localVarPath = `/api/v1alpha1/secrets/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/Secret * @param {string} name Name of secret @@ -323,6 +370,19 @@ export const V1alpha1SecretApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1SecretApi.listV1alpha1Secret']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/Secret + * @param {string} name Name of secret + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1Secret(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1Secret(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1SecretApi.patchV1alpha1Secret']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/Secret * @param {string} name Name of secret @@ -382,6 +442,15 @@ export const V1alpha1SecretApiFactory = function (configuration?: Configuration, listV1alpha1Secret(requestParameters: V1alpha1SecretApiListV1alpha1SecretRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1Secret(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/Secret + * @param {V1alpha1SecretApiPatchV1alpha1SecretRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Secret(requestParameters: V1alpha1SecretApiPatchV1alpha1SecretRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1Secret(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/Secret * @param {V1alpha1SecretApiUpdateV1alpha1SecretRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1SecretApiListV1alpha1SecretRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1Secret operation in V1alpha1SecretApi. + * @export + * @interface V1alpha1SecretApiPatchV1alpha1SecretRequest + */ +export interface V1alpha1SecretApiPatchV1alpha1SecretRequest { + /** + * Name of secret + * @type {string} + * @memberof V1alpha1SecretApiPatchV1alpha1Secret + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1SecretApiPatchV1alpha1Secret + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1Secret operation in V1alpha1SecretApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1SecretApi extends BaseAPI { return V1alpha1SecretApiFp(this.configuration).listV1alpha1Secret(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/Secret + * @param {V1alpha1SecretApiPatchV1alpha1SecretRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1SecretApi + */ + public patchV1alpha1Secret(requestParameters: V1alpha1SecretApiPatchV1alpha1SecretRequest, options?: RawAxiosRequestConfig) { + return V1alpha1SecretApiFp(this.configuration).patchV1alpha1Secret(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/Secret * @param {V1alpha1SecretApiUpdateV1alpha1SecretRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-setting-api.ts b/ui/packages/api-client/src/api/v1alpha1-setting-api.ts index 6f1ec030a..3f551b65f 100644 --- a/ui/packages/api-client/src/api/v1alpha1-setting-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-setting-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { Setting } from '../models'; // @ts-ignore import { SettingList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1SettingApiAxiosParamCreator = function (configuration?: Con options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/Setting + * @param {string} name Name of setting + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Setting: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1Setting', 'name', name) + const localVarPath = `/api/v1alpha1/settings/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/Setting * @param {string} name Name of setting @@ -323,6 +370,19 @@ export const V1alpha1SettingApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1SettingApi.listV1alpha1Setting']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/Setting + * @param {string} name Name of setting + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1Setting(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1Setting(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1SettingApi.patchV1alpha1Setting']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/Setting * @param {string} name Name of setting @@ -382,6 +442,15 @@ export const V1alpha1SettingApiFactory = function (configuration?: Configuration listV1alpha1Setting(requestParameters: V1alpha1SettingApiListV1alpha1SettingRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1Setting(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/Setting + * @param {V1alpha1SettingApiPatchV1alpha1SettingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1Setting(requestParameters: V1alpha1SettingApiPatchV1alpha1SettingRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1Setting(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/Setting * @param {V1alpha1SettingApiUpdateV1alpha1SettingRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1SettingApiListV1alpha1SettingRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1Setting operation in V1alpha1SettingApi. + * @export + * @interface V1alpha1SettingApiPatchV1alpha1SettingRequest + */ +export interface V1alpha1SettingApiPatchV1alpha1SettingRequest { + /** + * Name of setting + * @type {string} + * @memberof V1alpha1SettingApiPatchV1alpha1Setting + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1SettingApiPatchV1alpha1Setting + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1Setting operation in V1alpha1SettingApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1SettingApi extends BaseAPI { return V1alpha1SettingApiFp(this.configuration).listV1alpha1Setting(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/Setting + * @param {V1alpha1SettingApiPatchV1alpha1SettingRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1SettingApi + */ + public patchV1alpha1Setting(requestParameters: V1alpha1SettingApiPatchV1alpha1SettingRequest, options?: RawAxiosRequestConfig) { + return V1alpha1SettingApiFp(this.configuration).patchV1alpha1Setting(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/Setting * @param {V1alpha1SettingApiUpdateV1alpha1SettingRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/api/v1alpha1-user-api.ts b/ui/packages/api-client/src/api/v1alpha1-user-api.ts index 497d0b449..608f5a956 100644 --- a/ui/packages/api-client/src/api/v1alpha1-user-api.ts +++ b/ui/packages/api-client/src/api/v1alpha1-user-api.ts @@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore +import { JsonPatchInner } from '../models'; +// @ts-ignore import { User } from '../models'; // @ts-ignore import { UserList } from '../models'; @@ -216,6 +218,51 @@ export const V1alpha1UserApiAxiosParamCreator = function (configuration?: Config options: localVarRequestOptions, }; }, + /** + * Patch v1alpha1/User + * @param {string} name Name of user + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1User: async (name: string, jsonPatchInner?: Array, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'name' is not null or undefined + assertParamExists('patchV1alpha1User', 'name', name) + const localVarPath = `/api/v1alpha1/users/{name}` + .replace(`{${"name"}}`, encodeURIComponent(String(name))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options}; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication BasicAuth required + // http basic authentication required + setBasicAuthToObject(localVarRequestOptions, configuration) + + // authentication BearerAuth required + // http bearer authentication required + await setBearerAuthToObject(localVarHeaderParameter, configuration) + + + + localVarHeaderParameter['Content-Type'] = 'application/json-patch+json'; + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; + localVarRequestOptions.data = serializeDataIfNeeded(jsonPatchInner, localVarRequestOptions, configuration) + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Update v1alpha1/User * @param {string} name Name of user @@ -323,6 +370,19 @@ export const V1alpha1UserApiFp = function(configuration?: Configuration) { const localVarOperationServerBasePath = operationServerMap['V1alpha1UserApi.listV1alpha1User']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, + /** + * Patch v1alpha1/User + * @param {string} name Name of user + * @param {Array} [jsonPatchInner] + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async patchV1alpha1User(name: string, jsonPatchInner?: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.patchV1alpha1User(name, jsonPatchInner, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = operationServerMap['V1alpha1UserApi.patchV1alpha1User']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); + }, /** * Update v1alpha1/User * @param {string} name Name of user @@ -382,6 +442,15 @@ export const V1alpha1UserApiFactory = function (configuration?: Configuration, b listV1alpha1User(requestParameters: V1alpha1UserApiListV1alpha1UserRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.listV1alpha1User(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(axios, basePath)); }, + /** + * Patch v1alpha1/User + * @param {V1alpha1UserApiPatchV1alpha1UserRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + patchV1alpha1User(requestParameters: V1alpha1UserApiPatchV1alpha1UserRequest, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.patchV1alpha1User(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(axios, basePath)); + }, /** * Update v1alpha1/User * @param {V1alpha1UserApiUpdateV1alpha1UserRequest} requestParameters Request parameters. @@ -478,6 +547,27 @@ export interface V1alpha1UserApiListV1alpha1UserRequest { readonly sort?: Array } +/** + * Request parameters for patchV1alpha1User operation in V1alpha1UserApi. + * @export + * @interface V1alpha1UserApiPatchV1alpha1UserRequest + */ +export interface V1alpha1UserApiPatchV1alpha1UserRequest { + /** + * Name of user + * @type {string} + * @memberof V1alpha1UserApiPatchV1alpha1User + */ + readonly name: string + + /** + * + * @type {Array} + * @memberof V1alpha1UserApiPatchV1alpha1User + */ + readonly jsonPatchInner?: Array +} + /** * Request parameters for updateV1alpha1User operation in V1alpha1UserApi. * @export @@ -550,6 +640,17 @@ export class V1alpha1UserApi extends BaseAPI { return V1alpha1UserApiFp(this.configuration).listV1alpha1User(requestParameters.page, requestParameters.size, requestParameters.labelSelector, requestParameters.fieldSelector, requestParameters.sort, options).then((request) => request(this.axios, this.basePath)); } + /** + * Patch v1alpha1/User + * @param {V1alpha1UserApiPatchV1alpha1UserRequest} requestParameters Request parameters. + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof V1alpha1UserApi + */ + public patchV1alpha1User(requestParameters: V1alpha1UserApiPatchV1alpha1UserRequest, options?: RawAxiosRequestConfig) { + return V1alpha1UserApiFp(this.configuration).patchV1alpha1User(requestParameters.name, requestParameters.jsonPatchInner, options).then((request) => request(this.axios, this.basePath)); + } + /** * Update v1alpha1/User * @param {V1alpha1UserApiUpdateV1alpha1UserRequest} requestParameters Request parameters. diff --git a/ui/packages/api-client/src/models/add-operation.ts b/ui/packages/api-client/src/models/add-operation.ts new file mode 100644 index 000000000..013f79b5e --- /dev/null +++ b/ui/packages/api-client/src/models/add-operation.ts @@ -0,0 +1,49 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface AddOperation + */ +export interface AddOperation { + /** + * + * @type {string} + * @memberof AddOperation + */ + 'op': AddOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof AddOperation + */ + 'path': string; + /** + * Value can be any JSON value + * @type {any} + * @memberof AddOperation + */ + 'value': any; +} + +export const AddOperationOpEnum = { + Add: 'add' +} as const; + +export type AddOperationOpEnum = typeof AddOperationOpEnum[keyof typeof AddOperationOpEnum]; + + diff --git a/ui/packages/api-client/src/models/copy-operation.ts b/ui/packages/api-client/src/models/copy-operation.ts new file mode 100644 index 000000000..33daf5039 --- /dev/null +++ b/ui/packages/api-client/src/models/copy-operation.ts @@ -0,0 +1,49 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface CopyOperation + */ +export interface CopyOperation { + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof CopyOperation + */ + 'from': string; + /** + * + * @type {string} + * @memberof CopyOperation + */ + 'op': CopyOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof CopyOperation + */ + 'path': string; +} + +export const CopyOperationOpEnum = { + Copy: 'copy' +} as const; + +export type CopyOperationOpEnum = typeof CopyOperationOpEnum[keyof typeof CopyOperationOpEnum]; + + diff --git a/ui/packages/api-client/src/models/index.ts b/ui/packages/api-client/src/models/index.ts index d4734faee..07c82bcf1 100644 --- a/ui/packages/api-client/src/models/index.ts +++ b/ui/packages/api-client/src/models/index.ts @@ -1,3 +1,4 @@ +export * from './add-operation'; export * from './annotation-setting'; export * from './annotation-setting-list'; export * from './annotation-setting-spec'; @@ -44,6 +45,7 @@ export * from './content-vo'; export * from './content-wrapper'; export * from './contributor'; export * from './contributor-vo'; +export * from './copy-operation'; export * from './counter'; export * from './counter-list'; export * from './counter-request'; @@ -71,6 +73,7 @@ export * from './group-status'; export * from './install-from-uri-request'; export * from './interest-reason'; export * from './interest-reason-subject'; +export * from './json-patch-inner'; export * from './license'; export * from './list-result-reply-vo'; export * from './listed-auth-provider'; @@ -101,6 +104,7 @@ export * from './menu-list'; export * from './menu-spec'; export * from './menu-vo'; export * from './metadata'; +export * from './move-operation'; export * from './navigation-post-vo'; export * from './notification'; export * from './notification-list'; @@ -157,6 +161,8 @@ export * from './reason-type-notifier-request'; export * from './reason-type-spec'; export * from './ref'; export * from './register-verify-email-request'; +export * from './remove-operation'; +export * from './replace-operation'; export * from './reply'; export * from './reply-list'; export * from './reply-request'; @@ -212,6 +218,7 @@ export * from './tag-vo'; export * from './tag-vo-list'; export * from './template-content'; export * from './template-descriptor'; +export * from './test-operation'; export * from './theme'; export * from './theme-list'; export * from './theme-spec'; diff --git a/ui/packages/api-client/src/models/json-patch-inner.ts b/ui/packages/api-client/src/models/json-patch-inner.ts new file mode 100644 index 000000000..e582b71bb --- /dev/null +++ b/ui/packages/api-client/src/models/json-patch-inner.ts @@ -0,0 +1,41 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +// May contain unused imports in some cases +// @ts-ignore +import { AddOperation } from './add-operation'; +// May contain unused imports in some cases +// @ts-ignore +import { CopyOperation } from './copy-operation'; +// May contain unused imports in some cases +// @ts-ignore +import { MoveOperation } from './move-operation'; +// May contain unused imports in some cases +// @ts-ignore +import { RemoveOperation } from './remove-operation'; +// May contain unused imports in some cases +// @ts-ignore +import { ReplaceOperation } from './replace-operation'; +// May contain unused imports in some cases +// @ts-ignore +import { TestOperation } from './test-operation'; + +/** + * @type JsonPatchInner + * @export + */ +export type JsonPatchInner = AddOperation | CopyOperation | MoveOperation | RemoveOperation | ReplaceOperation | TestOperation; + + diff --git a/ui/packages/api-client/src/models/move-operation.ts b/ui/packages/api-client/src/models/move-operation.ts new file mode 100644 index 000000000..29cffd687 --- /dev/null +++ b/ui/packages/api-client/src/models/move-operation.ts @@ -0,0 +1,49 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface MoveOperation + */ +export interface MoveOperation { + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof MoveOperation + */ + 'from': string; + /** + * + * @type {string} + * @memberof MoveOperation + */ + 'op': MoveOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof MoveOperation + */ + 'path': string; +} + +export const MoveOperationOpEnum = { + Move: 'move' +} as const; + +export type MoveOperationOpEnum = typeof MoveOperationOpEnum[keyof typeof MoveOperationOpEnum]; + + diff --git a/ui/packages/api-client/src/models/remove-operation.ts b/ui/packages/api-client/src/models/remove-operation.ts new file mode 100644 index 000000000..ba9dbab7c --- /dev/null +++ b/ui/packages/api-client/src/models/remove-operation.ts @@ -0,0 +1,43 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface RemoveOperation + */ +export interface RemoveOperation { + /** + * + * @type {string} + * @memberof RemoveOperation + */ + 'op': RemoveOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof RemoveOperation + */ + 'path': string; +} + +export const RemoveOperationOpEnum = { + Remove: 'remove' +} as const; + +export type RemoveOperationOpEnum = typeof RemoveOperationOpEnum[keyof typeof RemoveOperationOpEnum]; + + diff --git a/ui/packages/api-client/src/models/replace-operation.ts b/ui/packages/api-client/src/models/replace-operation.ts new file mode 100644 index 000000000..f29a4b881 --- /dev/null +++ b/ui/packages/api-client/src/models/replace-operation.ts @@ -0,0 +1,49 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface ReplaceOperation + */ +export interface ReplaceOperation { + /** + * + * @type {string} + * @memberof ReplaceOperation + */ + 'op': ReplaceOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof ReplaceOperation + */ + 'path': string; + /** + * Value can be any JSON value + * @type {any} + * @memberof ReplaceOperation + */ + 'value': any; +} + +export const ReplaceOperationOpEnum = { + Replace: 'replace' +} as const; + +export type ReplaceOperationOpEnum = typeof ReplaceOperationOpEnum[keyof typeof ReplaceOperationOpEnum]; + + diff --git a/ui/packages/api-client/src/models/test-operation.ts b/ui/packages/api-client/src/models/test-operation.ts new file mode 100644 index 000000000..4c8bd7bfb --- /dev/null +++ b/ui/packages/api-client/src/models/test-operation.ts @@ -0,0 +1,49 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Halo Next API + * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + * + * The version of the OpenAPI document: 2.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * + * @export + * @interface TestOperation + */ +export interface TestOperation { + /** + * + * @type {string} + * @memberof TestOperation + */ + 'op': TestOperationOpEnum; + /** + * A JSON Pointer path pointing to the location to move/copy from. + * @type {string} + * @memberof TestOperation + */ + 'path': string; + /** + * Value can be any JSON value + * @type {any} + * @memberof TestOperation + */ + 'value': any; +} + +export const TestOperationOpEnum = { + Test: 'test' +} as const; + +export type TestOperationOpEnum = typeof TestOperationOpEnum[keyof typeof TestOperationOpEnum]; + +