// File generated from our OpenAPI spec by Stainless.
import { APIResource } from 'cloudflare/resource';
export class Certificates extends APIResource {
    /**
     * Upload a certificate to be used for client authentication on a hostname. 10
     * hostname certificates per zone are allowed.
     */
    create(params, options) {
        const { zone_id, ...body } = params;
        return this._client.post(`/zones/${zone_id}/origin_tls_client_auth/hostnames/certificates`, {
            body,
            ...options,
        })._thenUnwrap((obj) => obj.result);
    }
    /**
     * List Certificates
     */
    list(params, options) {
        const { zone_id } = params;
        return this._client.get(`/zones/${zone_id}/origin_tls_client_auth/hostnames/certificates`, options)._thenUnwrap((obj) => obj.result);
    }
    /**
     * Delete Hostname Client Certificate
     */
    delete(certificateId, params, options) {
        const { zone_id } = params;
        return this._client.delete(`/zones/${zone_id}/origin_tls_client_auth/hostnames/certificates/${certificateId}`, options)._thenUnwrap((obj) => obj.result);
    }
    /**
     * Get the certificate by ID to be used for client authentication on a hostname.
     */
    get(certificateId, params, options) {
        const { zone_id } = params;
        return this._client.get(`/zones/${zone_id}/origin_tls_client_auth/hostnames/certificates/${certificateId}`, options)._thenUnwrap((obj) => obj.result);
    }
}
(function (Certificates) {
})(Certificates || (Certificates = {}));
//# sourceMappingURL=certificates.mjs.map