UNPKG

cloudflare

Version:

The official TypeScript library for the Cloudflare API

38 lines • 1.51 kB
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from "../../core/resource.mjs"; import { buildHeaders } from "../../internal/headers.mjs"; import { path } from "../../internal/utils/path.mjs"; export var BaseLogos = /* @__PURE__ */ (() => { class BaseLogos extends APIResource { /** * Return new saved logo queries created from image files */ create(params, options) { const { account_id, match_type, tag, threshold, ...body } = params; return this._client.post(path `/accounts/${account_id}/brand-protection/logos`, { query: { match_type, tag, threshold }, body, ...options, headers: buildHeaders([{ 'Content-Type': 'application/x-www-form-urlencoded' }, options?.headers]), }); } /** * Return a success message after deleting saved logo queries by ID */ delete(logoID, params, options) { const { account_id } = params; return this._client.delete(path `/accounts/${account_id}/brand-protection/logos/${logoID}`, { ...options, headers: buildHeaders([{ Accept: '*/*' }, options?.headers]), }); } } BaseLogos._key = Object.freeze([ 'brandProtection', 'logos', ]); return BaseLogos; })(); export class Logos extends BaseLogos { } //# sourceMappingURL=logos.mjs.map