cloudflare
Version:
The official TypeScript library for the Cloudflare API
28 lines • 1.07 kB
JavaScript
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
import { APIResource } from "../../core/resource.mjs";
import { path } from "../../internal/utils/path.mjs";
export var BaseURLs = /* @__PURE__ */ (() => {
class BaseURLs extends APIResource {
/**
* Gets security information about a URL, including content categories and risk
* types. The URL must be provided as a query parameter.
*
* @example
* ```ts
* const url = await client.intel.urls.get({
* account_id: '023e105f4ecef8ad9ca31a8372d0c353',
* url: 'url',
* });
* ```
*/
get(params, options) {
const { account_id, ...query } = params;
return this._client.get(path `/accounts/${account_id}/intel/url`, { query, ...options })._thenUnwrap((obj) => obj.result);
}
}
BaseURLs._key = Object.freeze(['intel', 'urls']);
return BaseURLs;
})();
export class URLs extends BaseURLs {
}
//# sourceMappingURL=urls.mjs.map