Developer guide

Email to JSON API

ParseForce gives backend teams a stable JSON contract for inbound email. Define a schema once, route emails to a mailbox, and receive parsed output at your webhook.

What developers usually need

The hard part is not receiving email. It is turning inconsistent message bodies into a JSON payload your backend can trust.

  • One mailbox maps to one extraction schema.
  • The output contract stays JSON-first instead of IMAP-first.
  • Your app consumes webhook payloads, not raw MIME parsing code.

How ParseForce fits the flow

Inbound email is normalized, parsed against the mailbox schema, and forwarded as structured JSON to your application.

  • Schema-guided extraction supports nested objects and arrays.
  • Webhook payloads include both parsed data and raw email metadata.
  • Delivery logs let you inspect failed downstream requests.

Common backend workflows

Most teams use an email to JSON API to move inbox events into systems that already expect structured inputs.

  • Create CRM leads or support tickets from inbound form notifications.
  • Push supplier and order emails into queues, ERPs, or workflow engines.
  • Store the parsed payload next to the original sender and subject for traceability.

Example JSON output

Example webhook payload shape for this workflow.

json

{
  "event": "email.parsed",
  "mailboxId": "mbx_42d3",
  "parsedData": {
    "lead_name": "Avery Stone",
    "company": "Northline Labs",
    "email": "avery@northline.dev",
    "priority": "high",
    "use_case": "parse partner invoices into JSON"
  },
  "rawEmail": {
    "from": "website@northline.dev",
    "subject": "New automation request"
  }
}

Node.js webhook consumer

Minimal Node.js example for consuming ParseForce output.

node.js

import express from "express";

const app = express();
app.use(express.json());

app.post("/webhooks/parseforce", (req, res) => {
  if (req.body.event !== "email.parsed") {
    return res.status(202).end();
  }

  const { parsedData, rawEmail } = req.body;

  console.log("from:", rawEmail.from);
  console.log("lead email:", parsedData.email);
  console.log("priority:", parsedData.priority);

  return res.status(204).end();
});

app.listen(3000);

Related guides

Related ParseForce pages

Explore related ParseForce pages for webhook delivery, schema design, and implementation details for adjacent email automation workflows.

See the full product overview