Skip to main content
POST
Infer Schema From File

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-Organization-Id
string | null

Body

multipart/form-data
file
file
required

CSV or Excel file to analyze

prompt
string
required

Description of the data (e.g., 'Product catalog for electronics retailer')

generate_taxonomy
boolean
default:false

If true, also generate a suggested taxonomy

max_sample_rows
integer
default:20

Maximum rows to sample for analysis (default 20)

Response

Successful Response

Response with inferred configuration for enrichment.

file_name
string
required

Name of the uploaded file

total_rows
integer
required

Total rows in the file

sample_rows_used
integer
required

Number of rows sampled for inference

suggested_schema
Suggested Schema · object
required

JSON Schema with all fields found in the data. 'x-field-category' indicates 'input' (existing) or 'enriched' (suggested to add via web).

web_enrichment_fields
FieldDefinition · object[]
required

Fields to extract via web enrichment. Use as output_schema in /public/enrich.

suggested_taxonomy
Suggested Taxonomy · object | null

Taxonomy in TaxonomyInput format. Only present if generate_taxonomy=true.