Skip to content

Commit

Permalink
feat: update via SDK Studio (#65)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored Feb 22, 2024
1 parent d51c557 commit 7feb32e
Show file tree
Hide file tree
Showing 14 changed files with 223 additions and 223 deletions.
72 changes: 36 additions & 36 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -502,21 +502,21 @@ Methods:
- <code title="get /{account_or_zone}/{account_or_zone_id}/access/apps/{app_id}">client.access.applications.<a href="./src/resources/access/applications/applications.ts">get</a>(appId, { ...params }) -> ApplicationGetResponse</code>
- <code title="post /{account_or_zone}/{account_or_zone_id}/access/apps/{app_id}/revoke_tokens">client.access.applications.<a href="./src/resources/access/applications/applications.ts">revokeTokens</a>(appId, { ...params }) -> ApplicationRevokeTokensResponse | null</code>

### Cas
### CAs

Types:

- <code><a href="./src/resources/access/applications/cas.ts">CaCreateResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CaListResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CaDeleteResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CaGetResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CACreateResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CAListResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CADeleteResponse</a></code>
- <code><a href="./src/resources/access/applications/cas.ts">CAGetResponse</a></code>

Methods:

- <code title="post /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">create</a>(uuid, { ...params }) -> CaCreateResponse</code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/access/apps/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">list</a>({ ...params }) -> CaListResponse | null</code>
- <code title="delete /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">delete</a>(uuid, { ...params }) -> CaDeleteResponse</code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">get</a>(uuid, { ...params }) -> CaGetResponse</code>
- <code title="post /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">create</a>(uuid, { ...params }) -> CACreateResponse</code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/access/apps/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">list</a>({ ...params }) -> CAListResponse | null</code>
- <code title="delete /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">delete</a>(uuid, { ...params }) -> CADeleteResponse</code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/access/apps/{uuid}/ca">client.access.applications.cas.<a href="./src/resources/access/applications/cas.ts">get</a>(uuid, { ...params }) -> CAGetResponse</code>

### UserPolicyChecks

Expand Down Expand Up @@ -1342,23 +1342,23 @@ Methods:
- <code title="patch /{account_or_zone}/{account_or_zone_id}/firewall/access_rules/rules/{identifier}">client.firewalls.accessRules.<a href="./src/resources/firewalls/access-rules.ts">edit</a>(identifier, { ...params }) -> AccessRuleEditResponse | null</code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/firewall/access_rules/rules/{identifier}">client.firewalls.accessRules.<a href="./src/resources/firewalls/access-rules.ts">get</a>(identifier, { ...params }) -> AccessRuleGetResponse | null</code>

## UaRules
## UARules

Types:

- <code><a href="./src/resources/firewalls/ua-rules.ts">UaRuleCreateResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UaRuleUpdateResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UaRuleListResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UaRuleDeleteResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UaRuleGetResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UARuleCreateResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UARuleUpdateResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UARuleListResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UARuleDeleteResponse</a></code>
- <code><a href="./src/resources/firewalls/ua-rules.ts">UARuleGetResponse</a></code>

Methods:

- <code title="post /zones/{zone_identifier}/firewall/ua_rules">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">create</a>(zoneIdentifier, { ...params }) -> UaRuleCreateResponse | null</code>
- <code title="put /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">update</a>(zoneIdentifier, id, { ...params }) -> UaRuleUpdateResponse | null</code>
- <code title="get /zones/{zone_identifier}/firewall/ua_rules">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">list</a>(zoneIdentifier, { ...params }) -> UaRuleListResponsesV4PagePaginationArray</code>
- <code title="delete /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">delete</a>(zoneIdentifier, id) -> UaRuleDeleteResponse | null</code>
- <code title="get /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">get</a>(zoneIdentifier, id) -> UaRuleGetResponse | null</code>
- <code title="post /zones/{zone_identifier}/firewall/ua_rules">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">create</a>(zoneIdentifier, { ...params }) -> UARuleCreateResponse | null</code>
- <code title="put /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">update</a>(zoneIdentifier, id, { ...params }) -> UARuleUpdateResponse | null</code>
- <code title="get /zones/{zone_identifier}/firewall/ua_rules">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">list</a>(zoneIdentifier, { ...params }) -> UARuleListResponsesV4PagePaginationArray</code>
- <code title="delete /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">delete</a>(zoneIdentifier, id) -> UARuleDeleteResponse | null</code>
- <code title="get /zones/{zone_identifier}/firewall/ua_rules/{id}">client.firewalls.uaRules.<a href="./src/resources/firewalls/ua-rules.ts">get</a>(zoneIdentifier, id) -> UARuleGetResponse | null</code>

## WAF

Expand Down Expand Up @@ -1810,23 +1810,23 @@ Methods:
- <code title="delete /accounts/{account_id}/secondary_dns/peers/{peer_id}">client.secondaryDNS.peers.<a href="./src/resources/secondary-dns/peers.ts">delete</a>(accountId, peerId) -> PeerDeleteResponse</code>
- <code title="get /accounts/{account_id}/secondary_dns/peers/{peer_id}">client.secondaryDNS.peers.<a href="./src/resources/secondary-dns/peers.ts">get</a>(accountId, peerId) -> PeerGetResponse</code>

## Tsigs
## TSIGs

Types:

- <code><a href="./src/resources/secondary-dns/tsigs.ts">TsigCreateResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TsigUpdateResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TsigListResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TsigDeleteResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TsigGetResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TSIGCreateResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TSIGUpdateResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TSIGListResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TSIGDeleteResponse</a></code>
- <code><a href="./src/resources/secondary-dns/tsigs.ts">TSIGGetResponse</a></code>

Methods:

- <code title="post /accounts/{account_id}/secondary_dns/tsigs">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">create</a>(accountId, { ...params }) -> TsigCreateResponse</code>
- <code title="put /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">update</a>(accountId, tsigId, { ...params }) -> TsigUpdateResponse</code>
- <code title="get /accounts/{account_id}/secondary_dns/tsigs">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">list</a>(accountId) -> TsigListResponse | null</code>
- <code title="delete /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">delete</a>(accountId, tsigId) -> TsigDeleteResponse</code>
- <code title="get /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">get</a>(accountId, tsigId) -> TsigGetResponse</code>
- <code title="post /accounts/{account_id}/secondary_dns/tsigs">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">create</a>(accountId, { ...params }) -> TSIGCreateResponse</code>
- <code title="put /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">update</a>(accountId, tsigId, { ...params }) -> TSIGUpdateResponse</code>
- <code title="get /accounts/{account_id}/secondary_dns/tsigs">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">list</a>(accountId) -> TSIGListResponse | null</code>
- <code title="delete /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">delete</a>(accountId, tsigId) -> TSIGDeleteResponse</code>
- <code title="get /accounts/{account_id}/secondary_dns/tsigs/{tsig_id}">client.secondaryDNS.tsigs.<a href="./src/resources/secondary-dns/tsigs.ts">get</a>(accountId, tsigId) -> TSIGGetResponse</code>

# Settings

Expand All @@ -1840,17 +1840,17 @@ Methods:
- <code title="get /zones/{zone_id}/settings">client.settings.<a href="./src/resources/settings/settings.ts">list</a>(zoneId) -> SettingListResponse</code>
- <code title="patch /zones/{zone_id}/settings">client.settings.<a href="./src/resources/settings/settings.ts">edit</a>(zoneId, { ...params }) -> SettingEditResponse</code>

## ZeroRtt
## ZeroRTT

Types:

- <code><a href="./src/resources/settings/zero-rtt.ts">ZeroRttEditResponse</a></code>
- <code><a href="./src/resources/settings/zero-rtt.ts">ZeroRttGetResponse</a></code>
- <code><a href="./src/resources/settings/zero-rtt.ts">ZeroRTTEditResponse</a></code>
- <code><a href="./src/resources/settings/zero-rtt.ts">ZeroRTTGetResponse</a></code>

Methods:

- <code title="patch /zones/{zone_id}/settings/0rtt">client.settings.zeroRtt.<a href="./src/resources/settings/zero-rtt.ts">edit</a>(zoneId, { ...params }) -> ZeroRttEditResponse</code>
- <code title="get /zones/{zone_id}/settings/0rtt">client.settings.zeroRtt.<a href="./src/resources/settings/zero-rtt.ts">get</a>(zoneId) -> ZeroRttGetResponse</code>
- <code title="patch /zones/{zone_id}/settings/0rtt">client.settings.zeroRTT.<a href="./src/resources/settings/zero-rtt.ts">edit</a>(zoneId, { ...params }) -> ZeroRTTEditResponse</code>
- <code title="get /zones/{zone_id}/settings/0rtt">client.settings.zeroRTT.<a href="./src/resources/settings/zero-rtt.ts">get</a>(zoneId) -> ZeroRTTGetResponse</code>

## AdvancedDDOS

Expand Down
22 changes: 11 additions & 11 deletions src/resources/access/applications/applications.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
import * as Core from 'cloudflare/core';
import { APIResource } from 'cloudflare/resource';
import * as ApplicationsAPI from 'cloudflare/resources/access/applications/applications';
import * as CasAPI from 'cloudflare/resources/access/applications/cas';
import * as CAsAPI from 'cloudflare/resources/access/applications/cas';
import * as PoliciesAPI from 'cloudflare/resources/access/applications/policies';
import * as UserPolicyChecksAPI from 'cloudflare/resources/access/applications/user-policy-checks';

export class Applications extends APIResource {
cas: CasAPI.Cas = new CasAPI.Cas(this._client);
cas: CAsAPI.CAs = new CAsAPI.CAs(this._client);
userPolicyChecks: UserPolicyChecksAPI.UserPolicyChecks = new UserPolicyChecksAPI.UserPolicyChecks(
this._client,
);
Expand Down Expand Up @@ -4712,15 +4712,15 @@ export namespace Applications {
export import ApplicationDeleteParams = ApplicationsAPI.ApplicationDeleteParams;
export import ApplicationGetParams = ApplicationsAPI.ApplicationGetParams;
export import ApplicationRevokeTokensParams = ApplicationsAPI.ApplicationRevokeTokensParams;
export import Cas = CasAPI.Cas;
export import CaCreateResponse = CasAPI.CaCreateResponse;
export import CaListResponse = CasAPI.CaListResponse;
export import CaDeleteResponse = CasAPI.CaDeleteResponse;
export import CaGetResponse = CasAPI.CaGetResponse;
export import CaCreateParams = CasAPI.CaCreateParams;
export import CaListParams = CasAPI.CaListParams;
export import CaDeleteParams = CasAPI.CaDeleteParams;
export import CaGetParams = CasAPI.CaGetParams;
export import CAs = CAsAPI.CAs;
export import CACreateResponse = CAsAPI.CACreateResponse;
export import CAListResponse = CAsAPI.CAListResponse;
export import CADeleteResponse = CAsAPI.CADeleteResponse;
export import CAGetResponse = CAsAPI.CAGetResponse;
export import CACreateParams = CAsAPI.CACreateParams;
export import CAListParams = CAsAPI.CAListParams;
export import CADeleteParams = CAsAPI.CADeleteParams;
export import CAGetParams = CAsAPI.CAGetParams;
export import UserPolicyChecks = UserPolicyChecksAPI.UserPolicyChecks;
export import UserPolicyCheckListResponse = UserPolicyChecksAPI.UserPolicyCheckListResponse;
export import UserPolicyCheckListParams = UserPolicyChecksAPI.UserPolicyCheckListParams;
Expand Down
62 changes: 31 additions & 31 deletions src/resources/access/applications/cas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,33 @@

import * as Core from 'cloudflare/core';
import { APIResource } from 'cloudflare/resource';
import * as CasAPI from 'cloudflare/resources/access/applications/cas';
import * as CAsAPI from 'cloudflare/resources/access/applications/cas';

export class Cas extends APIResource {
export class CAs extends APIResource {
/**
* Generates a new short-lived certificate CA and public key.
*/
create(
uuid: string,
params: CaCreateParams,
params: CACreateParams,
options?: Core.RequestOptions,
): Core.APIPromise<CaCreateResponse> {
): Core.APIPromise<CACreateResponse> {
const { account_id, zone_id } = params;
return (
this._client.post(`/${account_id}/${zone_id}/access/apps/${uuid}/ca`, options) as Core.APIPromise<{
result: CaCreateResponse;
result: CACreateResponse;
}>
)._thenUnwrap((obj) => obj.result);
}

/**
* Lists short-lived certificate CAs and their public keys.
*/
list(params: CaListParams, options?: Core.RequestOptions): Core.APIPromise<CaListResponse | null> {
list(params: CAListParams, options?: Core.RequestOptions): Core.APIPromise<CAListResponse | null> {
const { account_id, zone_id } = params;
return (
this._client.get(`/${account_id}/${zone_id}/access/apps/ca`, options) as Core.APIPromise<{
result: CaListResponse | null;
result: CAListResponse | null;
}>
)._thenUnwrap((obj) => obj.result);
}
Expand All @@ -38,36 +38,36 @@ export class Cas extends APIResource {
*/
delete(
uuid: string,
params: CaDeleteParams,
params: CADeleteParams,
options?: Core.RequestOptions,
): Core.APIPromise<CaDeleteResponse> {
): Core.APIPromise<CADeleteResponse> {
const { account_id, zone_id } = params;
return (
this._client.delete(`/${account_id}/${zone_id}/access/apps/${uuid}/ca`, options) as Core.APIPromise<{
result: CaDeleteResponse;
result: CADeleteResponse;
}>
)._thenUnwrap((obj) => obj.result);
}

/**
* Fetches a short-lived certificate CA and its public key.
*/
get(uuid: string, params: CaGetParams, options?: Core.RequestOptions): Core.APIPromise<CaGetResponse> {
get(uuid: string, params: CAGetParams, options?: Core.RequestOptions): Core.APIPromise<CAGetResponse> {
const { account_id, zone_id } = params;
return (
this._client.get(`/${account_id}/${zone_id}/access/apps/${uuid}/ca`, options) as Core.APIPromise<{
result: CaGetResponse;
result: CAGetResponse;
}>
)._thenUnwrap((obj) => obj.result);
}
}

export type CaCreateResponse = unknown | string;
export type CACreateResponse = unknown | string;

export type CaListResponse = Array<CaListResponse.CaListResponseItem>;
export type CAListResponse = Array<CAListResponse.CAListResponseItem>;

export namespace CaListResponse {
export interface CaListResponseItem {
export namespace CAListResponse {
export interface CAListResponseItem {
/**
* The ID of the CA.
*/
Expand All @@ -86,16 +86,16 @@ export namespace CaListResponse {
}
}

export interface CaDeleteResponse {
export interface CADeleteResponse {
/**
* The ID of the CA.
*/
id?: string;
}

export type CaGetResponse = unknown | string;
export type CAGetResponse = unknown | string;

export interface CaCreateParams {
export interface CACreateParams {
/**
* The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.
*/
Expand All @@ -107,7 +107,7 @@ export interface CaCreateParams {
zone_id: string;
}

export interface CaListParams {
export interface CAListParams {
/**
* The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.
*/
Expand All @@ -119,7 +119,7 @@ export interface CaListParams {
zone_id: string;
}

export interface CaDeleteParams {
export interface CADeleteParams {
/**
* The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.
*/
Expand All @@ -131,7 +131,7 @@ export interface CaDeleteParams {
zone_id: string;
}

export interface CaGetParams {
export interface CAGetParams {
/**
* The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.
*/
Expand All @@ -143,13 +143,13 @@ export interface CaGetParams {
zone_id: string;
}

export namespace Cas {
export import CaCreateResponse = CasAPI.CaCreateResponse;
export import CaListResponse = CasAPI.CaListResponse;
export import CaDeleteResponse = CasAPI.CaDeleteResponse;
export import CaGetResponse = CasAPI.CaGetResponse;
export import CaCreateParams = CasAPI.CaCreateParams;
export import CaListParams = CasAPI.CaListParams;
export import CaDeleteParams = CasAPI.CaDeleteParams;
export import CaGetParams = CasAPI.CaGetParams;
export namespace CAs {
export import CACreateResponse = CAsAPI.CACreateResponse;
export import CAListResponse = CAsAPI.CAListResponse;
export import CADeleteResponse = CAsAPI.CADeleteResponse;
export import CAGetResponse = CAsAPI.CAGetResponse;
export import CACreateParams = CAsAPI.CACreateParams;
export import CAListParams = CAsAPI.CAListParams;
export import CADeleteParams = CAsAPI.CADeleteParams;
export import CAGetParams = CAsAPI.CAGetParams;
}
18 changes: 9 additions & 9 deletions src/resources/access/applications/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ export {
Applications,
} from './applications';
export {
CaCreateResponse,
CaListResponse,
CaDeleteResponse,
CaGetResponse,
CaCreateParams,
CaListParams,
CaDeleteParams,
CaGetParams,
Cas,
CACreateResponse,
CAListResponse,
CADeleteResponse,
CAGetResponse,
CACreateParams,
CAListParams,
CADeleteParams,
CAGetParams,
CAs,
} from './cas';
export {
PolicyCreateResponse,
Expand Down
Loading

0 comments on commit 7feb32e

Please sign in to comment.