Skip to content

Commit

Permalink
feat(api): update via SDK Studio (#670)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored and stainless-bot committed May 27, 2024
1 parent bcfa71f commit 14f40c3
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/resources/filters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export class Filters extends APIResource {
/**
* Creates one or more filters.
*
* @deprecated Filters are being deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
* @deprecated The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
create(
zoneIdentifier: string,
Expand All @@ -26,7 +26,7 @@ export class Filters extends APIResource {
/**
* Updates an existing filter.
*
* @deprecated Filters are being deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
* @deprecated The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
update(
zoneIdentifier: string,
Expand All @@ -45,7 +45,7 @@ export class Filters extends APIResource {
* Fetches filters in a zone. You can filter the results using several optional
* parameters.
*
* @deprecated Filters are being deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
* @deprecated The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
list(
zoneIdentifier: string,
Expand Down Expand Up @@ -73,7 +73,7 @@ export class Filters extends APIResource {
/**
* Deletes an existing filter.
*
* @deprecated Filters are being deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
* @deprecated The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
delete(zoneIdentifier: string, id: string, options?: Core.RequestOptions): Core.APIPromise<FirewallFilter> {
return (
Expand All @@ -86,7 +86,7 @@ export class Filters extends APIResource {
/**
* Fetches the details of a filter.
*
* @deprecated Filters are being deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
* @deprecated The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
get(zoneIdentifier: string, id: string, options?: Core.RequestOptions): Core.APIPromise<FirewallFilter> {
return (
Expand Down
12 changes: 12 additions & 0 deletions src/resources/firewall/rules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import { V4PagePaginationArray, type V4PagePaginationArrayParams } from '../../p
export class Rules extends APIResource {
/**
* Create one or more firewall rules.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
create(
zoneIdentifier: string,
Expand All @@ -26,6 +28,8 @@ export class Rules extends APIResource {

/**
* Updates an existing firewall rule.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
update(
zoneIdentifier: string,
Expand All @@ -44,6 +48,8 @@ export class Rules extends APIResource {
/**
* Fetches firewall rules in a zone. You can filter the results using several
* optional parameters.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
list(
zoneIdentifier: string,
Expand Down Expand Up @@ -71,6 +77,8 @@ export class Rules extends APIResource {

/**
* Deletes an existing firewall rule.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
delete(zoneIdentifier: string, id: string, options?: Core.RequestOptions): Core.APIPromise<FirewallRule> {
return (
Expand All @@ -82,6 +90,8 @@ export class Rules extends APIResource {

/**
* Updates the priority of an existing firewall rule.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
edit(
zoneIdentifier: string,
Expand All @@ -99,6 +109,8 @@ export class Rules extends APIResource {

/**
* Fetches the details of a firewall rule.
*
* @deprecated The Firewall Rules API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.
*/
get(
zoneIdentifier: string,
Expand Down
12 changes: 12 additions & 0 deletions src/resources/pagerules/pagerules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ export class Pagerules extends APIResource {

/**
* Creates a new Page Rule.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
create(
params: PageruleCreateParams,
Expand All @@ -25,6 +27,8 @@ export class Pagerules extends APIResource {
/**
* Replaces the configuration of an existing Page Rule. The configuration of the
* updated Page Rule will exactly match the data passed in the API request.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
update(
pageruleId: string,
Expand All @@ -41,6 +45,8 @@ export class Pagerules extends APIResource {

/**
* Fetches Page Rules in a zone.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
list(params: PageruleListParams, options?: Core.RequestOptions): Core.APIPromise<PageruleListResponse> {
const { zone_id, ...query } = params;
Expand All @@ -53,6 +59,8 @@ export class Pagerules extends APIResource {

/**
* Deletes an existing Page Rule.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
delete(
pageruleId: string,
Expand All @@ -69,6 +77,8 @@ export class Pagerules extends APIResource {

/**
* Updates one or more fields of an existing Page Rule.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
edit(
pageruleId: string,
Expand All @@ -86,6 +96,8 @@ export class Pagerules extends APIResource {

/**
* Fetches the details of a Page Rule.
*
* @deprecated The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
*/
get(
pageruleId: string,
Expand Down
10 changes: 10 additions & 0 deletions src/resources/rate-limits.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ export class RateLimits extends APIResource {
/**
* Creates a new rate limit for a zone. Refer to the object definition for a list
* of required attributes.
*
* @deprecated Rate limiting API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#rate-limiting-api-previous-version for full details.
*/
create(
zoneIdentifier: string,
Expand All @@ -25,6 +27,8 @@ export class RateLimits extends APIResource {

/**
* Fetches the rate limits for a zone.
*
* @deprecated Rate limiting API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#rate-limiting-api-previous-version for full details.
*/
list(
zoneIdentifier: string,
Expand All @@ -51,6 +55,8 @@ export class RateLimits extends APIResource {

/**
* Deletes an existing rate limit.
*
* @deprecated Rate limiting API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#rate-limiting-api-previous-version for full details.
*/
delete(
zoneIdentifier: string,
Expand All @@ -66,6 +72,8 @@ export class RateLimits extends APIResource {

/**
* Updates an existing rate limit.
*
* @deprecated Rate limiting API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#rate-limiting-api-previous-version for full details.
*/
edit(
zoneIdentifier: string,
Expand All @@ -83,6 +91,8 @@ export class RateLimits extends APIResource {

/**
* Fetches the details of a rate limit.
*
* @deprecated Rate limiting API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#rate-limiting-api-previous-version for full details.
*/
get(
zoneIdentifier: string,
Expand Down

0 comments on commit 14f40c3

Please sign in to comment.