Skip to content

Commit

Permalink
feat(api): api update (#2352)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] committed Jan 23, 2025
1 parent 4a3bdd9 commit 7e9db6b
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 1508
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-4d2ad2efc7849cfa1f1205e3d2b513df805aae225cc968df751a60ecd902d1ab.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-8a886fe980d03dce34f4bbfd3d40277e65cdb1997e06ffd220c0721fcbd63110.yml
72 changes: 72 additions & 0 deletions src/resources/email-security/settings/domains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,10 @@ export interface DomainListResponse {

transport: string;

authorization?: DomainListResponse.Authorization | null;

emails_processed?: DomainListResponse.EmailsProcessed | null;

folder?: 'AllItems' | 'Inbox' | null;

inbox_provider?: 'Microsoft' | 'Google' | null;
Expand All @@ -136,6 +140,24 @@ export interface DomainListResponse {
require_tls_outbound?: boolean | null;
}

export namespace DomainListResponse {
export interface Authorization {
authorized: boolean;

timestamp: string;

status_message?: string | null;
}

export interface EmailsProcessed {
timestamp: string;

total_emails_processed: number;

total_emails_processed_previous: number;
}
}

export interface DomainDeleteResponse {
/**
* The unique identifier for the domain.
Expand Down Expand Up @@ -187,6 +209,10 @@ export interface DomainEditResponse {

transport: string;

authorization?: DomainEditResponse.Authorization | null;

emails_processed?: DomainEditResponse.EmailsProcessed | null;

folder?: 'AllItems' | 'Inbox' | null;

inbox_provider?: 'Microsoft' | 'Google' | null;
Expand All @@ -200,6 +226,24 @@ export interface DomainEditResponse {
require_tls_outbound?: boolean | null;
}

export namespace DomainEditResponse {
export interface Authorization {
authorized: boolean;

timestamp: string;

status_message?: string | null;
}

export interface EmailsProcessed {
timestamp: string;

total_emails_processed: number;

total_emails_processed_previous: number;
}
}

export interface DomainGetResponse {
/**
* The unique identifier for the domain.
Expand Down Expand Up @@ -233,6 +277,10 @@ export interface DomainGetResponse {

transport: string;

authorization?: DomainGetResponse.Authorization | null;

emails_processed?: DomainGetResponse.EmailsProcessed | null;

folder?: 'AllItems' | 'Inbox' | null;

inbox_provider?: 'Microsoft' | 'Google' | null;
Expand All @@ -246,12 +294,36 @@ export interface DomainGetResponse {
require_tls_outbound?: boolean | null;
}

export namespace DomainGetResponse {
export interface Authorization {
authorized: boolean;

timestamp: string;

status_message?: string | null;
}

export interface EmailsProcessed {
timestamp: string;

total_emails_processed: number;

total_emails_processed_previous: number;
}
}

export interface DomainListParams extends V4PagePaginationArrayParams {
/**
* Path param: Account Identifier
*/
account_id: string;

/**
* Query param: Filters response to domains with the currently active delivery
* mode.
*/
active_delivery_mode?: 'DIRECT' | 'BCC' | 'JOURNAL' | 'API' | 'RETRO_SCAN';

/**
* Query param: Filters response to domains with the provided delivery mode.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ describe('resource domains', () => {
test('list: required and optional params', async () => {
const response = await client.emailSecurity.settings.domains.list({
account_id: '023e105f4ecef8ad9ca31a8372d0c353',
active_delivery_mode: 'DIRECT',
allowed_delivery_mode: 'DIRECT',
direction: 'asc',
domain: ['string'],
Expand Down

0 comments on commit 7e9db6b

Please sign in to comment.