From 2305c56e2627f731cdd7ece767a4d33ed764c153 Mon Sep 17 00:00:00 2001 From: Brendan Burns Date: Mon, 18 Dec 2017 20:42:30 -0800 Subject: [PATCH 1/2] Update docs. --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index e07ec27843..e21a171c66 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,9 @@ k8sApi.createNamespace(namespace).then( ); ``` +# Additional Examples +There are several more examples in the [examples](/kubernetes-client/javascript/tree/master/examples) directory. + # Development All dependencies of this project are expressed in its From 1a3eb1b941dd835602a9a50bc7ea1b53ecebc24a Mon Sep 17 00:00:00 2001 From: Brendan Burns Date: Mon, 19 Mar 2018 22:49:36 -0700 Subject: [PATCH 2/2] Update core library to 1.9.x --- README.md | 9 + node-client/index.ts | 5 + node-client/package.json | 10 +- node-client/src/.gitignore | 3 + node-client/src/.swagger-codegen-ignore | 23 + node-client/src/.swagger-codegen/COMMIT | 2 + node-client/src/.swagger-codegen/VERSION | 1 + node-client/src/api.ts | 22685 ++++++++++++++------- node-client/tsconfig.json | 2 +- settings | 26 + 10 files changed, 15652 insertions(+), 7114 deletions(-) create mode 100644 node-client/index.ts create mode 100644 node-client/src/.gitignore create mode 100644 node-client/src/.swagger-codegen-ignore create mode 100644 node-client/src/.swagger-codegen/COMMIT create mode 100644 node-client/src/.swagger-codegen/VERSION create mode 100644 settings diff --git a/README.md b/README.md index e21a171c66..3323ed5fc8 100644 --- a/README.md +++ b/README.md @@ -70,6 +70,15 @@ that you have [NPM](https://www.npmjs.com/) installed, then run: npm install ``` +## (re) Generating code + +``` +cd ../ +git clone https://github.com/kubernetes-client/gen +cd javascript +../gen/openapi/javascript.sh node-client/src settings +``` + # Testing Tests are written using the [Chai](http://chaijs.com/) library. See diff --git a/node-client/index.ts b/node-client/index.ts new file mode 100644 index 0000000000..7f49e18e9a --- /dev/null +++ b/node-client/index.ts @@ -0,0 +1,5 @@ +export * from './src/config'; +export * from './src/api'; +export * from './src/attach'; +export * from './src/watch'; +export * from './src/exec'; diff --git a/node-client/package.json b/node-client/package.json index b62bbc31e3..4a8ee06291 100644 --- a/node-client/package.json +++ b/node-client/package.json @@ -1,16 +1,18 @@ { "name": "@kubernetes/client-node", - "version": "0.1.3", + "version": "0.2.0", "description": "NodeJS client for kubernetes", "repository": { "type": "git", "url": "git+https://github.com/kubernetes-client/javascript.git" }, "files": [ - "*.ts", - "*.js" + "dist/src/*.ts", + "dist/src/*.js", + "index.ts" ], - "main": "index.js", + "main": "dist/index.js", + "types": "dist/index.d.ts", "scripts": { "clean": "rm -Rf node_modules/ dist/", "build": "tsc", diff --git a/node-client/src/.gitignore b/node-client/src/.gitignore new file mode 100644 index 0000000000..35e2fb2b02 --- /dev/null +++ b/node-client/src/.gitignore @@ -0,0 +1,3 @@ +wwwroot/*.js +node_modules +typings diff --git a/node-client/src/.swagger-codegen-ignore b/node-client/src/.swagger-codegen-ignore new file mode 100644 index 0000000000..c5fa491b4c --- /dev/null +++ b/node-client/src/.swagger-codegen-ignore @@ -0,0 +1,23 @@ +# Swagger Codegen Ignore +# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/node-client/src/.swagger-codegen/COMMIT b/node-client/src/.swagger-codegen/COMMIT new file mode 100644 index 0000000000..a25cb63362 --- /dev/null +++ b/node-client/src/.swagger-codegen/COMMIT @@ -0,0 +1,2 @@ +Requested Commit: v2.2.3 +Actual Commit: 049b1b2bcc904e1179a0e9b11124ed8fa0e3be2e diff --git a/node-client/src/.swagger-codegen/VERSION b/node-client/src/.swagger-codegen/VERSION new file mode 100644 index 0000000000..6b4d157738 --- /dev/null +++ b/node-client/src/.swagger-codegen/VERSION @@ -0,0 +1 @@ +2.2.3 \ No newline at end of file diff --git a/node-client/src/api.ts b/node-client/src/api.ts index 8ca9ed266a..aee9aa67cd 100644 --- a/node-client/src/api.ts +++ b/node-client/src/api.ts @@ -2,7 +2,7 @@ * Kubernetes * No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) * - * OpenAPI spec version: v1.8.4 + * OpenAPI spec version: v1.9.6 * * * NOTE: This class is auto generated by the swagger code generator program. @@ -22,6 +22,38 @@ let defaultBasePath = 'https://localhost'; /* tslint:disable:no-unused-variable */ +/** +* ServiceReference holds a reference to Service.legacy.k8s.io +*/ +export class AdmissionregistrationV1beta1ServiceReference { + /** + * `name` is the name of the service. Required + */ + 'name': string; + /** + * `namespace` is the namespace of the service. Required + */ + 'namespace': string; + /** + * `path` is an optional URL path which will be sent in any request to this service. + */ + 'path': string; +} + +/** +* ServiceReference holds a reference to Service.legacy.k8s.io +*/ +export class ApiregistrationV1beta1ServiceReference { + /** + * Name is the name of the service + */ + 'name': string; + /** + * Namespace is the namespace of the service + */ + 'namespace': string; +} + /** * DEPRECATED - This group version of Deployment is deprecated by apps/v1beta2/Deployment. See the release notes for more information. Deployment enables declarative updates for Pods and ReplicaSets. */ @@ -758,6 +790,16 @@ export class V1Affinity { 'podAntiAffinity': V1PodAntiAffinity; } +/** +* AggregationRule describes how to locate ClusterRoles to aggregate into the ClusterRole +*/ +export class V1AggregationRule { + /** + * ClusterRoleSelectors holds a list of selectors which will be used to find ClusterRoles and create the rules. If any of the selectors match, then the ClusterRole's permissions will be added + */ + 'clusterRoleSelectors': Array; +} + /** * AttachedVolume describes a volume attached to a node */ @@ -793,7 +835,7 @@ export class V1AzureDiskVolumeSource { */ 'fsType': string; /** - * Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared + * Expected values Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared */ 'kind': string; /** @@ -864,6 +906,24 @@ export class V1Binding { 'target': V1ObjectReference; } +/** +* Represents storage that is managed by an external CSI volume driver +*/ +export class V1CSIPersistentVolumeSource { + /** + * Driver is the name of the driver to use for this volume. Required. + */ + 'driver': string; + /** + * Optional: The value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write). + */ + 'readOnly': boolean; + /** + * VolumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required. + */ + 'volumeHandle': string; +} + /** * Adds and removes POSIX capabilities from running containers. */ @@ -970,6 +1030,10 @@ export class V1ClientIPConfig { * ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. */ export class V1ClusterRole { + /** + * AggregationRule is an optional field that describes how to build the Rules for this ClusterRole. If AggregationRule is set, then the Rules are controller managed and direct changes to Rules will be stomped by the controller. + */ + 'aggregationRule': V1AggregationRule; /** * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ @@ -1293,7 +1357,7 @@ export class V1Container { */ 'resources': V1ResourceRequirements; /** - * Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md + * Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ */ 'securityContext': V1SecurityContext; /** @@ -1317,6 +1381,10 @@ export class V1Container { */ 'tty': boolean; /** + * volumeDevices is the list of block devices to be used by the container. This is an alpha feature and may change in the future. + */ + 'volumeDevices': Array; + /** * Pod volumes to mount into the container's filesystem. Cannot be updated. */ 'volumeMounts': Array; @@ -1480,6 +1548,54 @@ export class V1ContainerStatus { 'state': V1ContainerState; } +/** +* ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers. +*/ +export class V1ControllerRevision { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Data is the serialized representation of the state. + */ + 'data': RuntimeRawExtension; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ObjectMeta; + /** + * Revision indicates the revision of the state represented by Data. + */ + 'revision': number; +} + +/** +* ControllerRevisionList is a resource containing a list of ControllerRevision objects. +*/ +export class V1ControllerRevisionList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Items is the list of ControllerRevisions + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ListMeta; +} + /** * CrossVersionObjectReference contains enough information to let you identify the referred resource. */ @@ -1508,6 +1624,166 @@ export class V1DaemonEndpoint { 'port': number; } +/** +* DaemonSet represents the configuration of a daemon set. +*/ +export class V1DaemonSet { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ObjectMeta; + /** + * The desired behavior of this daemon set. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status + */ + 'spec': V1DaemonSetSpec; + /** + * The current status of this daemon set. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status + */ + 'status': V1DaemonSetStatus; +} + +/** +* DaemonSetCondition describes the state of a DaemonSet at a certain point. +*/ +export class V1DaemonSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of DaemonSet condition. + */ + 'type': string; +} + +/** +* DaemonSetList is a collection of daemon sets. +*/ +export class V1DaemonSetList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * A list of daemon sets. + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ListMeta; +} + +/** +* DaemonSetSpec is the specification of a daemon set. +*/ +export class V1DaemonSetSpec { + /** + * The minimum number of seconds for which a newly created DaemonSet pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready). + */ + 'minReadySeconds': number; + /** + * The number of old history to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 10. + */ + 'revisionHistoryLimit': number; + /** + * A label query over pods that are managed by the daemon set. Must match in order to be controlled. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + */ + 'selector': V1LabelSelector; + /** + * An object that describes the pod that will be created. The DaemonSet will create exactly one copy of this pod on every node that matches the template's node selector (or on every node if no node selector is specified). More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template + */ + 'template': V1PodTemplateSpec; + /** + * An update strategy to replace existing DaemonSet pods with new pods. + */ + 'updateStrategy': V1DaemonSetUpdateStrategy; +} + +/** +* DaemonSetStatus represents the current status of a daemon set. +*/ +export class V1DaemonSetStatus { + /** + * Count of hash collisions for the DaemonSet. The DaemonSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision. + */ + 'collisionCount': number; + /** + * Represents the latest available observations of a DaemonSet's current state. + */ + 'conditions': Array; + /** + * The number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ + */ + 'currentNumberScheduled': number; + /** + * The total number of nodes that should be running the daemon pod (including nodes correctly running the daemon pod). More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ + */ + 'desiredNumberScheduled': number; + /** + * The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and available (ready for at least spec.minReadySeconds) + */ + 'numberAvailable': number; + /** + * The number of nodes that are running the daemon pod, but are not supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ + */ + 'numberMisscheduled': number; + /** + * The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and ready. + */ + 'numberReady': number; + /** + * The number of nodes that should be running the daemon pod and have none of the daemon pod running and available (ready for at least spec.minReadySeconds) + */ + 'numberUnavailable': number; + /** + * The most recent generation observed by the daemon set controller. + */ + 'observedGeneration': number; + /** + * The total number of nodes that are running updated daemon pod + */ + 'updatedNumberScheduled': number; +} + +/** +* DaemonSetUpdateStrategy is a struct used to control the update strategy for a DaemonSet. +*/ +export class V1DaemonSetUpdateStrategy { + /** + * Rolling update config params. Present only if type = \"RollingUpdate\". + */ + 'rollingUpdate': V1RollingUpdateDaemonSet; + /** + * Type of daemon set update. Can be \"RollingUpdate\" or \"OnDelete\". Default is RollingUpdate. + */ + 'type': string; +} + /** * DeleteOptions may be provided when deleting an API object. */ @@ -1533,11 +1809,179 @@ export class V1DeleteOptions { */ 'preconditions': V1Preconditions; /** - * Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ 'propagationPolicy': string; } +/** +* Deployment enables declarative updates for Pods and ReplicaSets. +*/ +export class V1Deployment { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard object metadata. + */ + 'metadata': V1ObjectMeta; + /** + * Specification of the desired behavior of the Deployment. + */ + 'spec': V1DeploymentSpec; + /** + * Most recently observed status of the Deployment. + */ + 'status': V1DeploymentStatus; +} + +/** +* DeploymentCondition describes the state of a deployment at a certain point. +*/ +export class V1DeploymentCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * The last time this condition was updated. + */ + 'lastUpdateTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of deployment condition. + */ + 'type': string; +} + +/** +* DeploymentList is a list of Deployments. +*/ +export class V1DeploymentList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Items is the list of Deployments. + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. + */ + 'metadata': V1ListMeta; +} + +/** +* DeploymentSpec is the specification of the desired behavior of the Deployment. +*/ +export class V1DeploymentSpec { + /** + * Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) + */ + 'minReadySeconds': number; + /** + * Indicates that the deployment is paused. + */ + 'paused': boolean; + /** + * The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Note that progress will not be estimated during the time a deployment is paused. Defaults to 600s. + */ + 'progressDeadlineSeconds': number; + /** + * Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1. + */ + 'replicas': number; + /** + * The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 10. + */ + 'revisionHistoryLimit': number; + /** + * Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. It must match the pod template's labels. + */ + 'selector': V1LabelSelector; + /** + * The deployment strategy to use to replace existing pods with new ones. + */ + 'strategy': V1DeploymentStrategy; + /** + * Template describes the pods that will be created. + */ + 'template': V1PodTemplateSpec; +} + +/** +* DeploymentStatus is the most recently observed status of the Deployment. +*/ +export class V1DeploymentStatus { + /** + * Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. + */ + 'availableReplicas': number; + /** + * Count of hash collisions for the Deployment. The Deployment controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ReplicaSet. + */ + 'collisionCount': number; + /** + * Represents the latest available observations of a deployment's current state. + */ + 'conditions': Array; + /** + * The generation observed by the deployment controller. + */ + 'observedGeneration': number; + /** + * Total number of ready pods targeted by this deployment. + */ + 'readyReplicas': number; + /** + * Total number of non-terminated pods targeted by this deployment (their labels match the selector). + */ + 'replicas': number; + /** + * Total number of unavailable pods targeted by this deployment. This is the total number of pods that are still required for the deployment to have 100% available capacity. They may either be pods that are running but not yet available or pods that still have not been created. + */ + 'unavailableReplicas': number; + /** + * Total number of non-terminated pods targeted by this deployment that have the desired template spec. + */ + 'updatedReplicas': number; +} + +/** +* DeploymentStrategy describes how to replace existing pods with new ones. +*/ +export class V1DeploymentStrategy { + /** + * Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. + */ + 'rollingUpdate': V1RollingUpdateDeployment; + /** + * Type of deployment. Can be \"Recreate\" or \"RollingUpdate\". Default is RollingUpdate. + */ + 'type': string; +} + /** * Represents downward API info for projecting into a projected volume. Note that this is identical to a downwardAPI volume source without the default mode. */ @@ -1762,6 +2206,10 @@ export class V1EnvVarSource { * Event is a report of an event somewhere in the cluster. */ export class V1Event { + /** + * What action was taken/failed regarding to the Regarding object. + */ + 'action': string; /** * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ @@ -1771,6 +2219,10 @@ export class V1Event { */ 'count': number; /** + * Time when this Event was first observed. + */ + 'eventTime': Date; + /** * The time at which the event was first recorded. (Time of server receipt is in TypeMeta.) */ 'firstTimestamp': Date; @@ -1799,6 +2251,22 @@ export class V1Event { */ 'reason': string; /** + * Optional secondary object for more complex actions. + */ + 'related': V1ObjectReference; + /** + * Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. + */ + 'reportingComponent': string; + /** + * ID of the controller instance, e.g. `kubelet-xyzf`. + */ + 'reportingInstance': string; + /** + * Data about the Event series this event represents or nil if it's a singleton Event. + */ + 'series': V1EventSeries; + /** * The component reporting this event. Should be a short machine understandable string. */ 'source': V1EventSource; @@ -1830,6 +2298,24 @@ export class V1EventList { 'metadata': V1ListMeta; } +/** +* EventSeries contain information on series of events, i.e. thing that was/is happening continously for some time. +*/ +export class V1EventSeries { + /** + * Number of occurrences in this series up to the last heartbeat time + */ + 'count': number; + /** + * Time of the last occurence observed + */ + 'lastObservedTime': Date; + /** + * State of this Series: Ongoing or Finished + */ + 'state': string; +} + /** * EventSource contains information for an event. */ @@ -1881,7 +2367,7 @@ export class V1FCVolumeSource { } /** -* FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. +* FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. */ export class V1FlexVolumeSource { /** @@ -2188,6 +2674,56 @@ export class V1IPBlock { 'except': Array; } +/** +* ISCSIPersistentVolumeSource represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling. +*/ +export class V1ISCSIPersistentVolumeSource { + /** + * whether support iSCSI Discovery CHAP authentication + */ + 'chapAuthDiscovery': boolean; + /** + * whether support iSCSI Session CHAP authentication + */ + 'chapAuthSession': boolean; + /** + * Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi + */ + 'fsType': string; + /** + * Custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection. + */ + 'initiatorName': string; + /** + * Target iSCSI Qualified Name. + */ + 'iqn': string; + /** + * iSCSI Interface Name that uses an iSCSI transport. Defaults to 'default' (tcp). + */ + 'iscsiInterface': string; + /** + * iSCSI Target Lun number. + */ + 'lun': number; + /** + * iSCSI Target Portal List. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). + */ + 'portals': Array; + /** + * ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. + */ + 'readOnly': boolean; + /** + * CHAP Secret for iSCSI target and initiator authentication + */ + 'secretRef': V1SecretReference; + /** + * iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). + */ + 'targetPortal': string; +} + /** * Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling. */ @@ -2205,7 +2741,7 @@ export class V1ISCSIVolumeSource { */ 'fsType': string; /** - * Custom iSCSI initiator name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection. + * Custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection. */ 'initiatorName': string; /** @@ -2213,15 +2749,15 @@ export class V1ISCSIVolumeSource { */ 'iqn': string; /** - * Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. + * iSCSI Interface Name that uses an iSCSI transport. Defaults to 'default' (tcp). */ 'iscsiInterface': string; /** - * iSCSI target lun number. + * iSCSI Target Lun number. */ 'lun': number; /** - * iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). + * iSCSI Target Portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). */ 'portals': Array; /** @@ -2229,11 +2765,11 @@ export class V1ISCSIVolumeSource { */ 'readOnly': boolean; /** - * CHAP secret for iSCSI target and initiator authentication + * CHAP Secret for iSCSI target and initiator authentication */ 'secretRef': V1LocalObjectReference; /** - * iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). + * iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). */ 'targetPortal': string; } @@ -2357,7 +2893,7 @@ export class V1JobSpec { */ 'completions': number; /** - * manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md + * manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/#specifying-your-own-pod-selector */ 'manualSelector': boolean; /** @@ -2529,7 +3065,7 @@ export class V1LimitRangeList { */ 'apiVersion': string; /** - * Items is a list of LimitRange objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_limit_range.md + * Items is a list of LimitRange objects. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ */ 'items': Array; /** @@ -2708,7 +3244,7 @@ export class V1NamespaceList { */ export class V1NamespaceSpec { /** - * Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers + * Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/ */ 'finalizers': Array; } @@ -2718,7 +3254,7 @@ export class V1NamespaceSpec { */ export class V1NamespaceStatus { /** - * Phase is the current lifecycle phase of the namespace. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#phases + * Phase is the current lifecycle phase of the namespace. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/ */ 'phase': string; } @@ -3203,7 +3739,7 @@ export class V1ObjectMeta { */ 'deletionGracePeriodSeconds': number; /** - * DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested. Populated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + * DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field, once the finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. Once the deletionTimestamp is set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested. Populated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata */ 'deletionTimestamp': Date; /** @@ -3435,6 +3971,10 @@ export class V1PersistentVolumeClaimSpec { */ 'storageClassName': string; /** + * volumeMode defines what type of volume is required by the claim. Value of Filesystem is implied when not included in claim spec. This is an alpha feature and may change in the future. + */ + 'volumeMode': string; + /** * VolumeName is the binding reference to the PersistentVolume backing this claim. */ 'volumeName': string; @@ -3535,11 +4075,15 @@ export class V1PersistentVolumeSpec { */ 'claimRef': V1ObjectReference; /** + * CSI represents storage that handled by an external CSI driver + */ + 'csi': V1CSIPersistentVolumeSource; + /** * FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. */ 'fc': V1FCVolumeSource; /** - * FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. + * FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. */ 'flexVolume': V1FlexVolumeSource; /** @@ -3561,7 +4105,7 @@ export class V1PersistentVolumeSpec { /** * ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. */ - 'iscsi': V1ISCSIVolumeSource; + 'iscsi': V1ISCSIPersistentVolumeSource; /** * Local represents directly-attached storage with node affinity */ @@ -3593,7 +4137,7 @@ export class V1PersistentVolumeSpec { /** * RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md */ - 'rbd': V1RBDVolumeSource; + 'rbd': V1RBDPersistentVolumeSource; /** * ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. */ @@ -3607,6 +4151,10 @@ export class V1PersistentVolumeSpec { */ 'storageos': V1StorageOSPersistentVolumeSource; /** + * volumeMode defines if a volume is intended to be used with a formatted filesystem or to remain in raw block state. Value of Filesystem is implied when not included in spec. This is an alpha feature and may change in the future. + */ + 'volumeMode': string; + /** * VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine */ 'vsphereVolume': V1VsphereVirtualDiskVolumeSource; @@ -3685,7 +4233,7 @@ export class V1PodAffinity { } /** -* Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key tches that of any node on which a pod of the set of pods is running +* Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key matches that of any node on which a pod of the set of pods is running */ export class V1PodAffinityTerm { /** @@ -3697,7 +4245,7 @@ export class V1PodAffinityTerm { */ 'namespaces': Array; /** - * This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as \"all topologies\" (\"all topologies\" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. + * This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed. */ 'topologyKey': string; } @@ -3746,6 +4294,35 @@ export class V1PodCondition { 'type': string; } +/** +* PodDNSConfig defines the DNS parameters of a pod in addition to those generated from DNSPolicy. +*/ +export class V1PodDNSConfig { + /** + * A list of DNS name server IP addresses. This will be appended to the base nameservers generated from DNSPolicy. Duplicated nameservers will be removed. + */ + 'nameservers': Array; + /** + * A list of DNS resolver options. This will be merged with the base options generated from DNSPolicy. Duplicated entries will be removed. Resolution options given in Options will override those that appear in the base DNSPolicy. + */ + 'options': Array; + /** + * A list of DNS search domains for host-name lookup. This will be appended to the base search paths generated from DNSPolicy. Duplicated search paths will be removed. + */ + 'searches': Array; +} + +/** +* PodDNSConfigOption defines DNS resolver options of a pod. +*/ +export class V1PodDNSConfigOption { + /** + * Required. + */ + 'name': string; + 'value': string; +} + /** * PodList is a list of Pods. */ @@ -3815,7 +4392,11 @@ export class V1PodSpec { */ 'containers': Array; /** - * Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to \"ClusterFirst\". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. + * Specifies the DNS parameters of a pod. Parameters specified here will be merged to the generated DNS configuration based on DNSPolicy. This is an alpha feature introduced in v1.9 and CustomPodDNS feature gate must be enabled to use it. + */ + 'dnsConfig': V1PodDNSConfig; + /** + * Set DNS policy for the pod. Defaults to \"ClusterFirst\". Valid values are 'ClusterFirstWithHostNet', 'ClusterFirst', 'Default' or 'None'. DNS parameters given in DNSConfig will be merged with the policy selected with DNSPolicy. To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. Note that 'None' policy is an alpha feature introduced in v1.9 and CustomPodDNS feature gate must be enabled to use it. */ 'dnsPolicy': string; /** @@ -4150,6 +4731,44 @@ export class V1QuobyteVolumeSource { 'volume': string; } +/** +* Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling. +*/ +export class V1RBDPersistentVolumeSource { + /** + * Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd + */ + 'fsType': string; + /** + * The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'image': string; + /** + * Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'keyring': string; + /** + * A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'monitors': Array; + /** + * The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'pool': string; + /** + * ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'readOnly': boolean; + /** + * SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'secretRef': V1SecretReference; + /** + * The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + */ + 'user': string; +} + /** * Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling. */ @@ -4188,6 +4807,132 @@ export class V1RBDVolumeSource { 'user': string; } +/** +* ReplicaSet ensures that a specified number of pod replicas are running at any given time. +*/ +export class V1ReplicaSet { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * If the Labels of a ReplicaSet are empty, they are defaulted to be the same as the Pod(s) that the ReplicaSet manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ObjectMeta; + /** + * Spec defines the specification of the desired behavior of the ReplicaSet. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status + */ + 'spec': V1ReplicaSetSpec; + /** + * Status is the most recently observed status of the ReplicaSet. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status + */ + 'status': V1ReplicaSetStatus; +} + +/** +* ReplicaSetCondition describes the state of a replica set at a certain point. +*/ +export class V1ReplicaSetCondition { + /** + * The last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of replica set condition. + */ + 'type': string; +} + +/** +* ReplicaSetList is a collection of ReplicaSets. +*/ +export class V1ReplicaSetList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'metadata': V1ListMeta; +} + +/** +* ReplicaSetSpec is the specification of a ReplicaSet. +*/ +export class V1ReplicaSetSpec { + /** + * Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) + */ + 'minReadySeconds': number; + /** + * Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller + */ + 'replicas': number; + /** + * Selector is a label query over pods that should match the replica count. Label keys and values that must match in order to be controlled by this replica set. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + */ + 'selector': V1LabelSelector; + /** + * Template is the object that describes the pod that will be created if insufficient replicas are detected. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template + */ + 'template': V1PodTemplateSpec; +} + +/** +* ReplicaSetStatus represents the current status of a ReplicaSet. +*/ +export class V1ReplicaSetStatus { + /** + * The number of available replicas (ready for at least minReadySeconds) for this replica set. + */ + 'availableReplicas': number; + /** + * Represents the latest available observations of a replica set's current state. + */ + 'conditions': Array; + /** + * The number of pods that have labels matching the labels of the pod template of the replicaset. + */ + 'fullyLabeledReplicas': number; + /** + * ObservedGeneration reflects the generation of the most recently observed ReplicaSet. + */ + 'observedGeneration': number; + /** + * The number of ready replicas for this replica set. + */ + 'readyReplicas': number; + /** + * Replicas is the most recently oberved number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller + */ + 'replicas': number; +} + /** * ReplicationController represents the configuration of a replication controller. */ @@ -4401,7 +5146,7 @@ export class V1ResourceQuotaList { */ 'apiVersion': string; /** - * Items is a list of ResourceQuota objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md + * Items is a list of ResourceQuota objects. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/ */ 'items': Array; /** @@ -4419,7 +5164,7 @@ export class V1ResourceQuotaList { */ export class V1ResourceQuotaSpec { /** - * Hard is the set of desired hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md + * Hard is the set of desired hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/ */ 'hard': { [key: string]: string; }; /** @@ -4433,7 +5178,7 @@ export class V1ResourceQuotaSpec { */ export class V1ResourceQuotaStatus { /** - * Hard is the set of enforced hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md + * Hard is the set of enforced hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/ */ 'hard': { [key: string]: string; }; /** @@ -4469,7 +5214,7 @@ export class V1ResourceRule { */ 'resourceNames': Array; /** - * Resources is a list of resources this rule applies to. ResourceAll represents all resources. \"*\" means all. + * Resources is a list of resources this rule applies to. \"*\" means all in the specified apiGroups. \"*_/foo\" represents the subresource 'foo' for all resources in the specified apiGroups. */ 'resources': Array; /** @@ -4588,6 +5333,40 @@ export class V1RoleRef { 'name': string; } +/** +* Spec to control the desired behavior of daemon set rolling update. +*/ +export class V1RollingUpdateDaemonSet { + /** + * The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update. + */ + 'maxUnavailable': any; +} + +/** +* Spec to control the desired behavior of rolling update. +*/ +export class V1RollingUpdateDeployment { + /** + * The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. + */ + 'maxSurge': any; + /** + * The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. + */ + 'maxUnavailable': any; +} + +/** +* RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType. +*/ +export class V1RollingUpdateStatefulSetStrategy { + /** + * Partition indicates the ordinal at which the StatefulSet should be partitioned. Default value is 0. + */ + 'partition': number; +} + /** * SELinuxOptions are the labels to be applied to the container */ @@ -5144,7 +5923,7 @@ export class V1ServiceSpec { */ 'externalIPs': Array; /** - * externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid DNS name and requires Type to be ExternalName. + * externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid RFC-1123 hostname (https://tools.ietf.org/html/rfc1123) and requires Type to be ExternalName. */ 'externalName': string; /** @@ -5209,6 +5988,165 @@ export class V1SessionAffinityConfig { 'clientIP': V1ClientIPConfig; } +/** +* StatefulSet represents a set of pods with consistent identities. Identities are defined as: - Network: A single stable DNS and hostname. - Storage: As many VolumeClaims as requested. The StatefulSet guarantees that a given network identity will always map to the same storage identity. +*/ +export class V1StatefulSet { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + 'metadata': V1ObjectMeta; + /** + * Spec defines the desired identities of pods in this set. + */ + 'spec': V1StatefulSetSpec; + /** + * Status is the current status of Pods in this StatefulSet. This data may be out of date by some window of time. + */ + 'status': V1StatefulSetStatus; +} + +/** +* StatefulSetCondition describes the state of a statefulset at a certain point. +*/ +export class V1StatefulSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of statefulset condition. + */ + 'type': string; +} + +/** +* StatefulSetList is a collection of StatefulSets. +*/ +export class V1StatefulSetList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + 'metadata': V1ListMeta; +} + +/** +* A StatefulSetSpec is the specification of a StatefulSet. +*/ +export class V1StatefulSetSpec { + /** + * podManagementPolicy controls how pods are created during initial scale up, when replacing pods on nodes, or when scaling down. The default policy is `OrderedReady`, where pods are created in increasing order (pod-0, then pod-1, etc) and the controller will wait until each pod is ready before continuing. When scaling down, the pods are removed in the opposite order. The alternative policy is `Parallel` which will create pods in parallel to match the desired scale without waiting, and on scale down will delete all pods at once. + */ + 'podManagementPolicy': string; + /** + * replicas is the desired number of replicas of the given Template. These are replicas in the sense that they are instantiations of the same Template, but individual replicas also have a consistent identity. If unspecified, defaults to 1. + */ + 'replicas': number; + /** + * revisionHistoryLimit is the maximum number of revisions that will be maintained in the StatefulSet's revision history. The revision history consists of all revisions not represented by a currently applied StatefulSetSpec version. The default value is 10. + */ + 'revisionHistoryLimit': number; + /** + * selector is a label query over pods that should match the replica count. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + */ + 'selector': V1LabelSelector; + /** + * serviceName is the name of the service that governs this StatefulSet. This service must exist before the StatefulSet, and is responsible for the network identity of the set. Pods get DNS/hostnames that follow the pattern: pod-specific-string.serviceName.default.svc.cluster.local where \"pod-specific-string\" is managed by the StatefulSet controller. + */ + 'serviceName': string; + /** + * template is the object that describes the pod that will be created if insufficient replicas are detected. Each pod stamped out by the StatefulSet will fulfill this Template, but have a unique identity from the rest of the StatefulSet. + */ + 'template': V1PodTemplateSpec; + /** + * updateStrategy indicates the StatefulSetUpdateStrategy that will be employed to update Pods in the StatefulSet when a revision is made to Template. + */ + 'updateStrategy': V1StatefulSetUpdateStrategy; + /** + * volumeClaimTemplates is a list of claims that pods are allowed to reference. The StatefulSet controller is responsible for mapping network identities to claims in a way that maintains the identity of a pod. Every claim in this list must have at least one matching (by name) volumeMount in one container in the template. A claim in this list takes precedence over any volumes in the template, with the same name. + */ + 'volumeClaimTemplates': Array; +} + +/** +* StatefulSetStatus represents the current state of a StatefulSet. +*/ +export class V1StatefulSetStatus { + /** + * collisionCount is the count of hash collisions for the StatefulSet. The StatefulSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision. + */ + 'collisionCount': number; + /** + * Represents the latest available observations of a statefulset's current state. + */ + 'conditions': Array; + /** + * currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision. + */ + 'currentReplicas': number; + /** + * currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas). + */ + 'currentRevision': string; + /** + * observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server. + */ + 'observedGeneration': number; + /** + * readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. + */ + 'readyReplicas': number; + /** + * replicas is the number of Pods created by the StatefulSet controller. + */ + 'replicas': number; + /** + * updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas) + */ + 'updateRevision': string; + /** + * updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision. + */ + 'updatedReplicas': number; +} + +/** +* StatefulSetUpdateStrategy indicates the strategy that the StatefulSet controller will use to perform updates. It includes any additional parameters necessary to perform the update for the indicated strategy. +*/ +export class V1StatefulSetUpdateStrategy { + /** + * RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. + */ + 'rollingUpdate': V1RollingUpdateStatefulSetStrategy; + /** + * Type indicates the type of the StatefulSetUpdateStrategy. Default is RollingUpdate. + */ + 'type': string; +} + /** * Status is a return value for calls that don't return other objects. */ @@ -5331,6 +6269,10 @@ export class V1StorageClass { * Dynamically provisioned PersistentVolumes of this storage class are created with this reclaimPolicy. Defaults to Delete. */ 'reclaimPolicy': string; + /** + * VolumeBindingMode indicates how PersistentVolumeClaims should be provisioned and bound. When unset, VolumeBindingImmediate is used. This field is alpha-level and is only honored by servers that enable the VolumeScheduling feature. + */ + 'volumeBindingMode': string; } /** @@ -5487,10 +6429,14 @@ export class V1SubjectAccessReviewSpec { */ export class V1SubjectAccessReviewStatus { /** - * Allowed is required. True if the action would be allowed, false otherwise. + * Allowed is required. True if the action would be allowed, false otherwise. */ 'allowed': boolean; /** + * Denied is optional. True if the action would be denied, otherwise false. If both allowed is false and denied is false, then the authorizer has no opinion on whether to authorize the action. Denied may not be true if Allowed is true. + */ + 'denied': boolean; + /** * EvaluationError is an indication that some error occurred during the authorization check. It is entirely possible to get an error and be able to continue determine authorization status in spite of it. For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. */ 'evaluationError': string; @@ -5698,7 +6644,7 @@ export class V1Volume { */ 'fc': V1FCVolumeSource; /** - * FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. + * FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. */ 'flexVolume': V1FlexVolumeSource; /** @@ -5775,6 +6721,20 @@ export class V1Volume { 'vsphereVolume': V1VsphereVirtualDiskVolumeSource; } +/** +* volumeDevice describes a mapping of a raw block device within a container. +*/ +export class V1VolumeDevice { + /** + * devicePath is the path inside of the container that the device will be mapped to. + */ + 'devicePath': string; + /** + * name must match the name of a persistentVolumeClaim in the pod + */ + 'name': string; +} + /** * VolumeMount describes a mounting of a Volume within a container. */ @@ -5867,23 +6827,23 @@ export class V1WeightedPodAffinityTerm { } /** -* AdmissionHookClientConfig contains the information to make a TLS connection with the webhook +* AggregationRule describes how to locate ClusterRoles to aggregate into the ClusterRole */ -export class V1alpha1AdmissionHookClientConfig { - /** - * CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required - */ - 'caBundle': string; +export class V1alpha1AggregationRule { /** - * Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required + * ClusterRoleSelectors holds a list of selectors which will be used to find ClusterRoles and create the rules. If any of the selectors match, then the ClusterRole's permissions will be added */ - 'service': V1alpha1ServiceReference; + 'clusterRoleSelectors': Array; } /** * ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. */ export class V1alpha1ClusterRole { + /** + * AggregationRule is an optional field that describes how to build the Rules for this ClusterRole. If AggregationRule is set, then the Rules are controller managed and direct changes to Rules will be stomped by the controller. + */ + 'aggregationRule': V1alpha1AggregationRule; /** * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ @@ -5972,72 +6932,6 @@ export class V1alpha1ClusterRoleList { 'metadata': V1ListMeta; } -/** -* ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to. -*/ -export class V1alpha1ExternalAdmissionHook { - /** - * ClientConfig defines how to communicate with the hook. Required - */ - 'clientConfig': V1alpha1AdmissionHookClientConfig; - /** - * FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore. - */ - 'failurePolicy': string; - /** - * The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required. - */ - 'name': string; - /** - * Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule. - */ - 'rules': Array; -} - -/** -* ExternalAdmissionHookConfiguration describes the configuration of initializers. -*/ -export class V1alpha1ExternalAdmissionHookConfiguration { - /** - * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources - */ - 'apiVersion': string; - /** - * ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations. - */ - 'externalAdmissionHooks': Array; - /** - * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds - */ - 'kind': string; - /** - * Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. - */ - 'metadata': V1ObjectMeta; -} - -/** -* ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. -*/ -export class V1alpha1ExternalAdmissionHookConfigurationList { - /** - * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources - */ - 'apiVersion': string; - /** - * List of ExternalAdmissionHookConfiguration. - */ - 'items': Array; - /** - * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds - */ - 'kind': string; - /** - * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds - */ - 'metadata': V1ListMeta; -} - /** * Initializer describes the name and the failure policy of an initializer, and what resources it applies to. */ @@ -6367,61 +7261,137 @@ export class V1alpha1Rule { } /** -* RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid. +* Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names. */ -export class V1alpha1RuleWithOperations { +export class V1alpha1Subject { /** - * APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required. + * APIVersion holds the API group and version of the referenced subject. Defaults to \"v1\" for ServiceAccount subjects. Defaults to \"rbac.authorization.k8s.io/v1alpha1\" for User and Group subjects. */ - 'apiGroups': Array; + 'apiVersion': string; /** - * APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required. + * Kind of object being referenced. Values defined by this API group are \"User\", \"Group\", and \"ServiceAccount\". If the Authorizer does not recognized the kind value, the Authorizer should report an error. */ - 'apiVersions': Array; + 'kind': string; /** - * Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required. + * Name of the object being referenced. */ - 'operations': Array; + 'name': string; /** - * Resources is a list of resources this rule applies to. For example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/_*' means all subresources of pods. '*_/scale' means all scale subresources. '*_/_*' means all resources and their subresources. If wildcard is present, the validation rule will ensure resources do not overlap with each other. Depending on the enclosing object, subresources might not be allowed. Required. + * Namespace of the referenced object. If the object kind is non-namespace, such as \"User\" or \"Group\", and this value is not empty the Authorizer should report an error. */ - 'resources': Array; + 'namespace': string; } /** -* ServiceReference holds a reference to Service.legacy.k8s.io +* VolumeAttachment captures the intent to attach or detach the specified volume to/from the specified node. VolumeAttachment objects are non-namespaced. */ -export class V1alpha1ServiceReference { +export class V1alpha1VolumeAttachment { /** - * Name is the name of the service Required + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ - 'name': string; + 'apiVersion': string; /** - * Namespace is the namespace of the service Required + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds */ - 'namespace': string; + 'kind': string; + /** + * Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ObjectMeta; + /** + * Specification of the desired attach/detach volume behavior. Populated by the Kubernetes system. + */ + 'spec': V1alpha1VolumeAttachmentSpec; + /** + * Status of the VolumeAttachment request. Populated by the entity completing the attach or detach operation, i.e. the external-attacher. + */ + 'status': V1alpha1VolumeAttachmentStatus; } /** -* Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names. +* VolumeAttachmentList is a collection of VolumeAttachment objects. */ -export class V1alpha1Subject { +export class V1alpha1VolumeAttachmentList { /** - * APIVersion holds the API group and version of the referenced subject. Defaults to \"v1\" for ServiceAccount subjects. Defaults to \"rbac.authorization.k8s.io/v1alpha1\" for User and Group subjects. + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ 'apiVersion': string; /** - * Kind of object being referenced. Values defined by this API group are \"User\", \"Group\", and \"ServiceAccount\". If the Authorizer does not recognized the kind value, the Authorizer should report an error. + * Items is the list of VolumeAttachments + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds */ 'kind': string; /** - * Name of the object being referenced. + * Standard list metadata More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata */ - 'name': string; + 'metadata': V1ListMeta; +} + +/** +* VolumeAttachmentSource represents a volume that should be attached. Right now only PersistenVolumes can be attached via external attacher, in future we may allow also inline volumes in pods. Exactly one member can be set. +*/ +export class V1alpha1VolumeAttachmentSource { /** - * Namespace of the referenced object. If the object kind is non-namespace, such as \"User\" or \"Group\", and this value is not empty the Authorizer should report an error. + * Name of the persistent volume to attach. */ - 'namespace': string; + 'persistentVolumeName': string; +} + +/** +* VolumeAttachmentSpec is the specification of a VolumeAttachment request. +*/ +export class V1alpha1VolumeAttachmentSpec { + /** + * Attacher indicates the name of the volume driver that MUST handle this request. This is the name returned by GetPluginName(). + */ + 'attacher': string; + /** + * The node that the volume should be attached to. + */ + 'nodeName': string; + /** + * Source represents the volume that should be attached. + */ + 'source': V1alpha1VolumeAttachmentSource; +} + +/** +* VolumeAttachmentStatus is the status of a VolumeAttachment request. +*/ +export class V1alpha1VolumeAttachmentStatus { + /** + * The last error encountered during attach operation, if any. This field must only be set by the entity completing the attach operation, i.e. the external-attacher. + */ + 'attachError': V1alpha1VolumeError; + /** + * Indicates the volume is successfully attached. This field must only be set by the entity completing the attach operation, i.e. the external-attacher. + */ + 'attached': boolean; + /** + * Upon successful attach, this field is populated with any information returned by the attach operation that must be passed into subsequent WaitForAttach or Mount calls. This field must only be set by the entity completing the attach operation, i.e. the external-attacher. + */ + 'attachmentMetadata': { [key: string]: string; }; + /** + * The last error encountered during detach operation, if any. This field must only be set by the entity completing the detach operation, i.e. the external-attacher. + */ + 'detachError': V1alpha1VolumeError; +} + +/** +* VolumeError captures an error encountered during a volume operation. +*/ +export class V1alpha1VolumeError { + /** + * String detailing the error encountered during Attach or Detach operation. This string maybe logged, so it should not contain sensitive information. + */ + 'message': string; + /** + * Time the error was encountered. + */ + 'time': Date; } /** @@ -6499,7 +7469,7 @@ export class V1beta1APIServiceSpec { */ 'group': string; /** - * GroupPriorityMininum is the priority this group should have at least. Higher priority means that the group is prefered by clients over lower priority ones. Note that other versions of this group might specify even higher GroupPriorityMininum values such that the whole group gets a higher priority. The primary sort is based on GroupPriorityMinimum, ordered highest number to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) We'd recommend something like: *.k8s.io (except extensions) at 18000 and PaaSes (OpenShift, Deis) are recommended to be in the 2000s + * GroupPriorityMininum is the priority this group should have at least. Higher priority means that the group is preferred by clients over lower priority ones. Note that other versions of this group might specify even higher GroupPriorityMininum values such that the whole group gets a higher priority. The primary sort is based on GroupPriorityMinimum, ordered highest number to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) We'd recommend something like: *.k8s.io (except extensions) at 18000 and PaaSes (OpenShift, Deis) are recommended to be in the 2000s */ 'groupPriorityMinimum': number; /** @@ -6509,7 +7479,7 @@ export class V1beta1APIServiceSpec { /** * Service is a reference to the service for this API server. It must communicate on port 443 If the Service is nil, that means the handling for the API groupversion is handled locally on this server. The call will simply delegate to the normal handler chain to be fulfilled. */ - 'service': V1beta1ServiceReference; + 'service': ApiregistrationV1beta1ServiceReference; /** * Version is the API version this server hosts. For example, \"v1\" */ @@ -6530,6 +7500,26 @@ export class V1beta1APIServiceStatus { 'conditions': Array; } +/** +* AggregationRule describes how to locate ClusterRoles to aggregate into the ClusterRole +*/ +export class V1beta1AggregationRule { + /** + * ClusterRoleSelectors holds a list of selectors which will be used to find ClusterRoles and create the rules. If any of the selectors match, then the ClusterRole's permissions will be added + */ + 'clusterRoleSelectors': Array; +} + +/** +* AllowedFlexVolume represents a single Flexvolume that is allowed to be used. +*/ +export class V1beta1AllowedFlexVolume { + /** + * Driver is the name of the Flexvolume driver. + */ + 'driver': string; +} + /** * defines the host volume conditions that will be enabled by a policy for pods to use. It requires the path prefix to be defined. */ @@ -6640,6 +7630,10 @@ export class V1beta1CertificateSigningRequestStatus { * ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. */ export class V1beta1ClusterRole { + /** + * AggregationRule is an optional field that describes how to build the Rules for this ClusterRole. If AggregationRule is set, then the Rules are controller managed and direct changes to Rules will be stomped by the controller. + */ + 'aggregationRule': V1beta1AggregationRule; /** * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources */ @@ -6829,7 +7823,7 @@ export class V1beta1CronJobList { */ export class V1beta1CronJobSpec { /** - * Specifies how to treat concurrent executions of a Job. Defaults to Allow. + * Specifies how to treat concurrent executions of a Job. Valid values are: - \"Allow\" (default): allows CronJobs to run concurrently; - \"Forbid\": forbids concurrent runs, skipping next run if previous run hasn't finished yet; - \"Replace\": cancels currently running job and replaces it with a new one */ 'concurrencyPolicy': string; /** @@ -6983,7 +7977,7 @@ export class V1beta1CustomResourceDefinitionSpec { */ 'scope': string; /** - * Validation describes the validation methods for CustomResources This field is alpha-level and should only be sent to servers that enable the CustomResourceValidation feature. + * Validation describes the validation methods for CustomResources */ 'validation': V1beta1CustomResourceValidation; /** @@ -7042,6 +8036,32 @@ export class V1beta1DaemonSet { 'status': V1beta1DaemonSetStatus; } +/** +* DaemonSetCondition describes the state of a DaemonSet at a certain point. +*/ +export class V1beta1DaemonSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of DaemonSet condition. + */ + 'type': string; +} + /** * DaemonSetList is a collection of daemon sets. */ @@ -7103,6 +8123,10 @@ export class V1beta1DaemonSetStatus { */ 'collisionCount': number; /** + * Represents the latest available observations of a DaemonSet's current state. + */ + 'conditions': Array; + /** * The number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ */ 'currentNumberScheduled': number; @@ -7147,6 +8171,117 @@ export class V1beta1DaemonSetUpdateStrategy { 'type': string; } +/** +* Event is a report of an event somewhere in the cluster. It generally denotes some state change in the system. +*/ +export class V1beta1Event { + /** + * What action was taken/failed regarding to the regarding object. + */ + 'action': string; + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Deprecated field assuring backward compatibility with core.v1 Event type + */ + 'deprecatedCount': number; + /** + * Deprecated field assuring backward compatibility with core.v1 Event type + */ + 'deprecatedFirstTimestamp': Date; + /** + * Deprecated field assuring backward compatibility with core.v1 Event type + */ + 'deprecatedLastTimestamp': Date; + /** + * Deprecated field assuring backward compatibility with core.v1 Event type + */ + 'deprecatedSource': V1EventSource; + /** + * Required. Time when this Event was first observed. + */ + 'eventTime': Date; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + 'metadata': V1ObjectMeta; + /** + * Optional. A human-readable description of the status of this operation. Maximal length of the note is 1kB, but libraries should be prepared to handle values up to 64kB. + */ + 'note': string; + /** + * Why the action was taken. + */ + 'reason': string; + /** + * The object this Event is about. In most cases it's an Object reporting controller implements. E.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object. + */ + 'regarding': V1ObjectReference; + /** + * Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object. + */ + 'related': V1ObjectReference; + /** + * Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. + */ + 'reportingController': string; + /** + * ID of the controller instance, e.g. `kubelet-xyzf`. + */ + 'reportingInstance': string; + /** + * Data about the Event series this event represents or nil if it's a singleton Event. + */ + 'series': V1beta1EventSeries; + /** + * Type of this event (Normal, Warning), new types could be added in the future. + */ + 'type': string; +} + +/** +* EventList is a list of Event objects. +*/ +export class V1beta1EventList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Items is a list of schema objects. + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + */ + 'metadata': V1ListMeta; +} + +/** +* EventSeries contain information on series of events, i.e. thing that was/is happening continously for some time. +*/ +export class V1beta1EventSeries { + /** + * Number of occurrences in this series up to the last heartbeat time + */ + 'count': number; + /** + * Time when last Event from the series was seen before last heartbeat. + */ + 'lastObservedTime': Date; + /** + * Information whether this series is ongoing or finished. + */ + 'state': string; +} + /** * Eviction evicts a pod from its node subject to certain policies and safety constraints. This is a subresource of Pod. A request to cause such an eviction is created by POSTing to .../pods//evictions. */ @@ -7244,7 +8379,7 @@ export class V1beta1IDRange { } /** -* IPBlock describes a particular CIDR (Ex. \"192.168.1.1/24\") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule. +* DEPRECATED 1.9 - This group version of IPBlock is deprecated by networking/v1/IPBlock. IPBlock describes a particular CIDR (Ex. \"192.168.1.1/24\") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule. */ export class V1beta1IPBlock { /** @@ -7483,7 +8618,51 @@ export class V1beta1LocalSubjectAccessReview { } /** -* NetworkPolicy describes what network traffic is allowed for a set of Pods +* MutatingWebhookConfiguration describes the configuration of and admission webhook that accept or reject and may change the object. +*/ +export class V1beta1MutatingWebhookConfiguration { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + */ + 'metadata': V1ObjectMeta; + /** + * Webhooks is a list of webhooks and the affected resources and operations. + */ + 'webhooks': Array; +} + +/** +* MutatingWebhookConfigurationList is a list of MutatingWebhookConfiguration. +*/ +export class V1beta1MutatingWebhookConfigurationList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * List of MutatingWebhookConfiguration. + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'metadata': V1ListMeta; +} + +/** +* DEPRECATED 1.9 - This group version of NetworkPolicy is deprecated by networking/v1/NetworkPolicy. NetworkPolicy describes what network traffic is allowed for a set of Pods */ export class V1beta1NetworkPolicy { /** @@ -7505,7 +8684,7 @@ export class V1beta1NetworkPolicy { } /** -* NetworkPolicyEgressRule describes a particular set of traffic that is allowed out of pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and to. This type is beta-level in 1.8 +* DEPRECATED 1.9 - This group version of NetworkPolicyEgressRule is deprecated by networking/v1/NetworkPolicyEgressRule. NetworkPolicyEgressRule describes a particular set of traffic that is allowed out of pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and to. This type is beta-level in 1.8 */ export class V1beta1NetworkPolicyEgressRule { /** @@ -7519,7 +8698,7 @@ export class V1beta1NetworkPolicyEgressRule { } /** -* This NetworkPolicyIngressRule matches traffic if and only if the traffic matches both ports AND from. +* DEPRECATED 1.9 - This group version of NetworkPolicyIngressRule is deprecated by networking/v1/NetworkPolicyIngressRule. This NetworkPolicyIngressRule matches traffic if and only if the traffic matches both ports AND from. */ export class V1beta1NetworkPolicyIngressRule { /** @@ -7533,7 +8712,7 @@ export class V1beta1NetworkPolicyIngressRule { } /** -* Network Policy List is a list of NetworkPolicy objects. +* DEPRECATED 1.9 - This group version of NetworkPolicyList is deprecated by networking/v1/NetworkPolicyList. Network Policy List is a list of NetworkPolicy objects. */ export class V1beta1NetworkPolicyList { /** @@ -7554,6 +8733,9 @@ export class V1beta1NetworkPolicyList { 'metadata': V1ListMeta; } +/** +* DEPRECATED 1.9 - This group version of NetworkPolicyPeer is deprecated by networking/v1/NetworkPolicyPeer. +*/ export class V1beta1NetworkPolicyPeer { /** * IPBlock defines policy on a particular IPBlock @@ -7569,6 +8751,9 @@ export class V1beta1NetworkPolicyPeer { 'podSelector': V1LabelSelector; } +/** +* DEPRECATED 1.9 - This group version of NetworkPolicyPort is deprecated by networking/v1/NetworkPolicyPort. +*/ export class V1beta1NetworkPolicyPort { /** * If specified, the port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers. If present, only traffic on the specified protocol AND port will be matched. @@ -7580,6 +8765,9 @@ export class V1beta1NetworkPolicyPort { 'protocol': string; } +/** +* DEPRECATED 1.9 - This group version of NetworkPolicySpec is deprecated by networking/v1/NetworkPolicySpec. +*/ export class V1beta1NetworkPolicySpec { /** * List of egress rules to be applied to the selected pods. Outgoing traffic is allowed if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic matches at least one egress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy limits all outgoing traffic (and serves solely to ensure that the pods it selects are isolated by default). This field is beta-level in 1.8 @@ -7771,11 +8959,15 @@ export class V1beta1PodSecurityPolicySpec { */ 'allowedCapabilities': Array; /** + * AllowedFlexVolumes is a whitelist of allowed Flexvolumes. Empty or nil indicates that all Flexvolumes may be used. This parameter is effective only when the usage of the Flexvolumes is allowed in the \"Volumes\" field. + */ + 'allowedFlexVolumes': Array; + /** * is a white list of allowed host paths. Empty indicates that all host paths may be used. */ 'allowedHostPaths': Array; /** - * DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities. + * DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capability in both DefaultAddCapabilities and RequiredDropCapabilities. Capabilities added here are implicitly allowed, and need not be included in the AllowedCapabilities list. */ 'defaultAddCapabilities': Array; /** @@ -7849,7 +9041,7 @@ export class V1beta1PolicyRule { */ 'resourceNames': Array; /** - * Resources is a list of resources this rule applies to. ResourceAll represents all resources. + * Resources is a list of resources this rule applies to. '*' represents all resources in the specified apiGroups. '*_/foo' represents the subresource 'foo' for all resources in the specified apiGroups. */ 'resources': Array; /** @@ -7859,7 +9051,7 @@ export class V1beta1PolicyRule { } /** -* DEPRECATED - This group version of ReplicaSet is deprecated by apps/v1beta2/ReplicaSet. See the release notes for more information. ReplicaSet represents the configuration of a ReplicaSet. +* DEPRECATED - This group version of ReplicaSet is deprecated by apps/v1beta2/ReplicaSet. See the release notes for more information. ReplicaSet ensures that a specified number of pod replicas are running at any given time. */ export class V1beta1ReplicaSet { /** @@ -8031,7 +9223,7 @@ export class V1beta1ResourceRule { */ 'resourceNames': Array; /** - * Resources is a list of resources this rule applies to. ResourceAll represents all resources. \"*\" means all. + * Resources is a list of resources this rule applies to. \"*\" means all in the specified apiGroups. \"*_/foo\" represents the subresource 'foo' for all resources in the specified apiGroups. */ 'resources': Array; /** @@ -8170,6 +9362,28 @@ export class V1beta1RollingUpdateStatefulSetStrategy { 'partition': number; } +/** +* RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid. +*/ +export class V1beta1RuleWithOperations { + /** + * APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required. + */ + 'apiGroups': Array; + /** + * APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required. + */ + 'apiVersions': Array; + /** + * Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required. + */ + 'operations': Array; + /** + * Resources is a list of resources this rule applies to. For example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/_*' means all subresources of pods. '*_/scale' means all scale subresources. '*_/_*' means all resources and their subresources. If wildcard is present, the validation rule will ensure resources do not overlap with each other. Depending on the enclosing object, subresources might not be allowed. Required. + */ + 'resources': Array; +} + /** * Run A sUser Strategy Options defines the strategy type and any options used to create the strategy. */ @@ -8193,7 +9407,7 @@ export class V1beta1SELinuxStrategyOptions { */ 'rule': string; /** - * seLinuxOptions required to run as; required for MustRunAs More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md + * seLinuxOptions required to run as; required for MustRunAs More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ */ 'seLinuxOptions': V1SELinuxOptions; } @@ -8265,20 +9479,6 @@ export class V1beta1SelfSubjectRulesReviewSpec { 'namespace': string; } -/** -* ServiceReference holds a reference to Service.legacy.k8s.io -*/ -export class V1beta1ServiceReference { - /** - * Name is the name of the service - */ - 'name': string; - /** - * Namespace is the namespace of the service - */ - 'namespace': string; -} - /** * DEPRECATED - This group version of StatefulSet is deprecated by apps/v1beta2/StatefulSet. See the release notes for more information. StatefulSet represents a set of pods with consistent identities. Identities are defined as: - Network: A single stable DNS and hostname. - Storage: As many VolumeClaims as requested. The StatefulSet guarantees that a given network identity will always map to the same storage identity. */ @@ -8302,6 +9502,32 @@ export class V1beta1StatefulSet { 'status': V1beta1StatefulSetStatus; } +/** +* StatefulSetCondition describes the state of a statefulset at a certain point. +*/ +export class V1beta1StatefulSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of statefulset condition. + */ + 'type': string; +} + /** * StatefulSetList is a collection of StatefulSets. */ @@ -8365,6 +9591,10 @@ export class V1beta1StatefulSetStatus { */ 'collisionCount': number; /** + * Represents the latest available observations of a statefulset's current state. + */ + 'conditions': Array; + /** * currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision. */ 'currentReplicas': number; @@ -8444,6 +9674,10 @@ export class V1beta1StorageClass { * Dynamically provisioned PersistentVolumes of this storage class are created with this reclaimPolicy. Defaults to Delete. */ 'reclaimPolicy': string; + /** + * VolumeBindingMode indicates how PersistentVolumeClaims should be provisioned and bound. When unset, VolumeBindingImmediate is used. This field is alpha-level and is only honored by servers that enable the VolumeScheduling feature. + */ + 'volumeBindingMode': string; } /** @@ -8548,10 +9782,14 @@ export class V1beta1SubjectAccessReviewSpec { */ export class V1beta1SubjectAccessReviewStatus { /** - * Allowed is required. True if the action would be allowed, false otherwise. + * Allowed is required. True if the action would be allowed, false otherwise. */ 'allowed': boolean; /** + * Denied is optional. True if the action would be denied, otherwise false. If both allowed is false and denied is false, then the authorizer has no opinion on whether to authorize the action. Denied may not be true if Allowed is true. + */ + 'denied': boolean; + /** * EvaluationError is an indication that some error occurred during the authorization check. It is entirely possible to get an error and be able to continue determine authorization status in spite of it. For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. */ 'evaluationError': string; @@ -8671,7 +9909,95 @@ export class V1beta1UserInfo { } /** -* ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers. +* ValidatingWebhookConfiguration describes the configuration of and admission webhook that accept or reject and object without changing it. +*/ +export class V1beta1ValidatingWebhookConfiguration { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + */ + 'metadata': V1ObjectMeta; + /** + * Webhooks is a list of webhooks and the affected resources and operations. + */ + 'webhooks': Array; +} + +/** +* ValidatingWebhookConfigurationList is a list of ValidatingWebhookConfiguration. +*/ +export class V1beta1ValidatingWebhookConfigurationList { + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + */ + 'apiVersion': string; + /** + * List of ValidatingWebhookConfiguration. + */ + 'items': Array; + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'kind': string; + /** + * Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + */ + 'metadata': V1ListMeta; +} + +/** +* Webhook describes an admission webhook and the resources and operations it applies to. +*/ +export class V1beta1Webhook { + /** + * ClientConfig defines how to communicate with the hook. Required + */ + 'clientConfig': V1beta1WebhookClientConfig; + /** + * FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore. + */ + 'failurePolicy': string; + /** + * The name of the admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required. + */ + 'name': string; + /** + * NamespaceSelector decides whether to run the webhook on an object based on whether the namespace for that object matches the selector. If the object itself is a namespace, the matching is performed on object.metadata.labels. If the object is another cluster scoped resource, it never skips the webhook. For example, to run the webhook on any objects whose namespace is not associated with \"runlevel\" of \"0\" or \"1\"; you will set the selector as follows: \"namespaceSelector\": { \"matchExpressions\": [ { \"key\": \"runlevel\", \"operator\": \"NotIn\", \"values\": [ \"0\", \"1\" ] } ] } If instead you want to only run the webhook on any objects whose namespace is associated with the \"environment\" of \"prod\" or \"staging\"; you will set the selector as follows: \"namespaceSelector\": { \"matchExpressions\": [ { \"key\": \"environment\", \"operator\": \"In\", \"values\": [ \"prod\", \"staging\" ] } ] } See https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ for more examples of label selectors. Default to the empty LabelSelector, which matches everything. + */ + 'namespaceSelector': V1LabelSelector; + /** + * Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule. + */ + 'rules': Array; +} + +/** +* WebhookClientConfig contains the information to make a TLS connection with the webhook +*/ +export class V1beta1WebhookClientConfig { + /** + * `caBundle` is a PEM encoded CA bundle which will be used to validate the webhook's server certificate. Required. + */ + 'caBundle': string; + /** + * `service` is a reference to the service for this webhook. Either `service` or `url` must be specified. If the webhook is running within the cluster, then you should use `service`. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. + */ + 'service': AdmissionregistrationV1beta1ServiceReference; + /** + * `url` gives the location of the webhook, in standard URL form (`[scheme://]host:port/path`). Exactly one of `url` or `service` must be specified. The `host` should not refer to a service running in the cluster; use the `service` field instead. The host might be resolved via external DNS in some apiservers (e.g., `kube-apiserver` cannot resolve in-cluster DNS as that would be a layering violation). `host` may also be an IP address. Please note that using `localhost` or `127.0.0.1` as a `host` is risky unless you take great care to run this webhook on all hosts which run an apiserver which might need to make calls to this webhook. Such installs are likely to be non-portable, i.e., not easy to turn up in a new cluster. The scheme must be \"https\"; the URL must begin with \"https://\". A path is optional, and if present may be any string permissible in a URL. You may use the path to pass an arbitrary string to the webhook, for example, a cluster identifier. Attempting to use a user or basic auth e.g. \"user:password@\" is not allowed. Fragments (\"#...\") and query parameters (\"?...\") are not allowed, either. + */ + 'url': string; +} + +/** +* DEPRECATED - This group version of ControllerRevision is deprecated by apps/v1/ControllerRevision. See the release notes for more information. ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers. */ export class V1beta2ControllerRevision { /** @@ -8719,7 +10045,7 @@ export class V1beta2ControllerRevisionList { } /** -* DaemonSet represents the configuration of a daemon set. +* DEPRECATED - This group version of DaemonSet is deprecated by apps/v1/DaemonSet. See the release notes for more information. DaemonSet represents the configuration of a daemon set. */ export class V1beta2DaemonSet { /** @@ -8744,6 +10070,32 @@ export class V1beta2DaemonSet { 'status': V1beta2DaemonSetStatus; } +/** +* DaemonSetCondition describes the state of a DaemonSet at a certain point. +*/ +export class V1beta2DaemonSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of DaemonSet condition. + */ + 'type': string; +} + /** * DaemonSetList is a collection of daemon sets. */ @@ -8779,7 +10131,7 @@ export class V1beta2DaemonSetSpec { */ 'revisionHistoryLimit': number; /** - * A label query over pods that are managed by the daemon set. Must match in order to be controlled. If empty, defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + * A label query over pods that are managed by the daemon set. Must match in order to be controlled. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors */ 'selector': V1LabelSelector; /** @@ -8801,6 +10153,10 @@ export class V1beta2DaemonSetStatus { */ 'collisionCount': number; /** + * Represents the latest available observations of a DaemonSet's current state. + */ + 'conditions': Array; + /** * The number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ */ 'currentNumberScheduled': number; @@ -8849,7 +10205,7 @@ export class V1beta2DaemonSetUpdateStrategy { } /** -* Deployment enables declarative updates for Pods and ReplicaSets. +* DEPRECATED - This group version of Deployment is deprecated by apps/v1/Deployment. See the release notes for more information. Deployment enables declarative updates for Pods and ReplicaSets. */ export class V1beta2Deployment { /** @@ -8951,7 +10307,7 @@ export class V1beta2DeploymentSpec { */ 'revisionHistoryLimit': number; /** - * Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. + * Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. It must match the pod template's labels. */ 'selector': V1LabelSelector; /** @@ -9017,7 +10373,7 @@ export class V1beta2DeploymentStrategy { } /** -* ReplicaSet represents the configuration of a ReplicaSet. +* DEPRECATED - This group version of ReplicaSet is deprecated by apps/v1/ReplicaSet. See the release notes for more information. ReplicaSet ensures that a specified number of pod replicas are running at any given time. */ export class V1beta2ReplicaSet { /** @@ -9103,7 +10459,7 @@ export class V1beta2ReplicaSetSpec { */ 'replicas': number; /** - * Selector is a label query over pods that should match the replica count. If the selector is empty, it is defaulted to the labels present on the pod template. Label keys and values that must match in order to be controlled by this replica set. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + * Selector is a label query over pods that should match the replica count. Label keys and values that must match in order to be controlled by this replica set. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors */ 'selector': V1LabelSelector; /** @@ -9231,7 +10587,7 @@ export class V1beta2ScaleStatus { } /** -* StatefulSet represents a set of pods with consistent identities. Identities are defined as: - Network: A single stable DNS and hostname. - Storage: As many VolumeClaims as requested. The StatefulSet guarantees that a given network identity will always map to the same storage identity. +* DEPRECATED - This group version of StatefulSet is deprecated by apps/v1/StatefulSet. See the release notes for more information. StatefulSet represents a set of pods with consistent identities. Identities are defined as: - Network: A single stable DNS and hostname. - Storage: As many VolumeClaims as requested. The StatefulSet guarantees that a given network identity will always map to the same storage identity. */ export class V1beta2StatefulSet { /** @@ -9253,6 +10609,32 @@ export class V1beta2StatefulSet { 'status': V1beta2StatefulSetStatus; } +/** +* StatefulSetCondition describes the state of a statefulset at a certain point. +*/ +export class V1beta2StatefulSetCondition { + /** + * Last time the condition transitioned from one status to another. + */ + 'lastTransitionTime': Date; + /** + * A human readable message indicating details about the transition. + */ + 'message': string; + /** + * The reason for the condition's last transition. + */ + 'reason': string; + /** + * Status of the condition, one of True, False, Unknown. + */ + 'status': string; + /** + * Type of statefulset condition. + */ + 'type': string; +} + /** * StatefulSetList is a collection of StatefulSets. */ @@ -9286,7 +10668,7 @@ export class V1beta2StatefulSetSpec { */ 'revisionHistoryLimit': number; /** - * selector is a label query over pods that should match the replica count. If empty, defaulted to labels on the pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + * selector is a label query over pods that should match the replica count. It must match the pod template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors */ 'selector': V1LabelSelector; /** @@ -9316,6 +10698,10 @@ export class V1beta2StatefulSetStatus { */ 'collisionCount': number; /** + * Represents the latest available observations of a statefulset's current state. + */ + 'conditions': Array; + /** * currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision. */ 'currentReplicas': number; @@ -9412,7 +10798,7 @@ export class V2alpha1CronJobList { */ export class V2alpha1CronJobSpec { /** - * Specifies how to treat concurrent executions of a Job. Defaults to Allow. + * Specifies how to treat concurrent executions of a Job. Valid values are: - \"Allow\" (default): allows CronJobs to run concurrently; - \"Forbid\": forbids concurrent runs, skipping next run if previous run hasn't finished yet; - \"Replace\": cancels currently running job and replaces it with a new one */ 'concurrencyPolicy': string; /** @@ -9962,64 +11348,6 @@ export class Admissionregistration_v1alpha1Api { public setApiKey(key: Admissionregistration_v1alpha1ApiApiKeys, value: string) { this.authentications[Admissionregistration_v1alpha1ApiApiKeys[key]].apiKey = value; } - /** - * create an ExternalAdmissionHookConfiguration - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public createExternalAdmissionHookConfiguration (body: V1alpha1ExternalAdmissionHookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createExternalAdmissionHookConfiguration.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'POST', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } /** * create an InitializerConfiguration * @param body @@ -10078,97 +11406,6 @@ export class Admissionregistration_v1alpha1Api { }); }); } - /** - * delete collection of ExternalAdmissionHookConfiguration - * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - */ - public deleteCollectionExternalAdmissionHookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'DELETE', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } /** * delete collection of InitializerConfiguration * @param pretty If 'true', then the output is pretty printed. @@ -10260,86 +11497,6 @@ export class Admissionregistration_v1alpha1Api { }); }); } - /** - * delete an ExternalAdmissionHookConfiguration - * @param name name of the ExternalAdmissionHookConfiguration - * @param body - * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. - */ - public deleteExternalAdmissionHookConfiguration (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}' - .replace('{' + 'name' + '}', String(name)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteExternalAdmissionHookConfiguration.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteExternalAdmissionHookConfiguration.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; - } - - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; - } - - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'DELETE', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } /** * delete an InitializerConfiguration * @param name name of the InitializerConfiguration @@ -10347,7 +11504,7 @@ export class Admissionregistration_v1alpha1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteInitializerConfiguration (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}' @@ -10466,97 +11623,6 @@ export class Admissionregistration_v1alpha1Api { }); }); } - /** - * list or watch objects of kind ExternalAdmissionHookConfiguration - * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - */ - public listExternalAdmissionHookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfigurationList; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'GET', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfigurationList; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } /** * list or watch objects of kind InitializerConfiguration * @param pretty If 'true', then the output is pretty printed. @@ -10648,71 +11714,6 @@ export class Admissionregistration_v1alpha1Api { }); }); } - /** - * partially update the specified ExternalAdmissionHookConfiguration - * @param name name of the ExternalAdmissionHookConfiguration - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public patchExternalAdmissionHookConfiguration (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}' - .replace('{' + 'name' + '}', String(name)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchExternalAdmissionHookConfiguration.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchExternalAdmissionHookConfiguration.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'PATCH', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } /** * partially update the specified InitializerConfiguration * @param name name of the InitializerConfiguration @@ -10779,14 +11780,14 @@ export class Admissionregistration_v1alpha1Api { }); } /** - * read the specified ExternalAdmissionHookConfiguration - * @param name name of the ExternalAdmissionHookConfiguration + * read the specified InitializerConfiguration + * @param name name of the InitializerConfiguration * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readExternalAdmissionHookConfiguration (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}' + public readInitializerConfiguration (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -10795,7 +11796,7 @@ export class Admissionregistration_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readExternalAdmissionHookConfiguration.'); + throw new Error('Required parameter name was null or undefined when calling readInitializerConfiguration.'); } if (pretty !== undefined) { @@ -10832,7 +11833,7 @@ export class Admissionregistration_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -10847,13 +11848,12 @@ export class Admissionregistration_v1alpha1Api { }); } /** - * read the specified InitializerConfiguration + * replace the specified InitializerConfiguration * @param name name of the InitializerConfiguration + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readInitializerConfiguration (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }> { + public replaceInitializerConfiguration (name: string, body: V1alpha1InitializerConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }> { const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -10863,30 +11863,28 @@ export class Admissionregistration_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readInitializerConfiguration.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter name was null or undefined when calling replaceInitializerConfiguration.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceInitializerConfiguration.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -10914,28 +11912,68 @@ export class Admissionregistration_v1alpha1Api { }); }); } +} +export enum Admissionregistration_v1beta1ApiApiKeys { + BearerToken, +} + +export class Admissionregistration_v1beta1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Admissionregistration_v1beta1ApiApiKeys, value: string) { + this.authentications[Admissionregistration_v1beta1ApiApiKeys[key]].apiKey = value; + } /** - * replace the specified ExternalAdmissionHookConfiguration - * @param name name of the ExternalAdmissionHookConfiguration + * create a MutatingWebhookConfiguration * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceExternalAdmissionHookConfiguration (name: string, body: V1alpha1ExternalAdmissionHookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}' - .replace('{' + 'name' + '}', String(name)); + public createMutatingWebhookConfiguration (body: V1beta1MutatingWebhookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceExternalAdmissionHookConfiguration.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceExternalAdmissionHookConfiguration.'); + throw new Error('Required parameter body was null or undefined when calling createMutatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -10945,7 +11983,7 @@ export class Admissionregistration_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -10965,7 +12003,7 @@ export class Admissionregistration_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ExternalAdmissionHookConfiguration; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -10980,27 +12018,20 @@ export class Admissionregistration_v1alpha1Api { }); } /** - * replace the specified InitializerConfiguration - * @param name name of the InitializerConfiguration + * create a ValidatingWebhookConfiguration * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceInitializerConfiguration (name: string, body: V1alpha1InitializerConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }> { - const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}' - .replace('{' + 'name' + '}', String(name)); + public createValidatingWebhookConfiguration (body: V1beta1ValidatingWebhookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceInitializerConfiguration.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceInitializerConfiguration.'); + throw new Error('Required parameter body was null or undefined when calling createValidatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11010,7 +12041,7 @@ export class Admissionregistration_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -11030,7 +12061,7 @@ export class Admissionregistration_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1InitializerConfiguration; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11044,67 +12075,65 @@ export class Admissionregistration_v1alpha1Api { }); }); } -} -export enum ApiextensionsApiApiKeys { - BearerToken, -} + /** + * delete collection of MutatingWebhookConfiguration + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionMutatingWebhookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; -export class ApiextensionsApi { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - } - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } - set basePath(basePath: string) { - this._basePath = basePath; - } + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } - get basePath() { - return this._basePath; - } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } + if (limit !== undefined) { + queryParameters['limit'] = limit; + } - public setApiKey(key: ApiextensionsApiApiKeys, value: string) { - this.authentications[ApiextensionsApiApiKeys[key]].apiKey = value; - } - /** - * get information of a group - */ - public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -11123,7 +12152,7 @@ export class ApiextensionsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11137,84 +12166,70 @@ export class ApiextensionsApi { }); }); } -} -export enum Apiextensions_v1beta1ApiApiKeys { - BearerToken, -} - -export class Apiextensions_v1beta1Api { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; + /** + * delete collection of ValidatingWebhookConfiguration + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionValidatingWebhookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - } - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } - set basePath(basePath: string) { - this._basePath = basePath; - } + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } - get basePath() { - return this._basePath; - } + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - public setApiKey(key: Apiextensions_v1beta1ApiApiKeys, value: string) { - this.authentications[Apiextensions_v1beta1ApiApiKeys[key]].apiKey = value; - } - /** - * create a CustomResourceDefinition - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public createCustomResourceDefinition (body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createCustomResourceDefinition.'); + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -11228,7 +12243,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11243,58 +12258,46 @@ export class Apiextensions_v1beta1Api { }); } /** - * delete collection of CustomResourceDefinition + * delete a MutatingWebhookConfiguration + * @param name name of the MutatingWebhookConfiguration + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionCustomResourceDefinition (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; + public deleteMutatingWebhookConfiguration (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteMutatingWebhookConfiguration.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteMutatingWebhookConfiguration.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -11306,6 +12309,7 @@ export class Apiextensions_v1beta1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -11334,16 +12338,16 @@ export class Apiextensions_v1beta1Api { }); } /** - * delete a CustomResourceDefinition - * @param name name of the CustomResourceDefinition + * delete a ValidatingWebhookConfiguration + * @param name name of the ValidatingWebhookConfiguration * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCustomResourceDefinition (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' + public deleteValidatingWebhookConfiguration (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -11352,12 +12356,12 @@ export class Apiextensions_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteCustomResourceDefinition.'); + throw new Error('Required parameter name was null or undefined when calling deleteValidatingWebhookConfiguration.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteCustomResourceDefinition.'); + throw new Error('Required parameter body was null or undefined when calling deleteValidatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11417,7 +12421,7 @@ export class Apiextensions_v1beta1Api { * get available resources */ public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/'; + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -11460,7 +12464,7 @@ export class Apiextensions_v1beta1Api { }); } /** - * list or watch objects of kind CustomResourceDefinition + * list or watch objects of kind MutatingWebhookConfiguration * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -11471,8 +12475,8 @@ export class Apiextensions_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listCustomResourceDefinition (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinitionList; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; + public listMutatingWebhookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfigurationList; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -11536,7 +12540,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinitionList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfigurationList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11551,27 +12555,118 @@ export class Apiextensions_v1beta1Api { }); } /** - * partially update the specified CustomResourceDefinition - * @param name name of the CustomResourceDefinition - * @param body + * list or watch objects of kind ValidatingWebhookConfiguration * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public patchCustomResourceDefinition (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' - .replace('{' + 'name' + '}', String(name)); + public listValidatingWebhookConfiguration (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfigurationList; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchCustomResourceDefinition.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'body' is not null or undefined + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfigurationList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified MutatingWebhookConfiguration + * @param name name of the MutatingWebhookConfiguration + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchMutatingWebhookConfiguration (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchMutatingWebhookConfiguration.'); + } + + // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchCustomResourceDefinition.'); + throw new Error('Required parameter body was null or undefined when calling patchMutatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11601,7 +12696,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11616,14 +12711,79 @@ export class Apiextensions_v1beta1Api { }); } /** - * read the specified CustomResourceDefinition - * @param name name of the CustomResourceDefinition + * partially update the specified ValidatingWebhookConfiguration + * @param name name of the ValidatingWebhookConfiguration + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchValidatingWebhookConfiguration (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchValidatingWebhookConfiguration.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchValidatingWebhookConfiguration.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified MutatingWebhookConfiguration + * @param name name of the MutatingWebhookConfiguration * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readCustomResourceDefinition (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' + public readMutatingWebhookConfiguration (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -11632,7 +12792,7 @@ export class Apiextensions_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readCustomResourceDefinition.'); + throw new Error('Required parameter name was null or undefined when calling readMutatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11669,7 +12829,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11684,13 +12844,81 @@ export class Apiextensions_v1beta1Api { }); } /** - * replace the specified CustomResourceDefinition - * @param name name of the CustomResourceDefinition + * read the specified ValidatingWebhookConfiguration + * @param name name of the ValidatingWebhookConfiguration + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readValidatingWebhookConfiguration (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readValidatingWebhookConfiguration.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified MutatingWebhookConfiguration + * @param name name of the MutatingWebhookConfiguration * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceCustomResourceDefinition (name: string, body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' + public replaceMutatingWebhookConfiguration (name: string, body: V1beta1MutatingWebhookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/mutatingwebhookconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -11699,12 +12927,12 @@ export class Apiextensions_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceCustomResourceDefinition.'); + throw new Error('Required parameter name was null or undefined when calling replaceMutatingWebhookConfiguration.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceCustomResourceDefinition.'); + throw new Error('Required parameter body was null or undefined when calling replaceMutatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11734,7 +12962,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1MutatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11749,13 +12977,13 @@ export class Apiextensions_v1beta1Api { }); } /** - * replace status of the specified CustomResourceDefinition - * @param name name of the CustomResourceDefinition + * replace the specified ValidatingWebhookConfiguration + * @param name name of the ValidatingWebhookConfiguration * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceCustomResourceDefinitionStatus (name: string, body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { - const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}/status' + public replaceValidatingWebhookConfiguration (name: string, body: V1beta1ValidatingWebhookConfiguration, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }> { + const localVarPath = this.basePath + '/apis/admissionregistration.k8s.io/v1beta1/validatingwebhookconfigurations/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -11764,12 +12992,12 @@ export class Apiextensions_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceCustomResourceDefinitionStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceValidatingWebhookConfiguration.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceCustomResourceDefinitionStatus.'); + throw new Error('Required parameter body was null or undefined when calling replaceValidatingWebhookConfiguration.'); } if (pretty !== undefined) { @@ -11799,7 +13027,7 @@ export class Apiextensions_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ValidatingWebhookConfiguration; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -11814,11 +13042,11 @@ export class Apiextensions_v1beta1Api { }); } } -export enum ApiregistrationApiApiKeys { +export enum ApiextensionsApiApiKeys { BearerToken, } -export class ApiregistrationApi { +export class ApiextensionsApi { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -11857,14 +13085,14 @@ export class ApiregistrationApi { this.authentications.default = auth; } - public setApiKey(key: ApiregistrationApiApiKeys, value: string) { - this.authentications[ApiregistrationApiApiKeys[key]].apiKey = value; + public setApiKey(key: ApiextensionsApiApiKeys, value: string) { + this.authentications[ApiextensionsApiApiKeys[key]].apiKey = value; } /** * get information of a group */ public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/'; + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -11907,11 +13135,11 @@ export class ApiregistrationApi { }); } } -export enum Apiregistration_v1beta1ApiApiKeys { +export enum Apiextensions_v1beta1ApiApiKeys { BearerToken, } -export class Apiregistration_v1beta1Api { +export class Apiextensions_v1beta1Api { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -11950,16 +13178,16 @@ export class Apiregistration_v1beta1Api { this.authentications.default = auth; } - public setApiKey(key: Apiregistration_v1beta1ApiApiKeys, value: string) { - this.authentications[Apiregistration_v1beta1ApiApiKeys[key]].apiKey = value; + public setApiKey(key: Apiextensions_v1beta1ApiApiKeys, value: string) { + this.authentications[Apiextensions_v1beta1ApiApiKeys[key]].apiKey = value; } /** - * create an APIService + * create a CustomResourceDefinition * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createAPIService (body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; + public createCustomResourceDefinition (body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -11967,7 +13195,7 @@ export class Apiregistration_v1beta1Api { // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createAPIService.'); + throw new Error('Required parameter body was null or undefined when calling createCustomResourceDefinition.'); } if (pretty !== undefined) { @@ -11997,7 +13225,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12012,46 +13240,58 @@ export class Apiregistration_v1beta1Api { }); } /** - * delete an APIService - * @param name name of the APIService - * @param body + * delete collection of CustomResourceDefinition * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteAPIService (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteCollectionCustomResourceDefinition (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteAPIService.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteAPIService.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; @@ -12063,7 +13303,6 @@ export class Apiregistration_v1beta1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -12092,58 +13331,46 @@ export class Apiregistration_v1beta1Api { }); } /** - * delete collection of APIService + * delete a CustomResourceDefinition + * @param name name of the CustomResourceDefinition + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionAPIService (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; + public deleteCustomResourceDefinition (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteCustomResourceDefinition.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteCustomResourceDefinition.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -12155,6 +13382,7 @@ export class Apiregistration_v1beta1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -12186,7 +13414,7 @@ export class Apiregistration_v1beta1Api { * get available resources */ public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/'; + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -12229,7 +13457,7 @@ export class Apiregistration_v1beta1Api { }); } /** - * list or watch objects of kind APIService + * list or watch objects of kind CustomResourceDefinition * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -12240,8 +13468,8 @@ export class Apiregistration_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listAPIService (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1APIServiceList; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; + public listCustomResourceDefinition (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinitionList; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -12305,7 +13533,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIServiceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinitionList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12320,13 +13548,13 @@ export class Apiregistration_v1beta1Api { }); } /** - * partially update the specified APIService - * @param name name of the APIService + * partially update the specified CustomResourceDefinition + * @param name name of the CustomResourceDefinition * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchAPIService (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + public patchCustomResourceDefinition (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -12335,12 +13563,12 @@ export class Apiregistration_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchAPIService.'); + throw new Error('Required parameter name was null or undefined when calling patchCustomResourceDefinition.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchAPIService.'); + throw new Error('Required parameter body was null or undefined when calling patchCustomResourceDefinition.'); } if (pretty !== undefined) { @@ -12370,7 +13598,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12385,14 +13613,14 @@ export class Apiregistration_v1beta1Api { }); } /** - * read the specified APIService - * @param name name of the APIService + * read the specified CustomResourceDefinition + * @param name name of the CustomResourceDefinition * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readAPIService (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + public readCustomResourceDefinition (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -12401,7 +13629,7 @@ export class Apiregistration_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readAPIService.'); + throw new Error('Required parameter name was null or undefined when calling readCustomResourceDefinition.'); } if (pretty !== undefined) { @@ -12438,7 +13666,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12453,13 +13681,13 @@ export class Apiregistration_v1beta1Api { }); } /** - * replace the specified APIService - * @param name name of the APIService + * replace the specified CustomResourceDefinition + * @param name name of the CustomResourceDefinition * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceAPIService (name: string, body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + public replaceCustomResourceDefinition (name: string, body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -12468,12 +13696,12 @@ export class Apiregistration_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceAPIService.'); + throw new Error('Required parameter name was null or undefined when calling replaceCustomResourceDefinition.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceAPIService.'); + throw new Error('Required parameter body was null or undefined when calling replaceCustomResourceDefinition.'); } if (pretty !== undefined) { @@ -12503,7 +13731,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12518,13 +13746,13 @@ export class Apiregistration_v1beta1Api { }); } /** - * replace status of the specified APIService - * @param name name of the APIService + * replace status of the specified CustomResourceDefinition + * @param name name of the CustomResourceDefinition * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceAPIServiceStatus (name: string, body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { - const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}/status' + public replaceCustomResourceDefinitionStatus (name: string, body: V1beta1CustomResourceDefinition, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }> { + const localVarPath = this.basePath + '/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/{name}/status' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -12533,12 +13761,12 @@ export class Apiregistration_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceAPIServiceStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceCustomResourceDefinitionStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceAPIServiceStatus.'); + throw new Error('Required parameter body was null or undefined when calling replaceCustomResourceDefinitionStatus.'); } if (pretty !== undefined) { @@ -12568,100 +13796,7 @@ export class Apiregistration_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } -} -export enum ApisApiApiKeys { - BearerToken, -} - -export class ApisApi { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; - - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } - } - } - - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } - - set basePath(basePath: string) { - this._basePath = basePath; - } - - get basePath() { - return this._basePath; - } - - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } - - public setApiKey(key: ApisApiApiKeys, value: string) { - this.authentications[ApisApiApiKeys[key]].apiKey = value; - } - /** - * get available API versions - */ - public getAPIVersions () : Promise<{ response: http.ClientResponse; body: V1APIGroupList; }> { - const localVarPath = this.basePath + '/apis/'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'GET', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1APIGroupList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1CustomResourceDefinition; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12676,11 +13811,11 @@ export class ApisApi { }); } } -export enum AppsApiApiKeys { +export enum ApiregistrationApiApiKeys { BearerToken, } -export class AppsApi { +export class ApiregistrationApi { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -12719,14 +13854,14 @@ export class AppsApi { this.authentications.default = auth; } - public setApiKey(key: AppsApiApiKeys, value: string) { - this.authentications[AppsApiApiKeys[key]].apiKey = value; + public setApiKey(key: ApiregistrationApiApiKeys, value: string) { + this.authentications[ApiregistrationApiApiKeys[key]].apiKey = value; } /** * get information of a group */ public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/apps/'; + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -12769,11 +13904,11 @@ export class AppsApi { }); } } -export enum Apps_v1beta1ApiApiKeys { +export enum Apiregistration_v1beta1ApiApiKeys { BearerToken, } -export class Apps_v1beta1Api { +export class Apiregistration_v1beta1Api { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -12812,31 +13947,24 @@ export class Apps_v1beta1Api { this.authentications.default = auth; } - public setApiKey(key: Apps_v1beta1ApiApiKeys, value: string) { - this.authentications[Apps_v1beta1ApiApiKeys[key]].apiKey = value; + public setApiKey(key: Apiregistration_v1beta1ApiApiKeys, value: string) { + this.authentications[Apiregistration_v1beta1ApiApiKeys[key]].apiKey = value; } /** - * create a ControllerRevision - * @param namespace object name and auth scope, such as for teams and projects + * create an APIService * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedControllerRevision (namespace: string, body: V1beta1ControllerRevision, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ControllerRevision; }> { - const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions' - .replace('{' + 'namespace' + '}', String(namespace)); + public createAPIService (body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedControllerRevision.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedControllerRevision.'); + throw new Error('Required parameter body was null or undefined when calling createAPIService.'); } if (pretty !== undefined) { @@ -12866,7 +13994,7 @@ export class Apps_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ControllerRevision; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12881,37 +14009,52 @@ export class Apps_v1beta1Api { }); } /** - * create a Deployment - * @param namespace object name and auth scope, such as for teams and projects + * delete an APIService + * @param name name of the APIService * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public createNamespacedDeployment (namespace: string, body: AppsV1beta1Deployment, pretty?: string) : Promise<{ response: http.ClientResponse; body: AppsV1beta1Deployment; }> { - const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/deployments' - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteAPIService (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDeployment.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteAPIService.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedDeployment.'); + throw new Error('Required parameter body was null or undefined when calling deleteAPIService.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -12931,7 +14074,7 @@ export class Apps_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: AppsV1beta1Deployment; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -12946,50 +14089,69 @@ export class Apps_v1beta1Api { }); } /** - * create rollback of a Deployment - * @param name name of the DeploymentRollback - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * delete collection of APIService * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedDeploymentRollback (name: string, namespace: string, body: AppsV1beta1DeploymentRollback, pretty?: string) : Promise<{ response: http.ClientResponse; body: AppsV1beta1DeploymentRollback; }> { - const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionAPIService (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling createNamespacedDeploymentRollback.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDeploymentRollback.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedDeploymentRollback.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -13003,7 +14165,7 @@ export class Apps_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: AppsV1beta1DeploymentRollback; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -13018,43 +14180,24 @@ export class Apps_v1beta1Api { }); } /** - * create a StatefulSet - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * get available resources */ - public createNamespacedStatefulSet (namespace: string, body: V1beta1StatefulSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1StatefulSet; }> { - const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/statefulsets' - .replace('{' + 'namespace' + '}', String(namespace)); + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedStatefulSet.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedStatefulSet.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -13068,7 +14211,7 @@ export class Apps_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1StatefulSet; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -13083,8 +14226,7 @@ export class Apps_v1beta1Api { }); } /** - * delete collection of ControllerRevision - * @param namespace object name and auth scope, such as for teams and projects + * list or watch objects of kind APIService * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -13095,19 +14237,5720 @@ export class Apps_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedControllerRevision (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions' - .replace('{' + 'namespace' + '}', String(namespace)); + public listAPIService (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1APIServiceList; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedControllerRevision.'); - } - + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1APIServiceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified APIService + * @param name name of the APIService + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchAPIService (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchAPIService.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchAPIService.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified APIService + * @param name name of the APIService + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readAPIService (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readAPIService.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified APIService + * @param name name of the APIService + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceAPIService (name: string, body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceAPIService.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceAPIService.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified APIService + * @param name name of the APIService + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceAPIServiceStatus (name: string, body: V1beta1APIService, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1APIService; }> { + const localVarPath = this.basePath + '/apis/apiregistration.k8s.io/v1beta1/apiservices/{name}/status' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceAPIServiceStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceAPIServiceStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1APIService; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum ApisApiApiKeys { + BearerToken, +} + +export class ApisApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: ApisApiApiKeys, value: string) { + this.authentications[ApisApiApiKeys[key]].apiKey = value; + } + /** + * get available API versions + */ + public getAPIVersions () : Promise<{ response: http.ClientResponse; body: V1APIGroupList; }> { + const localVarPath = this.basePath + '/apis/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIGroupList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum AppsApiApiKeys { + BearerToken, +} + +export class AppsApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: AppsApiApiKeys, value: string) { + this.authentications[AppsApiApiKeys[key]].apiKey = value; + } + /** + * get information of a group + */ + public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { + const localVarPath = this.basePath + '/apis/apps/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum Apps_v1ApiApiKeys { + BearerToken, +} + +export class Apps_v1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Apps_v1ApiApiKeys, value: string) { + this.authentications[Apps_v1ApiApiKeys[key]].apiKey = value; + } + /** + * create a ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedControllerRevision (namespace: string, body: V1ControllerRevision, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedControllerRevision.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedDaemonSet (namespace: string, body: V1DaemonSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDaemonSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedDeployment (namespace: string, body: V1Deployment, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDeployment.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedReplicaSet (namespace: string, body: V1ReplicaSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedReplicaSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedStatefulSet (namespace: string, body: V1StatefulSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedStatefulSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedControllerRevision (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedDaemonSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedDeployment (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedReplicaSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedStatefulSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a ControllerRevision + * @param name name of the ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteNamespacedControllerRevision (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedControllerRevision.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedControllerRevision.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteNamespacedDaemonSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedDaemonSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedDaemonSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteNamespacedDeployment (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedDeployment.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedDeployment.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteNamespacedReplicaSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedReplicaSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedReplicaSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteNamespacedStatefulSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedStatefulSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedStatefulSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * get available resources + */ + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ControllerRevision + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listControllerRevisionForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ControllerRevisionList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/controllerrevisions'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevisionList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind DaemonSet + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listDaemonSetForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1DaemonSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/daemonsets'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind Deployment + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listDeploymentForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1DeploymentList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/deployments'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DeploymentList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedControllerRevision (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ControllerRevisionList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevisionList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedDaemonSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1DaemonSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedDeployment (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1DeploymentList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DeploymentList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedReplicaSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicaSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedStatefulSet (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1StatefulSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ReplicaSet + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listReplicaSetForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicaSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/replicasets'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind StatefulSet + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listStatefulSetForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1StatefulSetList; }> { + const localVarPath = this.basePath + '/apis/apps/v1/statefulsets'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSetList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified ControllerRevision + * @param name name of the ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedControllerRevision (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedControllerRevision.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedControllerRevision.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedDaemonSet (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedDaemonSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedDaemonSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedDaemonSetStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedDaemonSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedDaemonSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedDaemonSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedDeployment (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedDeployment.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedDeployment.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update scale of the specified Deployment + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedDeploymentScale (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedDeploymentScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedDeploymentScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedDeploymentScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedDeploymentStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedDeploymentStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedDeploymentStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedDeploymentStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedReplicaSet (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicaSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicaSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update scale of the specified ReplicaSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedReplicaSetScale (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicaSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicaSetScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicaSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedReplicaSetStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicaSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicaSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicaSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedStatefulSet (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedStatefulSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedStatefulSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update scale of the specified StatefulSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedStatefulSetScale (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedStatefulSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedStatefulSetScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedStatefulSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedStatefulSetStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedStatefulSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedStatefulSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedStatefulSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified ControllerRevision + * @param name name of the ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedControllerRevision (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedControllerRevision.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedDaemonSet (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedDaemonSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedDaemonSetStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedDaemonSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedDaemonSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedDeployment (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedDeployment.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read scale of the specified Deployment + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedDeploymentScale (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedDeploymentScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedDeploymentScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedDeploymentStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedDeploymentStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedDeploymentStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedReplicaSet (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicaSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read scale of the specified ReplicaSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedReplicaSetScale (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicaSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicaSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedReplicaSetStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicaSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicaSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedStatefulSet (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedStatefulSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read scale of the specified StatefulSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedStatefulSetScale (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedStatefulSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedStatefulSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedStatefulSetStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedStatefulSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedStatefulSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified ControllerRevision + * @param name name of the ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedControllerRevision (name: string, namespace: string, body: V1ControllerRevision, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedControllerRevision.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedControllerRevision.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ControllerRevision; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedDaemonSet (name: string, namespace: string, body: V1DaemonSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedDaemonSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedDaemonSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedDaemonSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified DaemonSet + * @param name name of the DaemonSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedDaemonSetStatus (name: string, namespace: string, body: V1DaemonSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1DaemonSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedDaemonSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedDaemonSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedDaemonSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1DaemonSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedDeployment (name: string, namespace: string, body: V1Deployment, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedDeployment.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedDeployment.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace scale of the specified Deployment + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedDeploymentScale (name: string, namespace: string, body: V1Scale, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedDeploymentScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedDeploymentScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedDeploymentScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified Deployment + * @param name name of the Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedDeploymentStatus (name: string, namespace: string, body: V1Deployment, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedDeploymentStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedDeploymentStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedDeploymentStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedReplicaSet (name: string, namespace: string, body: V1ReplicaSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicaSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicaSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicaSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace scale of the specified ReplicaSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedReplicaSetScale (name: string, namespace: string, body: V1Scale, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicaSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicaSetScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicaSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified ReplicaSet + * @param name name of the ReplicaSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedReplicaSetStatus (name: string, namespace: string, body: V1ReplicaSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicaSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicaSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicaSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1ReplicaSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedStatefulSet (name: string, namespace: string, body: V1StatefulSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedStatefulSet.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedStatefulSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace scale of the specified StatefulSet + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedStatefulSetScale (name: string, namespace: string, body: V1Scale, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedStatefulSetScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedStatefulSetScale.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedStatefulSetScale.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified StatefulSet + * @param name name of the StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedStatefulSetStatus (name: string, namespace: string, body: V1StatefulSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedStatefulSetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedStatefulSetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedStatefulSetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum Apps_v1beta1ApiApiKeys { + BearerToken, +} + +export class Apps_v1beta1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Apps_v1beta1ApiApiKeys, value: string) { + this.authentications[Apps_v1beta1ApiApiKeys[key]].apiKey = value; + } + /** + * create a ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedControllerRevision (namespace: string, body: V1beta1ControllerRevision, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ControllerRevision; }> { + const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedControllerRevision.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedControllerRevision.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1ControllerRevision; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a Deployment + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedDeployment (namespace: string, body: AppsV1beta1Deployment, pretty?: string) : Promise<{ response: http.ClientResponse; body: AppsV1beta1Deployment; }> { + const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/deployments' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDeployment.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedDeployment.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: AppsV1beta1Deployment; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create rollback of a Deployment + * @param name name of the DeploymentRollback + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedDeploymentRollback (name: string, namespace: string, body: AppsV1beta1DeploymentRollback, pretty?: string) : Promise<{ response: http.ClientResponse; body: AppsV1beta1DeploymentRollback; }> { + const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling createNamespacedDeploymentRollback.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedDeploymentRollback.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedDeploymentRollback.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: AppsV1beta1DeploymentRollback; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * create a StatefulSet + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createNamespacedStatefulSet (namespace: string, body: V1beta1StatefulSet, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1StatefulSet; }> { + const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/statefulsets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedStatefulSet.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedStatefulSet.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'POST', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1StatefulSet; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete collection of ControllerRevision + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedControllerRevision (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedControllerRevision.'); + } + if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -13384,7 +20227,7 @@ export class Apps_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedControllerRevision (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}' @@ -13471,7 +20314,7 @@ export class Apps_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedDeployment (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}' @@ -13558,7 +20401,7 @@ export class Apps_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedStatefulSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}' @@ -16613,7 +23456,7 @@ export class Apps_v1beta2Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedControllerRevision (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta2/namespaces/{namespace}/controllerrevisions/{name}' @@ -16700,7 +23543,7 @@ export class Apps_v1beta2Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedDaemonSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta2/namespaces/{namespace}/daemonsets/{name}' @@ -16787,7 +23630,7 @@ export class Apps_v1beta2Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedDeployment (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta2/namespaces/{namespace}/deployments/{name}' @@ -16874,7 +23717,7 @@ export class Apps_v1beta2Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedReplicaSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta2/namespaces/{namespace}/replicasets/{name}' @@ -16961,7 +23804,7 @@ export class Apps_v1beta2Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedStatefulSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/apps/v1beta2/namespaces/{namespace}/statefulsets/{name}' @@ -22052,7 +28895,7 @@ export class Autoscaling_v1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedHorizontalPodAutoscaler (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}' @@ -23012,7 +29855,7 @@ export class Autoscaling_v2beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedHorizontalPodAutoscaler (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/autoscaling/v2beta1/namespaces/{namespace}/horizontalpodautoscalers/{name}' @@ -24065,7 +30908,7 @@ export class Batch_v1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedJob (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/batch/v1/namespaces/{namespace}/jobs/{name}' @@ -25025,7 +31868,7 @@ export class Batch_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedCronJob (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/batch/v1beta1/namespaces/{namespace}/cronjobs/{name}' @@ -25985,7 +32828,7 @@ export class Batch_v2alpha1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedCronJob (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/batch/v2alpha1/namespaces/{namespace}/cronjobs/{name}' @@ -26932,7 +33775,7 @@ export class Certificates_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteCertificateSigningRequest (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/certificates.k8s.io/v1beta1/certificatesigningrequests/{name}' @@ -28034,14 +34877,386 @@ export class Core_v1Api { }); } /** - * connect DELETE requests to proxy of Node - * @param name name of the Node + * connect DELETE requests to proxy of Node + * @param name name of the Node + * @param path path to the resource + * @param path2 Path is the URL path to use for the current proxy request to node. + */ + public connectDeleteNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'path' + '}', String(path)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectDeleteNodeProxyWithPath.'); + } + + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectDeleteNodeProxyWithPath.'); + } + + if (path2 !== undefined) { + queryParameters['path'] = path2; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to attach of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param container The container in which to execute the command. Defaults to only container if there is only one container in the pod. + * @param stderr Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true. + * @param stdin Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false. + * @param stdout Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true. + * @param tty TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false. + */ + public connectGetNamespacedPodAttach (name: string, namespace: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/attach' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodAttach.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodAttach.'); + } + + if (container !== undefined) { + queryParameters['container'] = container; + } + + if (stderr !== undefined) { + queryParameters['stderr'] = stderr; + } + + if (stdin !== undefined) { + queryParameters['stdin'] = stdin; + } + + if (stdout !== undefined) { + queryParameters['stdout'] = stdout; + } + + if (tty !== undefined) { + queryParameters['tty'] = tty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to exec of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param command Command is the remote command to execute. argv array. Not executed within a shell. + * @param container Container in which to execute the command. Defaults to only container if there is only one container in the pod. + * @param stderr Redirect the standard error stream of the pod for this call. Defaults to true. + * @param stdin Redirect the standard input stream of the pod for this call. Defaults to false. + * @param stdout Redirect the standard output stream of the pod for this call. Defaults to true. + * @param tty TTY if true indicates that a tty will be allocated for the exec call. Defaults to false. + */ + public connectGetNamespacedPodExec (name: string, namespace: string, command?: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/exec' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodExec.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodExec.'); + } + + if (command !== undefined) { + queryParameters['command'] = command; + } + + if (container !== undefined) { + queryParameters['container'] = container; + } + + if (stderr !== undefined) { + queryParameters['stderr'] = stderr; + } + + if (stdin !== undefined) { + queryParameters['stdin'] = stdin; + } + + if (stdout !== undefined) { + queryParameters['stdout'] = stdout; + } + + if (tty !== undefined) { + queryParameters['tty'] = tty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to portforward of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param ports List of ports to forward Required when using WebSockets + */ + public connectGetNamespacedPodPortforward (name: string, namespace: string, ports?: number) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/portforward' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodPortforward.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodPortforward.'); + } + + if (ports !== undefined) { + queryParameters['ports'] = ports; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to proxy of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param path Path is the URL path to use for the current proxy request to pod. + */ + public connectGetNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodProxy.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodProxy.'); + } + + if (path !== undefined) { + queryParameters['path'] = path; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to proxy of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to node. + * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectDeleteNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' + public connectGetNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)) .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -28050,12 +35265,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectDeleteNodeProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectDeleteNodeProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); } if (path2 !== undefined) { @@ -28065,7 +35285,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28099,17 +35319,13 @@ export class Core_v1Api { }); } /** - * connect GET requests to attach of Pod - * @param name name of the Pod + * connect GET requests to proxy of Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects - * @param container The container in which to execute the command. Defaults to only container if there is only one container in the pod. - * @param stderr Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true. - * @param stdin Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false. - * @param stdout Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true. - * @param tty TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false. + * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectGetNamespacedPodAttach (name: string, namespace: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/attach' + public connectGetNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -28119,32 +35335,16 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodAttach.'); + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedServiceProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodAttach.'); - } - - if (container !== undefined) { - queryParameters['container'] = container; - } - - if (stderr !== undefined) { - queryParameters['stderr'] = stderr; - } - - if (stdin !== undefined) { - queryParameters['stdin'] = stdin; - } - - if (stdout !== undefined) { - queryParameters['stdout'] = stdout; + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedServiceProxy.'); } - if (tty !== undefined) { - queryParameters['tty'] = tty; + if (path !== undefined) { + queryParameters['path'] = path; } let useFormData = false; @@ -28184,20 +35384,17 @@ export class Core_v1Api { }); } /** - * connect GET requests to exec of Pod - * @param name name of the Pod + * connect GET requests to proxy of Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects - * @param command Command is the remote command to execute. argv array. Not executed within a shell. - * @param container Container in which to execute the command. Defaults to only container if there is only one container in the pod. - * @param stderr Redirect the standard error stream of the pod for this call. Defaults to true. - * @param stdin Redirect the standard input stream of the pod for this call. Defaults to false. - * @param stdout Redirect the standard output stream of the pod for this call. Defaults to true. - * @param tty TTY if true indicates that a tty will be allocated for the exec call. Defaults to false. + * @param path path to the resource + * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectGetNamespacedPodExec (name: string, namespace: string, command?: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/exec' + public connectGetNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -28205,36 +35402,79 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodExec.'); + throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodExec.'); + throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); } - if (command !== undefined) { - queryParameters['command'] = command; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); } - if (container !== undefined) { - queryParameters['container'] = container; + if (path2 !== undefined) { + queryParameters['path'] = path2; } - if (stderr !== undefined) { - queryParameters['stderr'] = stderr; - } + let useFormData = false; - if (stdin !== undefined) { - queryParameters['stdin'] = stdin; + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect GET requests to proxy of Node + * @param name name of the Node + * @param path Path is the URL path to use for the current proxy request to node. + */ + public connectGetNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - if (stdout !== undefined) { - queryParameters['stdout'] = stdout; + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectGetNodeProxy.'); } - if (tty !== undefined) { - queryParameters['tty'] = tty; + if (path !== undefined) { + queryParameters['path'] = path; } let useFormData = false; @@ -28274,15 +35514,15 @@ export class Core_v1Api { }); } /** - * connect GET requests to portforward of Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - * @param ports List of ports to forward Required when using WebSockets + * connect GET requests to proxy of Node + * @param name name of the Node + * @param path path to the resource + * @param path2 Path is the URL path to use for the current proxy request to node. */ - public connectGetNamespacedPodPortforward (name: string, namespace: string, ports?: number) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/portforward' + public connectGetNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -28290,16 +35530,16 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodPortforward.'); + throw new Error('Required parameter name was null or undefined when calling connectGetNodeProxyWithPath.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodPortforward.'); + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectGetNodeProxyWithPath.'); } - if (ports !== undefined) { - queryParameters['ports'] = ports; + if (path2 !== undefined) { + queryParameters['path'] = path2; } let useFormData = false; @@ -28339,12 +35579,12 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Pod + * connect HEAD requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the URL path to use for the current proxy request to pod. */ - public connectGetNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -28355,12 +35595,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedPodProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedPodProxy.'); } if (path !== undefined) { @@ -28370,7 +35610,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28404,13 +35644,13 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Pod + * connect HEAD requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectGetNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -28422,17 +35662,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectGetNamespacedPodProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); } if (path2 !== undefined) { @@ -28442,7 +35682,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28476,12 +35716,12 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Service + * connect HEAD requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectGetNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -28492,12 +35732,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedServiceProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedServiceProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedServiceProxy.'); } if (path !== undefined) { @@ -28507,7 +35747,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28541,13 +35781,13 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Service + * connect HEAD requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectGetNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -28559,17 +35799,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectGetNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); } if (path2 !== undefined) { @@ -28579,7 +35819,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28613,11 +35853,11 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Node + * connect HEAD requests to proxy of Node * @param name name of the Node * @param path Path is the URL path to use for the current proxy request to node. */ - public connectGetNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -28627,7 +35867,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNodeProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNodeProxy.'); } if (path !== undefined) { @@ -28637,7 +35877,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28671,12 +35911,12 @@ export class Core_v1Api { }); } /** - * connect GET requests to proxy of Node + * connect HEAD requests to proxy of Node * @param name name of the Node * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to node. */ - public connectGetNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectHeadNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -28687,12 +35927,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectGetNodeProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectHeadNodeProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectGetNodeProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectHeadNodeProxyWithPath.'); } if (path2 !== undefined) { @@ -28702,7 +35942,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28736,12 +35976,12 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Pod + * connect OPTIONS requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the URL path to use for the current proxy request to pod. */ - public connectHeadNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -28752,12 +35992,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedPodProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedPodProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedPodProxy.'); } if (path !== undefined) { @@ -28767,7 +36007,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28801,13 +36041,13 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Pod + * connect OPTIONS requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectHeadNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -28819,17 +36059,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectHeadNamespacedPodProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); } if (path2 !== undefined) { @@ -28839,7 +36079,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28873,12 +36113,12 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Service + * connect OPTIONS requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectHeadNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -28889,12 +36129,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedServiceProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedServiceProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedServiceProxy.'); } if (path !== undefined) { @@ -28904,7 +36144,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -28938,13 +36178,13 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Service + * connect OPTIONS requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectHeadNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -28956,17 +36196,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectHeadNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); } if (path2 !== undefined) { @@ -28976,7 +36216,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29010,11 +36250,11 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Node + * connect OPTIONS requests to proxy of Node * @param name name of the Node * @param path Path is the URL path to use for the current proxy request to node. */ - public connectHeadNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -29024,7 +36264,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNodeProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNodeProxy.'); } if (path !== undefined) { @@ -29034,7 +36274,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29068,12 +36308,12 @@ export class Core_v1Api { }); } /** - * connect HEAD requests to proxy of Node + * connect OPTIONS requests to proxy of Node * @param name name of the Node * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to node. */ - public connectHeadNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectOptionsNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -29084,12 +36324,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectHeadNodeProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectOptionsNodeProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectHeadNodeProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectOptionsNodeProxyWithPath.'); } if (path2 !== undefined) { @@ -29099,7 +36339,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29133,12 +36373,12 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Pod + * connect PATCH requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the URL path to use for the current proxy request to pod. */ - public connectOptionsNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -29149,12 +36389,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedPodProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedPodProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedPodProxy.'); } if (path !== undefined) { @@ -29164,7 +36404,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29198,13 +36438,13 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Pod + * connect PATCH requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectOptionsNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -29216,17 +36456,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectOptionsNamespacedPodProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); } if (path2 !== undefined) { @@ -29236,7 +36476,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29270,12 +36510,12 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Service + * connect PATCH requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectOptionsNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -29286,12 +36526,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedServiceProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedServiceProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedServiceProxy.'); } if (path !== undefined) { @@ -29301,7 +36541,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29335,13 +36575,13 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Service + * connect PATCH requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectOptionsNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -29353,17 +36593,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectOptionsNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); } if (path2 !== undefined) { @@ -29373,7 +36613,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29407,11 +36647,11 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Node + * connect PATCH requests to proxy of Node * @param name name of the Node * @param path Path is the URL path to use for the current proxy request to node. */ - public connectOptionsNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -29421,7 +36661,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNodeProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNodeProxy.'); } if (path !== undefined) { @@ -29431,7 +36671,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29465,12 +36705,12 @@ export class Core_v1Api { }); } /** - * connect OPTIONS requests to proxy of Node + * connect PATCH requests to proxy of Node * @param name name of the Node * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to node. */ - public connectOptionsNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPatchNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -29481,12 +36721,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectOptionsNodeProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPatchNodeProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectOptionsNodeProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectPatchNodeProxyWithPath.'); } if (path2 !== undefined) { @@ -29496,7 +36736,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29530,13 +36770,17 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Pod + * connect POST requests to attach of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param path Path is the URL path to use for the current proxy request to pod. + * @param container The container in which to execute the command. Defaults to only container if there is only one container in the pod. + * @param stderr Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true. + * @param stdin Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false. + * @param stdout Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true. + * @param tty TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false. */ - public connectPatchNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' + public connectPostNamespacedPodAttach (name: string, namespace: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/attach' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -29546,22 +36790,38 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedPodProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodAttach.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodAttach.'); } - if (path !== undefined) { - queryParameters['path'] = path; + if (container !== undefined) { + queryParameters['container'] = container; + } + + if (stderr !== undefined) { + queryParameters['stderr'] = stderr; + } + + if (stdin !== undefined) { + queryParameters['stdin'] = stdin; + } + + if (stdout !== undefined) { + queryParameters['stdout'] = stdout; + } + + if (tty !== undefined) { + queryParameters['tty'] = tty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29595,17 +36855,20 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Pod + * connect POST requests to exec of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to pod. + * @param command Command is the remote command to execute. argv array. Not executed within a shell. + * @param container Container in which to execute the command. Defaults to only container if there is only one container in the pod. + * @param stderr Redirect the standard error stream of the pod for this call. Defaults to true. + * @param stdin Redirect the standard input stream of the pod for this call. Defaults to false. + * @param stdout Redirect the standard output stream of the pod for this call. Defaults to true. + * @param tty TTY if true indicates that a tty will be allocated for the exec call. Defaults to false. */ - public connectPatchNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' + public connectPostNamespacedPodExec (name: string, namespace: string, command?: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/exec' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -29613,27 +36876,42 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodExec.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodExec.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPatchNamespacedPodProxyWithPath.'); + if (command !== undefined) { + queryParameters['command'] = command; } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (container !== undefined) { + queryParameters['container'] = container; + } + + if (stderr !== undefined) { + queryParameters['stderr'] = stderr; + } + + if (stdin !== undefined) { + queryParameters['stdin'] = stdin; + } + + if (stdout !== undefined) { + queryParameters['stdout'] = stdout; + } + + if (tty !== undefined) { + queryParameters['tty'] = tty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29667,13 +36945,13 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Service - * @param name name of the Service + * connect POST requests to portforward of Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. + * @param ports List of ports to forward Required when using WebSockets */ - public connectPatchNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' + public connectPostNamespacedPodPortforward (name: string, namespace: string, ports?: number) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/portforward' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -29683,22 +36961,22 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedServiceProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodPortforward.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodPortforward.'); } - if (path !== undefined) { - queryParameters['path'] = path; + if (ports !== undefined) { + queryParameters['ports'] = ports; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29732,17 +37010,15 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Service - * @param name name of the Service + * connect POST requests to proxy of Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource - * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. + * @param path Path is the URL path to use for the current proxy request to pod. */ - public connectPatchNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' + public connectPostNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -29750,27 +37026,22 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); - } - - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPatchNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodProxy.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (path !== undefined) { + queryParameters['path'] = path; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29804,13 +37075,17 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Node - * @param name name of the Node - * @param path Path is the URL path to use for the current proxy request to node. + * connect POST requests to proxy of Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param path path to the resource + * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectPatchNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' - .replace('{' + 'name' + '}', String(name)); + public connectPostNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -29818,17 +37093,27 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNodeProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); } - if (path !== undefined) { - queryParameters['path'] = path; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); + } + + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); + } + + if (path2 !== undefined) { + queryParameters['path'] = path2; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29862,15 +37147,15 @@ export class Core_v1Api { }); } /** - * connect PATCH requests to proxy of Node - * @param name name of the Node - * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to node. + * connect POST requests to proxy of Service + * @param name name of the Service + * @param namespace object name and auth scope, such as for teams and projects + * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectPatchNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' + public connectPostNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -29878,22 +37163,22 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPatchNodeProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedServiceProxy.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPatchNodeProxyWithPath.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedServiceProxy.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (path !== undefined) { + queryParameters['path'] = path; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -29927,19 +37212,17 @@ export class Core_v1Api { }); } /** - * connect POST requests to attach of Pod - * @param name name of the Pod + * connect POST requests to proxy of Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects - * @param container The container in which to execute the command. Defaults to only container if there is only one container in the pod. - * @param stderr Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true. - * @param stdin Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false. - * @param stdout Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true. - * @param tty TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false. + * @param path path to the resource + * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectPostNamespacedPodAttach (name: string, namespace: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/attach' + public connectPostNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -29947,32 +37230,21 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodAttach.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodAttach.'); - } - - if (container !== undefined) { - queryParameters['container'] = container; - } - - if (stderr !== undefined) { - queryParameters['stderr'] = stderr; - } - - if (stdin !== undefined) { - queryParameters['stdin'] = stdin; + throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); } - if (stdout !== undefined) { - queryParameters['stdout'] = stdout; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); } - if (tty !== undefined) { - queryParameters['tty'] = tty; + if (path2 !== undefined) { + queryParameters['path'] = path2; } let useFormData = false; @@ -30012,20 +37284,13 @@ export class Core_v1Api { }); } /** - * connect POST requests to exec of Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - * @param command Command is the remote command to execute. argv array. Not executed within a shell. - * @param container Container in which to execute the command. Defaults to only container if there is only one container in the pod. - * @param stderr Redirect the standard error stream of the pod for this call. Defaults to true. - * @param stdin Redirect the standard input stream of the pod for this call. Defaults to false. - * @param stdout Redirect the standard output stream of the pod for this call. Defaults to true. - * @param tty TTY if true indicates that a tty will be allocated for the exec call. Defaults to false. + * connect POST requests to proxy of Node + * @param name name of the Node + * @param path Path is the URL path to use for the current proxy request to node. */ - public connectPostNamespacedPodExec (name: string, namespace: string, command?: string, container?: string, stderr?: boolean, stdin?: boolean, stdout?: boolean, tty?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/exec' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public connectPostNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -30033,36 +37298,11 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodExec.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodExec.'); - } - - if (command !== undefined) { - queryParameters['command'] = command; - } - - if (container !== undefined) { - queryParameters['container'] = container; - } - - if (stderr !== undefined) { - queryParameters['stderr'] = stderr; - } - - if (stdin !== undefined) { - queryParameters['stdin'] = stdin; - } - - if (stdout !== undefined) { - queryParameters['stdout'] = stdout; + throw new Error('Required parameter name was null or undefined when calling connectPostNodeProxy.'); } - if (tty !== undefined) { - queryParameters['tty'] = tty; + if (path !== undefined) { + queryParameters['path'] = path; } let useFormData = false; @@ -30102,15 +37342,15 @@ export class Core_v1Api { }); } /** - * connect POST requests to portforward of Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - * @param ports List of ports to forward Required when using WebSockets + * connect POST requests to proxy of Node + * @param name name of the Node + * @param path path to the resource + * @param path2 Path is the URL path to use for the current proxy request to node. */ - public connectPostNamespacedPodPortforward (name: string, namespace: string, ports?: number) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/portforward' + public connectPostNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -30118,16 +37358,16 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodPortforward.'); + throw new Error('Required parameter name was null or undefined when calling connectPostNodeProxyWithPath.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodPortforward.'); + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectPostNodeProxyWithPath.'); } - if (ports !== undefined) { - queryParameters['ports'] = ports; + if (path2 !== undefined) { + queryParameters['path'] = path2; } let useFormData = false; @@ -30167,12 +37407,12 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Pod + * connect PUT requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the URL path to use for the current proxy request to pod. */ - public connectPostNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPutNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -30183,12 +37423,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedPodProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedPodProxy.'); } if (path !== undefined) { @@ -30198,7 +37438,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -30232,13 +37472,13 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Pod + * connect PUT requests to proxy of Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the URL path to use for the current proxy request to pod. */ - public connectPostNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPutNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -30250,17 +37490,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPostNamespacedPodProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); } if (path2 !== undefined) { @@ -30270,7 +37510,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -30304,12 +37544,12 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Service + * connect PUT requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectPostNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPutNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -30320,12 +37560,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedServiceProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedServiceProxy.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedServiceProxy.'); } if (path !== undefined) { @@ -30335,7 +37575,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -30369,13 +37609,13 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Service + * connect PUT requests to proxy of Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. */ - public connectPostNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPutNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -30387,17 +37627,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPostNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter path was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); } if (path2 !== undefined) { @@ -30407,7 +37647,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -30441,11 +37681,11 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Node + * connect PUT requests to proxy of Node * @param name name of the Node * @param path Path is the URL path to use for the current proxy request to node. */ - public connectPostNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public connectPutNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -30455,7 +37695,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNodeProxy.'); + throw new Error('Required parameter name was null or undefined when calling connectPutNodeProxy.'); } if (path !== undefined) { @@ -30465,7 +37705,72 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * connect PUT requests to proxy of Node + * @param name name of the Node + * @param path path to the resource + * @param path2 Path is the URL path to use for the current proxy request to node. + */ + public connectPutNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'path' + '}', String(path)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling connectPutNodeProxyWithPath.'); + } + + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling connectPutNodeProxyWithPath.'); + } + + if (path2 !== undefined) { + queryParameters['path'] = path2; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -30499,32 +37804,24 @@ export class Core_v1Api { }); } /** - * connect POST requests to proxy of Node - * @param name name of the Node - * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to node. + * create a Namespace + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPostNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'path' + '}', String(path)); + public createNamespace (body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPostNodeProxyWithPath.'); - } - - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPostNodeProxyWithPath.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespace.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; @@ -30536,6 +37833,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30549,7 +37847,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30564,43 +37862,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Pod - * @param name name of the Pod + * create a Binding * @param namespace object name and auth scope, such as for teams and projects - * @param path Path is the URL path to use for the current proxy request to pod. + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNamespacedPodProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedBinding (namespace: string, body: V1Binding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Binding; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/bindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedPodProxy.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedPodProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedBinding.'); } - if (path !== undefined) { - queryParameters['path'] = path; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedBinding.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30614,7 +37912,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Binding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30629,50 +37927,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Pod - * @param name name of the Pod + * create a ConfigMap * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to pod. + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNamespacedPodProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + public createNamespacedConfigMap (namespace: string, body: V1ConfigMap, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedConfigMap.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPutNamespacedPodProxyWithPath.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedConfigMap.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30686,7 +37977,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30701,43 +37992,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Service - * @param name name of the Service + * create Endpoints * @param namespace object name and auth scope, such as for teams and projects - * @param path Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNamespacedServiceProxy (name: string, namespace: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedEndpoints (namespace: string, body: V1Endpoints, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedServiceProxy.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedServiceProxy.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedEndpoints.'); } - if (path !== undefined) { - queryParameters['path'] = path; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedEndpoints.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30751,7 +38042,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30766,50 +38057,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Service - * @param name name of the Service + * create an Event * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource - * @param path2 Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy. + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNamespacedServiceProxyWithPath (name: string, namespace: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + public createNamespacedEvent (namespace: string, body: V1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedEvent.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPutNamespacedServiceProxyWithPath.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedEvent.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30823,7 +38107,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30838,36 +38122,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Node - * @param name name of the Node - * @param path Path is the URL path to use for the current proxy request to node. + * create a LimitRange + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNodeProxy (name: string, path?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy' - .replace('{' + 'name' + '}', String(name)); + public createNamespacedLimitRange (namespace: string, body: V1LimitRange, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNodeProxy.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedLimitRange.'); } - if (path !== undefined) { - queryParameters['path'] = path; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedLimitRange.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30881,7 +38172,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30896,43 +38187,43 @@ export class Core_v1Api { }); } /** - * connect PUT requests to proxy of Node - * @param name name of the Node - * @param path path to the resource - * @param path2 Path is the URL path to use for the current proxy request to node. + * create a PersistentVolumeClaim + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public connectPutNodeProxyWithPath (name: string, path: string, path2?: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/proxy/{path}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'path' + '}', String(path)); + public createNamespacedPersistentVolumeClaim (namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling connectPutNodeProxyWithPath.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPersistentVolumeClaim.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling connectPutNodeProxyWithPath.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedPersistentVolumeClaim.'); } - if (path2 !== undefined) { - queryParameters['path'] = path2; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -30946,7 +38237,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -30961,20 +38252,27 @@ export class Core_v1Api { }); } /** - * create a Namespace + * create a Pod + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespace (body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces'; + public createNamespacedPod (namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPod.'); + } + // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespace.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedPod.'); } if (pretty !== undefined) { @@ -31004,7 +38302,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31019,27 +38317,34 @@ export class Core_v1Api { }); } /** - * create a Binding + * create binding of a Pod + * @param name name of the Binding * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedBinding (namespace: string, body: V1Binding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Binding; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/bindings' + public createNamespacedPodBinding (name: string, namespace: string, body: V1Binding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Binding; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/binding' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling createNamespacedPodBinding.'); + } + // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedBinding.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedPodBinding.'); } if (pretty !== undefined) { @@ -31084,27 +38389,34 @@ export class Core_v1Api { }); } /** - * create a ConfigMap + * create eviction of a Pod + * @param name name of the Eviction * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedConfigMap (namespace: string, body: V1ConfigMap, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' + public createNamespacedPodEviction (name: string, namespace: string, body: V1beta1Eviction, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Eviction; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/eviction' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling createNamespacedPodEviction.'); + } + // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodEviction.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedConfigMap.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedPodEviction.'); } if (pretty !== undefined) { @@ -31134,7 +38446,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Eviction; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31149,13 +38461,13 @@ export class Core_v1Api { }); } /** - * create Endpoints + * create a PodTemplate * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedEndpoints (namespace: string, body: V1Endpoints, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' + public createNamespacedPodTemplate (namespace: string, body: V1PodTemplate, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31164,12 +38476,12 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodTemplate.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedEndpoints.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedPodTemplate.'); } if (pretty !== undefined) { @@ -31199,7 +38511,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31214,13 +38526,13 @@ export class Core_v1Api { }); } /** - * create an Event + * create a ReplicationController * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedEvent (namespace: string, body: V1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' + public createNamespacedReplicationController (namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31229,12 +38541,12 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedReplicationController.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedEvent.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -31264,7 +38576,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31279,13 +38591,13 @@ export class Core_v1Api { }); } /** - * create a LimitRange + * create a ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedLimitRange (namespace: string, body: V1LimitRange, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' + public createNamespacedResourceQuota (namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31294,12 +38606,12 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedResourceQuota.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedLimitRange.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -31329,7 +38641,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31344,13 +38656,13 @@ export class Core_v1Api { }); } /** - * create a PersistentVolumeClaim + * create a Secret * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. - */ - public createNamespacedPersistentVolumeClaim (namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' + */ + public createNamespacedSecret (namespace: string, body: V1Secret, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31359,12 +38671,12 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedSecret.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedSecret.'); } if (pretty !== undefined) { @@ -31394,7 +38706,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31409,13 +38721,13 @@ export class Core_v1Api { }); } /** - * create a Pod + * create a Service * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedPod (namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' + public createNamespacedService (namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31424,12 +38736,12 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedService.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPod.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedService.'); } if (pretty !== undefined) { @@ -31459,7 +38771,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31474,34 +38786,27 @@ export class Core_v1Api { }); } /** - * create binding of a Pod - * @param name name of the Binding + * create a ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedPodBinding (name: string, namespace: string, body: V1Binding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Binding; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/binding' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedServiceAccount (namespace: string, body: V1ServiceAccount, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling createNamespacedPodBinding.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedServiceAccount.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPodBinding.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -31531,7 +38836,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Binding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31546,34 +38851,20 @@ export class Core_v1Api { }); } /** - * create eviction of a Pod - * @param name name of the Eviction - * @param namespace object name and auth scope, such as for teams and projects + * create a Node * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedPodEviction (name: string, namespace: string, body: V1beta1Eviction, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Eviction; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/eviction' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public createNode (body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling createNamespacedPodEviction.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodEviction.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPodEviction.'); + throw new Error('Required parameter body was null or undefined when calling createNode.'); } if (pretty !== undefined) { @@ -31603,7 +38894,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1Eviction; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31618,27 +38909,20 @@ export class Core_v1Api { }); } /** - * create a PodTemplate - * @param namespace object name and auth scope, such as for teams and projects + * create a PersistentVolume * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedPodTemplate (namespace: string, body: V1PodTemplate, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' - .replace('{' + 'namespace' + '}', String(namespace)); + public createPersistentVolume (body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodTemplate.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPodTemplate.'); + throw new Error('Required parameter body was null or undefined when calling createPersistentVolume.'); } if (pretty !== undefined) { @@ -31668,7 +38952,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31683,13 +38967,20 @@ export class Core_v1Api { }); } /** - * create a ReplicationController + * delete collection of ConfigMap * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedReplicationController (namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' + public deleteCollectionNamespacedConfigMap (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31698,28 +38989,54 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedReplicationController.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedReplicationController.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedConfigMap.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -31733,7 +39050,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31748,13 +39065,20 @@ export class Core_v1Api { }); } /** - * create a ResourceQuota + * delete collection of Endpoints * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedResourceQuota (namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' + public deleteCollectionNamespacedEndpoints (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31763,28 +39087,54 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedResourceQuota.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedResourceQuota.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedEndpoints.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -31798,7 +39148,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31813,13 +39163,20 @@ export class Core_v1Api { }); } /** - * create a Secret + * delete collection of Event * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedSecret (namespace: string, body: V1Secret, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' + public deleteCollectionNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31828,28 +39185,54 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedSecret.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedSecret.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedEvent.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -31863,7 +39246,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31878,13 +39261,20 @@ export class Core_v1Api { }); } /** - * create a Service + * delete collection of LimitRange * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedService (namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services' + public deleteCollectionNamespacedLimitRange (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31893,28 +39283,54 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedService.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedLimitRange.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -31928,7 +39344,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -31943,13 +39359,20 @@ export class Core_v1Api { }); } /** - * create a ServiceAccount + * delete collection of PersistentVolumeClaim * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedServiceAccount (namespace: string, body: V1ServiceAccount, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' + public deleteCollectionNamespacedPersistentVolumeClaim (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -31958,28 +39381,54 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedServiceAccount.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedServiceAccount.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPersistentVolumeClaim.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -31993,7 +39442,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -32008,36 +39457,76 @@ export class Core_v1Api { }); } /** - * create a Node - * @param body + * delete collection of Pod + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNode (body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes'; + public deleteCollectionNamespacedPod (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNode.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPod.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -32051,7 +39540,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -32066,36 +39555,76 @@ export class Core_v1Api { }); } /** - * create a PersistentVolume - * @param body + * delete collection of PodTemplate + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createPersistentVolume (body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes'; + public deleteCollectionNamespacedPodTemplate (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createPersistentVolume.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPodTemplate.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -32109,7 +39638,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -32124,7 +39653,7 @@ export class Core_v1Api { }); } /** - * delete collection of ConfigMap + * delete collection of ReplicationController * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -32136,8 +39665,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedConfigMap (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' + public deleteCollectionNamespacedReplicationController (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -32146,7 +39675,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -32222,7 +39751,7 @@ export class Core_v1Api { }); } /** - * delete collection of Endpoints + * delete collection of ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -32234,8 +39763,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedEndpoints (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' + public deleteCollectionNamespacedResourceQuota (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -32244,7 +39773,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -32320,7 +39849,7 @@ export class Core_v1Api { }); } /** - * delete collection of Event + * delete collection of Secret * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -32332,8 +39861,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' + public deleteCollectionNamespacedSecret (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -32342,7 +39871,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedSecret.'); } if (pretty !== undefined) { @@ -32418,7 +39947,7 @@ export class Core_v1Api { }); } /** - * delete collection of LimitRange + * delete collection of ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -32430,8 +39959,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedLimitRange (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' + public deleteCollectionNamespacedServiceAccount (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -32440,7 +39969,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -32516,8 +40045,7 @@ export class Core_v1Api { }); } /** - * delete collection of PersistentVolumeClaim - * @param namespace object name and auth scope, such as for teams and projects + * delete collection of Node * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -32528,19 +40056,13 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedPersistentVolumeClaim (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionNode (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/nodes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPersistentVolumeClaim.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -32614,8 +40136,7 @@ export class Core_v1Api { }); } /** - * delete collection of Pod - * @param namespace object name and auth scope, such as for teams and projects + * delete collection of PersistentVolume * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -32626,19 +40147,13 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedPod (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionPersistentVolume (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPod.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -32712,65 +40227,46 @@ export class Core_v1Api { }); } /** - * delete collection of PodTemplate - * @param namespace object name and auth scope, such as for teams and projects + * delete a Namespace + * @param name name of the Namespace + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNamespacedPodTemplate (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteNamespace (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPodTemplate.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespace.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespace.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -32782,6 +40278,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -32810,65 +40307,53 @@ export class Core_v1Api { }); } /** - * delete collection of ReplicationController + * delete a ConfigMap + * @param name name of the ConfigMap * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNamespacedReplicationController (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' + public deleteNamespacedConfigMap (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedReplicationController.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedConfigMap.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedConfigMap.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedConfigMap.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -32880,6 +40365,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -32908,65 +40394,53 @@ export class Core_v1Api { }); } /** - * delete collection of ResourceQuota + * delete Endpoints + * @param name name of the Endpoints * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNamespacedResourceQuota (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' + public deleteNamespacedEndpoints (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedResourceQuota.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedEndpoints.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedEndpoints.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedEndpoints.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -32978,6 +40452,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -33006,65 +40481,53 @@ export class Core_v1Api { }); } /** - * delete collection of Secret + * delete an Event + * @param name name of the Event * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNamespacedSecret (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' + public deleteNamespacedEvent (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedSecret.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedEvent.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedEvent.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedEvent.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -33076,6 +40539,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -33104,65 +40568,53 @@ export class Core_v1Api { }); } /** - * delete collection of ServiceAccount + * delete a LimitRange + * @param name name of the LimitRange * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNamespacedServiceAccount (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' + public deleteNamespacedLimitRange (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedServiceAccount.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedLimitRange.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedLimitRange.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedLimitRange.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -33174,6 +40626,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -33202,58 +40655,53 @@ export class Core_v1Api { }); } /** - * delete collection of Node + * delete a PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionNode (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/nodes'; + public deleteNamespacedPersistentVolumeClaim (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -33265,6 +40713,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -33293,58 +40742,53 @@ export class Core_v1Api { }); } /** - * delete collection of PersistentVolume + * delete a Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteCollectionPersistentVolume (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes'; + public deleteNamespacedPod (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPod.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPod.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPod.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; @@ -33356,6 +40800,7 @@ export class Core_v1Api { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -33384,17 +40829,19 @@ export class Core_v1Api { }); } /** - * delete a Namespace - * @param name name of the Namespace + * delete a PodTemplate + * @param name name of the PodTemplate + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespace (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedPodTemplate (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -33402,12 +40849,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespace.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPodTemplate.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPodTemplate.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespace.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPodTemplate.'); } if (pretty !== undefined) { @@ -33464,17 +40916,17 @@ export class Core_v1Api { }); } /** - * delete a ConfigMap - * @param name name of the ConfigMap + * delete a ReplicationController + * @param name name of the ReplicationController * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedConfigMap (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + public deleteNamespacedReplicationController (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -33484,17 +40936,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedConfigMap.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedReplicationController.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedReplicationController.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedConfigMap.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -33551,17 +41003,17 @@ export class Core_v1Api { }); } /** - * delete Endpoints - * @param name name of the Endpoints + * delete a ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedEndpoints (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + public deleteNamespacedResourceQuota (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -33571,17 +41023,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedEndpoints.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedResourceQuota.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedResourceQuota.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedEndpoints.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -33638,17 +41090,17 @@ export class Core_v1Api { }); } /** - * delete an Event - * @param name name of the Event + * delete a Secret + * @param name name of the Secret * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedEvent (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + public deleteNamespacedSecret (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -33658,17 +41110,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedEvent.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedSecret.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedSecret.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedEvent.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedSecret.'); } if (pretty !== undefined) { @@ -33725,17 +41177,82 @@ export class Core_v1Api { }); } /** - * delete a LimitRange - * @param name name of the LimitRange + * delete a Service + * @param name name of the Service + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public deleteNamespacedService (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedService.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedService.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * delete a ServiceAccount + * @param name name of the ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedLimitRange (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + public deleteNamespacedServiceAccount (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -33745,17 +41262,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedLimitRange.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedServiceAccount.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedServiceAccount.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedLimitRange.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -33812,19 +41329,17 @@ export class Core_v1Api { }); } /** - * delete a PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim - * @param namespace object name and auth scope, such as for teams and projects + * delete a Node + * @param name name of the Node * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedPersistentVolumeClaim (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteNode (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -33832,17 +41347,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter name was null or undefined when calling deleteNode.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter body was null or undefined when calling deleteNode.'); } if (pretty !== undefined) { @@ -33899,19 +41409,17 @@ export class Core_v1Api { }); } /** - * delete a Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects + * delete a PersistentVolume + * @param name name of the PersistentVolume * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedPod (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deletePersistentVolume (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -33919,17 +41427,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPod.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling deletePersistentVolume.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPod.'); + throw new Error('Required parameter body was null or undefined when calling deletePersistentVolume.'); } if (pretty !== undefined) { @@ -33986,65 +41489,115 @@ export class Core_v1Api { }); } /** - * delete a PodTemplate - * @param name name of the PodTemplate - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * get available resources + */ + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/api/v1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list objects of kind ComponentStatus + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedPodTemplate (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listComponentStatus (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ComponentStatusList; }> { + const localVarPath = this.basePath + '/api/v1/componentstatuses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPodTemplate.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPodTemplate.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPodTemplate.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34058,7 +41611,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ComponentStatusList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34073,65 +41626,69 @@ export class Core_v1Api { }); } /** - * delete a ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind ConfigMap + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedReplicationController (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listConfigMapForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }> { + const localVarPath = this.basePath + '/api/v1/configmaps'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedReplicationController.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedReplicationController.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedReplicationController.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34145,7 +41702,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34160,65 +41717,69 @@ export class Core_v1Api { }); } /** - * delete a ResourceQuota - * @param name name of the ResourceQuota - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Endpoints + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedResourceQuota (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listEndpointsForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EndpointsList; }> { + const localVarPath = this.basePath + '/api/v1/endpoints'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedResourceQuota.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedResourceQuota.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedResourceQuota.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34232,7 +41793,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1EndpointsList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34247,65 +41808,69 @@ export class Core_v1Api { }); } /** - * delete a Secret - * @param name name of the Secret - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Event + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedSecret (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listEventForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EventList; }> { + const localVarPath = this.basePath + '/api/v1/events'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedSecret.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedSecret.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedSecret.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34319,7 +41884,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1EventList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34334,38 +41899,64 @@ export class Core_v1Api { }); } /** - * delete a Service - * @param name name of the Service - * @param namespace object name and auth scope, such as for teams and projects + * list or watch objects of kind LimitRange + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedService (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listLimitRangeForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }> { + const localVarPath = this.basePath + '/api/v1/limitranges'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedService.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedService.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -34384,7 +41975,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34399,65 +41990,69 @@ export class Core_v1Api { }); } /** - * delete a ServiceAccount - * @param name name of the ServiceAccount - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Namespace * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedServiceAccount (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listNamespace (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1NamespaceList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedServiceAccount.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedServiceAccount.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedServiceAccount.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (limit !== undefined) { + queryParameters['limit'] = limit; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34471,7 +42066,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1NamespaceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34486,58 +42081,76 @@ export class Core_v1Api { }); } /** - * delete a Node - * @param name name of the Node - * @param body + * list or watch objects of kind ConfigMap + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNode (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}' - .replace('{' + 'name' + '}', String(name)); + public listNamespacedConfigMap (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNode.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNode.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedConfigMap.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -34551,7 +42164,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34566,94 +42179,66 @@ export class Core_v1Api { }); } /** - * delete a PersistentVolume - * @param name name of the PersistentVolume - * @param body + * list or watch objects of kind Endpoints + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deletePersistentVolume (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' - .replace('{' + 'name' + '}', String(name)); + public listNamespacedEndpoints (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EndpointsList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deletePersistentVolume.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deletePersistentVolume.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedEndpoints.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } - let useFormData = false; - - let requestOptions: request.Options = { - method: 'DELETE', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - this.authentications.BearerToken.applyToRequest(requestOptions); + if (limit !== undefined) { + queryParameters['limit'] = limit; + } - this.authentications.default.applyToRequest(requestOptions); + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * get available resources - */ - public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/api/v1/'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (watch !== undefined) { + queryParameters['watch'] = watch; + } let useFormData = false; @@ -34677,7 +42262,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1EndpointsList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34692,24 +42277,35 @@ export class Core_v1Api { }); } /** - * list objects of kind ComponentStatus + * list or watch objects of kind Event + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listComponentStatus (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ComponentStatusList; }> { - const localVarPath = this.basePath + '/api/v1/componentstatuses'; + public listNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EventList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedEvent.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -34730,10 +42326,6 @@ export class Core_v1Api { queryParameters['limit'] = limit; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -34768,7 +42360,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ComponentStatusList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1EventList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34783,24 +42375,35 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ConfigMap + * list or watch objects of kind LimitRange + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listConfigMapForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }> { - const localVarPath = this.basePath + '/api/v1/configmaps'; + public listNamespacedLimitRange (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedLimitRange.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -34821,10 +42424,6 @@ export class Core_v1Api { queryParameters['limit'] = limit; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -34859,7 +42458,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34874,24 +42473,35 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Endpoints + * list or watch objects of kind PersistentVolumeClaim + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listEndpointsForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EndpointsList; }> { - const localVarPath = this.basePath + '/api/v1/endpoints'; + public listNamespacedPersistentVolumeClaim (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPersistentVolumeClaim.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -34912,10 +42522,6 @@ export class Core_v1Api { queryParameters['limit'] = limit; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -34950,7 +42556,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1EndpointsList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -34965,24 +42571,35 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Event + * list or watch objects of kind Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listEventForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EventList; }> { - const localVarPath = this.basePath + '/api/v1/events'; + public listNamespacedPod (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPod.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -35003,10 +42620,6 @@ export class Core_v1Api { queryParameters['limit'] = limit; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -35041,7 +42654,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1EventList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35056,24 +42669,35 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind LimitRange + * list or watch objects of kind PodTemplate + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listLimitRangeForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }> { - const localVarPath = this.basePath + '/api/v1/limitranges'; + public listNamespacedPodTemplate (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPodTemplate.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -35094,10 +42718,6 @@ export class Core_v1Api { queryParameters['limit'] = limit; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -35132,7 +42752,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35147,7 +42767,8 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Namespace + * list or watch objects of kind ReplicationController + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -35158,13 +42779,19 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespace (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1NamespaceList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces'; + public listNamespacedReplicationController (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedReplicationController.'); + } + if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -35223,7 +42850,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1NamespaceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35238,7 +42865,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ConfigMap + * list or watch objects of kind ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -35250,8 +42877,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedConfigMap (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps' + public listNamespacedResourceQuota (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -35260,7 +42887,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -35321,7 +42948,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMapList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35336,7 +42963,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Endpoints + * list or watch objects of kind Secret * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -35348,8 +42975,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedEndpoints (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EndpointsList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints' + public listNamespacedSecret (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1SecretList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -35358,7 +42985,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedSecret.'); } if (pretty !== undefined) { @@ -35419,7 +43046,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1EndpointsList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1SecretList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35434,7 +43061,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Event + * list or watch objects of kind Service * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -35446,8 +43073,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1EventList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events' + public listNamespacedService (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -35456,7 +43083,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedService.'); } if (pretty !== undefined) { @@ -35517,7 +43144,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1EventList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35532,7 +43159,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind LimitRange + * list or watch objects of kind ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -35544,8 +43171,8 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedLimitRange (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges' + public listNamespacedServiceAccount (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -35554,7 +43181,7 @@ export class Core_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -35615,7 +43242,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRangeList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35630,8 +43257,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind PersistentVolumeClaim - * @param namespace object name and auth scope, such as for teams and projects + * list or watch objects of kind Node * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -35642,19 +43268,13 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedPersistentVolumeClaim (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims' - .replace('{' + 'namespace' + '}', String(namespace)); + public listNode (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1NodeList; }> { + const localVarPath = this.basePath + '/api/v1/nodes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPersistentVolumeClaim.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -35713,7 +43333,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1NodeList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35728,8 +43348,7 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Pod - * @param namespace object name and auth scope, such as for teams and projects + * list or watch objects of kind PersistentVolume * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -35740,19 +43359,13 @@ export class Core_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedPod (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods' - .replace('{' + 'namespace' + '}', String(namespace)); + public listPersistentVolume (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeList; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPod.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -35811,7 +43424,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35826,35 +43439,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind PodTemplate - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind PersistentVolumeClaim * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedPodTemplate (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates' - .replace('{' + 'namespace' + '}', String(namespace)); + public listPersistentVolumeClaimForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumeclaims'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPodTemplate.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -35875,6 +43477,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -35909,7 +43515,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -35924,35 +43530,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ReplicationController - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind Pod * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedReplicationController (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers' - .replace('{' + 'namespace' + '}', String(namespace)); + public listPodForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodList; }> { + const localVarPath = this.basePath + '/api/v1/pods'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedReplicationController.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -35973,6 +43568,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36007,7 +43606,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36022,35 +43621,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ResourceQuota - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind PodTemplate * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedResourceQuota (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas' - .replace('{' + 'namespace' + '}', String(namespace)); + public listPodTemplateForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }> { + const localVarPath = this.basePath + '/api/v1/podtemplates'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedResourceQuota.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36071,6 +43659,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36105,7 +43697,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36120,35 +43712,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Secret - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind ReplicationController * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedSecret (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1SecretList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets' - .replace('{' + 'namespace' + '}', String(namespace)); + public listReplicationControllerForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }> { + const localVarPath = this.basePath + '/api/v1/replicationcontrollers'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedSecret.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36169,6 +43750,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36203,7 +43788,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1SecretList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36218,35 +43803,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Service - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind ResourceQuota * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedService (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services' - .replace('{' + 'namespace' + '}', String(namespace)); + public listResourceQuotaForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }> { + const localVarPath = this.basePath + '/api/v1/resourcequotas'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedService.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36267,6 +43841,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36301,7 +43879,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36316,35 +43894,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ServiceAccount - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind Secret * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedServiceAccount (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts' - .replace('{' + 'namespace' + '}', String(namespace)); + public listSecretForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1SecretList; }> { + const localVarPath = this.basePath + '/api/v1/secrets'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedServiceAccount.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36365,6 +43932,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36399,7 +43970,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1SecretList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36414,28 +43985,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Node - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind ServiceAccount * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNode (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1NodeList; }> { - const localVarPath = this.basePath + '/api/v1/nodes'; + public listServiceAccountForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }> { + const localVarPath = this.basePath + '/api/v1/serviceaccounts'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36456,6 +44023,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36490,7 +44061,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1NodeList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36505,28 +44076,24 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind PersistentVolume - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind Service * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listPersistentVolume (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeList; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes'; + public listServiceForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceList; }> { + const localVarPath = this.basePath + '/api/v1/services'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -36547,6 +44114,10 @@ export class Core_v1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -36581,7 +44152,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36596,69 +44167,180 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind PersistentVolumeClaim - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified Namespace + * @param name name of the Namespace + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listPersistentVolumeClaimForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumeclaims'; + public patchNamespace (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespace.'); } - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespace.'); } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } } + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified Namespace + * @param name name of the Namespace + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespaceStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - if (limit !== undefined) { - queryParameters['limit'] = limit; + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespaceStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespaceStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update the specified ConfigMap + * @param name name of the ConfigMap + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNamespacedConfigMap (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedConfigMap.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedConfigMap.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedConfigMap.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -36672,7 +44354,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaimList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36687,69 +44369,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Pod - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified Endpoints + * @param name name of the Endpoints + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listPodForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodList; }> { - const localVarPath = this.basePath + '/api/v1/pods'; + public patchNamespacedEndpoints (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedEndpoints.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedEndpoints.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedEndpoints.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -36763,7 +44426,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36778,69 +44441,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind PodTemplate - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listPodTemplateForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }> { - const localVarPath = this.basePath + '/api/v1/podtemplates'; + public patchNamespacedEvent (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedEvent.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedEvent.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedEvent.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -36854,7 +44498,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplateList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36869,69 +44513,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ReplicationController - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified LimitRange + * @param name name of the LimitRange + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listReplicationControllerForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }> { - const localVarPath = this.basePath + '/api/v1/replicationcontrollers'; + public patchNamespacedLimitRange (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedLimitRange.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedLimitRange.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedLimitRange.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -36945,7 +44570,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationControllerList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -36960,69 +44585,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ResourceQuota - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listResourceQuotaForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }> { - const localVarPath = this.basePath + '/api/v1/resourcequotas'; + public patchNamespacedPersistentVolumeClaim (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -37036,7 +44642,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuotaList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37051,69 +44657,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Secret - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update status of the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listSecretForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1SecretList; }> { - const localVarPath = this.basePath + '/api/v1/secrets'; + public patchNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -37127,7 +44714,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1SecretList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37142,69 +44729,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind ServiceAccount - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listServiceAccountForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }> { - const localVarPath = this.basePath + '/api/v1/serviceaccounts'; + public patchNamespacedPod (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPod.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPod.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPod.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -37218,7 +44786,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccountList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37233,69 +44801,50 @@ export class Core_v1Api { }); } /** - * list or watch objects of kind Service - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * partially update status of the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listServiceForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceList; }> { - const localVarPath = this.basePath + '/api/v1/services'; + public patchNamespacedPodStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodStatus.'); } - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodStatus.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -37309,7 +44858,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37324,14 +44873,16 @@ export class Core_v1Api { }); } /** - * partially update the specified Namespace - * @param name name of the Namespace + * partially update the specified PodTemplate + * @param name name of the PodTemplate + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespace (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}' - .replace('{' + 'name' + '}', String(name)); + public patchNamespacedPodTemplate (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -37339,12 +44890,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespace.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodTemplate.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodTemplate.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespace.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodTemplate.'); } if (pretty !== undefined) { @@ -37374,7 +44930,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37389,14 +44945,16 @@ export class Core_v1Api { }); } /** - * partially update status of the specified Namespace - * @param name name of the Namespace + * partially update the specified ReplicationController + * @param name name of the ReplicationController + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespaceStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public patchNamespacedReplicationController (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -37404,12 +44962,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespaceStatus.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationController.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationController.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespaceStatus.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -37439,7 +45002,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37454,14 +45017,14 @@ export class Core_v1Api { }); } /** - * partially update the specified ConfigMap - * @param name name of the ConfigMap + * partially update scale of the specified ReplicationController + * @param name name of the Scale * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedConfigMap (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + public patchNamespacedReplicationControllerScale (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37471,17 +45034,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedConfigMap.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationControllerScale.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationControllerScale.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedConfigMap.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationControllerScale.'); } if (pretty !== undefined) { @@ -37511,7 +45074,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37526,14 +45089,14 @@ export class Core_v1Api { }); } /** - * partially update the specified Endpoints - * @param name name of the Endpoints + * partially update status of the specified ReplicationController + * @param name name of the ReplicationController * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedEndpoints (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + public patchNamespacedReplicationControllerStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37543,17 +45106,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedEndpoints.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationControllerStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationControllerStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedEndpoints.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationControllerStatus.'); } if (pretty !== undefined) { @@ -37583,7 +45146,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37598,14 +45161,14 @@ export class Core_v1Api { }); } /** - * partially update the specified Event - * @param name name of the Event + * partially update the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedEvent (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + public patchNamespacedResourceQuota (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37615,17 +45178,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedEvent.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedResourceQuota.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedResourceQuota.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedEvent.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -37655,7 +45218,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37670,14 +45233,14 @@ export class Core_v1Api { }); } /** - * partially update the specified LimitRange - * @param name name of the LimitRange + * partially update status of the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedLimitRange (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + public patchNamespacedResourceQuotaStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37687,17 +45250,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedLimitRange.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedResourceQuotaStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedResourceQuotaStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedLimitRange.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedResourceQuotaStatus.'); } if (pretty !== undefined) { @@ -37727,7 +45290,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37742,14 +45305,14 @@ export class Core_v1Api { }); } /** - * partially update the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * partially update the specified Secret + * @param name name of the Secret * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedPersistentVolumeClaim (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' + public patchNamespacedSecret (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37759,17 +45322,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedSecret.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedSecret.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedSecret.'); } if (pretty !== undefined) { @@ -37799,7 +45362,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37814,14 +45377,14 @@ export class Core_v1Api { }); } /** - * partially update status of the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * partially update the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' + public patchNamespacedService (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37831,17 +45394,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedService.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedService.'); } if (pretty !== undefined) { @@ -37871,7 +45434,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37886,14 +45449,14 @@ export class Core_v1Api { }); } /** - * partially update the specified Pod - * @param name name of the Pod + * partially update the specified ServiceAccount + * @param name name of the ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedPod (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' + public patchNamespacedServiceAccount (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37903,17 +45466,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedServiceAccount.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedServiceAccount.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPod.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -37943,7 +45506,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -37958,14 +45521,14 @@ export class Core_v1Api { }); } /** - * partially update status of the specified Pod - * @param name name of the Pod + * partially update status of the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedPodStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' + public patchNamespacedServiceStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -37975,17 +45538,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodStatus.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedServiceStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedServiceStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodStatus.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedServiceStatus.'); } if (pretty !== undefined) { @@ -38015,7 +45578,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38030,16 +45593,14 @@ export class Core_v1Api { }); } /** - * partially update the specified PodTemplate - * @param name name of the PodTemplate - * @param namespace object name and auth scope, such as for teams and projects + * partially update the specified Node + * @param name name of the Node * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedPodTemplate (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public patchNode (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38047,17 +45608,77 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodTemplate.'); + throw new Error('Required parameter name was null or undefined when calling patchNode.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodTemplate.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNode.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified Node + * @param name name of the Node + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchNodeStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNodeStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodTemplate.'); + throw new Error('Required parameter body was null or undefined when calling patchNodeStatus.'); } if (pretty !== undefined) { @@ -38087,7 +45708,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38102,16 +45723,14 @@ export class Core_v1Api { }); } /** - * partially update the specified ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects + * partially update the specified PersistentVolume + * @param name name of the PersistentVolume * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedReplicationController (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public patchPersistentVolume (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38119,17 +45738,77 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationController.'); + throw new Error('Required parameter name was null or undefined when calling patchPersistentVolume.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationController.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchPersistentVolume.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * partially update status of the specified PersistentVolume + * @param name name of the PersistentVolume + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public patchPersistentVolumeStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchPersistentVolumeStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationController.'); + throw new Error('Required parameter body was null or undefined when calling patchPersistentVolumeStatus.'); } if (pretty !== undefined) { @@ -38159,7 +45838,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38174,14 +45853,12 @@ export class Core_v1Api { }); } /** - * partially update scale of the specified ReplicationController - * @param name name of the Scale + * proxy DELETE requests to Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedReplicationControllerScale (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' + public proxyDELETENamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -38191,33 +45868,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationControllerScale.'); + throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationControllerScale.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationControllerScale.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38231,7 +45898,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38246,16 +45913,16 @@ export class Core_v1Api { }); } /** - * partially update status of the specified ReplicationController - * @param name name of the ReplicationController + * proxy DELETE requests to Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * @param path path to the resource */ - public patchNamespacedReplicationControllerStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' + public proxyDELETENamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38263,33 +45930,28 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedReplicationControllerStatus.'); + throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedReplicationControllerStatus.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedReplicationControllerStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedPodWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyDELETENamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38303,7 +45965,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38318,14 +45980,12 @@ export class Core_v1Api { }); } /** - * partially update the specified ResourceQuota - * @param name name of the ResourceQuota + * proxy DELETE requests to Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedResourceQuota (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' + public proxyDELETENamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -38335,33 +45995,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedResourceQuota.'); + throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedResourceQuota.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedResourceQuota.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38375,7 +46025,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38390,16 +46040,16 @@ export class Core_v1Api { }); } /** - * partially update status of the specified ResourceQuota - * @param name name of the ResourceQuota + * proxy DELETE requests to Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * @param path path to the resource */ - public patchNamespacedResourceQuotaStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' + public proxyDELETENamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38407,33 +46057,28 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedResourceQuotaStatus.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38447,7 +46092,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38462,16 +46107,12 @@ export class Core_v1Api { }); } /** - * partially update the specified Secret - * @param name name of the Secret - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy DELETE requests to Node + * @param name name of the Node */ - public patchNamespacedSecret (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public proxyDELETENode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38479,33 +46120,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedSecret.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedSecret.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedSecret.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter name was null or undefined when calling proxyDELETENode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38519,7 +46145,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38534,16 +46160,14 @@ export class Core_v1Api { }); } /** - * partially update the specified Service - * @param name name of the Service - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy DELETE requests to Node + * @param name name of the Node + * @param path path to the resource */ - public patchNamespacedService (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' + public proxyDELETENodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38551,33 +46175,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedService.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedService.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyDELETENodeWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyDELETENodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38591,7 +46205,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38606,14 +46220,12 @@ export class Core_v1Api { }); } /** - * partially update the specified ServiceAccount - * @param name name of the ServiceAccount + * proxy GET requests to Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedServiceAccount (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' + public proxyGETNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -38623,33 +46235,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedServiceAccount.'); + throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedServiceAccount.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedServiceAccount.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38663,7 +46265,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38678,16 +46280,16 @@ export class Core_v1Api { }); } /** - * partially update status of the specified Service - * @param name name of the Service + * proxy GET requests to Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * @param path path to the resource */ - public patchNamespacedServiceStatus (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' + public proxyGETNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38695,33 +46297,28 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedServiceStatus.'); + throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedServiceStatus.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedServiceStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedPodWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyGETNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38735,7 +46332,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38750,14 +46347,14 @@ export class Core_v1Api { }); } /** - * partially update the specified Node - * @param name name of the Node - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy GET requests to Service + * @param name name of the Service + * @param namespace object name and auth scope, such as for teams and projects */ - public patchNode (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}' - .replace('{' + 'name' + '}', String(name)); + public proxyGETNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38765,28 +46362,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNode.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNode.'); + throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedService.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38800,7 +46392,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38815,14 +46407,16 @@ export class Core_v1Api { }); } /** - * partially update status of the specified Node - * @param name name of the Node - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy GET requests to Service + * @param name name of the Service + * @param namespace object name and auth scope, such as for teams and projects + * @param path path to the resource */ - public patchNodeStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public proxyGETNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38830,28 +46424,28 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNodeStatus.'); + throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedServiceWithPath.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNodeStatus.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedServiceWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyGETNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38865,7 +46459,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38880,13 +46474,11 @@ export class Core_v1Api { }); } /** - * partially update the specified PersistentVolume - * @param name name of the PersistentVolume - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy GET requests to Node + * @param name name of the Node */ - public patchPersistentVolume (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + public proxyGETNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -38895,28 +46487,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchPersistentVolume.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchPersistentVolume.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter name was null or undefined when calling proxyGETNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38930,7 +46512,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -38945,14 +46527,14 @@ export class Core_v1Api { }); } /** - * partially update status of the specified PersistentVolume - * @param name name of the PersistentVolume - * @param body - * @param pretty If 'true', then the output is pretty printed. + * proxy GET requests to Node + * @param name name of the Node + * @param path path to the resource */ - public patchPersistentVolumeStatus (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public proxyGETNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'path' + '}', String(path)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -38960,28 +46542,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchPersistentVolumeStatus.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchPersistentVolumeStatus.'); + throw new Error('Required parameter name was null or undefined when calling proxyGETNodeWithPath.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'path' is not null or undefined + if (path === null || path === undefined) { + throw new Error('Required parameter path was null or undefined when calling proxyGETNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -38995,7 +46572,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -39010,11 +46587,11 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Pod + * proxy HEAD requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects */ - public proxyDELETENamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39025,18 +46602,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39070,12 +46647,12 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Pod + * proxy HEAD requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyDELETENamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39087,23 +46664,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedPodWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyDELETENamespacedPodWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyHEADNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39137,11 +46714,11 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Service + * proxy HEAD requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects */ - public proxyDELETENamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39152,18 +46729,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39197,12 +46774,12 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Service + * proxy HEAD requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyDELETENamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39214,23 +46791,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyDELETENamespacedServiceWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39264,10 +46841,10 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Node + * proxy HEAD requests to Node * @param name name of the Node */ - public proxyDELETENode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -39277,13 +46854,13 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENode.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39317,11 +46894,11 @@ export class Core_v1Api { }); } /** - * proxy DELETE requests to Node + * proxy HEAD requests to Node * @param name name of the Node * @param path path to the resource */ - public proxyDELETENodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyHEADNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -39332,18 +46909,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyDELETENodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyHEADNodeWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyDELETENodeWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyHEADNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'HEAD', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39377,11 +46954,11 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Pod + * proxy OPTIONS requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects */ - public proxyGETNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39392,18 +46969,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39437,12 +47014,12 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Pod + * proxy OPTIONS requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyGETNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39454,23 +47031,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyGETNamespacedPodWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39504,11 +47081,11 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Service + * proxy OPTIONS requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects */ - public proxyGETNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39519,18 +47096,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39564,12 +47141,12 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Service + * proxy OPTIONS requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyGETNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39581,23 +47158,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyGETNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyGETNamespacedServiceWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39631,10 +47208,10 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Node + * proxy OPTIONS requests to Node * @param name name of the Node */ - public proxyGETNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -39644,13 +47221,13 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNode.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39684,11 +47261,11 @@ export class Core_v1Api { }); } /** - * proxy GET requests to Node + * proxy OPTIONS requests to Node * @param name name of the Node * @param path path to the resource */ - public proxyGETNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyOPTIONSNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -39699,18 +47276,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyGETNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNodeWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyGETNodeWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'OPTIONS', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39744,11 +47321,11 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Pod + * proxy PATCH requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects */ - public proxyHEADNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39759,18 +47336,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39804,12 +47381,12 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Pod + * proxy PATCH requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyHEADNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39821,23 +47398,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyHEADNamespacedPodWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39871,11 +47448,11 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Service + * proxy PATCH requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects */ - public proxyHEADNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -39886,18 +47463,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39931,12 +47508,12 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Service + * proxy PATCH requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyHEADNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -39948,23 +47525,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyHEADNamespacedServiceWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -39998,10 +47575,10 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Node + * proxy PATCH requests to Node * @param name name of the Node */ - public proxyHEADNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -40011,13 +47588,13 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNode.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40051,11 +47628,11 @@ export class Core_v1Api { }); } /** - * proxy HEAD requests to Node + * proxy PATCH requests to Node * @param name name of the Node * @param path path to the resource */ - public proxyHEADNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPATCHNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -40066,18 +47643,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyHEADNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPATCHNodeWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyHEADNodeWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPATCHNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'HEAD', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40111,11 +47688,11 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Pod + * proxy POST requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects */ - public proxyOPTIONSNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -40126,18 +47703,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40171,12 +47748,12 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Pod + * proxy POST requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyOPTIONSNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -40188,23 +47765,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNamespacedPodWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40238,11 +47815,11 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Service + * proxy POST requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects */ - public proxyOPTIONSNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -40253,18 +47830,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40298,12 +47875,12 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Service + * proxy POST requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyOPTIONSNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -40315,23 +47892,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNamespacedServiceWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40365,10 +47942,10 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Node + * proxy POST requests to Node * @param name name of the Node */ - public proxyOPTIONSNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -40378,13 +47955,13 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNode.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40418,11 +47995,11 @@ export class Core_v1Api { }); } /** - * proxy OPTIONS requests to Node + * proxy POST requests to Node * @param name name of the Node * @param path path to the resource */ - public proxyOPTIONSNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPOSTNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -40433,18 +48010,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyOPTIONSNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPOSTNodeWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyOPTIONSNodeWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPOSTNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'OPTIONS', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40478,11 +48055,11 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Pod + * proxy PUT requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects */ - public proxyPATCHNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -40493,18 +48070,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedPod.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40538,12 +48115,12 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Pod + * proxy PUT requests to Pod * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyPATCHNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -40555,23 +48132,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedPodWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedPodWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPATCHNamespacedPodWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPUTNamespacedPodWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40605,11 +48182,11 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Service + * proxy PUT requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects */ - public proxyPATCHNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -40620,18 +48197,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedService.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40665,12 +48242,12 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Service + * proxy PUT requests to Service * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param path path to the resource */ - public proxyPATCHNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)) @@ -40682,23 +48259,23 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPATCHNamespacedServiceWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40732,10 +48309,10 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Node + * proxy PUT requests to Node * @param name name of the Node */ - public proxyPATCHNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -40745,13 +48322,13 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNode.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNode.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40785,11 +48362,11 @@ export class Core_v1Api { }); } /** - * proxy PATCH requests to Node + * proxy PUT requests to Node * @param name name of the Node * @param path path to the resource */ - public proxyPATCHNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { + public proxyPUTNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'path' + '}', String(path)); @@ -40800,18 +48377,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPATCHNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling proxyPUTNodeWithPath.'); } // verify required parameter 'path' is not null or undefined if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPATCHNodeWithPath.'); + throw new Error('Required parameter path was null or undefined when calling proxyPUTNodeWithPath.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40845,14 +48422,13 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - */ - public proxyPOSTNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + * read the specified ComponentStatus + * @param name name of the ComponentStatus + * @param pretty If 'true', then the output is pretty printed. + */ + public readComponentStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ComponentStatus; }> { + const localVarPath = this.basePath + '/api/v1/componentstatuses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -40860,18 +48436,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling readComponentStatus.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedPod.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40890,7 +48465,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ComponentStatus; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -40905,16 +48480,15 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource + * read the specified Namespace + * @param name name of the Namespace + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPOSTNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + public readNamespace (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -40922,23 +48496,25 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespace.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPOSTNamespacedPodWithPath.'); + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -40957,7 +48533,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -40972,14 +48548,13 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Service - * @param name name of the Service - * @param namespace object name and auth scope, such as for teams and projects + * read status of the specified Namespace + * @param name name of the Namespace + * @param pretty If 'true', then the output is pretty printed. */ - public proxyPOSTNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public readNamespaceStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -40987,18 +48562,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling readNamespaceStatus.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedService.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41017,7 +48591,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41032,16 +48606,17 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Service - * @param name name of the Service + * read the specified ConfigMap + * @param name name of the ConfigMap * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPOSTNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' + public readNamespacedConfigMap (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41049,23 +48624,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedConfigMap.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedConfigMap.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPOSTNamespacedServiceWithPath.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41084,7 +48666,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41099,12 +48681,17 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Node - * @param name name of the Node + * read the specified Endpoints + * @param name name of the Endpoints + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPOSTNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedEndpoints (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41112,13 +48699,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNode.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedEndpoints.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedEndpoints.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41137,7 +48741,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41152,14 +48756,17 @@ export class Core_v1Api { }); } /** - * proxy POST requests to Node - * @param name name of the Node - * @param path path to the resource + * read the specified Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPOSTNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' + public readNamespacedEvent (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Event; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41167,18 +48774,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPOSTNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedEvent.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPOSTNodeWithPath.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedEvent.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41197,7 +48816,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41212,12 +48831,15 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Pod - * @param name name of the Pod + * read the specified LimitRange + * @param name name of the LimitRange * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPUTNamespacedPod (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}' + public readNamespacedLimitRange (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -41227,18 +48849,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedLimitRange.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedLimitRange.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41257,7 +48891,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41272,16 +48906,17 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Pod - * @param name name of the Pod + * read the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPUTNamespacedPodWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}' + public readNamespacedPersistentVolumeClaim (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41289,23 +48924,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedPodWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPersistentVolumeClaim.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedPodWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPersistentVolumeClaim.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPUTNamespacedPodWithPath.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41324,7 +48966,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41339,12 +48981,13 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Service - * @param name name of the Service + * read status of the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. */ - public proxyPUTNamespacedService (name: string, namespace: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}' + public readNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -41354,18 +48997,22 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPersistentVolumeClaimStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPersistentVolumeClaimStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41384,7 +49031,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41399,16 +49046,17 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Service - * @param name name of the Service + * read the specified Pod + * @param name name of the Pod * @param namespace object name and auth scope, such as for teams and projects - * @param path path to the resource + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public proxyPUTNamespacedServiceWithPath (name: string, namespace: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/namespaces/{namespace}/services/{name}/{path}' + public readNamespacedPod (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41416,23 +49064,30 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPod.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPod.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPUTNamespacedServiceWithPath.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41451,7 +49106,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41466,12 +49121,22 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Node - * @param name name of the Node + * read log of the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param container The container for which to stream logs. Defaults to only container if there is one container in the pod. + * @param follow Follow the log stream of the pod. Defaults to false. + * @param limitBytes If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit. + * @param pretty If 'true', then the output is pretty printed. + * @param previous Return previous terminated container logs. Defaults to false. + * @param sinceSeconds A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified. + * @param tailLines If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime + * @param timestamps If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false. */ - public proxyPUTNode (name: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedPodLog (name: string, namespace: string, container?: string, follow?: boolean, limitBytes?: number, pretty?: string, previous?: boolean, sinceSeconds?: number, tailLines?: number, timestamps?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/log' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41479,13 +49144,50 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNode.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodLog.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodLog.'); + } + + if (container !== undefined) { + queryParameters['container'] = container; + } + + if (follow !== undefined) { + queryParameters['follow'] = follow; + } + + if (limitBytes !== undefined) { + queryParameters['limitBytes'] = limitBytes; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (previous !== undefined) { + queryParameters['previous'] = previous; + } + + if (sinceSeconds !== undefined) { + queryParameters['sinceSeconds'] = sinceSeconds; + } + + if (tailLines !== undefined) { + queryParameters['tailLines'] = tailLines; + } + + if (timestamps !== undefined) { + queryParameters['timestamps'] = timestamps; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41519,14 +49221,15 @@ export class Core_v1Api { }); } /** - * proxy PUT requests to Node - * @param name name of the Node - * @param path path to the resource + * read status of the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. */ - public proxyPUTNodeWithPath (name: string, path: string) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/proxy/nodes/{name}/{path}' + public readNamespacedPodStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'path' + '}', String(path)); + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41534,18 +49237,22 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling proxyPUTNodeWithPath.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodStatus.'); } - // verify required parameter 'path' is not null or undefined - if (path === null || path === undefined) { - throw new Error('Required parameter path was null or undefined when calling proxyPUTNodeWithPath.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -41564,7 +49271,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41579,13 +49286,17 @@ export class Core_v1Api { }); } /** - * read the specified ComponentStatus - * @param name name of the ComponentStatus + * read the specified PodTemplate + * @param name name of the PodTemplate + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readComponentStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ComponentStatus; }> { - const localVarPath = this.basePath + '/api/v1/componentstatuses/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedPodTemplate (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41593,13 +49304,26 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readComponentStatus.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodTemplate.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodTemplate.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + let useFormData = false; let requestOptions: request.Options = { @@ -41622,7 +49346,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ComponentStatus; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41637,15 +49361,17 @@ export class Core_v1Api { }); } /** - * read the specified Namespace - * @param name name of the Namespace + * read the specified ReplicationController + * @param name name of the ReplicationController + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespace (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedReplicationController (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41653,7 +49379,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespace.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationController.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -41690,7 +49421,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41705,13 +49436,15 @@ export class Core_v1Api { }); } /** - * read status of the specified Namespace - * @param name name of the Namespace + * read scale of the specified ReplicationController + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. */ - public readNamespaceStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedReplicationControllerScale (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -41719,7 +49452,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespaceStatus.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationControllerScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationControllerScale.'); } if (pretty !== undefined) { @@ -41748,7 +49486,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41763,15 +49501,13 @@ export class Core_v1Api { }); } /** - * read the specified ConfigMap - * @param name name of the ConfigMap + * read status of the specified ReplicationController + * @param name name of the ReplicationController * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedConfigMap (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + public readNamespacedReplicationControllerStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -41781,26 +49517,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedConfigMap.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationControllerStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationControllerStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { @@ -41823,7 +49551,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41838,15 +49566,15 @@ export class Core_v1Api { }); } /** - * read the specified Endpoints - * @param name name of the Endpoints + * read the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedEndpoints (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + public readNamespacedResourceQuota (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -41856,12 +49584,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedEndpoints.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedResourceQuota.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -41898,7 +49626,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41913,15 +49641,13 @@ export class Core_v1Api { }); } /** - * read the specified Event - * @param name name of the Event + * read status of the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedEvent (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Event; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + public readNamespacedResourceQuotaStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -41931,26 +49657,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedEvent.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedResourceQuotaStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedResourceQuotaStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { @@ -41973,7 +49691,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -41988,15 +49706,15 @@ export class Core_v1Api { }); } /** - * read the specified LimitRange - * @param name name of the LimitRange + * read the specified Secret + * @param name name of the Secret * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedLimitRange (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + public readNamespacedSecret (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42006,12 +49724,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedLimitRange.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedSecret.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedSecret.'); } if (pretty !== undefined) { @@ -42048,7 +49766,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42063,15 +49781,15 @@ export class Core_v1Api { }); } /** - * read the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * read the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPersistentVolumeClaim (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' + public readNamespacedService (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42081,12 +49799,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedService.'); } if (pretty !== undefined) { @@ -42123,7 +49841,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42138,13 +49856,15 @@ export class Core_v1Api { }); } /** - * read status of the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * read the specified ServiceAccount + * @param name name of the ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' + public readNamespacedServiceAccount (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42154,18 +49874,26 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedServiceAccount.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedServiceAccount.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + let useFormData = false; let requestOptions: request.Options = { @@ -42188,7 +49916,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42203,15 +49931,13 @@ export class Core_v1Api { }); } /** - * read the specified Pod - * @param name name of the Pod + * read status of the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPod (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' + public readNamespacedServiceStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42221,26 +49947,18 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedServiceStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPod.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedServiceStatus.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { @@ -42263,7 +49981,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42278,22 +49996,15 @@ export class Core_v1Api { }); } /** - * read log of the specified Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects - * @param container The container for which to stream logs. Defaults to only container if there is one container in the pod. - * @param follow Follow the log stream of the pod. Defaults to false. - * @param limitBytes If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit. + * read the specified Node + * @param name name of the Node * @param pretty If 'true', then the output is pretty printed. - * @param previous Return previous terminated container logs. Defaults to false. - * @param sinceSeconds A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified. - * @param tailLines If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime - * @param timestamps If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPodLog (name: string, namespace: string, container?: string, follow?: boolean, limitBytes?: number, pretty?: string, previous?: boolean, sinceSeconds?: number, tailLines?: number, timestamps?: boolean) : Promise<{ response: http.ClientResponse; body: string; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/log' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public readNode (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42301,44 +50012,19 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodLog.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodLog.'); - } - - if (container !== undefined) { - queryParameters['container'] = container; - } - - if (follow !== undefined) { - queryParameters['follow'] = follow; - } - - if (limitBytes !== undefined) { - queryParameters['limitBytes'] = limitBytes; + throw new Error('Required parameter name was null or undefined when calling readNode.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (previous !== undefined) { - queryParameters['previous'] = previous; - } - - if (sinceSeconds !== undefined) { - queryParameters['sinceSeconds'] = sinceSeconds; - } - - if (tailLines !== undefined) { - queryParameters['tailLines'] = tailLines; + if (exact !== undefined) { + queryParameters['exact'] = exact; } - if (timestamps !== undefined) { - queryParameters['timestamps'] = timestamps; + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; @@ -42363,7 +50049,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: string; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42378,15 +50064,13 @@ export class Core_v1Api { }); } /** - * read status of the specified Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects + * read status of the specified Node + * @param name name of the Node * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedPodStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public readNodeStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42394,12 +50078,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodStatus.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodStatus.'); + throw new Error('Required parameter name was null or undefined when calling readNodeStatus.'); } if (pretty !== undefined) { @@ -42428,7 +50107,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42443,17 +50122,15 @@ export class Core_v1Api { }); } /** - * read the specified PodTemplate - * @param name name of the PodTemplate - * @param namespace object name and auth scope, such as for teams and projects + * read the specified PersistentVolume + * @param name name of the PersistentVolume * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPodTemplate (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public readPersistentVolume (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42461,12 +50138,7 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodTemplate.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodTemplate.'); + throw new Error('Required parameter name was null or undefined when calling readPersistentVolume.'); } if (pretty !== undefined) { @@ -42503,7 +50175,65 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified PersistentVolume + * @param name name of the PersistentVolume + * @param pretty If 'true', then the output is pretty printed. + */ + public readPersistentVolumeStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readPersistentVolumeStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42518,17 +50248,14 @@ export class Core_v1Api { }); } /** - * read the specified ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects + * replace the specified Namespace + * @param name name of the Namespace + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedReplicationController (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceNamespace (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42536,35 +50263,28 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationController.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespace.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationController.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespace.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42578,7 +50298,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42593,15 +50313,14 @@ export class Core_v1Api { }); } /** - * read scale of the specified ReplicationController - * @param name name of the Scale - * @param namespace object name and auth scope, such as for teams and projects + * replace finalize of the specified Namespace + * @param name name of the Namespace + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedReplicationControllerScale (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceNamespaceFinalize (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}/finalize' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42609,12 +50328,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationControllerScale.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespaceFinalize.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationControllerScale.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespaceFinalize.'); } if (pretty !== undefined) { @@ -42624,12 +50343,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42643,7 +50363,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42658,15 +50378,14 @@ export class Core_v1Api { }); } /** - * read status of the specified ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects + * replace status of the specified Namespace + * @param name name of the Namespace + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedReplicationControllerStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceNamespaceStatus (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -42674,12 +50393,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedReplicationControllerStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespaceStatus.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedReplicationControllerStatus.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespaceStatus.'); } if (pretty !== undefined) { @@ -42689,12 +50408,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42708,7 +50428,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42723,15 +50443,14 @@ export class Core_v1Api { }); } /** - * read the specified ResourceQuota - * @param name name of the ResourceQuota + * replace the specified ConfigMap + * @param name name of the ConfigMap * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedResourceQuota (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' + public replaceNamespacedConfigMap (name: string, namespace: string, body: V1ConfigMap, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42741,35 +50460,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedResourceQuota.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedConfigMap.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedResourceQuota.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedConfigMap.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedConfigMap.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42783,7 +50500,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42798,13 +50515,14 @@ export class Core_v1Api { }); } /** - * read status of the specified ResourceQuota - * @param name name of the ResourceQuota + * replace the specified Endpoints + * @param name name of the Endpoints * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedResourceQuotaStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' + public replaceNamespacedEndpoints (name: string, namespace: string, body: V1Endpoints, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42814,12 +50532,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedEndpoints.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedEndpoints.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedEndpoints.'); } if (pretty !== undefined) { @@ -42829,12 +50552,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42848,7 +50572,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42863,15 +50587,14 @@ export class Core_v1Api { }); } /** - * read the specified Secret - * @param name name of the Secret + * replace the specified Event + * @param name name of the Event * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedSecret (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' + public replaceNamespacedEvent (name: string, namespace: string, body: V1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42881,35 +50604,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedSecret.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedEvent.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedSecret.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedEvent.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedEvent.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42923,7 +50644,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -42938,15 +50659,14 @@ export class Core_v1Api { }); } /** - * read the specified Service - * @param name name of the Service + * replace the specified LimitRange + * @param name name of the LimitRange * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedService (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' + public replaceNamespacedLimitRange (name: string, namespace: string, body: V1LimitRange, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -42956,35 +50676,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedService.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedLimitRange.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedService.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedLimitRange.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedLimitRange.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -42998,7 +50716,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43013,15 +50731,14 @@ export class Core_v1Api { }); } /** - * read the specified ServiceAccount - * @param name name of the ServiceAccount + * replace the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedServiceAccount (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' + public replaceNamespacedPersistentVolumeClaim (name: string, namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43031,35 +50748,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedServiceAccount.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedServiceAccount.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43073,7 +50788,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43088,13 +50803,14 @@ export class Core_v1Api { }); } /** - * read status of the specified Service - * @param name name of the Service + * replace status of the specified PersistentVolumeClaim + * @param name name of the PersistentVolumeClaim * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedServiceStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' + public replaceNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43104,12 +50820,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedServiceStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedServiceStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); } if (pretty !== undefined) { @@ -43119,12 +50840,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43138,7 +50860,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43153,15 +50875,16 @@ export class Core_v1Api { }); } /** - * read the specified Node - * @param name name of the Node + * replace the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNode (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedPod (name: string, namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43169,30 +50892,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNode.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPod.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPod.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPod.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43206,7 +50932,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43221,13 +50947,16 @@ export class Core_v1Api { }); } /** - * read status of the specified Node - * @param name name of the Node + * replace status of the specified Pod + * @param name name of the Pod + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNodeStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedPodStatus (name: string, namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43235,7 +50964,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNodeStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodStatus.'); } if (pretty !== undefined) { @@ -43245,12 +50984,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43264,7 +51004,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43279,15 +51019,16 @@ export class Core_v1Api { }); } /** - * read the specified PersistentVolume - * @param name name of the PersistentVolume + * replace the specified PodTemplate + * @param name name of the PodTemplate + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readPersistentVolume (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedPodTemplate (name: string, namespace: string, body: V1PodTemplate, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43295,30 +51036,33 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readPersistentVolume.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodTemplate.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodTemplate.'); } - if (exact !== undefined) { - queryParameters['exact'] = exact; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodTemplate.'); } - if (_export !== undefined) { - queryParameters['export'] = _export; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43332,7 +51076,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43347,13 +51091,16 @@ export class Core_v1Api { }); } /** - * read status of the specified PersistentVolume - * @param name name of the PersistentVolume + * replace the specified ReplicationController + * @param name name of the ReplicationController + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readPersistentVolumeStatus (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedReplicationController (name: string, namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43361,7 +51108,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readPersistentVolumeStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationController.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationController.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationController.'); } if (pretty !== undefined) { @@ -43371,12 +51128,13 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -43390,7 +51148,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43405,14 +51163,16 @@ export class Core_v1Api { }); } /** - * replace the specified Namespace - * @param name name of the Namespace + * replace scale of the specified ReplicationController + * @param name name of the Scale + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespace (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedReplicationControllerScale (name: string, namespace: string, body: V1Scale, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43420,12 +51180,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespace.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationControllerScale.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationControllerScale.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespace.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationControllerScale.'); } if (pretty !== undefined) { @@ -43455,7 +51220,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43470,14 +51235,16 @@ export class Core_v1Api { }); } /** - * replace finalize of the specified Namespace - * @param name name of the Namespace + * replace status of the specified ReplicationController + * @param name name of the ReplicationController + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespaceFinalize (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}/finalize' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedReplicationControllerStatus (name: string, namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -43485,77 +51252,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespaceFinalize.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespaceFinalize.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); } - let useFormData = false; - - let requestOptions: request.Options = { - method: 'PUT', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * replace status of the specified Namespace - * @param name name of the Namespace - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public replaceNamespaceStatus (name: string, body: V1Namespace, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Namespace; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{name}/status' - .replace('{' + 'name' + '}', String(name)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespaceStatus.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespaceStatus.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); } if (pretty !== undefined) { @@ -43585,7 +51292,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Namespace; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43600,14 +51307,14 @@ export class Core_v1Api { }); } /** - * replace the specified ConfigMap - * @param name name of the ConfigMap + * replace the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedConfigMap (name: string, namespace: string, body: V1ConfigMap, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ConfigMap; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/configmaps/{name}' + public replaceNamespacedResourceQuota (name: string, namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43617,17 +51324,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedConfigMap.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedResourceQuota.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedConfigMap.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedResourceQuota.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedConfigMap.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedResourceQuota.'); } if (pretty !== undefined) { @@ -43657,7 +51364,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ConfigMap; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43672,14 +51379,14 @@ export class Core_v1Api { }); } /** - * replace the specified Endpoints - * @param name name of the Endpoints + * replace status of the specified ResourceQuota + * @param name name of the ResourceQuota * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedEndpoints (name: string, namespace: string, body: V1Endpoints, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Endpoints; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/endpoints/{name}' + public replaceNamespacedResourceQuotaStatus (name: string, namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43689,17 +51396,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedEndpoints.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedEndpoints.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedEndpoints.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); } if (pretty !== undefined) { @@ -43729,7 +51436,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Endpoints; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43744,14 +51451,14 @@ export class Core_v1Api { }); } /** - * replace the specified Event - * @param name name of the Event + * replace the specified Secret + * @param name name of the Secret * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedEvent (name: string, namespace: string, body: V1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Event; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/events/{name}' + public replaceNamespacedSecret (name: string, namespace: string, body: V1Secret, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43761,17 +51468,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedEvent.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedSecret.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedEvent.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedSecret.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedEvent.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedSecret.'); } if (pretty !== undefined) { @@ -43801,7 +51508,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Event; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43816,14 +51523,14 @@ export class Core_v1Api { }); } /** - * replace the specified LimitRange - * @param name name of the LimitRange + * replace the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedLimitRange (name: string, namespace: string, body: V1LimitRange, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1LimitRange; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/limitranges/{name}' + public replaceNamespacedService (name: string, namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43833,17 +51540,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedLimitRange.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedService.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedLimitRange.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedService.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedLimitRange.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedService.'); } if (pretty !== undefined) { @@ -43873,7 +51580,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1LimitRange; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43888,14 +51595,14 @@ export class Core_v1Api { }); } /** - * replace the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * replace the specified ServiceAccount + * @param name name of the ServiceAccount * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPersistentVolumeClaim (name: string, namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}' + public replaceNamespacedServiceAccount (name: string, namespace: string, body: V1ServiceAccount, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43905,17 +51612,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedServiceAccount.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedServiceAccount.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPersistentVolumeClaim.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedServiceAccount.'); } if (pretty !== undefined) { @@ -43945,7 +51652,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -43960,14 +51667,14 @@ export class Core_v1Api { }); } /** - * replace status of the specified PersistentVolumeClaim - * @param name name of the PersistentVolumeClaim + * replace status of the specified Service + * @param name name of the Service * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPersistentVolumeClaimStatus (name: string, namespace: string, body: V1PersistentVolumeClaim, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status' + public replaceNamespacedServiceStatus (name: string, namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { + const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -43977,17 +51684,17 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedServiceStatus.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedServiceStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPersistentVolumeClaimStatus.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedServiceStatus.'); } if (pretty !== undefined) { @@ -44017,7 +51724,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolumeClaim; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44032,16 +51739,14 @@ export class Core_v1Api { }); } /** - * replace the specified Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects + * replace the specified Node + * @param name name of the Node * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPod (name: string, namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceNode (name: string, body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -44049,17 +51754,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPod.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPod.'); + throw new Error('Required parameter name was null or undefined when calling replaceNode.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPod.'); + throw new Error('Required parameter body was null or undefined when calling replaceNode.'); } if (pretty !== undefined) { @@ -44089,7 +51789,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44104,16 +51804,14 @@ export class Core_v1Api { }); } /** - * replace status of the specified Pod - * @param name name of the Pod - * @param namespace object name and auth scope, such as for teams and projects + * replace status of the specified Node + * @param name name of the Node * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPodStatus (name: string, namespace: string, body: V1Pod, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Pod; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/pods/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceNodeStatus (name: string, body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { + const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -44121,17 +51819,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodStatus.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNodeStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodStatus.'); + throw new Error('Required parameter body was null or undefined when calling replaceNodeStatus.'); } if (pretty !== undefined) { @@ -44161,7 +51854,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Pod; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44176,16 +51869,14 @@ export class Core_v1Api { }); } /** - * replace the specified PodTemplate - * @param name name of the PodTemplate - * @param namespace object name and auth scope, such as for teams and projects + * replace the specified PersistentVolume + * @param name name of the PersistentVolume * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPodTemplate (name: string, namespace: string, body: V1PodTemplate, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PodTemplate; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/podtemplates/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replacePersistentVolume (name: string, body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -44193,17 +51884,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodTemplate.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodTemplate.'); + throw new Error('Required parameter name was null or undefined when calling replacePersistentVolume.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodTemplate.'); + throw new Error('Required parameter body was null or undefined when calling replacePersistentVolume.'); } if (pretty !== undefined) { @@ -44233,7 +51919,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PodTemplate; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44248,16 +51934,14 @@ export class Core_v1Api { }); } /** - * replace the specified ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects + * replace status of the specified PersistentVolume + * @param name name of the PersistentVolume * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public replaceNamespacedReplicationController (name: string, namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + * @param pretty If 'true', then the output is pretty printed. + */ + public replacePersistentVolumeStatus (name: string, body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { + const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -44265,17 +51949,12 @@ export class Core_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationController.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationController.'); + throw new Error('Required parameter name was null or undefined when calling replacePersistentVolumeStatus.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationController.'); + throw new Error('Required parameter body was null or undefined when calling replacePersistentVolumeStatus.'); } if (pretty !== undefined) { @@ -44305,7 +51984,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44319,35 +51998,89 @@ export class Core_v1Api { }); }); } +} +export enum Custom_objectsApiApiKeys { + BearerToken, +} + +export class Custom_objectsApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Custom_objectsApiApiKeys, value: string) { + this.authentications[Custom_objectsApiApiKeys[key]].apiKey = value; + } /** - * replace scale of the specified ReplicationController - * @param name name of the Scale - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * Creates a cluster scoped Custom object + * @param group The custom resource's group name + * @param version The custom resource's version + * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param body The JSON schema of the Resource to create. * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedReplicationControllerScale (name: string, namespace: string, body: V1Scale, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Scale; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public createClusterCustomObject (group: string, version: string, plural: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationControllerScale.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling createClusterCustomObject.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationControllerScale.'); + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling createClusterCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling createClusterCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationControllerScale.'); + throw new Error('Required parameter body was null or undefined when calling createClusterCustomObject.'); } if (pretty !== undefined) { @@ -44357,7 +52090,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -44377,7 +52110,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Scale; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44392,34 +52125,48 @@ export class Core_v1Api { }); } /** - * replace status of the specified ReplicationController - * @param name name of the ReplicationController - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * Creates a namespace scoped Custom object + * @param group The custom resource's group name + * @param version The custom resource's version + * @param namespace The custom resource's namespace + * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param body The JSON schema of the Resource to create. * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedReplicationControllerStatus (name: string, namespace: string, body: V1ReplicationController, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ReplicationController; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public createNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling createNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling createNamespacedCustomObject.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling createNamespacedCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedReplicationControllerStatus.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedCustomObject.'); } if (pretty !== undefined) { @@ -44429,7 +52176,7 @@ export class Core_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -44449,7 +52196,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ReplicationController; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44464,44 +52211,68 @@ export class Core_v1Api { }); } /** - * replace the specified ResourceQuota - * @param name name of the ResourceQuota - * @param namespace object name and auth scope, such as for teams and projects + * Deletes the specified cluster scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name * @param body - * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. */ - public replaceNamespacedResourceQuota (name: string, namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteClusterCustomObject (group: string, version: string, plural: string, name: string, body: V1DeleteOptions, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)) + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedResourceQuota.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling deleteClusterCustomObject.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedResourceQuota.'); + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling deleteClusterCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling deleteClusterCustomObject.'); + } + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteClusterCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedResourceQuota.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterCustomObject.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -44521,7 +52292,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44536,44 +52307,75 @@ export class Core_v1Api { }); } /** - * replace status of the specified ResourceQuota - * @param name name of the ResourceQuota - * @param namespace object name and auth scope, such as for teams and projects + * Deletes the specified namespace scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param namespace The custom resource's namespace + * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name * @param body - * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. */ - public replaceNamespacedResourceQuotaStatus (name: string, namespace: string, body: V1ResourceQuota, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/resourcequotas/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string, body: V1DeleteOptions, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)) + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling deleteNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling deleteNamespacedCustomObject.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling deleteNamespacedCustomObject.'); + } + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedResourceQuotaStatus.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedCustomObject.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -44593,7 +52395,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ResourceQuota; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44608,50 +52410,52 @@ export class Core_v1Api { }); } /** - * replace the specified Secret - * @param name name of the Secret - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * Returns a cluster scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name */ - public replaceNamespacedSecret (name: string, namespace: string, body: V1Secret, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Secret; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/secrets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public getClusterCustomObject (group: string, version: string, plural: string, name: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)) + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedSecret.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling getClusterCustomObject.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedSecret.'); + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling getClusterCustomObject.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedSecret.'); + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling getClusterCustomObject.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling getClusterCustomObject.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -44665,7 +52469,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Secret; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44680,50 +52484,59 @@ export class Core_v1Api { }); } /** - * replace the specified Service - * @param name name of the Service - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. + * Returns a namespace scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param namespace The custom resource's namespace + * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name */ - public replaceNamespacedService (name: string, namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public getNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)) + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedService.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling getNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling getNamespacedCustomObject.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedService.'); + throw new Error('Required parameter namespace was null or undefined when calling getNamespacedCustomObject.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedService.'); + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling getNamespacedCustomObject.'); } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling getNamespacedCustomObject.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -44737,7 +52550,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44752,50 +52565,65 @@ export class Core_v1Api { }); } /** - * replace the specified ServiceAccount - * @param name name of the ServiceAccount - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch cluster scoped custom objects + * @param group The custom resource's group name + * @param version The custom resource's version + * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. * @param pretty If 'true', then the output is pretty printed. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. */ - public replaceNamespacedServiceAccount (name: string, namespace: string, body: V1ServiceAccount, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/serviceaccounts/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listClusterCustomObject (group: string, version: string, plural: string, pretty?: string, labelSelector?: string, resourceVersion?: string, watch?: boolean) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedServiceAccount.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling listClusterCustomObject.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedServiceAccount.'); + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling listClusterCustomObject.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedServiceAccount.'); + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling listClusterCustomObject.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -44809,7 +52637,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ServiceAccount; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44824,50 +52652,72 @@ export class Core_v1Api { }); } /** - * replace status of the specified Service - * @param name name of the Service - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch namespace scoped custom objects + * @param group The custom resource's group name + * @param version The custom resource's version + * @param namespace The custom resource's namespace + * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. * @param pretty If 'true', then the output is pretty printed. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. */ - public replaceNamespacedServiceStatus (name: string, namespace: string, body: V1Service, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Service; }> { - const localVarPath = this.basePath + '/api/v1/namespaces/{namespace}/services/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, pretty?: string, labelSelector?: string, resourceVersion?: string, watch?: boolean) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedServiceStatus.'); + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling listNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling listNamespacedCustomObject.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedServiceStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedCustomObject.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedServiceStatus.'); + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling listNamespacedCustomObject.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -44881,7 +52731,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Service; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44896,37 +52746,53 @@ export class Core_v1Api { }); } /** - * replace the specified Node - * @param name name of the Node - * @param body - * @param pretty If 'true', then the output is pretty printed. + * patch the specified cluster scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name + * @param body The JSON schema of the Resource to patch. */ - public replaceNode (name: string, body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}' + public patchClusterCustomObject (group: string, version: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)) .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling patchClusterCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling patchClusterCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling patchClusterCustomObject.'); + } + // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNode.'); + throw new Error('Required parameter name was null or undefined when calling patchClusterCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNode.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter body was null or undefined when calling patchClusterCustomObject.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -44946,7 +52812,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -44961,37 +52827,60 @@ export class Core_v1Api { }); } /** - * replace status of the specified Node - * @param name name of the Node - * @param body - * @param pretty If 'true', then the output is pretty printed. + * patch the specified namespace scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param namespace The custom resource's namespace + * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name + * @param body The JSON schema of the Resource to patch. */ - public replaceNodeStatus (name: string, body: V1Node, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Node; }> { - const localVarPath = this.basePath + '/api/v1/nodes/{name}/status' + public patchNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)) .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling patchNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling patchNamespacedCustomObject.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling patchNamespacedCustomObject.'); + } + // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNodeStatus.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNodeStatus.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter body was null or undefined when calling patchNamespacedCustomObject.'); } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -45011,7 +52900,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Node; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45026,31 +52915,47 @@ export class Core_v1Api { }); } /** - * replace the specified PersistentVolume - * @param name name of the PersistentVolume - * @param body - * @param pretty If 'true', then the output is pretty printed. + * replace the specified cluster scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name + * @param body The JSON schema of the Resource to replace. */ - public replacePersistentVolume (name: string, body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}' + public replaceClusterCustomObject (group: string, version: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'plural' + '}', String(plural)) .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling replaceClusterCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling replaceClusterCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling replaceClusterCustomObject.'); + } + // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replacePersistentVolume.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replacePersistentVolume.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter body was null or undefined when calling replaceClusterCustomObject.'); } let useFormData = false; @@ -45076,7 +52981,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45091,31 +52996,54 @@ export class Core_v1Api { }); } /** - * replace status of the specified PersistentVolume - * @param name name of the PersistentVolume - * @param body - * @param pretty If 'true', then the output is pretty printed. + * replace the specified namespace scoped custom object + * @param group the custom resource's group + * @param version the custom resource's version + * @param namespace The custom resource's namespace + * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. + * @param name the custom object's name + * @param body The JSON schema of the Resource to replace. */ - public replacePersistentVolumeStatus (name: string, body: V1PersistentVolume, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }> { - const localVarPath = this.basePath + '/api/v1/persistentvolumes/{name}/status' + public replaceNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { + const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' + .replace('{' + 'group' + '}', String(group)) + .replace('{' + 'version' + '}', String(version)) + .replace('{' + 'namespace' + '}', String(namespace)) + .replace('{' + 'plural' + '}', String(plural)) .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'group' is not null or undefined + if (group === null || group === undefined) { + throw new Error('Required parameter group was null or undefined when calling replaceNamespacedCustomObject.'); + } + + // verify required parameter 'version' is not null or undefined + if (version === null || version === undefined) { + throw new Error('Required parameter version was null or undefined when calling replaceNamespacedCustomObject.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedCustomObject.'); + } + + // verify required parameter 'plural' is not null or undefined + if (plural === null || plural === undefined) { + throw new Error('Required parameter plural was null or undefined when calling replaceNamespacedCustomObject.'); + } + // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replacePersistentVolumeStatus.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedCustomObject.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replacePersistentVolumeStatus.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedCustomObject.'); } let useFormData = false; @@ -45141,7 +53069,7 @@ export class Core_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1PersistentVolume; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45156,11 +53084,11 @@ export class Core_v1Api { }); } } -export enum Custom_objectsApiApiKeys { +export enum EventsApiApiKeys { BearerToken, } -export class Custom_objectsApi { +export class EventsApi { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -45199,61 +53127,28 @@ export class Custom_objectsApi { this.authentications.default = auth; } - public setApiKey(key: Custom_objectsApiApiKeys, value: string) { - this.authentications[Custom_objectsApiApiKeys[key]].apiKey = value; + public setApiKey(key: EventsApiApiKeys, value: string) { + this.authentications[EventsApiApiKeys[key]].apiKey = value; } /** - * Creates a cluster scoped Custom object - * @param group The custom resource's group name - * @param version The custom resource's version - * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param body The JSON schema of the Resource to create. - * @param pretty If 'true', then the output is pretty printed. + * get information of a group */ - public createClusterCustomObject (group: string, version: string, plural: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'plural' + '}', String(plural)); + public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling createClusterCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling createClusterCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling createClusterCustomObject.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterCustomObject.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -45267,7 +53162,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45281,49 +53176,75 @@ export class Custom_objectsApi { }); }); } +} +export enum Events_v1beta1ApiApiKeys { + BearerToken, +} + +export class Events_v1beta1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Events_v1beta1ApiApiKeys, value: string) { + this.authentications[Events_v1beta1ApiApiKeys[key]].apiKey = value; + } /** - * Creates a namespace scoped Custom object - * @param group The custom resource's group name - * @param version The custom resource's version - * @param namespace The custom resource's namespace - * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param body The JSON schema of the Resource to create. + * create an Event + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'plural' + '}', String(plural)); + public createNamespacedEvent (namespace: string, body: V1beta1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Event; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling createNamespacedCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling createNamespacedCustomObject.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling createNamespacedCustomObject.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedEvent.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedCustomObject.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedEvent.'); } if (pretty !== undefined) { @@ -45353,7 +53274,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45368,62 +53289,65 @@ export class Custom_objectsApi { }); } /** - * Deletes the specified cluster scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name - * @param body - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * delete collection of Event + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteClusterCustomObject (group: string, version: string, plural: string, name: string, body: V1DeleteOptions, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); + public deleteCollectionNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling deleteClusterCustomObject.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedEvent.'); } - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling deleteClusterCustomObject.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling deleteClusterCustomObject.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterCustomObject.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterCustomObject.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (limit !== undefined) { + queryParameters['limit'] = limit; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; @@ -45435,7 +53359,6 @@ export class Custom_objectsApi { uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -45449,7 +53372,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45464,57 +53387,41 @@ export class Custom_objectsApi { }); } /** - * Deletes the specified namespace scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param namespace The custom resource's namespace - * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name + * delete an Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects * @param body + * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string, body: V1DeleteOptions, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedEvent (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling deleteNamespacedCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling deleteNamespacedCustomObject.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedEvent.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling deleteNamespacedCustomObject.'); - } - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedCustomObject.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedEvent.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedCustomObject.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedEvent.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } if (gracePeriodSeconds !== undefined) { @@ -45552,81 +53459,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * Returns a cluster scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name - */ - public getClusterCustomObject (group: string, version: string, plural: string, name: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling getClusterCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling getClusterCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling getClusterCustomObject.'); - } - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling getClusterCustomObject.'); - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'GET', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45641,50 +53474,15 @@ export class Custom_objectsApi { }); } /** - * Returns a namespace scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param namespace The custom resource's namespace - * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name + * get available resources */ - public getNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling getNamespacedCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling getNamespacedCustomObject.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling getNamespacedCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling getNamespacedCustomObject.'); - } - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling getNamespacedCustomObject.'); - } - let useFormData = false; let requestOptions: request.Options = { @@ -45707,7 +53505,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45722,52 +53520,56 @@ export class Custom_objectsApi { }); } /** - * list or watch cluster scoped custom objects - * @param group The custom resource's group name - * @param version The custom resource's version - * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind Event + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterCustomObject (group: string, version: string, plural: string, pretty?: string, labelSelector?: string, resourceVersion?: string, watch?: boolean) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'plural' + '}', String(plural)); + public listEventForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1EventList; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/events'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling listClusterCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling listClusterCustomObject.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling listClusterCustomObject.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } if (labelSelector !== undefined) { queryParameters['labelSelector'] = labelSelector; } + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + if (watch !== undefined) { queryParameters['watch'] = watch; } @@ -45794,7 +53596,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1EventList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45809,59 +53611,63 @@ export class Custom_objectsApi { }); } /** - * list or watch namespace scoped custom objects - * @param group The custom resource's group name - * @param version The custom resource's version - * @param namespace The custom resource's namespace - * @param plural The custom resource's plural name. For TPRs this would be lowercase plural kind. + * list or watch objects of kind Event + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, pretty?: string, labelSelector?: string, resourceVersion?: string, watch?: boolean) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'plural' + '}', String(plural)); + public listNamespacedEvent (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1EventList; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling listNamespacedCustomObject.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedEvent.'); } - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling listNamespacedCustomObject.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedCustomObject.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling listNamespacedCustomObject.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } if (labelSelector !== undefined) { queryParameters['labelSelector'] = labelSelector; } + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + if (watch !== undefined) { queryParameters['watch'] = watch; } @@ -45888,7 +53694,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1EventList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45903,53 +53709,44 @@ export class Custom_objectsApi { }); } /** - * replace the specified cluster scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param plural the custom object's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name - * @param body The JSON schema of the Resource to replace. + * partially update the specified Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public replaceClusterCustomObject (group: string, version: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); + public patchNamespacedEvent (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Event; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling replaceClusterCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling replaceClusterCustomObject.'); - } - - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling replaceClusterCustomObject.'); - } - // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterCustomObject.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedEvent.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedEvent.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterCustomObject.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedEvent.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -45969,7 +53766,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -45984,54 +53781,113 @@ export class Custom_objectsApi { }); } /** - * replace the specified namespace scoped custom object - * @param group the custom resource's group - * @param version the custom resource's version - * @param namespace The custom resource's namespace - * @param plural the custom resource's plural name. For TPRs this would be lowercase plural kind. - * @param name the custom object's name - * @param body The JSON schema of the Resource to replace. + * read the specified Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public replaceNamespacedCustomObject (group: string, version: string, namespace: string, plural: string, name: string, body: any) : Promise<{ response: http.ClientResponse; body: any; }> { - const localVarPath = this.basePath + '/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}' - .replace('{' + 'group' + '}', String(group)) - .replace('{' + 'version' + '}', String(version)) - .replace('{' + 'namespace' + '}', String(namespace)) - .replace('{' + 'plural' + '}', String(plural)) - .replace('{' + 'name' + '}', String(name)); + public readNamespacedEvent (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1Event; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'group' is not null or undefined - if (group === null || group === undefined) { - throw new Error('Required parameter group was null or undefined when calling replaceNamespacedCustomObject.'); - } - - // verify required parameter 'version' is not null or undefined - if (version === null || version === undefined) { - throw new Error('Required parameter version was null or undefined when calling replaceNamespacedCustomObject.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedEvent.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedCustomObject.'); + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedEvent.'); } - // verify required parameter 'plural' is not null or undefined - if (plural === null || plural === undefined) { - throw new Error('Required parameter plural was null or undefined when calling replaceNamespacedCustomObject.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } } + return new Promise<{ response: http.ClientResponse; body: V1beta1Event; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified Event + * @param name name of the Event + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedEvent (name: string, namespace: string, body: V1beta1Event, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Event; }> { + const localVarPath = this.basePath + '/apis/events.k8s.io/v1beta1/namespaces/{namespace}/events/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedCustomObject.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedEvent.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedEvent.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedCustomObject.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedEvent.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; @@ -46057,7 +53913,7 @@ export class Custom_objectsApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: any; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Event; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -47255,7 +55111,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedDaemonSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/namespaces/{namespace}/daemonsets/{name}' @@ -47342,7 +55198,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedDeployment (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/namespaces/{namespace}/deployments/{name}' @@ -47429,7 +55285,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedIngress (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/namespaces/{namespace}/ingresses/{name}' @@ -47516,7 +55372,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedNetworkPolicy (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/namespaces/{namespace}/networkpolicies/{name}' @@ -47603,7 +55459,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedReplicaSet (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/namespaces/{namespace}/replicasets/{name}' @@ -47689,7 +55545,7 @@ export class Extensions_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deletePodSecurityPolicy (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/extensions/v1beta1/podsecuritypolicies/{name}' @@ -52057,7 +59913,7 @@ export class Networking_v1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedNetworkPolicy (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}' @@ -52901,7 +60757,7 @@ export class Policy_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteNamespacedPodDisruptionBudget (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}' @@ -53308,14 +61164,496 @@ export class Policy_v1beta1Api { throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodDisruptionBudgetStatus.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodDisruptionBudgetStatus.'); - } + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodDisruptionBudgetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodDisruptionBudgetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PATCH', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified PodDisruptionBudget + * @param name name of the PodDisruptionBudget + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. + */ + public readNamespacedPodDisruptionBudget (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { + const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodDisruptionBudget.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodDisruptionBudget.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (exact !== undefined) { + queryParameters['exact'] = exact; + } + + if (_export !== undefined) { + queryParameters['export'] = _export; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read status of the specified PodDisruptionBudget + * @param name name of the PodDisruptionBudget + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedPodDisruptionBudgetStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { + const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodDisruptionBudgetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodDisruptionBudgetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace the specified PodDisruptionBudget + * @param name name of the PodDisruptionBudget + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedPodDisruptionBudget (name: string, namespace: string, body: V1beta1PodDisruptionBudget, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { + const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * replace status of the specified PodDisruptionBudget + * @param name name of the PodDisruptionBudget + * @param namespace object name and auth scope, such as for teams and projects + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public replaceNamespacedPodDisruptionBudgetStatus (name: string, namespace: string, body: V1beta1PodDisruptionBudget, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { + const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}/status' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'PUT', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum RbacAuthorizationApiApiKeys { + BearerToken, +} + +export class RbacAuthorizationApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: RbacAuthorizationApiApiKeys, value: string) { + this.authentications[RbacAuthorizationApiApiKeys[key]].apiKey = value; + } + /** + * get information of a group + */ + public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum RbacAuthorization_v1ApiApiKeys { + BearerToken, +} + +export class RbacAuthorization_v1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: RbacAuthorization_v1ApiApiKeys, value: string) { + this.authentications[RbacAuthorization_v1ApiApiKeys[key]].apiKey = value; + } + /** + * create a ClusterRole + * @param body + * @param pretty If 'true', then the output is pretty printed. + */ + public createClusterRole (body: V1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodDisruptionBudgetStatus.'); + throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); } if (pretty !== undefined) { @@ -53325,7 +61663,7 @@ export class Policy_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -53345,7 +61683,7 @@ export class Policy_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53360,53 +61698,36 @@ export class Policy_v1beta1Api { }); } /** - * read the specified PodDisruptionBudget - * @param name name of the PodDisruptionBudget - * @param namespace object name and auth scope, such as for teams and projects + * create a ClusterRoleBinding + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPodDisruptionBudget (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { - const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public createClusterRoleBinding (body: V1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodDisruptionBudget.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodDisruptionBudget.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53420,7 +61741,7 @@ export class Policy_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53435,28 +61756,27 @@ export class Policy_v1beta1Api { }); } /** - * read status of the specified PodDisruptionBudget - * @param name name of the PodDisruptionBudget + * create a Role * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedPodDisruptionBudgetStatus (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { - const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}/status' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedRole (namespace: string, body: V1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodDisruptionBudgetStatus.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodDisruptionBudgetStatus.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); } if (pretty !== undefined) { @@ -53466,12 +61786,13 @@ export class Policy_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53485,7 +61806,7 @@ export class Policy_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53500,34 +61821,27 @@ export class Policy_v1beta1Api { }); } /** - * replace the specified PodDisruptionBudget - * @param name name of the PodDisruptionBudget + * create a RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedPodDisruptionBudget (name: string, namespace: string, body: V1beta1PodDisruptionBudget, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { - const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedRoleBinding (namespace: string, body: V1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodDisruptionBudget.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -53537,7 +61851,7 @@ export class Policy_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -53557,7 +61871,7 @@ export class Policy_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53572,16 +61886,17 @@ export class Policy_v1beta1Api { }); } /** - * replace status of the specified PodDisruptionBudget - * @param name name of the PodDisruptionBudget - * @param namespace object name and auth scope, such as for teams and projects + * delete a ClusterRole + * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public replaceNamespacedPodDisruptionBudgetStatus (name: string, namespace: string, body: V1beta1PodDisruptionBudget, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }> { - const localVarPath = this.basePath + '/apis/policy/v1beta1/namespaces/{namespace}/poddisruptionbudgets/{name}/status' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -53589,27 +61904,34 @@ export class Policy_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); + throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodDisruptionBudgetStatus.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -53629,7 +61951,7 @@ export class Policy_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1PodDisruptionBudget; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53643,72 +61965,59 @@ export class Policy_v1beta1Api { }); }); } -} -export enum RbacAuthorizationApiApiKeys { - BearerToken, -} - -export class RbacAuthorizationApi { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; + /** + * delete a ClusterRoleBinding + * @param name name of the ClusterRoleBinding + * @param body + * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + */ + public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); } - } - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } - - set basePath(basePath: string) { - this._basePath = basePath; - } + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); + } - get basePath() { - return this._basePath; - } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } - public setApiKey(key: RbacAuthorizationApiApiKeys, value: string) { - this.authentications[RbacAuthorizationApiApiKeys[key]].apiKey = value; - } - /** - * get information of a group - */ - public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53722,7 +62031,7 @@ export class RbacAuthorizationApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53736,84 +62045,70 @@ export class RbacAuthorizationApi { }); }); } -} -export enum RbacAuthorization_v1ApiApiKeys { - BearerToken, -} - -export class RbacAuthorization_v1Api { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; + /** + * delete collection of ClusterRole + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - } - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } - set basePath(basePath: string) { - this._basePath = basePath; - } + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } - get basePath() { - return this._basePath; - } + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - public setApiKey(key: RbacAuthorization_v1ApiApiKeys, value: string) { - this.authentications[RbacAuthorization_v1ApiApiKeys[key]].apiKey = value; - } - /** - * create a ClusterRole - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public createClusterRole (body: V1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53827,7 +62122,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53842,36 +62137,69 @@ export class RbacAuthorization_v1Api { }); } /** - * create a ClusterRoleBinding - * @param body + * delete collection of ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createClusterRoleBinding (body: V1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { + public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53885,7 +62213,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53900,12 +62228,19 @@ export class RbacAuthorization_v1Api { }); } /** - * create a Role + * delete collection of Role * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedRole (namespace: string, body: V1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { + public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -53915,28 +62250,54 @@ export class RbacAuthorization_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -53950,7 +62311,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -53965,12 +62326,19 @@ export class RbacAuthorization_v1Api { }); } /** - * create a RoleBinding + * delete collection of RoleBinding * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedRoleBinding (namespace: string, body: V1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { + public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -53980,28 +62348,54 @@ export class RbacAuthorization_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54015,7 +62409,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54030,17 +62424,19 @@ export class RbacAuthorization_v1Api { }); } /** - * delete a ClusterRole - * @param name name of the ClusterRole + * delete a Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -54048,12 +62444,17 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); } if (pretty !== undefined) { @@ -54110,17 +62511,19 @@ export class RbacAuthorization_v1Api { }); } /** - * delete a ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * delete a RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -54128,12 +62531,17 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -54190,7 +62598,53 @@ export class RbacAuthorization_v1Api { }); } /** - * delete collection of ClusterRole + * get available resources + */ + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ClusterRole * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -54201,7 +62655,7 @@ export class RbacAuthorization_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -54247,7 +62701,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -54266,7 +62720,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54281,7 +62735,7 @@ export class RbacAuthorization_v1Api { }); } /** - * delete collection of ClusterRoleBinding + * list or watch objects of kind ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -54292,7 +62746,7 @@ export class RbacAuthorization_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBindingList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -54338,7 +62792,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -54357,7 +62811,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54372,7 +62826,7 @@ export class RbacAuthorization_v1Api { }); } /** - * delete collection of Role + * list or watch objects of kind Role * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -54384,7 +62838,7 @@ export class RbacAuthorization_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -54394,7 +62848,7 @@ export class RbacAuthorization_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); } if (pretty !== undefined) { @@ -54436,7 +62890,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -54455,7 +62909,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54470,7 +62924,7 @@ export class RbacAuthorization_v1Api { }); } /** - * delete collection of RoleBinding + * list or watch objects of kind RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -54482,7 +62936,7 @@ export class RbacAuthorization_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -54492,7 +62946,7 @@ export class RbacAuthorization_v1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -54534,7 +62988,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -54553,7 +63007,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54568,65 +63022,69 @@ export class RbacAuthorization_v1Api { }); } /** - * delete a Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind RoleBinding + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/rolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54640,7 +63098,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54655,65 +63113,69 @@ export class RbacAuthorization_v1Api { }); } /** - * delete a RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Role + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/roles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54727,7 +63189,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54742,24 +63204,43 @@ export class RbacAuthorization_v1Api { }); } /** - * get available resources + * partially update the specified ClusterRole + * @param name name of the ClusterRole + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/'; + public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54773,7 +63254,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54788,69 +63269,43 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind ClusterRole + * partially update the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles'; + public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54864,7 +63319,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54879,69 +63334,50 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind ClusterRoleBinding + * partially update the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings'; + public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -54955,7 +63391,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -54970,76 +63406,50 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind Role + * partially update the specified RoleBinding + * @param name name of the RoleBinding * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles' + public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55053,7 +63463,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55068,67 +63478,27 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * read the specified ClusterRole + * @param name name of the ClusterRole * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings' - .replace('{' + 'namespace' + '}', String(namespace)); + public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -55151,7 +63521,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55166,60 +63536,27 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/rolebindings'; + public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -55242,7 +63579,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55257,60 +63594,34 @@ export class RbacAuthorization_v1Api { }); } /** - * list or watch objects of kind Role - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/roles'; + public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -55333,7 +63644,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55348,14 +63659,15 @@ export class RbacAuthorization_v1Api { }); } /** - * partially update the specified ClusterRole - * @param name name of the ClusterRole - * @param body + * read the specified RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -55363,12 +63675,12 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -55378,13 +63690,12 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55398,7 +63709,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55413,13 +63724,13 @@ export class RbacAuthorization_v1Api { }); } /** - * partially update the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * replace the specified ClusterRole + * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + public replaceClusterRole (name: string, body: V1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -55428,12 +63739,12 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); } if (pretty !== undefined) { @@ -55443,7 +63754,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -55463,7 +63774,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55478,16 +63789,14 @@ export class RbacAuthorization_v1Api { }); } /** - * partially update the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects + * replace the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replaceClusterRoleBinding (name: string, body: V1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -55495,17 +63804,12 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); } if (pretty !== undefined) { @@ -55515,7 +63819,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -55535,7 +63839,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55550,14 +63854,14 @@ export class RbacAuthorization_v1Api { }); } /** - * partially update the specified RoleBinding - * @param name name of the RoleBinding + * replace the specified Role + * @param name name of the Role * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' + public replaceNamespacedRole (name: string, namespace: string, body: V1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -55567,17 +63871,17 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); } if (pretty !== undefined) { @@ -55587,7 +63891,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -55607,7 +63911,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55622,13 +63926,16 @@ export class RbacAuthorization_v1Api { }); } /** - * read the specified ClusterRole - * @param name name of the ClusterRole + * replace the specified RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -55636,7 +63943,17 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -55646,12 +63963,13 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55665,7 +63983,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55679,22 +63997,68 @@ export class RbacAuthorization_v1Api { }); }); } +} +export enum RbacAuthorization_v1alpha1ApiApiKeys { + BearerToken, +} + +export class RbacAuthorization_v1alpha1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: RbacAuthorization_v1alpha1ApiApiKeys, value: string) { + this.authentications[RbacAuthorization_v1alpha1ApiApiKeys[key]].apiKey = value; + } /** - * read the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * create a ClusterRole + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public createClusterRole (body: V1alpha1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); } if (pretty !== undefined) { @@ -55704,12 +64068,13 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55723,7 +64088,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55738,28 +64103,20 @@ export class RbacAuthorization_v1Api { }); } /** - * read the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects + * create a ClusterRoleBinding + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public createClusterRoleBinding (body: V1alpha1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); } if (pretty !== undefined) { @@ -55769,12 +64126,13 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55788,7 +64146,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55803,28 +64161,27 @@ export class RbacAuthorization_v1Api { }); } /** - * read the specified RoleBinding - * @param name name of the RoleBinding + * create a Role * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedRole (namespace: string, body: V1alpha1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); } if (pretty !== undefined) { @@ -55834,12 +64191,13 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -55853,7 +64211,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55868,27 +64226,27 @@ export class RbacAuthorization_v1Api { }); } /** - * replace the specified ClusterRole - * @param name name of the ClusterRole + * create a RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceClusterRole (name: string, body: V1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public createNamespacedRoleBinding (namespace: string, body: V1alpha1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -55898,7 +64256,7 @@ export class RbacAuthorization_v1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -55918,7 +64276,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55933,13 +64291,16 @@ export class RbacAuthorization_v1Api { }); } /** - * replace the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * delete a ClusterRole + * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public replaceClusterRoleBinding (name: string, body: V1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/clusterrolebindings/{name}' + public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -55948,22 +64309,34 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -55983,7 +64356,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -55998,16 +64371,17 @@ export class RbacAuthorization_v1Api { }); } /** - * replace the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects + * delete a ClusterRoleBinding + * @param name name of the ClusterRoleBinding * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public replaceNamespacedRole (name: string, namespace: string, body: V1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -56015,27 +64389,34 @@ export class RbacAuthorization_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); + throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -56055,7 +64436,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56070,50 +64451,69 @@ export class RbacAuthorization_v1Api { }); } /** - * replace the specified RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * delete collection of ClusterRole * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -56127,7 +64527,7 @@ export class RbacAuthorization_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56141,142 +64541,70 @@ export class RbacAuthorization_v1Api { }); }); } -} -export enum RbacAuthorization_v1alpha1ApiApiKeys { - BearerToken, -} - -export class RbacAuthorization_v1alpha1Api { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; - - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } - } - } - - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } - - set basePath(basePath: string) { - this._basePath = basePath; - } - - get basePath() { - return this._basePath; - } - - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } - - public setApiKey(key: RbacAuthorization_v1alpha1ApiApiKeys, value: string) { - this.authentications[RbacAuthorization_v1alpha1ApiApiKeys[key]].apiKey = value; - } /** - * create a ClusterRole - * @param body + * delete collection of ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createClusterRole (body: V1alpha1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles'; + public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - let useFormData = false; + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } - let requestOptions: request.Options = { - method: 'POST', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } - this.authentications.BearerToken.applyToRequest(requestOptions); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } - this.authentications.default.applyToRequest(requestOptions); + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } + if (limit !== undefined) { + queryParameters['limit'] = limit; } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * create a ClusterRoleBinding - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public createClusterRoleBinding (body: V1alpha1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -56290,7 +64618,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56305,12 +64633,19 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * create a Role + * delete collection of Role * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedRole (namespace: string, body: V1alpha1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { + public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -56320,28 +64655,54 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -56355,7 +64716,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56370,12 +64731,19 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * create a RoleBinding + * delete collection of RoleBinding * @param namespace object name and auth scope, such as for teams and projects - * @param body * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createNamespacedRoleBinding (namespace: string, body: V1alpha1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { + public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -56385,28 +64753,54 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -56420,7 +64814,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56435,17 +64829,19 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete a ClusterRole - * @param name name of the ClusterRole + * delete a Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -56453,12 +64849,17 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); } if (pretty !== undefined) { @@ -56515,17 +64916,19 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete a ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * delete a RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -56533,12 +64936,17 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -56595,7 +65003,53 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete collection of ClusterRole + * get available resources + */ + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind ClusterRole * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -56606,7 +65060,7 @@ export class RbacAuthorization_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -56652,7 +65106,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -56671,7 +65125,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56686,7 +65140,7 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete collection of ClusterRoleBinding + * list or watch objects of kind ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -56697,7 +65151,7 @@ export class RbacAuthorization_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBindingList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -56743,7 +65197,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -56762,7 +65216,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56777,7 +65231,7 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete collection of Role + * list or watch objects of kind Role * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -56789,7 +65243,7 @@ export class RbacAuthorization_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -56799,7 +65253,7 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); } if (pretty !== undefined) { @@ -56841,7 +65295,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -56860,7 +65314,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56875,7 +65329,7 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete collection of RoleBinding + * list or watch objects of kind RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -56887,7 +65341,7 @@ export class RbacAuthorization_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; @@ -56897,7 +65351,7 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -56939,7 +65393,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -56958,7 +65412,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -56973,65 +65427,69 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete a Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind RoleBinding + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/rolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57045,7 +65503,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57060,65 +65518,69 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * delete a RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Role + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/roles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57132,7 +65594,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57147,24 +65609,43 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * get available resources + * partially update the specified ClusterRole + * @param name name of the ClusterRole + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/'; + public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57178,7 +65659,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57193,69 +65674,43 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind ClusterRole + * partially update the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles'; + public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57269,7 +65724,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57284,69 +65739,50 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind ClusterRoleBinding + * partially update the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings'; + public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57360,7 +65796,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57375,76 +65811,50 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind Role + * partially update the specified RoleBinding + * @param name name of the RoleBinding * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles' + public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -57458,7 +65868,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57473,67 +65883,27 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * read the specified ClusterRole + * @param name name of the ClusterRole * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings' - .replace('{' + 'namespace' + '}', String(namespace)); + public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -57556,7 +65926,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57571,58 +65941,90 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/rolebindings'; + public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); } - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } + let useFormData = false; - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; - if (limit !== undefined) { - queryParameters['limit'] = limit; - } + this.authentications.BearerToken.applyToRequest(requestOptions); - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } } + return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * read the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + */ + public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; @@ -57647,7 +66049,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57662,60 +66064,34 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * list or watch objects of kind Role - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/roles'; + public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -57738,7 +66114,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -57753,12 +66129,12 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * partially update the specified ClusterRole + * replace the specified ClusterRole * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { + public replaceClusterRole (name: string, body: V1alpha1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -57768,12 +66144,12 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); } if (pretty !== undefined) { @@ -57783,7 +66159,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -57818,12 +66194,12 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * partially update the specified ClusterRoleBinding + * replace the specified ClusterRoleBinding * @param name name of the ClusterRoleBinding * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { + public replaceClusterRoleBinding (name: string, body: V1alpha1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -57833,12 +66209,12 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); } if (pretty !== undefined) { @@ -57848,7 +66224,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -57883,13 +66259,13 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * partially update the specified Role + * replace the specified Role * @param name name of the Role * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { + public replaceNamespacedRole (name: string, namespace: string, body: V1alpha1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -57900,17 +66276,17 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); } if (pretty !== undefined) { @@ -57920,7 +66296,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -57955,13 +66331,13 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * partially update the specified RoleBinding + * replace the specified RoleBinding * @param name name of the RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { + public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1alpha1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -57972,17 +66348,17 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -57992,7 +66368,7 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -58026,22 +66402,68 @@ export class RbacAuthorization_v1alpha1Api { }); }); } +} +export enum RbacAuthorization_v1beta1ApiApiKeys { + BearerToken, +} + +export class RbacAuthorization_v1beta1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: RbacAuthorization_v1beta1ApiApiKeys, value: string) { + this.authentications[RbacAuthorization_v1beta1ApiApiKeys[key]].apiKey = value; + } /** - * read the specified ClusterRole - * @param name name of the ClusterRole + * create a ClusterRole + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public createClusterRole (body: V1beta1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); } if (pretty !== undefined) { @@ -58051,12 +66473,13 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58070,7 +66493,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58085,21 +66508,20 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * read the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * create a ClusterRoleBinding + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public createClusterRoleBinding (body: V1beta1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); } if (pretty !== undefined) { @@ -58109,12 +66531,13 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58128,7 +66551,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58143,28 +66566,27 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * read the specified Role - * @param name name of the Role + * create a Role * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedRole (namespace: string, body: V1beta1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); } if (pretty !== undefined) { @@ -58174,12 +66596,13 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58193,7 +66616,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58208,28 +66631,27 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * read the specified RoleBinding - * @param name name of the RoleBinding + * create a RoleBinding * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) + public createNamespacedRoleBinding (namespace: string, body: V1beta1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); - } - // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -58239,12 +66661,13 @@ export class RbacAuthorization_v1alpha1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58258,7 +66681,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58273,13 +66696,16 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * replace the specified ClusterRole + * delete a ClusterRole * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public replaceClusterRole (name: string, body: V1alpha1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/{name}' + public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -58288,22 +66714,34 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -58323,7 +66761,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58338,13 +66776,16 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * replace the specified ClusterRoleBinding + * delete a ClusterRoleBinding * @param name name of the ClusterRoleBinding * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public replaceClusterRoleBinding (name: string, body: V1alpha1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/clusterrolebindings/{name}' + public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -58353,22 +66794,34 @@ export class RbacAuthorization_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -58388,7 +66841,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58403,50 +66856,69 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * replace the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * delete collection of ClusterRole * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public replaceNamespacedRole (name: string, namespace: string, body: V1alpha1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58460,7 +66932,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58475,50 +66947,69 @@ export class RbacAuthorization_v1alpha1Api { }); } /** - * replace the specified RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * delete collection of ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1alpha1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1alpha1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58532,7 +67023,7 @@ export class RbacAuthorization_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58546,84 +67037,77 @@ export class RbacAuthorization_v1alpha1Api { }); }); } -} -export enum RbacAuthorization_v1beta1ApiApiKeys { - BearerToken, -} + /** + * delete collection of Role + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; -export class RbacAuthorization_v1beta1Api { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); + } - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - } - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } - set basePath(basePath: string) { - this._basePath = basePath; - } + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } - get basePath() { - return this._basePath; - } + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } - public setApiKey(key: RbacAuthorization_v1beta1ApiApiKeys, value: string) { - this.authentications[RbacAuthorization_v1beta1ApiApiKeys[key]].apiKey = value; - } - /** - * create a ClusterRole - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public createClusterRole (body: V1beta1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRole.'); + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58637,7 +67121,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58652,36 +67136,76 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * create a ClusterRoleBinding - * @param body + * delete collection of RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public createClusterRoleBinding (body: V1beta1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; + public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createClusterRoleBinding.'); + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58695,7 +67219,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58710,37 +67234,59 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * create a Role + * delete a Role + * @param name name of the Role * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public createNamespacedRole (namespace: string, body: V1beta1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' + public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + } + // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRole.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -58760,7 +67306,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58775,37 +67321,59 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * create a RoleBinding + * delete a RoleBinding + * @param name name of the RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public createNamespacedRoleBinding (namespace: string, body: V1beta1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' + public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); + } + // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'POST', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -58825,7 +67393,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58840,58 +67408,24 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete a ClusterRole - * @param name name of the ClusterRole - * @param body - * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * get available resources */ - public deleteClusterRole (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRole.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRole.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; - } - - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; - } + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; - } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58905,7 +67439,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -58920,58 +67454,69 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete a ClusterRoleBinding - * @param name name of the ClusterRoleBinding - * @param body + * list or watch objects of kind ClusterRole * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteClusterRoleBinding (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteClusterRoleBinding.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteClusterRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -58985,7 +67530,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59000,7 +67545,7 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete collection of ClusterRole + * list or watch objects of kind ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -59011,8 +67556,8 @@ export class RbacAuthorization_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; + public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBindingList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -59057,7 +67602,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -59076,7 +67621,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59091,7 +67636,8 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete collection of ClusterRoleBinding + * list or watch objects of kind Role + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -59102,13 +67648,19 @@ export class RbacAuthorization_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; + public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); + } + if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -59148,7 +67700,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -59167,7 +67719,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59182,7 +67734,7 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete collection of Role + * list or watch objects of kind RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. @@ -59194,8 +67746,8 @@ export class RbacAuthorization_v1beta1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' + public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -59204,7 +67756,7 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -59246,7 +67798,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -59265,7 +67817,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59280,35 +67832,24 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete collection of RoleBinding - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind RoleBinding * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/rolebindings'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedRoleBinding.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -59329,6 +67870,10 @@ export class RbacAuthorization_v1beta1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -59344,7 +67889,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -59363,7 +67908,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59378,65 +67923,69 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete a Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind Role + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteNamespacedRole (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/roles'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRole.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRole.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRole.'); + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; } - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; } - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -59450,7 +67999,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59465,19 +68014,14 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * delete a RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * partially update the specified ClusterRole + * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. - * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. */ - public deleteNamespacedRoleBinding (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -59485,39 +68029,22 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedRoleBinding.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (gracePeriodSeconds !== undefined) { - queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; - } - - if (orphanDependents !== undefined) { - queryParameters['orphanDependents'] = orphanDependents; - } - - if (propagationPolicy !== undefined) { - queryParameters['propagationPolicy'] = propagationPolicy; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'DELETE', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -59537,7 +68064,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59552,24 +68079,43 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * get available resources + * partially update the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/'; + public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -59583,7 +68129,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59598,69 +68144,50 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind ClusterRole + * partially update the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRole (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles'; + public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -59674,7 +68201,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59689,69 +68216,50 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind ClusterRoleBinding + * partially update the specified RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listClusterRoleBinding (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings'; + public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); } - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); } - if (watch !== undefined) { - queryParameters['watch'] = watch; + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -59765,7 +68273,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59780,67 +68288,27 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind Role - * @param namespace object name and auth scope, such as for teams and projects + * read the specified ClusterRole + * @param name name of the ClusterRole * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRole (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles' - .replace('{' + 'namespace' + '}', String(namespace)); + public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRole.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -59863,7 +68331,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59878,65 +68346,25 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * read the specified ClusterRoleBinding + * @param name name of the ClusterRoleBinding * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listNamespacedRoleBinding (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings' - .replace('{' + 'namespace' + '}', String(namespace)); + public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedRoleBinding.'); + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); } if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; + queryParameters['pretty'] = pretty; } let useFormData = false; @@ -59961,7 +68389,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -59976,60 +68404,34 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind RoleBinding - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified Role + * @param name name of the Role + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleBindingForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/rolebindings'; + public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -60052,7 +68454,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBindingList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60067,60 +68469,34 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * list or watch objects of kind Role - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * read the specified RoleBinding + * @param name name of the RoleBinding + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listRoleForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/roles'; + public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { + const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); } - if (limit !== undefined) { - queryParameters['limit'] = limit; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -60143,7 +68519,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60158,12 +68534,12 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * partially update the specified ClusterRole + * replace the specified ClusterRole * @param name name of the ClusterRole * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRole (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { + public replaceClusterRole (name: string, body: V1beta1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -60173,12 +68549,12 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); } if (pretty !== undefined) { @@ -60188,7 +68564,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60223,12 +68599,12 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * partially update the specified ClusterRoleBinding + * replace the specified ClusterRoleBinding * @param name name of the ClusterRoleBinding * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchClusterRoleBinding (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { + public replaceClusterRoleBinding (name: string, body: V1beta1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; @@ -60238,12 +68614,12 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchClusterRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); } if (pretty !== undefined) { @@ -60253,7 +68629,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60288,13 +68664,13 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * partially update the specified Role + * replace the specified Role * @param name name of the Role * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRole (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { + public replaceNamespacedRole (name: string, namespace: string, body: V1beta1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -60305,17 +68681,17 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRole.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); } if (pretty !== undefined) { @@ -60325,7 +68701,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60360,13 +68736,13 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * partially update the specified RoleBinding + * replace the specified RoleBinding * @param name name of the RoleBinding * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchNamespacedRoleBinding (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { + public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1beta1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' .replace('{' + 'name' + '}', String(name)) .replace('{' + 'namespace' + '}', String(namespace)); @@ -60377,17 +68753,17 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); } // verify required parameter 'namespace' is not null or undefined if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); } if (pretty !== undefined) { @@ -60397,7 +68773,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60431,22 +68807,161 @@ export class RbacAuthorization_v1beta1Api { }); }); } +} +export enum SchedulingApiApiKeys { + BearerToken, +} + +export class SchedulingApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: SchedulingApiApiKeys, value: string) { + this.authentications[SchedulingApiApiKeys[key]].apiKey = value; + } /** - * read the specified ClusterRole - * @param name name of the ClusterRole + * get information of a group + */ + public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} +export enum Scheduling_v1alpha1ApiApiKeys { + BearerToken, +} + +export class Scheduling_v1alpha1Api { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + 'BearerToken': new ApiKeyAuth('header', 'authorization'), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: Scheduling_v1alpha1ApiApiKeys, value: string) { + this.authentications[Scheduling_v1alpha1ApiApiKeys[key]].apiKey = value; + } + /** + * create a PriorityClass + * @param body * @param pretty If 'true', then the output is pretty printed. */ - public readClusterRole (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' - .replace('{' + 'name' + '}', String(name)); + public createPriorityClass (body: V1alpha1PriorityClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRole.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling createPriorityClass.'); } if (pretty !== undefined) { @@ -60456,12 +68971,13 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'POST', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -60475,7 +68991,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60490,31 +69006,64 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * read the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding + * delete collection of PriorityClass * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public readClusterRoleBinding (name: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteCollectionPriorityClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readClusterRoleBinding.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'DELETE', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60533,7 +69082,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60548,15 +69097,17 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * read the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects + * delete a PriorityClass + * @param name name of the PriorityClass + * @param body * @param pretty If 'true', then the output is pretty printed. + * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public readNamespacedRole (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deletePriorityClass (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -60564,18 +69115,77 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRole.'); + throw new Error('Required parameter name was null or undefined when calling deletePriorityClass.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRole.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling deletePriorityClass.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } + if (gracePeriodSeconds !== undefined) { + queryParameters['gracePeriodSeconds'] = gracePeriodSeconds; + } + + if (orphanDependents !== undefined) { + queryParameters['orphanDependents'] = orphanDependents; + } + + if (propagationPolicy !== undefined) { + queryParameters['propagationPolicy'] = propagationPolicy; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'DELETE', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: body, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1Status; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * get available resources + */ + public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/'; + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + let useFormData = false; let requestOptions: request.Options = { @@ -60598,7 +69208,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60613,32 +69223,58 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * read the specified RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * list or watch objects of kind PriorityClass * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public readNamespacedRoleBinding (name: string, namespace: string, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listPriorityClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClassList; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedRoleBinding.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedRoleBinding.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; @@ -60663,7 +69299,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClassList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60678,13 +69314,13 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * replace the specified ClusterRole - * @param name name of the ClusterRole + * partially update the specified PriorityClass + * @param name name of the PriorityClass * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceClusterRole (name: string, body: V1beta1ClusterRole, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/{name}' + public patchPriorityClass (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -60693,12 +69329,12 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRole.'); + throw new Error('Required parameter name was null or undefined when calling patchPriorityClass.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRole.'); + throw new Error('Required parameter body was null or undefined when calling patchPriorityClass.'); } if (pretty !== undefined) { @@ -60708,7 +69344,7 @@ export class RbacAuthorization_v1beta1Api { let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, @@ -60728,7 +69364,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRole; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60743,13 +69379,14 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * replace the specified ClusterRoleBinding - * @param name name of the ClusterRoleBinding - * @param body + * read the specified PriorityClass + * @param name name of the PriorityClass * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public replaceClusterRoleBinding (name: string, body: V1beta1ClusterRoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/clusterrolebindings/{name}' + public readPriorityClass (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -60758,100 +69395,30 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceClusterRoleBinding.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceClusterRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling readPriorityClass.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - let useFormData = false; - - let requestOptions: request.Options = { - method: 'PUT', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - body: body, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1beta1ClusterRoleBinding; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * replace the specified Role - * @param name name of the Role - * @param namespace object name and auth scope, such as for teams and projects - * @param body - * @param pretty If 'true', then the output is pretty printed. - */ - public replaceNamespacedRole (name: string, namespace: string, body: V1beta1Role, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1Role; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/roles/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRole.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRole.'); - } - - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRole.'); + if (exact !== undefined) { + queryParameters['exact'] = exact; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -60865,7 +69432,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1Role; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60880,16 +69447,14 @@ export class RbacAuthorization_v1beta1Api { }); } /** - * replace the specified RoleBinding - * @param name name of the RoleBinding - * @param namespace object name and auth scope, such as for teams and projects + * replace the specified PriorityClass + * @param name name of the PriorityClass * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceNamespacedRoleBinding (name: string, namespace: string, body: V1beta1RoleBinding, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }> { - const localVarPath = this.basePath + '/apis/rbac.authorization.k8s.io/v1beta1/namespaces/{namespace}/rolebindings/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public replacePriorityClass (name: string, body: V1alpha1PriorityClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { + const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -60897,17 +69462,12 @@ export class RbacAuthorization_v1beta1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedRoleBinding.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedRoleBinding.'); + throw new Error('Required parameter name was null or undefined when calling replacePriorityClass.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedRoleBinding.'); + throw new Error('Required parameter body was null or undefined when calling replacePriorityClass.'); } if (pretty !== undefined) { @@ -60937,7 +69497,7 @@ export class RbacAuthorization_v1beta1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1beta1RoleBinding; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -60952,11 +69512,11 @@ export class RbacAuthorization_v1beta1Api { }); } } -export enum SchedulingApiApiKeys { +export enum SettingsApiApiKeys { BearerToken, } -export class SchedulingApi { +export class SettingsApi { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -60995,14 +69555,14 @@ export class SchedulingApi { this.authentications.default = auth; } - public setApiKey(key: SchedulingApiApiKeys, value: string) { - this.authentications[SchedulingApiApiKeys[key]].apiKey = value; + public setApiKey(key: SettingsApiApiKeys, value: string) { + this.authentications[SettingsApiApiKeys[key]].apiKey = value; } /** * get information of a group */ public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/'; + const localVarPath = this.basePath + '/apis/settings.k8s.io/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61045,11 +69605,11 @@ export class SchedulingApi { }); } } -export enum Scheduling_v1alpha1ApiApiKeys { +export enum Settings_v1alpha1ApiApiKeys { BearerToken, } -export class Scheduling_v1alpha1Api { +export class Settings_v1alpha1Api { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -61088,24 +69648,31 @@ export class Scheduling_v1alpha1Api { this.authentications.default = auth; } - public setApiKey(key: Scheduling_v1alpha1ApiApiKeys, value: string) { - this.authentications[Scheduling_v1alpha1ApiApiKeys[key]].apiKey = value; + public setApiKey(key: Settings_v1alpha1ApiApiKeys, value: string) { + this.authentications[Settings_v1alpha1ApiApiKeys[key]].apiKey = value; } /** - * create a PriorityClass + * create a PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createPriorityClass (body: V1alpha1PriorityClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; + public createNamespacedPodPreset (namespace: string, body: V1alpha1PodPreset, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodPreset.'); + } + // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createPriorityClass.'); + throw new Error('Required parameter body was null or undefined when calling createNamespacedPodPreset.'); } if (pretty !== undefined) { @@ -61135,7 +69702,7 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61150,7 +69717,8 @@ export class Scheduling_v1alpha1Api { }); } /** - * delete collection of PriorityClass + * delete collection of PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -61161,13 +69729,19 @@ export class Scheduling_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionPriorityClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; + public deleteCollectionNamespacedPodPreset (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPodPreset.'); + } + if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -61241,17 +69815,19 @@ export class Scheduling_v1alpha1Api { }); } /** - * delete a PriorityClass - * @param name name of the PriorityClass + * delete a PodPreset + * @param name name of the PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deletePriorityClass (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' - .replace('{' + 'name' + '}', String(name)); + public deleteNamespacedPodPreset (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61259,12 +69835,17 @@ export class Scheduling_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deletePriorityClass.'); + throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPodPreset.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPodPreset.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deletePriorityClass.'); + throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPodPreset.'); } if (pretty !== undefined) { @@ -61324,7 +69905,7 @@ export class Scheduling_v1alpha1Api { * get available resources */ public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/'; + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61352,7 +69933,105 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { + request(requestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * list or watch objects of kind PodPreset + * @param namespace object name and auth scope, such as for teams and projects + * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + */ + public listNamespacedPodPreset (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' + .replace('{' + 'namespace' + '}', String(namespace)); + let queryParameters: any = {}; + let headerParams: any = (Object).assign({}, this.defaultHeaders); + let formParams: any = {}; + + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPodPreset.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + + if (_continue !== undefined) { + queryParameters['continue'] = _continue; + } + + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; + } + + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; + } + + let useFormData = false; + + let requestOptions: request.Options = { + method: 'GET', + qs: queryParameters, + headers: headerParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.BearerToken.applyToRequest(requestOptions); + + this.authentications.default.applyToRequest(requestOptions); + + if (Object.keys(formParams).length) { + if (useFormData) { + (requestOptions).formData = formParams; + } else { + requestOptions.form = formParams; + } + } + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61367,28 +70046,24 @@ export class Scheduling_v1alpha1Api { }); } /** - * list or watch objects of kind PriorityClass - * @param pretty If 'true', then the output is pretty printed. + * list or watch objects of kind PodPreset * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. * @param includeUninitialized If true, partially initialized resources are included in the response. * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param pretty If 'true', then the output is pretty printed. * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listPriorityClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClassList; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses'; + public listPodPresetForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/podpresets'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - if (_continue !== undefined) { queryParameters['continue'] = _continue; } @@ -61409,6 +70084,10 @@ export class Scheduling_v1alpha1Api { queryParameters['limit'] = limit; } + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + if (resourceVersion !== undefined) { queryParameters['resourceVersion'] = resourceVersion; } @@ -61443,7 +70122,7 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClassList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61458,14 +70137,16 @@ export class Scheduling_v1alpha1Api { }); } /** - * partially update the specified PriorityClass - * @param name name of the PriorityClass + * partially update the specified PodPreset + * @param name name of the PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchPriorityClass (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' - .replace('{' + 'name' + '}', String(name)); + public patchNamespacedPodPreset (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61473,12 +70154,17 @@ export class Scheduling_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchPriorityClass.'); + throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodPreset.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodPreset.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchPriorityClass.'); + throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodPreset.'); } if (pretty !== undefined) { @@ -61508,7 +70194,7 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61523,15 +70209,17 @@ export class Scheduling_v1alpha1Api { }); } /** - * read the specified PriorityClass - * @param name name of the PriorityClass + * read the specified PodPreset + * @param name name of the PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readPriorityClass (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' - .replace('{' + 'name' + '}', String(name)); + public readNamespacedPodPreset (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61539,7 +70227,12 @@ export class Scheduling_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readPriorityClass.'); + throw new Error('Required parameter name was null or undefined when calling readNamespacedPodPreset.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodPreset.'); } if (pretty !== undefined) { @@ -61576,7 +70269,7 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61591,14 +70284,16 @@ export class Scheduling_v1alpha1Api { }); } /** - * replace the specified PriorityClass - * @param name name of the PriorityClass + * replace the specified PodPreset + * @param name name of the PodPreset + * @param namespace object name and auth scope, such as for teams and projects * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replacePriorityClass (name: string, body: V1alpha1PriorityClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }> { - const localVarPath = this.basePath + '/apis/scheduling.k8s.io/v1alpha1/priorityclasses/{name}' - .replace('{' + 'name' + '}', String(name)); + public replaceNamespacedPodPreset (name: string, namespace: string, body: V1alpha1PodPreset, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { + const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' + .replace('{' + 'name' + '}', String(name)) + .replace('{' + 'namespace' + '}', String(namespace)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61606,12 +70301,17 @@ export class Scheduling_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replacePriorityClass.'); + throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodPreset.'); + } + + // verify required parameter 'namespace' is not null or undefined + if (namespace === null || namespace === undefined) { + throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodPreset.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replacePriorityClass.'); + throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodPreset.'); } if (pretty !== undefined) { @@ -61641,7 +70341,7 @@ export class Scheduling_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PriorityClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61656,11 +70356,11 @@ export class Scheduling_v1alpha1Api { }); } } -export enum SettingsApiApiKeys { +export enum StorageApiApiKeys { BearerToken, } -export class SettingsApi { +export class StorageApi { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -61699,14 +70399,14 @@ export class SettingsApi { this.authentications.default = auth; } - public setApiKey(key: SettingsApiApiKeys, value: string) { - this.authentications[SettingsApiApiKeys[key]].apiKey = value; + public setApiKey(key: StorageApiApiKeys, value: string) { + this.authentications[StorageApiApiKeys[key]].apiKey = value; } /** * get information of a group */ public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/'; + const localVarPath = this.basePath + '/apis/storage.k8s.io/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61749,11 +70449,11 @@ export class SettingsApi { }); } } -export enum Settings_v1alpha1ApiApiKeys { +export enum Storage_v1ApiApiKeys { BearerToken, } -export class Settings_v1alpha1Api { +export class Storage_v1Api { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -61792,31 +70492,24 @@ export class Settings_v1alpha1Api { this.authentications.default = auth; } - public setApiKey(key: Settings_v1alpha1ApiApiKeys, value: string) { - this.authentications[Settings_v1alpha1ApiApiKeys[key]].apiKey = value; + public setApiKey(key: Storage_v1ApiApiKeys, value: string) { + this.authentications[Storage_v1ApiApiKeys[key]].apiKey = value; } /** - * create a PodPreset - * @param namespace object name and auth scope, such as for teams and projects + * create a StorageClass * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createNamespacedPodPreset (namespace: string, body: V1alpha1PodPreset, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' - .replace('{' + 'namespace' + '}', String(namespace)); + public createStorageClass (body: V1StorageClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling createNamespacedPodPreset.'); - } - // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createNamespacedPodPreset.'); + throw new Error('Required parameter body was null or undefined when calling createStorageClass.'); } if (pretty !== undefined) { @@ -61846,7 +70539,7 @@ export class Settings_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -61861,8 +70554,7 @@ export class Settings_v1alpha1Api { }); } /** - * delete collection of PodPreset - * @param namespace object name and auth scope, such as for teams and projects + * delete collection of StorageClass * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -61873,19 +70565,13 @@ export class Settings_v1alpha1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionNamespacedPodPreset (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteCollectionStorageClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteCollectionNamespacedPodPreset.'); - } - if (pretty !== undefined) { queryParameters['pretty'] = pretty; } @@ -61959,19 +70645,17 @@ export class Settings_v1alpha1Api { }); } /** - * delete a PodPreset - * @param name name of the PodPreset - * @param namespace object name and auth scope, such as for teams and projects + * delete a StorageClass + * @param name name of the StorageClass * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteNamespacedPodPreset (name: string, namespace: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public deleteStorageClass (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -61979,17 +70663,12 @@ export class Settings_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteNamespacedPodPreset.'); - } - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling deleteNamespacedPodPreset.'); + throw new Error('Required parameter name was null or undefined when calling deleteStorageClass.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteNamespacedPodPreset.'); + throw new Error('Required parameter body was null or undefined when calling deleteStorageClass.'); } if (pretty !== undefined) { @@ -62049,201 +70728,12 @@ export class Settings_v1alpha1Api { * get available resources */ public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/'; - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'GET', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * list or watch objects of kind PodPreset - * @param namespace object name and auth scope, such as for teams and projects - * @param pretty If 'true', then the output is pretty printed. - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - */ - public listNamespacedPodPreset (namespace: string, pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets' - .replace('{' + 'namespace' + '}', String(namespace)); - let queryParameters: any = {}; - let headerParams: any = (Object).assign({}, this.defaultHeaders); - let formParams: any = {}; - - - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling listNamespacedPodPreset.'); - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - - let useFormData = false; - - let requestOptions: request.Options = { - method: 'GET', - qs: queryParameters, - headers: headerParams, - uri: localVarPath, - useQuerystring: this._useQuerystring, - json: true, - }; - - this.authentications.BearerToken.applyToRequest(requestOptions); - - this.authentications.default.applyToRequest(requestOptions); - - if (Object.keys(formParams).length) { - if (useFormData) { - (requestOptions).formData = formParams; - } else { - requestOptions.form = formParams; - } - } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }>((resolve, reject) => { - request(requestOptions, (error, response, body) => { - if (error) { - reject(error); - } else { - if (response.statusCode >= 200 && response.statusCode <= 299) { - resolve({ response: response, body: body }); - } else { - reject({ response: response, body: body }); - } - } - }); - }); - } - /** - * list or watch objects of kind PodPreset - * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. - * @param includeUninitialized If true, partially initialized resources are included in the response. - * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. - * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - * @param pretty If 'true', then the output is pretty printed. - * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. - * @param timeoutSeconds Timeout for the list/watch call. - * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - */ - public listPodPresetForAllNamespaces (_continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, pretty?: string, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/podpresets'; + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - if (_continue !== undefined) { - queryParameters['continue'] = _continue; - } - - if (fieldSelector !== undefined) { - queryParameters['fieldSelector'] = fieldSelector; - } - - if (includeUninitialized !== undefined) { - queryParameters['includeUninitialized'] = includeUninitialized; - } - - if (labelSelector !== undefined) { - queryParameters['labelSelector'] = labelSelector; - } - - if (limit !== undefined) { - queryParameters['limit'] = limit; - } - - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; - } - - if (resourceVersion !== undefined) { - queryParameters['resourceVersion'] = resourceVersion; - } - - if (timeoutSeconds !== undefined) { - queryParameters['timeoutSeconds'] = timeoutSeconds; - } - - if (watch !== undefined) { - queryParameters['watch'] = watch; - } - let useFormData = false; let requestOptions: request.Options = { @@ -62266,7 +70756,7 @@ export class Settings_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPresetList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1APIResourceList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62281,50 +70771,69 @@ export class Settings_v1alpha1Api { }); } /** - * partially update the specified PodPreset - * @param name name of the PodPreset - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * list or watch objects of kind StorageClass * @param pretty If 'true', then the output is pretty printed. + * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. + * @param includeUninitialized If true, partially initialized resources are included in the response. + * @param labelSelector A selector to restrict the list of returned objects by their labels. Defaults to everything. + * @param limit limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + * @param resourceVersion When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv. + * @param timeoutSeconds Timeout for the list/watch call. + * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public patchNamespacedPodPreset (name: string, namespace: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public listStorageClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1StorageClassList; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; - // verify required parameter 'name' is not null or undefined - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchNamespacedPodPreset.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling patchNamespacedPodPreset.'); + if (_continue !== undefined) { + queryParameters['continue'] = _continue; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchNamespacedPodPreset.'); + if (fieldSelector !== undefined) { + queryParameters['fieldSelector'] = fieldSelector; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (includeUninitialized !== undefined) { + queryParameters['includeUninitialized'] = includeUninitialized; + } + + if (labelSelector !== undefined) { + queryParameters['labelSelector'] = labelSelector; + } + + if (limit !== undefined) { + queryParameters['limit'] = limit; + } + + if (resourceVersion !== undefined) { + queryParameters['resourceVersion'] = resourceVersion; + } + + if (timeoutSeconds !== undefined) { + queryParameters['timeoutSeconds'] = timeoutSeconds; + } + + if (watch !== undefined) { + queryParameters['watch'] = watch; } let useFormData = false; let requestOptions: request.Options = { - method: 'PATCH', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -62338,7 +70847,7 @@ export class Settings_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1StorageClassList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62353,17 +70862,14 @@ export class Settings_v1alpha1Api { }); } /** - * read the specified PodPreset - * @param name name of the PodPreset - * @param namespace object name and auth scope, such as for teams and projects + * partially update the specified StorageClass + * @param name name of the StorageClass + * @param body * @param pretty If 'true', then the output is pretty printed. - * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. - * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readNamespacedPodPreset (name: string, namespace: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public patchStorageClass (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62371,35 +70877,28 @@ export class Settings_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readNamespacedPodPreset.'); + throw new Error('Required parameter name was null or undefined when calling patchStorageClass.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling readNamespacedPodPreset.'); + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling patchStorageClass.'); } if (pretty !== undefined) { queryParameters['pretty'] = pretty; } - if (exact !== undefined) { - queryParameters['exact'] = exact; - } - - if (_export !== undefined) { - queryParameters['export'] = _export; - } - let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PATCH', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -62413,7 +70912,7 @@ export class Settings_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62428,16 +70927,15 @@ export class Settings_v1alpha1Api { }); } /** - * replace the specified PodPreset - * @param name name of the PodPreset - * @param namespace object name and auth scope, such as for teams and projects - * @param body + * read the specified StorageClass + * @param name name of the StorageClass * @param pretty If 'true', then the output is pretty printed. + * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public replaceNamespacedPodPreset (name: string, namespace: string, body: V1alpha1PodPreset, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }> { - const localVarPath = this.basePath + '/apis/settings.k8s.io/v1alpha1/namespaces/{namespace}/podpresets/{name}' - .replace('{' + 'name' + '}', String(name)) - .replace('{' + 'namespace' + '}', String(namespace)); + public readStorageClass (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62445,33 +70943,30 @@ export class Settings_v1alpha1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceNamespacedPodPreset.'); + throw new Error('Required parameter name was null or undefined when calling readStorageClass.'); } - // verify required parameter 'namespace' is not null or undefined - if (namespace === null || namespace === undefined) { - throw new Error('Required parameter namespace was null or undefined when calling replaceNamespacedPodPreset.'); + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; } - // verify required parameter 'body' is not null or undefined - if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceNamespacedPodPreset.'); + if (exact !== undefined) { + queryParameters['exact'] = exact; } - if (pretty !== undefined) { - queryParameters['pretty'] = pretty; + if (_export !== undefined) { + queryParameters['export'] = _export; } let useFormData = false; let requestOptions: request.Options = { - method: 'PUT', + method: 'GET', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, - body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -62485,7 +70980,7 @@ export class Settings_v1alpha1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1alpha1PodPreset; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62499,72 +70994,44 @@ export class Settings_v1alpha1Api { }); }); } -} -export enum StorageApiApiKeys { - BearerToken, -} - -export class StorageApi { - protected _basePath = defaultBasePath; - protected defaultHeaders : any = {}; - protected _useQuerystring : boolean = false; - - protected authentications = { - 'default': new VoidAuth(), - 'BearerToken': new ApiKeyAuth('header', 'authorization'), - } - - constructor(basePath?: string); - constructor(basePathOrUsername: string, password?: string, basePath?: string) { - if (password) { - if (basePath) { - this.basePath = basePath; - } - } else { - if (basePathOrUsername) { - this.basePath = basePathOrUsername - } - } - } - - set useQuerystring(value: boolean) { - this._useQuerystring = value; - } - - set basePath(basePath: string) { - this._basePath = basePath; - } - - get basePath() { - return this._basePath; - } - - public setDefaultAuthentication(auth: Authentication) { - this.authentications.default = auth; - } - - public setApiKey(key: StorageApiApiKeys, value: string) { - this.authentications[StorageApiApiKeys[key]].apiKey = value; - } /** - * get information of a group + * replace the specified StorageClass + * @param name name of the StorageClass + * @param body + * @param pretty If 'true', then the output is pretty printed. */ - public getAPIGroup () : Promise<{ response: http.ClientResponse; body: V1APIGroup; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/'; + public replaceStorageClass (name: string, body: V1StorageClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; + // verify required parameter 'name' is not null or undefined + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling replaceStorageClass.'); + } + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new Error('Required parameter body was null or undefined when calling replaceStorageClass.'); + } + + if (pretty !== undefined) { + queryParameters['pretty'] = pretty; + } + let useFormData = false; let requestOptions: request.Options = { - method: 'GET', + method: 'PUT', qs: queryParameters, headers: headerParams, uri: localVarPath, useQuerystring: this._useQuerystring, json: true, + body: body, }; this.authentications.BearerToken.applyToRequest(requestOptions); @@ -62578,7 +71045,7 @@ export class StorageApi { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1APIGroup; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62593,11 +71060,11 @@ export class StorageApi { }); } } -export enum Storage_v1ApiApiKeys { +export enum Storage_v1alpha1ApiApiKeys { BearerToken, } -export class Storage_v1Api { +export class Storage_v1alpha1Api { protected _basePath = defaultBasePath; protected defaultHeaders : any = {}; protected _useQuerystring : boolean = false; @@ -62636,16 +71103,16 @@ export class Storage_v1Api { this.authentications.default = auth; } - public setApiKey(key: Storage_v1ApiApiKeys, value: string) { - this.authentications[Storage_v1ApiApiKeys[key]].apiKey = value; + public setApiKey(key: Storage_v1alpha1ApiApiKeys, value: string) { + this.authentications[Storage_v1alpha1ApiApiKeys[key]].apiKey = value; } /** - * create a StorageClass + * create a VolumeAttachment * @param body * @param pretty If 'true', then the output is pretty printed. */ - public createStorageClass (body: V1StorageClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; + public createVolumeAttachment (body: V1alpha1VolumeAttachment, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62653,7 +71120,7 @@ export class Storage_v1Api { // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling createStorageClass.'); + throw new Error('Required parameter body was null or undefined when calling createVolumeAttachment.'); } if (pretty !== undefined) { @@ -62683,7 +71150,7 @@ export class Storage_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -62698,7 +71165,7 @@ export class Storage_v1Api { }); } /** - * delete collection of StorageClass + * delete collection of VolumeAttachment * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -62709,8 +71176,8 @@ export class Storage_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public deleteCollectionStorageClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; + public deleteCollectionVolumeAttachment (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62789,16 +71256,16 @@ export class Storage_v1Api { }); } /** - * delete a StorageClass - * @param name name of the StorageClass + * delete a VolumeAttachment + * @param name name of the VolumeAttachment * @param body * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ - public deleteStorageClass (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + public deleteVolumeAttachment (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -62807,12 +71274,12 @@ export class Storage_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling deleteStorageClass.'); + throw new Error('Required parameter name was null or undefined when calling deleteVolumeAttachment.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling deleteStorageClass.'); + throw new Error('Required parameter body was null or undefined when calling deleteVolumeAttachment.'); } if (pretty !== undefined) { @@ -62872,7 +71339,7 @@ export class Storage_v1Api { * get available resources */ public getAPIResources () : Promise<{ response: http.ClientResponse; body: V1APIResourceList; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/'; + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62915,7 +71382,7 @@ export class Storage_v1Api { }); } /** - * list or watch objects of kind StorageClass + * list or watch objects of kind VolumeAttachment * @param pretty If 'true', then the output is pretty printed. * @param _continue The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server the server will respond with a 410 ResourceExpired error indicating the client must restart their list without the continue field. This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. * @param fieldSelector A selector to restrict the list of returned objects by their fields. Defaults to everything. @@ -62926,8 +71393,8 @@ export class Storage_v1Api { * @param timeoutSeconds Timeout for the list/watch call. * @param watch Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. */ - public listStorageClass (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1StorageClassList; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses'; + public listVolumeAttachment (pretty?: string, _continue?: string, fieldSelector?: string, includeUninitialized?: boolean, labelSelector?: string, limit?: number, resourceVersion?: string, timeoutSeconds?: number, watch?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachmentList; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments'; let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); let formParams: any = {}; @@ -62991,7 +71458,7 @@ export class Storage_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1StorageClassList; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachmentList; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -63006,13 +71473,13 @@ export class Storage_v1Api { }); } /** - * partially update the specified StorageClass - * @param name name of the StorageClass + * partially update the specified VolumeAttachment + * @param name name of the VolumeAttachment * @param body * @param pretty If 'true', then the output is pretty printed. */ - public patchStorageClass (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + public patchVolumeAttachment (name: string, body: any, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -63021,12 +71488,12 @@ export class Storage_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling patchStorageClass.'); + throw new Error('Required parameter name was null or undefined when calling patchVolumeAttachment.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling patchStorageClass.'); + throw new Error('Required parameter body was null or undefined when calling patchVolumeAttachment.'); } if (pretty !== undefined) { @@ -63056,7 +71523,7 @@ export class Storage_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -63071,14 +71538,14 @@ export class Storage_v1Api { }); } /** - * read the specified StorageClass - * @param name name of the StorageClass + * read the specified VolumeAttachment + * @param name name of the VolumeAttachment * @param pretty If 'true', then the output is pretty printed. * @param exact Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. * @param _export Should this value be exported. Export strips fields that a user can not specify. */ - public readStorageClass (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + public readVolumeAttachment (name: string, pretty?: string, exact?: boolean, _export?: boolean) : Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -63087,7 +71554,7 @@ export class Storage_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling readStorageClass.'); + throw new Error('Required parameter name was null or undefined when calling readVolumeAttachment.'); } if (pretty !== undefined) { @@ -63124,7 +71591,7 @@ export class Storage_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -63139,13 +71606,13 @@ export class Storage_v1Api { }); } /** - * replace the specified StorageClass - * @param name name of the StorageClass + * replace the specified VolumeAttachment + * @param name name of the VolumeAttachment * @param body * @param pretty If 'true', then the output is pretty printed. */ - public replaceStorageClass (name: string, body: V1StorageClass, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1StorageClass; }> { - const localVarPath = this.basePath + '/apis/storage.k8s.io/v1/storageclasses/{name}' + public replaceVolumeAttachment (name: string, body: V1alpha1VolumeAttachment, pretty?: string) : Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }> { + const localVarPath = this.basePath + '/apis/storage.k8s.io/v1alpha1/volumeattachments/{name}' .replace('{' + 'name' + '}', String(name)); let queryParameters: any = {}; let headerParams: any = (Object).assign({}, this.defaultHeaders); @@ -63154,12 +71621,12 @@ export class Storage_v1Api { // verify required parameter 'name' is not null or undefined if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling replaceStorageClass.'); + throw new Error('Required parameter name was null or undefined when calling replaceVolumeAttachment.'); } // verify required parameter 'body' is not null or undefined if (body === null || body === undefined) { - throw new Error('Required parameter body was null or undefined when calling replaceStorageClass.'); + throw new Error('Required parameter body was null or undefined when calling replaceVolumeAttachment.'); } if (pretty !== undefined) { @@ -63189,7 +71656,7 @@ export class Storage_v1Api { requestOptions.form = formParams; } } - return new Promise<{ response: http.ClientResponse; body: V1StorageClass; }>((resolve, reject) => { + return new Promise<{ response: http.ClientResponse; body: V1alpha1VolumeAttachment; }>((resolve, reject) => { request(requestOptions, (error, response, body) => { if (error) { reject(error); @@ -63406,7 +71873,7 @@ export class Storage_v1beta1Api { * @param pretty If 'true', then the output is pretty printed. * @param gracePeriodSeconds The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. * @param orphanDependents Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. + * @param propagationPolicy Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. */ public deleteStorageClass (name: string, body: V1DeleteOptions, pretty?: string, gracePeriodSeconds?: number, orphanDependents?: boolean, propagationPolicy?: string) : Promise<{ response: http.ClientResponse; body: V1Status; }> { const localVarPath = this.basePath + '/apis/storage.k8s.io/v1beta1/storageclasses/{name}' diff --git a/node-client/tsconfig.json b/node-client/tsconfig.json index 878b643a04..64f1493f53 100644 --- a/node-client/tsconfig.json +++ b/node-client/tsconfig.json @@ -5,7 +5,7 @@ "suppressImplicitAnyIndexErrors": true, "target": "es6", "moduleResolution": "node", - "removeComments": true, + "removeComments": false, "sourceMap": true, "noLib": false, "declaration": true, diff --git a/settings b/settings new file mode 100644 index 0000000000..27dfa71bfb --- /dev/null +++ b/settings @@ -0,0 +1,26 @@ +#!/bin/bash + +# Copyright 2015 The Kubernetes Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Kubernetes branch to get the OpenAPI spec from. +export KUBERNETES_BRANCH="release-1.9" + +# client version for packaging and releasing. It can +# be different than SPEC_VERSION. +export CLIENT_VERSION="0.1-SNAPSHOT" + +# Name of the release package +export PACKAGE_NAME="io.kubernetes.client" +