"use strict";
// File generated from our OpenAPI spec by Stainless.
Object.defineProperty(exports, "__esModule", { value: true });
exports.CustomPages = void 0;
const resource_1 = require("cloudflare/resource");
class CustomPages extends resource_1.APIResource {
    /**
     * Create a custom page
     */
    create(identifier, body, options) {
        return this._client.post(`/accounts/${identifier}/access/custom_pages`, {
            body,
            ...options,
        })._thenUnwrap((obj) => obj.result);
    }
    /**
     * Update a custom page
     */
    update(identifier, uuid, body, options) {
        return this._client.put(`/accounts/${identifier}/access/custom_pages/${uuid}`, {
            body,
            ...options,
        })._thenUnwrap((obj) => obj.result);
    }
    /**
     * List custom pages
     */
    list(identifier, options) {
        return this._client.get(`/accounts/${identifier}/access/custom_pages`, options)._thenUnwrap((obj) => obj.result);
    }
    /**
     * Delete a custom page
     */
    delete(identifier, uuid, options) {
        return this._client.delete(`/accounts/${identifier}/access/custom_pages/${uuid}`, options)._thenUnwrap((obj) => obj.result);
    }
    /**
     * Fetches a custom page and also returns its HTML.
     */
    get(identifier, uuid, options) {
        return this._client.get(`/accounts/${identifier}/access/custom_pages/${uuid}`, options)._thenUnwrap((obj) => obj.result);
    }
}
exports.CustomPages = CustomPages;
(function (CustomPages) {
})(CustomPages = exports.CustomPages || (exports.CustomPages = {}));
//# sourceMappingURL=custom-pages.js.map