GithubHelp home page GithubHelp logo

archived-resend-go's Introduction

Resend is the email platform for developers.

SDK Installation

go get github.com/resendlabs/resend-go

Authentication

To authenticate you need to add an Authorization header with the contents of the header being Bearer re_123456789 where re_123456789 is your API Key. First, you need to get an API key, which is available in the Resend Dashboard.

Authorization: Bearer re_123

SDK Example Usage

package main

import (
    "context"
    "log"
    "github.com/resendlabs/resend-go"
    "github.com/resendlabs/resend-go/pkg/models/shared"
    "github.com/resendlabs/resend-go/pkg/models/operations"
)

func main() {
    s := resend.New(resend.WithSecurity(
        shared.Security{
            BearerAuth: "Bearer YOUR_BEARER_TOKEN_HERE",
        },
    ))
    
    req := operations.SendEmailRequest{
        Request: shared.Email{
            From: "[email protected]",
            To: "[email protected]",
            Subject: "Welcome to Resend!",
            Text: "Hello, World!",
        },
    }

    ctx := context.Background()
    res, err := s.Email.SendEmail(ctx, req)
    if err != nil {
        log.Fatal(err)
    }

    if res.SendEmailResponse != nil {
        // handle response
    }
}

SDK Available Operations

Email

  • SendEmail - Send an email

Contributions

While we value open-source contributions to this SDK, this library is generated programmatically. Feel free to open a PR or a Github issue as a proof of concept and we'll do our best to include it in a future release !

SDK Generated by Speakeasy

archived-resend-go's People

Contributors

simplesagar avatar speakeasybot avatar zenorocha avatar tristanspeakeasy avatar anuraagnalluri avatar github-actions[bot] avatar

Stargazers

Henrique A. Lavezzo avatar Avelino avatar Luis Quiñones avatar Daniel Moretti V. avatar David A avatar Luis Felipe Sousa avatar Erik Dasque avatar Diego Aquino avatar Firmino Changani avatar Leonardo Lima avatar Gustavo Parra avatar NicBuihner avatar Weldhapi avatar  avatar

Watchers

 avatar Weldhapi avatar  avatar

Forkers

ndimares

archived-resend-go's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.