Getting Started: Upload Your First CSV and Get an API in 60 Seconds
A step-by-step walkthrough of uploading a CSV file and making your first API request.
What you'll learn
- How to prepare and upload a CSV file
- How csv-api detects column types automatically
- How to grab your API key and make your first request
Step 1: Prepare your CSV
Any standard CSV file will work. Make sure the first row contains your column headers. Here's an example products.csv:
name,category,price,in_stock Wireless Mouse,Electronics,29.99,true Standing Desk,Furniture,449.00,true USB-C Hub,Electronics,54.99,false Ergonomic Chair,Furniture,389.00,true Webcam HD,Electronics,79.99,true
csv-api supports up to 100 columns and will auto-detect types including integers, decimals, booleans, dates, and text.
Step 2: Upload your file
After signing up and logging in, click New Dataset from your dashboard. Select your CSV file and click Upload.
You'll see a preview screen showing:
- • The detected column names and their inferred types
- • A sample of the first few rows
- • The total number of rows to be imported
Review the preview and click Confirm to finalize the import. Your data will be processed in the background and your API will be ready within seconds.
Step 3: Get your API key
Navigate to your Account page and create a new API key. Give it a descriptive name like "My App" so you can identify it later.
Important: Your API key token is only shown once when created. Copy it and store it somewhere safe. If you lose it, you'll need to create a new one.
Step 4: Make your first request
Find your dataset's public ID on its detail page (it looks like d_a1b2c3d4e5f6g7h8). Then use curl or any HTTP client:
curl -H "Authorization: Bearer YOUR_API_KEY" \ "https://csv-api.com/api/v1/datasets/YOUR_PUBLIC_ID/records"
You'll get back a JSON response with your data:
{
"data": [
{
"name": "Wireless Mouse",
"category": "Electronics",
"price": 29.99,
"in_stock": true
},
{
"name": "Standing Desk",
"category": "Furniture",
"price": 449.00,
"in_stock": true
}
],
"meta": {
"total": 5,
"page": 1,
"per_page": 25,
"total_pages": 1
}
}
What's next?
Now that your API is live, you can start filtering, sorting, and paginating your data. Check out the next tutorial on Mastering Filters to learn how to query your data with precision.