cloudflare
Version:
The official TypeScript library for the Cloudflare API
33 lines • 1.61 kB
JavaScript
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
import { APIResource } from "../../../../../core/resource.mjs";
import { V4PagePaginationArray, } from "../../../../../core/pagination.mjs";
import { path } from "../../../../../internal/utils/path.mjs";
export var BaseRemediationTypes = /* @__PURE__ */ (() => {
class BaseRemediationTypes extends APIResource {
/**
* List all remediation types for a given finding type. This endpoint supports both
* cursor and offset pagination. Note that `cursor` and `page` are mutually
* exclusive.
*
* @example
* ```ts
* // Automatically fetches more pages as needed.
* for await (const remediationTypeListResponse of client.zeroTrust.casb.posture.findingTypes.remediationTypes.list(
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
* { account_id: '46148281d8a93d002ef242d8b0d5f9f6' },
* )) {
* // ...
* }
* ```
*/
list(findingTypeID, params, options) {
const { account_id, ...query } = params;
return this._client.getAPIList(path `/accounts/${account_id}/data-security/posture/finding_types/${findingTypeID}/remediation_types`, (V4PagePaginationArray), { query, ...options });
}
}
BaseRemediationTypes._key = Object.freeze(['zeroTrust', 'casb', 'posture', 'findingTypes', 'remediationTypes']);
return BaseRemediationTypes;
})();
export class RemediationTypes extends BaseRemediationTypes {
}
//# sourceMappingURL=remediation-types.mjs.map