Skip to main content

REST API

Everything in the web app is available over a JSON REST API, so you can refresh test data from a CI/CD pipeline.

Authenticate​

curl -s -X POST https://<host>/auth/signin \
-H 'Content-Type: application/json' \
-d '{"username":"ci.bot","password":"…"}'
# → {"access_token":"eyJ…","token_type":"bearer"}

Send the token on every call: Authorization: Bearer <access_token>. Use a dedicated Member account for automation, and save the passwords of the connections it uses.

Main endpoints​

AreaEndpoint
Connections/api/v1/connections
Virtual data sets & prune/api/v1/vds · POST /api/v1/vds/shrink to run · GET /api/v1/vds/shrink/{id}/status · /result · /artifacts
Bloom plansPOST /api/v1/bloom/plans {vds_id, learn, learn_columns} (from a VDS) · POST /api/v1/bloom/plans/from-sql (DDL or template) · GET /api/v1/bloom/templates · POST /api/v1/bloom/plans/{id}/preflight
Bloom runsPOST /api/v1/bloom/plans/{id}/runs {seed, scale, formats} · GET /api/v1/bloom/runs/{id}/status · /runs/{id}/artifacts
LoadPOST /api/v1/bloom/runs/{id}/load/preflight to check · POST /api/v1/bloom/runs/{id}/load to load

Long jobs return a task ID. Their …/status endpoints stream progress as server-sent events.

Load options​

FieldMeaning
connection_idThe target. It must be approved as a test database, or the call returns 403 Approve this connection as a test database before loading into it.
schema_nameTarget schema; the connection's default if empty
modeappend (default) or replace
create_missingCreate missing tables
keep_schemasFor plans read from several schemas: load each table into its own schema
create_schemaCreate the target schema if it's missing
recreate_tablesPlan tables to drop and create again before loading
confirm_databaseThe target database's exact name. Required for replace and recreate_tables.

learn_columns lists the columns whose value mixes a plan may learn. Leave it empty to learn table sizes only.

Example: refresh test data in a pipeline​

TOKEN=$(curl -s -X POST https://<host>/auth/signin -H 'Content-Type: application/json' \
-d '{"username":"ci.bot","password":"'"$DF_PASSWORD"'"}' | jq -r .access_token)

# Generate a fresh, repeatable data set from an existing plan
curl -s -X POST https://<host>/api/v1/bloom/plans/$PLAN_ID/runs \
-H "Authorization: Bearer $TOKEN" -H 'Content-Type: application/json' \
-d '{"seed": 42, "scale": 1, "formats": ["csv"]}'

Responses to handle​

StatusMeaning
402The licence is missing or expired, so DataFactory is read-only. See Licence.
403Not allowed, e.g. the load target isn't an approved test database.
429Three runs are already queued or running for this account. Wait for one to finish.

Interactive reference​

The full, interactive API reference is at https://<host>/api/docs when your admin sets API_DOCS=true (it's off by default).