UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

51 lines 1.84 kB
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from 'cloudflare/resource'; import * as BookmarksAPI from 'cloudflare/resources/zero-trust/access/bookmarks'; import { SinglePage } from 'cloudflare/pagination'; export class Bookmarks extends APIResource { /** * Create a new Bookmark application. */ create(identifier, uuid, body, options) { return this._client.post(`/accounts/${identifier}/access/bookmarks/${uuid}`, { body, ...options, })._thenUnwrap((obj) => obj.result); } /** * Updates a configured Bookmark application. */ update(identifier, uuid, body, options) { return this._client.put(`/accounts/${identifier}/access/bookmarks/${uuid}`, { body, ...options, })._thenUnwrap((obj) => obj.result); } /** * Lists Bookmark applications. */ list(identifier, options) { return this._client.getAPIList(`/accounts/${identifier}/access/bookmarks`, BookmarksSinglePage, options); } /** * Deletes a Bookmark application. */ delete(identifier, uuid, body, options) { return this._client.delete(`/accounts/${identifier}/access/bookmarks/${uuid}`, { body, ...options, })._thenUnwrap((obj) => obj.result); } /** * Fetches a single Bookmark application. */ get(identifier, uuid, options) { return this._client.get(`/accounts/${identifier}/access/bookmarks/${uuid}`, options)._thenUnwrap((obj) => obj.result); } } export class BookmarksSinglePage extends SinglePage { } (function (Bookmarks) { Bookmarks.BookmarksSinglePage = BookmarksAPI.BookmarksSinglePage; })(Bookmarks || (Bookmarks = {})); //# sourceMappingURL=bookmarks.mjs.map