Multi-Chain Cryptocurrency Security Scanner API
Detect rug pulls and vulnerabilities across 7+ blockchains
The amIrug.xyz API provides comprehensive smart contract security analysis across multiple blockchains. Our AI-powered system analyzes contract code, tokenomics, and social signals to detect potential rug pulls and vulnerabilities.
Analysis across 7+ major blockchains including Ethereum, Solana, BSC, and Layer 2 solutions.
Instant vulnerability detection with comprehensive risk scoring from 0-100%.
Advanced pattern recognition for obfuscated vulnerabilities and social engineering.
Simple REST endpoints with JSON responses, rate limiting, and comprehensive error handling.
All API requests require authentication using a Bearer token. Premium plans include extended features and higher rate limits.
Authorization: Bearer amr_1234567890abcdef1234567890abcdef
| Plan | Requests/Month | Rate Limit | Features |
|---|---|---|---|
| Free | 100 | 10/hour | Basic scanning |
| Starter | 10,000 | 100/hour | Advanced AI analysis |
| Professional | 100,000 | 500/hour | All features + priority support |
Analyze a smart contract for security vulnerabilities and rug pull indicators.
| Parameter | Type | Required | Description |
|---|---|---|---|
| address | string | Yes | Smart contract address (0x... for EVM, base58 for Solana) |
| detailed | boolean | No | Include detailed vulnerability analysis (Premium only) |
| social_analysis | boolean | No | Include social sentiment analysis (Premium only) |
{
"risk_score": 75,
"risk_level": "HIGH",
"contract_name": "SuspiciousToken",
"chain": "ethereum",
"is_verified": false,
"ownership_renounced": false,
"suspicious_functions": [
"Found 'selfdestruct' capability controlled by owner",
"Detected hidden mint function with unlimited supply"
],
"ai_analysis": {
"risk_score": 75,
"owner_reputation": "Low - Limited history",
"social_signals": "Weak - Limited community engagement",
"team_assessment": "Fully Anonymous - No verifiable identity",
"confidence": 0.92
},
"premium_analysis": {
"vulnerability_scan": "7 critical vulnerabilities detected",
"social_sentiment": "Negative sentiment: 73% negative mentions",
"cross_chain_presence": "No activity on other chains",
"historical_performance": "No historical data available",
"liquidity_analysis": "Low liquidity: $12K total",
"holder_distribution": "Whale concentration: 85% held by top 10"
},
"usage_info": {
"api_key": "amr_1234...",
"plan": "professional",
"status": "active",
"monthly_scan_limit": 100000,
"scans_remaining": 99847
}
}
Official PHP SDK for seamless integration with your PHP applications.
composer require amirug/php-sdk
<?php
require_once 'vendor/autoload.php';
use AmIRug\SDK\SecurityScanner;
// Initialize the scanner
$scanner = new SecurityScanner('your-api-key-here');
try {
// Analyze a contract
$result = $scanner->analyzeContract('0x742d35Cc6634C0532925a3b844Bc454e4438f44e');
echo "Risk Level: " . $result->getRiskLevel() . "\n";
echo "Risk Score: " . $result->getRiskScore() . "%\n";
echo "Chain: " . $result->getChain() . "\n";
// Check for specific vulnerabilities
if ($result->hasVulnerabilities()) {
echo "Vulnerabilities found:\n";
foreach ($result->getVulnerabilities() as $vulnerability) {
echo "- " . $vulnerability . "\n";
}
}
// Premium features
if ($result->hasPremiumAnalysis()) {
$premium = $result->getPremiumAnalysis();
echo "Social Sentiment: " . $premium->getSocialSentiment() . "\n";
echo "Liquidity Analysis: " . $premium->getLiquidityAnalysis() . "\n";
}
} catch (Exception $e) {
echo "Error: " . $e->getMessage() . "\n";
}
?>
<?php
// Batch analysis
$contracts = [
'0x742d35Cc6634C0532925a3b844Bc454e4438f44e',
'0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48',
'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v'
];
$results = $scanner->batchAnalyze($contracts);
foreach ($results as $address => $result) {
if ($result->isSuccess()) {
echo "Contract: " . $address . "\n";
echo "Risk: " . $result->getRiskLevel() . " (" . $result->getRiskScore() . "%)\n";
echo "Safe to invest: " . ($result->getRiskScore() < 30 ? "Yes" : "No") . "\n\n";
} else {
echo "Failed to analyze: " . $address . " - " . $result->getError() . "\n\n";
}
}
// Set options
$scanner->setOptions([
'detailed_analysis' => true,
'social_analysis' => true,
'timeout' => 30
]);
// Get usage statistics
$usage = $scanner->getUsageStats();
echo "API calls this month: " . $usage->getCallsUsed() . "/" . $usage->getCallsLimit() . "\n";
echo "Rate limit remaining: " . $usage->getRateLimitRemaining() . "\n";
?>
| Method | Parameters | Description |
|---|---|---|
| analyzeContract() | string $address | Analyze a single contract |
| batchAnalyze() | array $addresses | Analyze multiple contracts |
| setOptions() | array $options | Configure SDK behavior |
| getUsageStats() | - | Get API usage statistics |
JavaScript SDK for frontend and Node.js applications.
npm install @amirug/js-sdk
const AmIRug = require('@amirug/js-sdk');
// Initialize
const scanner = new AmIRug('your-api-key-here');
// Analyze a contract
async function analyzeContract() {
try {
const result = await scanner.analyze('0x742d35Cc6634C0532925a3b844Bc454e4438f44e');
console.log('Risk Level:', result.riskLevel);
console.log('Risk Score:', result.riskScore + '%');
console.log('Chain:', result.chain);
if (result.vulnerabilities.length > 0) {
console.log('Vulnerabilities:');
result.vulnerabilities.forEach(vuln => {
console.log('-', vuln);
});
}
} catch (error) {
console.error('Analysis failed:', error.message);
}
}
analyzeContract();
import React, { useState } from 'react';
import AmIRug from '@amirug/js-sdk';
const ContractScanner = () => {
const [address, setAddress] = useState('');
const [result, setResult] = useState(null);
const [loading, setLoading] = useState(false);
const scanner = new AmIRug(process.env.REACT_APP_AMIRUG_API_KEY);
const handleScan = async () => {
setLoading(true);
try {
const analysis = await scanner.analyze(address);
setResult(analysis);
} catch (error) {
console.error('Scan failed:', error);
} finally {
setLoading(false);
}
};
return (
<div>
<input
type="text"
placeholder="Enter contract address"
value={address}
onChange={(e) => setAddress(e.target.value)}
/>
<button onClick={handleScan} disabled={loading}>
{loading ? 'Scanning...' : 'Scan Contract'}
</button>
{result && (
<div className={`risk-${result.riskLevel.toLowerCase()}`}>
<h3>Risk Level: {result.riskLevel}</h3>
<p>Score: {result.riskScore}%</p>
<p>Chain: {result.chain}</p>
</div>
)}
</div>
);
};
export default ContractScanner;
Python SDK for data analysis and automation workflows.
pip install amirug-sdk
import amirug
# Initialize the client
client = amirug.Client(api_key='your-api-key-here')
# Analyze a contract
result = client.analyze_contract('0x742d35Cc6634C0532925a3b844Bc454e4438f44e')
print(f"Risk Level: {result.risk_level}")
print(f"Risk Score: {result.risk_score}%")
print(f"Chain: {result.chain}")
if result.vulnerabilities:
print("Vulnerabilities found:")
for vuln in result.vulnerabilities:
print(f"- {vuln}")
# Batch analysis with pandas
import pandas as pd
contracts = [
'0x742d35Cc6634C0532925a3b844Bc454e4438f44e',
'0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48'
]
results = client.batch_analyze(contracts)
df = pd.DataFrame([{
'address': addr,
'risk_score': result.risk_score,
'risk_level': result.risk_level,
'chain': result.chain,
'verified': result.is_verified
} for addr, result in results.items()])
print(df)
curl -X POST https://amirug.xyz/premium-api.php \
-H "Content-Type: application/json" \
-H "Authorization: Bearer amr_1234567890abcdef1234567890abcdef" \
-d '{
"address": "0x742d35Cc6634C0532925a3b844Bc454e4438f44e",
"detailed": true,
"social_analysis": true
}'
const fetch = require('node-fetch');
async function scanContract(address) {
const response = await fetch('https://amirug.xyz/premium-api.php', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer amr_1234567890abcdef1234567890abcdef'
},
body: JSON.stringify({
address: address,
detailed: true
})
});
const result = await response.json();
return result;
}
scanContract('0x742d35Cc6634C0532925a3b844Bc454e4438f44e')
.then(result => console.log(result))
.catch(error => console.error(error));
| Status Code | Error | Description |
|---|---|---|
| 200 | Success | Request completed successfully |
| 400 | Bad Request | Invalid contract address format |
| 401 | Unauthorized | Invalid or missing API key |
| 429 | Rate Limited | Too many requests, please slow down |
{
"error": true,
"code": 401,
"message": "Invalid API key",
"details": "The provided API key is not valid or has expired"
}
Need help integrating the API? Contact our support team:
© 2025 amIrug.xyz - Machine learning meets crypto protection