Quick Start
Quick Start
Get up and running with XCROP in under 5 minutes. This guide shows you how to make your first API call and fetch tweets.
1. Get your API key
Sign up at xcrop.io and navigate to Dashboard → API Keys. Copy your key, which starts with xc_live_.
2. Set environment variable
BASH
export XCROP_API_KEY="xc_live_4k2mNpQrT8vZxLhWcYoE9sJdFbGiUaKn"
3. Make your first request
Fetch trending topicsBASH
curl -X POST https://xcrop.io/api/v2/search \ -H "Authorization: Bearer $XCROP_API_KEY" \ -H "Content-Type: application/json" \ -d '{"query": "#BTC lang:en", "limit": 5, "sort": "engagement"}'
4. Parse the response
JSON
{ "data": [ { "id": "1893045123456789012", "text": "Bitcoin breaks $100K for the first time...", "author": { "id": "12345", "username": "CryptoWhale", "name": "Crypto Whale" }, "metrics": { "likes": 4821, "retweets": 1203, "replies": 389, "views": 182000, "bookmarks": 52 }, "created_at": "2026-03-02T08:14:33Z", "is_reply": false, "is_quote": false, "is_retweet": false, "media": [{ "url": "https://pbs.twimg.com/media/Abc123.jpg", "type": "photo", "video_url": null }] } ], "meta": { "total": 5, "has_next_page": true, "next_cursor": "eyJvZmZzZXQiOjV9", "query": "#BTC lang:en", "latency_ms": 2841 } }
✦
Use the
next_cursor from meta in your next request to paginate through results.5. Next steps
- • Explore the Search Tweets endpoint for advanced filtering
- • Use Interaction Check to verify campaign engagement
- • Install the JavaScript SDK for a type-safe developer experience