cloudflare
Version:
The official TypeScript library for the Cloudflare API
50 lines • 2.59 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.OriginPostQuantumEncryption = exports.BaseOriginPostQuantumEncryption = void 0;
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
const resource_1 = require("../../core/resource.js");
const path_1 = require("../../internal/utils/path.js");
var BaseOriginPostQuantumEncryption = /* @__PURE__ */ (() => {
class BaseOriginPostQuantumEncryption extends resource_1.APIResource {
/**
* Instructs Cloudflare to use Post-Quantum (PQ) key agreement algorithms when
* connecting to your origin. Preferred instructs Cloudflare to opportunistically
* send a Post-Quantum keyshare in the first message to the origin (for fastest
* connections when the origin supports and prefers PQ), supported means that PQ
* algorithms are advertised but only used when requested by the origin, and off
* means that PQ algorithms are not advertised.
*
* @deprecated
*/
update(params, options) {
const { zone_id, ...body } = params;
return this._client.put((0, path_1.path) `/zones/${zone_id}/cache/origin_post_quantum_encryption`, {
body,
...options,
})._thenUnwrap((obj) => obj.result);
}
/**
* Instructs Cloudflare to use Post-Quantum (PQ) key agreement algorithms when
* connecting to your origin. Preferred instructs Cloudflare to opportunistically
* send a Post-Quantum keyshare in the first message to the origin (for fastest
* connections when the origin supports and prefers PQ), supported means that PQ
* algorithms are advertised but only used when requested by the origin, and off
* means that PQ algorithms are not advertised.
*
* @deprecated
*/
get(params, options) {
const { zone_id } = params;
return this._client.get((0, path_1.path) `/zones/${zone_id}/cache/origin_post_quantum_encryption`, options)._thenUnwrap((obj) => obj.result);
}
}
BaseOriginPostQuantumEncryption._key = Object.freeze([
'originPostQuantumEncryption',
]);
return BaseOriginPostQuantumEncryption;
})();
exports.BaseOriginPostQuantumEncryption = BaseOriginPostQuantumEncryption;
class OriginPostQuantumEncryption extends BaseOriginPostQuantumEncryption {
}
exports.OriginPostQuantumEncryption = OriginPostQuantumEncryption;
//# sourceMappingURL=origin-post-quantum-encryption.js.map