API Overview

The ScanLikely API provides content-aware QR code analysis capabilities, enabling developers to integrate advanced QR security features into their applications. Our API recognizes and analyzes different content types including WiFi credentials, payment requests, social links, passkey authentication, and general websites.

Content Classification

Automatically identify QR content types: WiFi, Payment, Social, Passkey, Website

Threat Detection

Real-time analysis for malicious URLs, fake networks, payment fraud, and social engineering

Security Scoring

Numerical risk assessment with detailed security recommendations

Privacy-First

Optional on-device processing mode for maximum privacy protection

Authentication

ScanLikely API uses API keys for authentication. Include your API key in the Authorization header:

HTTP Header
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json

Base URL

Production
https://api.scanlikely.com/v1

QR Code Analysis

POST /analyze

Analyze QR code content for security threats and content classification.

Request Body

JSON
{
  "qr_content": "WIFI:T:WPA;S:CoffeeShop-Guest;P:password123;;",
  "analysis_level": "comprehensive",
  "return_recommendations": true
}

Parameters

Parameter Type Required Description
qr_content string Yes Raw QR code content to analyze
analysis_level string No Analysis depth: "basic", "standard", "comprehensive"
return_recommendations boolean No Include security recommendations in response

Response

JSON Response
{
  "content_type": "wifi",
  "security_score": 85,
  "risk_level": "low",
  "analysis": {
    "wifi": {
      "ssid": "CoffeeShop-Guest",
      "security_type": "WPA",
      "encryption": "WPA2-PSK",
      "password_provided": true,
      "security_analysis": {
        "encryption_strong": true,
        "ssid_suspicious": false,
        "password_strength": "medium"
      }
    }
  },
  "threats_detected": [],
  "recommendations": [
    "Verify this network with venue staff before connecting",
    "Consider using VPN for additional security"
  ],
  "metadata": {
    "analysis_timestamp": "2025-01-15T10:30:00Z",
    "processing_time_ms": 245
  }
}

Content Classification

POST /classify

Classify QR code content type without full security analysis.

Request Example
curl -X POST https://api.scanlikely.com/v1/classify \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "qr_content": "https://venmo.com/pay/john-doe-123"
  }'
Response
{
  "content_type": "payment",
  "confidence": 0.95,
  "details": {
    "platform": "venmo",
    "payment_type": "person_to_person",
    "recipient": "john-doe-123"
  }
}

Threat Detection

POST /threats

Focused threat detection and security analysis.

Example: Malicious URL Detection
{
  "qr_content": "https://bit.ly/suspicious-link",
  "check_reputation": true,
  "expand_urls": true
}
Response
{
  "threats_detected": [
    {
      "threat_type": "suspicious_domain",
      "severity": "high",
      "description": "Domain recently registered and flagged for suspicious activity",
      "indicators": ["new_domain", "suspicious_tld", "blacklist_match"]
    }
  ],
  "final_url": "https://malicious-site.tk/phishing-page",
  "redirect_chain": [
    "https://bit.ly/suspicious-link",
    "https://malicious-site.tk/phishing-page"
  ],
  "security_score": 15,
  "recommendation": "Do not visit this URL. It appears to be a phishing attempt."
}

Content Type Examples

WiFi QR Code Analysis

WiFi Example
// Request
{
  "qr_content": "WIFI:T:WPA;S:Corporate-WiFi;P:SecurePass123!;;"
}

// Response
{
  "content_type": "wifi",
  "security_score": 92,
  "analysis": {
    "wifi": {
      "ssid": "Corporate-WiFi",
      "security_type": "WPA",
      "password_strength": "strong",
      "network_legitimacy": "verified"
    }
  }
}

Payment QR Code Analysis

Payment Example
// Request
{
  "qr_content": "https://square.link/u/abc123?amount=24.99"
}

// Response
{
  "content_type": "payment", 
  "security_score": 88,
  "analysis": {
    "payment": {
      "platform": "square",
      "merchant_verified": true,
      "amount": "24.99",
      "currency": "USD",
      "ssl_verified": true
    }
  }
}

Social Platform Analysis

Social Example
// Request
{
  "qr_content": "https://instagram.com/business_account"
}

// Response
{
  "content_type": "social",
  "security_score": 90,
  "analysis": {
    "social": {
      "platform": "instagram",
      "account_type": "business",
      "verified": true,
      "account_age": "3_years",
      "authenticity_score": 0.94
    }
  }
}

Error Handling

The API returns standard HTTP status codes and detailed error messages:

Status Code Description Response
400 Bad Request Invalid QR content or parameters
401 Unauthorized Invalid or missing API key
429 Rate Limited Too many requests, check rate limits
500 Server Error Internal processing error
Error Response Format
{
  "error": {
    "code": "INVALID_QR_CONTENT",
    "message": "The provided QR content is not in a recognized format",
    "details": "Expected URL, WiFi credentials, or payment information"
  }
}

Rate Limits

Plan Requests per minute Requests per day
Free 60 1,000
Developer 300 10,000
Enterprise 1,000 100,000

SDKs and Code Examples

JavaScript/Node.js

JavaScript
const scanlikely = require('scanlikely-api');

const client = new scanlikely.Client('YOUR_API_KEY');

async function analyzeQR(qrContent) {
  try {
    const result = await client.analyze({
      qr_content: qrContent,
      analysis_level: 'comprehensive'
    });
    
    console.log('Content Type:', result.content_type);
    console.log('Security Score:', result.security_score);
    console.log('Recommendations:', result.recommendations);
    
    return result;
  } catch (error) {
    console.error('Analysis failed:', error.message);
  }
}

Python

Python
import scanlikely

client = scanlikely.Client(api_key='YOUR_API_KEY')

def analyze_qr(qr_content):
    try:
        result = client.analyze(
            qr_content=qr_content,
            analysis_level='comprehensive'
        )
        
        print(f"Content Type: {result.content_type}")
        print(f"Security Score: {result.security_score}")
        print(f"Threats: {result.threats_detected}")
        
        return result
    except scanlikely.APIError as e:
        print(f"API Error: {e.message}")
    except Exception as e:
        print(f"Error: {str(e)}")

# Example usage
wifi_qr = "WIFI:T:WPA;S:MyNetwork;P:password;;"
result = analyze_qr(wifi_qr)

Support and Contact

For API support, technical questions, or to request access: