Testing the API
Using cURL
# Convert image to WebP
curl -X POST https://api.jetweb.app/convert \
-H "X-Access-Token: demo-token-jetweb-2024" \
-F "[email protected]" \
-F "format=webp" \
-o converted.webp
# Check response headers
curl -i -X POST https://api.jetweb.app/convert \
-H "X-Access-Token: demo-token-jetweb-2024" \
-F "[email protected]"
Demo Tokens
Use these tokens for testing:
demo-token-jetweb-2024- Unlimited conversionspro-token-test-2024- 10,000/month limitfree-token-test-2024- 100/month limit
Testing CDN
After converting an image, use the CDN URL from the response headers:
# Get CDN URLs from headers
curl -i -X POST https://api.jetweb.app/convert \
-H "X-Access-Token: demo-token-jetweb-2024" \
-F "[email protected]" | grep "X-CDN"
# Download from CDN
curl -o image.webp "https://cdn.jetweb.app/{id}.webp?token=...&sig=..."
Testing in Browser
- Open Developer Tools (F12)
- Go to the Network tab
- Load a page with optimized images
- Check Content-Type headers for image/webp or image/avif