Skip to content

y0n0zawa/terraform-provider-resend

Repository files navigation

terraform-provider-resend

Terraform provider for managing Resend resources such as domains and API keys.

Requirements

Usage

terraform {
  required_providers {
    resend = {
      source = "y0n0zawa/resend"
    }
  }
}

provider "resend" {
  api_key = var.resend_api_key # Or set RESEND_API_KEY environment variable
}

Authentication

Set the API key via the provider block or the RESEND_API_KEY environment variable:

export RESEND_API_KEY="re_..."

Resources and Data Sources

Resources

  • resend_domain - Manages a Resend domain
  • resend_api_key - Manages a Resend API key
  • resend_domain_verification - Triggers domain verification

Data Sources

  • resend_domain - Reads a Resend domain
  • resend_api_key - Reads a Resend API key

Example

# Create a domain
resource "resend_domain" "example" {
  name   = "mail.example.com"
  region = "us-east-1"
}

# Verify the domain
resource "resend_domain_verification" "example" {
  domain_id = resend_domain.example.id
}

Development

Build

go build -o terraform-provider-resend

Test

go test ./...

Generate documentation

go generate ./...

License

MPL-2.0

About

Resend provider for Terraform and OpenTofu

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors