File size: 973 Bytes
d6d843f
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/bash

echo "Testing Crypto Intelligence Hub endpoints..."
echo ""

BASE_URL="${1:-http://localhost:7860}"

echo "1. Testing /api/health"
curl -s "$BASE_URL/api/health" | python3 -m json.tool
echo ""

echo "2. Testing /api/coins/top?limit=5"
curl -s "$BASE_URL/api/coins/top?limit=5" | python3 -m json.tool | head -30
echo ""

echo "3. Testing /api/market/stats"
curl -s "$BASE_URL/api/market/stats" | python3 -m json.tool
echo ""

echo "4. Testing /api/sentiment/analyze"
curl -s -X POST "$BASE_URL/api/sentiment/analyze" \
  -H "Content-Type: application/json" \
  -d '{"text":"Bitcoin is pumping to the moon!"}' | python3 -m json.tool
echo ""

echo "5. Testing /api/datasets/list"
curl -s "$BASE_URL/api/datasets/list" | python3 -m json.tool | head -20
echo ""

echo "6. Testing /api/models/list"
curl -s "$BASE_URL/api/models/list" | python3 -m json.tool | head -30
echo ""

echo "All tests completed!"
echo "Open $BASE_URL/ in your browser to see the dashboard"