Get Your API Key
Navigate to API Keys
Go to Settings → API Keys in your dashboard
Generate a New Key
Click Create API Key and copy it somewhere safe
Never commit your API key to version control or expose it in client-side code.
Install the SDK
Send Your First Email
import { Transmit } from 'transmitdev';
const client = new Transmit({
apiKey: process.env.TRANSMIT_API_KEY
});
async function sendEmail() {
try {
const response = await client.emails.send({
from: '[email protected]',
to: '[email protected]',
subject: 'My First Email',
html: `
<h1>Hello from Transmit!</h1>
<p>This is my first email sent via the Transmit API.</p>
`
});
console.log('Email sent!', response.id);
} catch (error) {
console.error('Error sending email:', error);
}
}
sendEmail();
Verify Your Domain
Before sending emails in production, you need to verify your domain:
Add Your Domain
Go to Settings → Domains and add your sending domain
Add DNS Records
Copy the provided DNS records (SPF, DKIM, DMARC)
Wait for Verification
Verification usually takes 24-48 hours
Get Trial Credits
Once verified, you’ll receive free trial credits automatically
Next Steps