ChainX Scanner API
A comprehensive smart contract vulnerability scanner with AI-powered analysis, security scoring, and subscription management.
Real-world Use: This API can be integrated into development tools, CI/CD pipelines, or security analysis platforms to automate the process of identifying vulnerabilities in Solidity smart contracts.
For support and questions, contact support@chainx.id or visit our Discord community.
Key Features
- 12+ Vulnerability Patterns: Detect Smart Contract Weakness Classification (SWC) patterns including reentrancy, integer overflow, and more
- Security Scoring: Automatic security rating from 0-100 with detailed severity breakdown
- AI-Powered Analysis: Advanced vulnerability analysis using OpenRouter AI models
- Fast & Reliable: Instant scan results with global API infrastructure
- Flexible Plans: Free tier for testing, plus Basic and Pro plans for production use
- Easy Integration: Simple HTTP API with multiple language support
- Rate Limiting & Quotas: Fair usage with daily scan limits per plan
- Webhook Support: Real-time notifications when scans complete
Quick Start
Get up and running in 3 minutes:
- 1. Register
- 2. Verify Email
- 3. Get API Key
- 4. Scan Contract
curl -X POST https://chainx-api-a154bfdeaf7a.herokuapp.com/api/register \ -H "Content-Type: application/json" \ -d '{ "email": "your@email.com", "password": "securePassword123", "name": "Your Name" }'
Check your email for OTP, then verify:
curl -X POST https://chainx-api-a154bfdeaf7a.herokuapp.com/api/verify-email \ -H "Content-Type: application/json" \ -d '{ "email": "your@email.com", "otp": "12345678" }'
Login and generate an API key:
curl -X POST https://chainx-api-a154bfdeaf7a.herokuapp.com/api/generate-api-key \ -H "Content-Type: application/json" \ -d '{ "userId": "your-user-id", "type": "PRODUCTION", "name": "My API Key" }'
Upload and scan your contract:
curl -X POST https://chainx-api-a154bfdeaf7a.herokuapp.com/api/v1/scan \ -H "X-API-Key: your-api-key" \ -F "file=@contract.sol"
What Can You Do?
Standard Vulnerability Scanning
Detect 12+ known Smart Contract Weakness Classification (SWC) patterns in seconds:
- Integer overflow/underflow (SWC-101)
- Reentrancy attacks (SWC-107)
- Unprotected functions (SWC-105, SWC-106)
- Authorization issues (SWC-114, SWC-115)
- And more...
AI-Powered Analysis
Get deep insights using advanced AI models via OpenRouter:
- Detailed vulnerability explanations
- Security best practices recommendations
- Custom risk assessment
- Comprehensive audit reports
Subscription Plans
Choose the plan that fits your needs:
| Feature | Free | Basic | Pro |
|---|---|---|---|
| Scans/Day | 5 | 100 | 1000 |
| Max File Size | 100 KB | 1 MB | 5 MB |
| AI Analysis | ❌ | ❌ | ✅ |
| Support | Community | Email + Chat | |
| Price | Free | $9.99/mo | $29.99/mo |
Integration Examples
GitHub Actions
- name: Scan Contracts run: | curl -X POST https://chainx-api-a154bfdeaf7a.herokuapp.com/api/v1/scan \ -H "X-API-Key: ${{ secrets.CHAINX_API_KEY }}" \ -F "file=@contracts/Token.sol"
Node.js
const response = await fetch('https://chainx-api-a154bfdeaf7a.herokuapp.com/api/v1/scan', { method: 'POST', headers: { 'X-API-Key': apiKey }, body: formData});
Python
response = requests.post( 'https://chainx-api-a154bfdeaf7a.herokuapp.com/api/v1/scan', headers={'X-API-Key': api_key}, files={'file': open('contract.sol', 'rb')})
Documentation
- Getting Started - Complete setup guide
- Smart Contract Scanning - Detailed scanning documentation
- Authentication - API key management
- Subscription Plans - Plan comparison and quotas
- Use Cases - Real-world integration examples
- API Reference - Complete API documentation
Supported Vulnerabilities
ChainX Scanner detects the following SWC (Smart Contract Weakness Classification) patterns:
- SWC-101 - Integer Overflow and Underflow
- SWC-103 - Floating Pragma
- SWC-104 - Unchecked Call Return Value
- SWC-105 - Unprotected Ether Withdrawal
- SWC-106 - Unprotected SELFDESTRUCT
- SWC-107 - Reentrancy
- SWC-112 - Delegatecall to Untrusted Callee
- SWC-113 - DoS with Failed Call
- SWC-114 - Tx.Origin Authentication
- SWC-115 - Authorization via tx.origin
- SWC-116 - Block Values as Time Proxies
- SWC-118 - Incorrect Constructor Name
- SWC-120 - Weak Sources of Randomness
- SWC-123 - Requirement Violation
- SWC-132 - Unexpected Gas Usage
Complete vulnerability reference →
API Endpoints
All requests require authentication via X-API-Key header (except registration/login endpoints).
Authentication
POST /api/register- Create accountPOST /api/verify-email- Verify email with OTPPOST /api/login- Login to accountPOST /api/generate-api-key- Generate API key
Scanning
POST /api/v1/scan- Scan smart contractPOST /api/v1/ai-scan- AI-powered analysis scanGET /api/v1/user-api-keys- List your API keysGET /api/v1/user-plan- Check subscription plan
Account Management
POST /api/forgot-password- Request password resetPOST /api/reset-password- Reset passwordPOST /api/resend-otp- Resend verification OTP
Rate Limits & Quotas
All plans include daily scan limits and file size restrictions:
Free Plan: 5 scans/day, 100 KB max file
Basic Plan: 100 scans/day, 1 MB max file
Pro Plan: 1000 scans/day, 5 MB max file
Popular Use Cases
Development Teams
Integrate security scanning into your CI/CD pipeline with GitHub Actions, GitLab CI, or Jenkins.
Security Auditors
Batch scan multiple projects and generate professional audit reports with security scores and recommendations.
Smart Contract Platforms
Provide security scanning as a platform feature for your users.
DevOps
Automate pre-deployment security checks to catch vulnerabilities before production.
Security & Privacy
- No Code Storage: We don't store your contract code permanently
- Encrypted Transmission: All data encrypted in transit with HTTPS/TLS
- API Key Security: Industry-standard API key authentication
- Compliance: GDPR compliant with transparent data handling
Support
- Documentation: Complete guides and API reference
- Email Support: support@chainx.id (Free, Basic, Pro plans)
- Community: Discord
- Enterprise: enterprise@chainx.id for custom solutions