Export jobs as CSV

Download a CSV of moderation jobs in a date range, including prompt and category metadata.

GEThttps://api.omnifence.ai/api/v1/jobs/export

Requires the job:read scope. Requests without this scope receive a 403 FORBIDDEN response. See authentication.

The response streams as text/csv; charset=utf-8 with a UTF-8 BOM so spreadsheet apps decode prompts correctly.

Date range#

Both from and to are required ISO 8601 date-time strings. Jobs are filtered by created_at (from inclusive, to exclusive). The maximum window is 366 days; longer ranges return 400 INVALID_REQUEST.

CSV columns#

Column Description
job_id UUID of the job
type The job's modality. See below for the full set
status queued, processing, completed, or failed
is_prohibited true if rejected, false if passed, or empty if not yet decided
created_at ISO 8601 timestamp the job was submitted
completed_at ISO 8601 timestamp the job finished, or empty
api_key_id The API key the job was submitted with, or empty. See below
api_key_name That key's current name, or empty
prompt Original prompt submitted with the job
reason Why the content was rejected
category_nsfw true, false, or empty. See below

type values#

The column is written verbatim from the stored job, so a range that reaches back far enough can contain more than the current values. Validate against the full set:

  • text, image, video, audio: the moderation modalities. chat is a retired modality kept for historical jobs.
  • pre, post: retired values on jobs created before the modality split. The API never writes them for new jobs, but existing rows keep them.
  • generate, companion_chat, companion_retarget, companion_media_tag: non-moderation job types. They appear only if your account uses them.

Empty API key cells#

api_key_id is empty for a job that no API key submitted: one sent from the dashboard, and any job created before key attribution shipped.

api_key_name is resolved when you run the export, not stored on the job, so it is also empty for a key you never named and for one you have since deleted. api_key_id survives both, so group on it rather than on the name.

Empty category_nsfw cells#

category_nsfw is the only category column, and an empty cell means the job carries no NSFW label rather than a clean one. Three different situations produce it:

  • The job is a text, chat, audio, or generate job. The NSFW check does not apply to those, so they never carry the label, even when complete.
  • The job is an image or video job, but you disabled the NSFW check for your account.
  • The job has not finished.

A false cell means the NSFW check ran and found the content clean.

Example#

Shell
curl -G "https://api.omnifence.ai/api/v1/jobs/export" \
  -H "Authorization: Bearer $API_KEY" \
  --data-urlencode "from=2026-04-01T00:00:00Z" \
  --data-urlencode "to=2026-05-01T00:00:00Z" \
  --output jobs-april.csv

to is exclusive, so use the start of the day after your last desired date (e.g. 2026-05-01T00:00:00Z to include all of April).

Request#

Headers#

Name Type Required Description
Authorization string Yes Your API key as a Bearer token: Bearer YOUR_API_KEY.

Query parameters#

Name Type Required Description
from string (date-time) Yes Inclusive lower bound on job created_at (ISO 8601).
to string (date-time) Yes Exclusive upper bound on job created_at (ISO 8601). Use the start of the day after your last desired date to include the full final day.

Responses#

200 OK#

CSV stream of jobs.

The response body is text/csv.