Workers Types Interface
WorkersTypesInterface is used 0 times on 0 pages.
Pages which use WorkersTypesInterface
Used 0 times.
Pages
Partials
This component uses ts-morph ↗ to generate documentation about the methods on an interface from @cloudflare/workers-types, including their parameters and return types.
import { WorkersTypesInterface } from "~/components";/** * An email message that is sent to a consumer Worker and can be rejected/forwarded. */interface ForwardableEmailMessage extends EmailMessage { /** * Stream of the email message content. */ readonly raw: ReadableStream<Uint8Array>; /** * An [Headers object](https://developer.mozilla.org/en-US/docs/Web/API/Headers). */ readonly headers: Headers; /** * Size of the email message content. */ readonly rawSize: number; /** * Reject this email message by returning a permanent SMTP error back to the connecting client including the given reason. * @param reason The reject reason. * @returns void */ setReject(reason: string): void; /** * Forward this email message to a verified destination address of the account. * @param rcptTo Verified destination address. * @param headers A [Headers object](https://developer.mozilla.org/en-US/docs/Web/API/Headers). * @returns A promise that resolves when the email message is forwarded. */ forward(rcptTo: string, headers?: Headers): Promise<void>; /** * Reply to the sender of this email message with a new EmailMessage object. * @param message The reply message. * @returns A promise that resolves when the email message is replied. */ reply(message: EmailMessage): Promise<void>;}Reject this email message by returning a permanent SMTP error back to the connecting client including the given reason.
/** * Reject this email message by returning a permanent SMTP error back to the connecting client including the given reason. * @param reason The reject reason. * @returns void */setReject(reason: string): void;-
reasonstringThe reject reason.
- void
void
Forward this email message to a verified destination address of the account.
/** * Forward this email message to a verified destination address of the account. * @param rcptTo Verified destination address. * @param headers A [Headers object](https://developer.mozilla.org/en-US/docs/Web/API/Headers). * @returns A promise that resolves when the email message is forwarded. */forward(rcptTo: string, headers?: Headers): Promise<void>;-
rcptTostringVerified destination address.
-
headersHeaders
- Promise<void>
A promise that resolves when the email message is forwarded.
Reply to the sender of this email message with a new EmailMessage object.
/** * Reply to the sender of this email message with a new EmailMessage object. * @param message The reply message. * @returns A promise that resolves when the email message is replied. */reply(message: EmailMessage): Promise<void>;-
messageEmailMessageThe reply message.
- Promise<void>
A promise that resolves when the email message is replied.
import { WorkersTypesInterface } from "~/components";
<WorkersTypesInterface name="ForwardableEmailMessage" />required
type: string
The name of the TypeScript interface.
Was this helpful?
- Resources
- API
- New to Cloudflare?
- Directory
- Sponsorships
- Open Source
- Support
- Help Center
- System Status
- Compliance
- GDPR
- Company
- cloudflare.com
- Our team
- Careers
- © 2025 Cloudflare, Inc.
- Privacy Policy
- Terms of Use
- Report Security Issues
- Trademark