See llms.txt for all machine-readable content.

Back to Templates

Validate and normalize product feeds with ContentSweep Feeds API

Quick overview

This workflow manually submits a CSV product feed to the ContentSweep Feeds API, validates it against a target JSON schema and mapping, creates and approves a profile, runs a normalization job, polls for completion, and downloads the normalized JSONL output when validation passes.

How it works

  1. Starts when you run the workflow manually.
  2. Loads the ContentSweep configuration, including the CSV feed content, target schema, mapping rules, and an operator-approval flag.
  3. If operator approval is enabled, uploads the CSV to ContentSweep and requests a preview against the provided target schema.
  4. Creates a ContentSweep profile with the mapping and contract rules, then approves the profile using the returned profile hash.
  5. Requests a quote and, if the source is compatible, starts a ContentSweep job using the quote ID and idempotency key.
  6. Polls the job status every 5 seconds until it completes or fails, stopping after 60 checks.
  7. If the job completes, fetches the validation report and downloads the normalized JSONL output file when the verdict is passed.

Setup

  1. Create a ContentSweep API key and add it as an HTTP Header Auth credential using the header name X-API-Key.
  2. In the Config step, replace YOUR_APPROVED_PROFILE_ID, YOUR_REJECTED_JOB_ID, YOUR_UNIQUE_IMPORT_KEY, and YOUR_EMAIL, and update the CSV feed, target schema, mapping, and contract rules for your dataset.
  3. Set approvedByOperator to true in the Config step when you are ready to allow the workflow to submit and run jobs.