/** * ProtectionPolicies service. * @version 4.3.1 * @class ProtectionPoliciesApi */ export class ProtectionPoliciesApi { /** * Make the default {@link ApiClient} class available for developers to be able to extend it and bring * their own fetch methods into the SDK */ static get ApiClient(): typeof ApiClient; /** * Constructs a new ProtectionPoliciesApi. * @alias module:api/ProtectionPoliciesApi * @class * @param {module:ApiClient} [apiClient] Optional API client implementation to use, * default to {@link module:ApiClient#instance} if unspecified. */ constructor(apiClient?: any); apiClient: any; /** * Create a consistency rule * Creates a new consistency rule with the provided specification. * @param { Required> & Partial } body specification * @param { String } protectionPolicyExtId The external identifier of the protection policy. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link CreateConsistencyRuleApiResponse } and HTTP response */ createConsistencyRule(protectionPolicyExtId: string, body: Required> & Partial, ...args: any): Promise; /** * Create a protection policy * Creates a protection policy to automate the recovery point creation and replication process. * @param { Required> & Partial } body specification * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link CreateProtectionPolicyApiResponse } and HTTP response */ createProtectionPolicy(body: Required> & Partial, ...args: any): Promise; /** * Delete a consistency rule * Deletes a consistency rule for the provided external identifier. * @param { String } protectionPolicyExtId The external identifier of the protection policy. * @param { String } extId The external identifier of the consistency rule. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link DeleteConsistencyRuleApiResponse } and HTTP response */ deleteConsistencyRuleById(protectionPolicyExtId: string, extId: string, ...args: any): Promise; /** * Delete a protection policy * Deletes the protection policy identified by an external identifier. * @param { String } extId The external identifier of the protection policy. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link DeleteProtectionPolicyApiResponse } and HTTP response */ deleteProtectionPolicyById(extId: string, ...args: any): Promise; /** * Get details of a consistency rule * Fetches the details of a consistency rule for the provided external identifier. * @param { String } protectionPolicyExtId The external identifier of the protection policy. * @param { String } extId The external identifier of the consistency rule. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link GetConsistencyRuleApiResponse } and HTTP response */ getConsistencyRuleById(protectionPolicyExtId: string, extId: string, ...args: any): Promise; /** * Get a protection policy * Fetches the protection policy identified by an external identifier. * @param { String } extId The external identifier of the protection policy. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link GetProtectionPolicyApiResponse } and HTTP response */ getProtectionPolicyById(extId: string, ...args: any): Promise; /** * List consistency rules * Lists the consistency rules defined in the system. The list of consistency rules can be further filtered using various filtering options. * @param { String } protectionPolicyExtId The external identifier of the protection policy. * @param {Object} opts Optional parameters defined for the operation * @param { Number } opts.$page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. If both $page and $apply query parameters are present, $page will be applied on entities within the groups. * @param { Number } opts.$limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. If both $limit and $apply query parameters are present, $limit will be applied on entities within the groups. Default value of limit with $apply will be 5. * @param { String } opts.$filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions.
* For example, filter **$filter=name eq 'karbon-ntnx-1.0'** would filter the result on cluster name 'karbon-ntnx1.0', filter **$filter=startswith(name, 'C')** would filter on cluster name starting with 'C'. If both $filter and $apply query parameters are present, $filter will be applied on entities within the groups. * @param { String } opts.$orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. If both $orderby and $apply query parameters are present, $orderby will be applied on entities within the groups. * @param { String } opts.$select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. If both $select and $apply query parameters are present, $select will be applied on entities within the groups. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link ListConsistencyRulesApiResponse } and HTTP response */ listConsistencyRulesByProtectionPolicyId(protectionPolicyExtId: string, opts: { $page: number; $limit: number; $filter: string; $orderby: string; $select: string; }, ...args: any): Promise; /** * List protection policies * List the protection policies defined on the system. This operation supports filtering, sorting, selection and pagination. * @param {Object} opts Optional parameters defined for the operation * @param { Number } opts.$page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. If both $page and $apply query parameters are present, $page will be applied on entities within the groups. * @param { Number } opts.$limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. If both $limit and $apply query parameters are present, $limit will be applied on entities within the groups. Default value of limit with $apply will be 5. * @param { String } opts.$filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions.
* For example, filter **$filter=name eq 'karbon-ntnx-1.0'** would filter the result on cluster name 'karbon-ntnx1.0', filter **$filter=startswith(name, 'C')** would filter on cluster name starting with 'C'. If both $filter and $apply query parameters are present, $filter will be applied on entities within the groups. * @param { String } opts.$orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. If both $orderby and $apply query parameters are present, $orderby will be applied on entities within the groups. * @param { String } opts.$select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. If both $select and $apply query parameters are present, $select will be applied on entities within the groups. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link ListProtectionPoliciesApiResponse } and HTTP response */ listProtectionPolicies(opts: { $page: number; $limit: number; $filter: string; $orderby: string; $select: string; }, ...args: any): Promise; /** * Update a consistency rule * Updates the details of a consistency rule for the provided external identifier. * @param { Required> & Partial } body specification * @param { String } protectionPolicyExtId The external identifier of the protection policy. * @param { String } extId The external identifier of the consistency rule. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link UpdateConsistencyRuleApiResponse } and HTTP response */ updateConsistencyRuleById(protectionPolicyExtId: string, extId: string, body: Required> & Partial, ...args: any): Promise; /** * Update a protection policy * Updates the protection policy identified by an external identifier. * @param { Required> & Partial } body specification * @param { String } extId The external identifier of the protection policy. * @param {Object} args Additional Arguments * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link UpdateProtectionPolicyApiResponse } and HTTP response */ updateProtectionPolicyById(extId: string, body: Required> & Partial, ...args: any): Promise; #private; } import ConsistencyRule from "../models/datapolicies/v4/config/ConsistencyRule"; import CreateConsistencyRuleApiResponse from "../models/datapolicies/v4/config/CreateConsistencyRuleApiResponse"; import ProtectionPolicy from "../models/datapolicies/v4/config/ProtectionPolicy"; import CreateProtectionPolicyApiResponse from "../models/datapolicies/v4/config/CreateProtectionPolicyApiResponse"; import DeleteConsistencyRuleApiResponse from "../models/datapolicies/v4/config/DeleteConsistencyRuleApiResponse"; import DeleteProtectionPolicyApiResponse from "../models/datapolicies/v4/config/DeleteProtectionPolicyApiResponse"; import GetConsistencyRuleApiResponse from "../models/datapolicies/v4/config/GetConsistencyRuleApiResponse"; import GetProtectionPolicyApiResponse from "../models/datapolicies/v4/config/GetProtectionPolicyApiResponse"; import ListConsistencyRulesApiResponse from "../models/datapolicies/v4/config/ListConsistencyRulesApiResponse"; import ListProtectionPoliciesApiResponse from "../models/datapolicies/v4/config/ListProtectionPoliciesApiResponse"; import UpdateConsistencyRuleApiResponse from "../models/datapolicies/v4/config/UpdateConsistencyRuleApiResponse"; import UpdateProtectionPolicyApiResponse from "../models/datapolicies/v4/config/UpdateProtectionPolicyApiResponse"; import { ApiClient } from "../ApiClient";