Stewi API
Endpoints

Pipeline Events

Push normalized records directly into the processing pipeline.

POST /api/pipeline/events

Use this endpoint if you have sources that bypass Merge.dev. Provide a normalized record payload and Stewi will treat it the same as a webhook event.

Request

POST /api/pipeline/events HTTP/1.1
Authorization: Bearer <STEW_API_KEY>
Content-Type: application/json
{
  "provider": "internal",
  "record_type": "note",
  "external_id": "note_42",
  "title": "Q4 forecast adjustment",
  "content": "Updated ARR guidance to 19.4M.",
  "metadata": {
    "source": "finance-notes",
    "channel": "Slack",
    "author": "steward@example.com"
  },
  "occurred_at": "2024-11-29T22:08:00.000Z"
}

Response

{
  "ok": true,
  "normalizedRecordId": "e6a1f502-6b1d-4c71-b372-0d8d1267c0f2"
}

Validation Rules

  • provider, record_type, and content are required.
  • external_id is used for idempotency; duplicates update the existing record.
  • metadata must be JSON-serializable (nested objects allowed).

On this page