API

Ship merch from a webhook.

One POST creates a real order: blank sourced, embroidered, shipped. No dashboard, no ops person, no purchase order.

The canonical case

Someone upgrades to premium. A crewneck ships.

Wire it once. Every future upgrade gifts itself.

stripe-webhook.jsnode
// customer.subscription.created
import { Sewn } from '@sewn/node';
const sewn = new Sewn(process.env.SEWN_KEY);

export async function handler(event) {
  if (event.type !== 'customer.subscription.created') return;

  const { customer, plan } = event.data.object;
  if (plan.nickname !== 'premium') return;

  await sewn.orders.create({
    product: 'crewneck',
    size:    customer.metadata.size ?? 'L',
    ship_to: customer.shipping,
    note:    'Welcome to premium.'
  });
}

Reference

Create an order

POST /v1/orderscurl
curl https://api.sewn.dev/v1/orders \
  -H "Authorization: Bearer $SEWN_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "product": "hat",
    "size": "os",
    "ship_to": {
      "name": "Ada Lovelace",
      "line1": "1 Analytical Way",
      "city": "San Francisco",
      "state": "CA",
      "postal_code": "94110",
      "country": "US"
    }
  }'

No address? Send a claim link

POST /v1/giftscurl
curl https://api.sewn.dev/v1/gifts \
  -H "Authorization: Bearer $SEWN_KEY" \
  -d '{
    "product": "crewneck",
    "email": "ada@example.com",
    "message": "Thanks for shipping with us."
  }'

# They pick a size and enter an address.
# You never store either.

Triggers teams wire up

on_upgrade

Paid plan starts

The crewneck arrives the week they commit. Best retention gift you can send.

on_milestone

Usage milestone hit

Thousandth deploy, hundredth customer, first million rows. The piece marks it.

on_hire

New hire accepts

Day-one kit fires from your HR system, not from someone's shopping trip.

Endpoints, payloads and sandbox keys come with Studio, $100/mo. The manual store is the way in — most teams run it for a month before they wire anything.

Start selling merch tomorrow.

Upload a PNG. See it on four pieces. Decide in two minutes.

Upload a PNG