For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dashboard
User GuideDeveloper GuidesAPI Reference
User GuideDeveloper GuidesAPI Reference
    • Overview
  • Runtype API
      • POSTBulk delete records
      • GETList records
      • POSTCreate record
      • GETDiscover record schema
      • GETGet field values
      • POSTPreview record filter
      • GETGet record details
      • PUTUpdate record
      • DELDelete record
      • GETGet record step results
      • GETGet record costs
      • GETGet record results
      • DELDelete record result
      • POSTBulk edit records
      • POSTUpload CSV records
Dashboard
LogoLogo
Runtype APIRecords

Upload CSV records

POST
/v1/records/upload-csv
POST
/v1/records/upload-csv
$curl -X POST https://api.runtype.com/v1/records/upload-csv \
> -H "Authorization: Bearer <token>" \
> -H "Content-Type: multipart/form-data"
1{
2 "success": true,
3 "message": "CSV file processed successfully with some warnings.",
4 "created": 45,
5 "errors": 2,
6 "errorDetails": [
7 "Row 12: Missing required field 'email'.",
8 "Row 27: Invalid date format in 'signup_date'."
9 ],
10 "records": [
11 {
12 "id": "a1b2c3d4-e5f6-7890-ab12-cd34ef567890",
13 "type": "customer",
14 "name": "Acme Corporation",
15 "metadata": {}
16 }
17 ]
18}

Upload and process a CSV file to create records in bulk. Either supply typeColumn to read the type from a column, or typeValue to assign the same constant type to every row (skipping the column lookup). typeValue takes precedence when both are provided.

Was this page helpful?
Previous

List available models

Next
Built with

Authentication

AuthorizationBearer
API key or Clerk session token

Request

This endpoint expects a multipart form.
fileany or nullOptional
typeColumnstringOptional
nameColumnstringOptional
typeValuestringOptional<=255 characters

Response

CSV upload result
successboolean
messagestring
createdinteger
errorsinteger
errorDetailslist of strings
recordslist of objects

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
500
Internal Server Error