Edits history of script submission #106 for ' Send Email (smtp)'

  • deno
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    type Smtp = {
      host: string;
      port: number;
      user: string;
      password: string;
    };
    export async function main(
      smtp_res: Smtp,
      to_email: string,
      from_email: string,
      subject: string,
      content: string,
    ) {
      const client = new SmtpClient();
    
      await client.connectTLS({
          hostname: smtp_res.host,
          username: smtp_res.user,
          port: smtp_res.port,
          password: smtp_res.password
      });
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }
    

    Submitted by hugo697 399 days ago

  • deno
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    type Smtp = {
      host: string;
      port: number;
      user: string;
      password: string;
    };
    export async function main(
      smtp_res: Smtp,
      to_email: string,
      from_email: string,
      subject: string,
      content: string,
    ) {
      const client = new SmtpClient();
    
      await client.connectTLS({
          hostname: smtp_res.host,
          username: smtp_res.user,
          port: smtp_res.port,
          password: smtp_res.password
      });
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }
    

    Submitted by rubenfiszel 1029 days ago

  • deno
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    type Smtp = {
      host: string;
      port: number;
      user: string;
      password: string;
    };
    export async function main(
      smtp_res: Smtp,
      to_email: string,
      from_email: string,
      subject: string,
      content: string,
    ) {
      const client = new SmtpClient();
    
      await client.connectTLS(smtp_res);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }
    

    Submitted by rubenfiszel 1029 days ago

  • deno
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    type Smtp = {
      host: string;
      port: number;
      user: string;
      password: string;
    };
    export async function main(
      smtp_res: Smtp,
      to_email: string,
      from_email: string,
      subject: string,
      content: string,
    ) {
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }
    

    Submitted by admin 1031 days ago

  • deno
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    type Smtp = {
      host: string;
      port: number;
      user: string;
      password: string;
    };
    export async function main(smtp_res: Smtp, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by admin 1034 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/mod.ts";
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    export async function main(smtp_res: wmill.Resource<"smtp">, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by adam186 1160 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    export async function main(smtp_res: wmill.Resource<"smtp">, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by adam186 1163 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    export async function main(smtp_res: wmill.Resource<"smtp">, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by adam186 1198 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    export async function main(smtp_res: wmill.Resource<"smtp">, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by admin 1393 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { SmtpClient } from "https://deno.land/x/smtp/mod.ts";
    
    export async function main(smtp_res: wmill.Resource<"email_smtp">, to_email: string, from_email: string, subject: string, content: string) {
    
      const client = new SmtpClient(smtp_res);
    
      const connectConfig: any = client;
      await client.connectTLS(client);
    
      await client.send({
        from: from_email,
        to: to_email,
        subject: subject,
        content: content,
      });
    
      await client.close();
      return `Email sent from ${from_email} to ${to_email}`;
    }

    Submitted by admin 1393 days ago