Developers

Node.js SDK

Use the Artmail API from Node.js with REST or the official SDK (coming soon)

Node.js

This guide shows how to integrate Artmail into your Node.js application using the REST API. An official artmail-node SDK is planned; until then, use fetch or axios with the examples below.

Installation (SDK — Coming Soon)

Bash
Loading...

The official artmail-node package will provide a typed client, automatic retries, and webhook signature verification. Join our waitlist to be notified when it's available.


REST API Usage

Setup

Store your API key in an environment variable:

Bash
Loading...
Typescript
Loading...

Send Email (Direct)

Typescript
Loading...

Send Email (Template)

Typescript
Loading...

Batch Send (up to 50 recipients)

Typescript
Loading...

Using Axios

Typescript
Loading...

Webhook Verification

When receiving webhooks, verify the signature before processing:

Typescript
Loading...

Raw body required

Use express.raw({ type: "application/json" }) so the body stays a string for signature verification. Do not use express.json() before verifying.


Error Handling

Typescript
Loading...

Next Steps

Send Email API

Full reference for the send endpoints.

Send Email →

Webhooks

Set up webhooks to receive event notifications.

Webhooks →