UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

62 lines • 2.28 kB
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from "../../../core/resource.mjs"; import { SinglePage } from "../../../core/pagination.mjs"; import { path } from "../../../internal/utils/path.mjs"; export var BaseBookmarks = /* @__PURE__ */ (() => { class BaseBookmarks extends APIResource { /** * Create a new Bookmark application. * * @deprecated */ create(bookmarkID, params, options) { const { account_id } = params; return this._client.post(path `/accounts/${account_id}/access/bookmarks/${bookmarkID}`, options)._thenUnwrap((obj) => obj.result); } /** * Updates a configured Bookmark application. * * @deprecated */ update(bookmarkID, params, options) { const { account_id } = params; return this._client.put(path `/accounts/${account_id}/access/bookmarks/${bookmarkID}`, options)._thenUnwrap((obj) => obj.result); } /** * Lists Bookmark applications. * * @deprecated */ list(params, options) { const { account_id } = params; return this._client.getAPIList(path `/accounts/${account_id}/access/bookmarks`, (SinglePage), options); } /** * Deletes a Bookmark application. * * @deprecated */ delete(bookmarkID, params, options) { const { account_id } = params; return this._client.delete(path `/accounts/${account_id}/access/bookmarks/${bookmarkID}`, options)._thenUnwrap((obj) => obj.result); } /** * Fetches a single Bookmark application. * * @deprecated */ get(bookmarkID, params, options) { const { account_id } = params; return this._client.get(path `/accounts/${account_id}/access/bookmarks/${bookmarkID}`, options)._thenUnwrap((obj) => obj.result); } } BaseBookmarks._key = Object.freeze([ 'zeroTrust', 'access', 'bookmarks', ]); return BaseBookmarks; })(); export class Bookmarks extends BaseBookmarks { } //# sourceMappingURL=bookmarks.mjs.map