UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

16 lines 731 B
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from 'cloudflare/resource'; export class Metadata extends APIResource { /** * Returns the metadata associated with the given key in the given namespace. Use * URL-encoding to use special characters (for example, `:`, `!`, `%`) in the key * name. */ get(namespaceId, keyName, params, options) { const { account_id } = params; return this._client.get(`/accounts/${account_id}/storage/kv/namespaces/${namespaceId}/metadata/${keyName}`, options)._thenUnwrap((obj) => obj.result); } } (function (Metadata) { })(Metadata || (Metadata = {})); //# sourceMappingURL=metadata.mjs.map