All workflows

Structured Record Merge

Merge structured records only where enough independent caller-supplied sources agree, while preserving field provenance and surfacing conflicts.

2 credits per call · $0.015 USDC with x402

Sample input

{
  "min_sources": 2,
  "records": [
    {
      "source_id": "a",
      "data": {
        "name": "Acme",
        "country": "GR"
      }
    },
    {
      "source_id": "b",
      "data": {
        "name": "Acme",
        "country": "GR"
      }
    },
    {
      "source_id": "c",
      "data": {
        "name": "Acme Ltd",
        "country": "GR"
      }
    }
  ]
}

Worked sample output

{
  "ok": true,
  "mode": "structured_record_merge",
  "decision": "merged",
  "source_count": 3,
  "min_sources": 2,
  "merged": {
    "country": "GR",
    "name": "Acme"
  },
  "provenance": {
    "country": [
      "a",
      "b",
      "c"
    ],
    "name": [
      "a",
      "b"
    ]
  },
  "conflicts": [],
  "merged_field_count": 2,
  "conflict_count": 0,
  "limitations": [
    "Merge uses exact value agreement across caller-supplied records. It does not decide which disagreeing source is factually correct."
  ]
}

Worked example using published sample data only. Own-data execution is paid.

Connect in curl

Set BOUNTY_API_KEY privately after your payment is verified. Change the retry key for each new logical request.

curl 'https://bounty-engineer-x402-prod.onrender.com/v1/prepaid/structured-record-merge' \
  -H "Authorization: Bearer $BOUNTY_API_KEY" \
  -H 'Content-Type: application/json' \
  -H 'Idempotency-Key: workflow-request-001' \
  -H 'X-Max-Credits: 2' \
  --data '{"min_sources":2,"records":[{"source_id":"a","data":{"name":"Acme","country":"GR"}},{"source_id":"b","data":{"name":"Acme","country":"GR"}},{"source_id":"c","data":{"name":"Acme Ltd","country":"GR"}}]}'

Connect in n8n

Download the inactive n8n template. Import it, configure the private Header Auth credential, inspect the sample and run it manually. A new execution creates a new billable request; there is no automatic schedule.

Use an HTTP POST to https://bounty-engineer-x402-prod.onrender.com/v1/prepaid/structured-record-merge. Send JSON and these headers; store the Bearer token as a private credential.

{
  "method": "POST",
  "headers": {
    "Authorization": "Bearer YOUR_PRIVATE_API_KEY",
    "Content-Type": "application/json",
    "Idempotency-Key": "UNIQUE_PER_LOGICAL_REQUEST",
    "X-Max-Credits": "2"
  },
  "body": {
    "min_sources": 2,
    "records": [
      {
        "source_id": "a",
        "data": {
          "name": "Acme",
          "country": "GR"
        }
      },
      {
        "source_id": "b",
        "data": {
          "name": "Acme",
          "country": "GR"
        }
      },
      {
        "source_id": "c",
        "data": {
          "name": "Acme Ltd",
          "country": "GR"
        }
      }
    ]
  }
}

Reuse a retry key only for the same input. Failed execution returns reserved credits. Full integration and recovery guide · Machine-readable recipe