add the backend
Browse filesFiles changed (3)
- backend.htmlAdded+350
- dashboard.html+2-1
- index.html+2-1
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350<!DOCTYPE html><html lang="en"><head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>AVA Backend & API</title> <link rel="icon" type="image/x-icon" href="/static/favicon.ico"> <script src="https://cdn.tailwindcss.com"></script> <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/animejs@3.2.1/lib/anime.min.js"></script> <style> .gradient-text { background: linear-gradient(90deg, #6d28d9 0%, #a855f7 50%, #7c3aed 100%); -webkit-background-clip: text; background-clip: text; color: transparent; } .code-block { background: #1a1a1a; border-radius: 8px; padding: 16px; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace; font-size: 14px; color: #e6e6e6; overflow-x: auto; } .endpoint-card { transition: all 0.3s ease; border-left: 4px solid #6d28d9; } .endpoint-card:hover { transform: translateX(4px); box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); } </style></head><body class="bg-gray-50"> <div class="min-h-screen flex flex-col"> <!-- Header --> <header class="bg-white shadow-sm border-b border-gray-200"> <div class="container mx-auto px-6 py-4 flex justify-between items-center"> <div class="flex items-center space-x-3"> <i data-feather="zap" class="text-purple-600 w-6 h-6"></i> <span class="text-xl font-bold gradient-text">AVA Backend & API</span> </div> <nav class="flex space-x-6 items-center"> <a href="index.html" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Home</a> <a href="dashboard.html" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Dashboard</a> <a href="index.html#features" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Features</a> </nav> </div> </header>
<!-- Main Content --> <main class="flex-grow container mx-auto px-6 py-8"> <!-- API Overview --> <div class="bg-white rounded-xl shadow-sm border border-gray-200 p-8 mb-8"> <h1 class="text-3xl font-bold text-gray-800 mb-4">AVA Backend API</h1> <p class="text-gray-600 text-lg mb-6"> RESTful API endpoints for programmatic access to AVA's automation capabilities. All endpoints require authentication via API key. </p> <div class="grid grid-cols-1 md:grid-cols-3 gap-6 mb-8"> <div class="text-center p-4"> <i data-feather="cpu" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800">Real-time Processing</h3> <p class="text-sm text-gray-600 mt-2">Process commands instantly with low latency responses</p> </div> <div class="text-center p-4"> <i data-feather="shield" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800">Secure & Scalable</h3> <p class="text-sm text-gray-600 mt-2">Enterprise-grade security with automatic scaling for high workloads</p> </div> <div class="text-center p-4"> <i data-feather="database" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800">Webhook Support</h3> <p class="text-sm text-gray-600 mt-2">Receive real-time notifications for workflow completions and errors</p> </div> </div> </div>
<!-- API Endpoints --> <div class="grid grid-cols-1 lg:grid-cols-2 gap-8"> <!-- Commands Endpoint --> <div class="bg-white rounded-xl shadow-sm border border-gray-200 p-6"> <h2 class="text-xl font-bold text-gray-800 mb-6">Core API Endpoints</h2> <div class="space-y-6"> <!-- Execute Command --> <div class="endpoint-card bg-gray-50 p-4 rounded-lg"> <div class="flex items-center justify-between mb-3"> <span class="bg-green-100 text-green-800 px-2 py-1 rounded text-xs font-medium">POST</span> <code class="text-sm text-purple-600 font-medium">/api/v1/commands/execute</code> </div> <div class="code-block"> <pre><code class="text-green-400">// Execute a natural language commandPOST https://api.ava-ai.com/v1/commands/executeContent-Type: application/jsonAuthorization: Bearer YOUR_API_KEY
{ "command": "Extract sales data from columns A to F and create a pivot table", "workflow_id": "optional_workflow_reference", "parameters": { "output_format": "excel", "email_results": true}</code></pre> </div>
<!-- Get Workflows --> <div class="endpoint-card bg-gray-50 p-4 rounded-lg"> <div class="flex items-center justify-between mb-3"> <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs font-medium">GET</span> <code class="text-sm text-purple-600 font-medium">/api/v1/workflows</code> </div> <div class="code-block"> <pre><code class="text-green-400">// List all workflowsGET https://api.ava-ai.com/v1/workflowsAuthorization: Bearer YOUR_API_KEY</code></pre> </div>
<!-- Create Workflow --> <div class="endpoint-card bg-gray-50 p-4 rounded-lg"> <div class="flex items-center justify-between mb-3"> <span class="bg-purple-100 text-purple-800 px-2 py-1 rounded text-xs font-medium">POST</span> <code class="text-sm text-purple-600 font-medium">/api/v1/workflows</code> </div> <div class="code-block"> <pre><code class="text-green-400">// Create a new workflowPOST https://api.ava-ai.com/v1/workflowsContent-Type: application/jsonAuthorization: Bearer YOUR_API_KEY
{ "name": "Monthly Sales Report", "description": "Automated Q3 sales analysis", "steps": [ { "action": "extract_data", "parameters": {"range": "A1:F100"} }, { "action": "create_pivot", "parameters": {"rows": ["Region"], "values": ["Revenue"]} ]}</code></pre> </div> </div>
<!-- API Documentation --> <div class="bg-white rounded-xl shadow-sm border border-gray-200 p-6"> <h2 class="text-xl font-bold text-gray-800 mb-6">API Documentation</h2> <div class="space-y-6"> <div class="bg-purple-50 p-4 rounded-lg"> <h3 class="font-semibold text-purple-800 mb-3">Authentication</h3> <p class="text-sm text-gray-600 mb-3"> All API requests require an API key in the Authorization header: </p> <div class="code-block"> <pre><code class="text-green-400">Authorization: Bearer ava_sk_1234567890abcdef</code></pre> </div> </div>
<div class="bg-blue-50 p-4 rounded-lg"> <h3 class="font-semibold text-blue-800 mb-3">Rate Limiting</h3> <p class="text-sm text-gray-600"> • 1000 requests per hour per API key<br> • 100 concurrent connections<br> • 10MB maximum payload size </p> </div>
<div class="bg-green-50 p-4 rounded-lg"> <h3 class="font-semibold text-green-800 mb-3">Response Format</h3> <div class="code-block"> <pre><code class="text-green-400">// Success Response{ "success": true, "data": { "workflow_id": "wf_123456", "status": "completed", "result_url": "https://api.ava-ai.com/results/wf_123456", "execution_time": 2.45}
// Error Response{ "success": false, "error": { "code": "invalid_command", "message": "The provided command could not be processed"}</code></pre> </div> </div> </div> </div>
<!-- Webhook Configuration --> <div class="mt-8 bg-white rounded-xl shadow-sm border border-gray-200 p-8"> <h2 class="text-2xl font-bold text-gray-800 mb-6">Webhook Integration</h2> <div class="grid grid-cols-1 md:grid-cols-2 gap-6"> <div class="bg-gray-50 p-6 rounded-lg"> <h3 class="font-semibold text-gray-800 mb-4">Configure Webhooks</h3> <div class="code-block"> <pre><code class="text-green-400">// Webhook ConfigurationPOST https://api.ava-ai.com/v1/webhooksContent-Type: application/json
{ "url": "https://your-app.com/ava-webhook", "events": ["workflow.completed", "workflow.failed"]}</code></pre> </div>
<div class="bg-gray-50 p-6 rounded-lg"> <h3 class="font-semibold text-gray-800 mb-4">Webhook Payload</h3> <div class="code-block"> <pre><code class="text-green-400">// Webhook Event Example{ "event": "workflow.completed", "workflow_id": "wf_123456", "timestamp": "2023-11-15T10:30:00Z", "data": { "workflow_name": "Monthly Sales Report", "execution_time": 3.21, "result_url": "https://api.ava-ai.com/results/wf_123456", "status": "success" }}</code></pre> </div> </div> </div> </div>
<!-- SDK Section --> <div class="mt-8 bg-white rounded-xl shadow-sm border border-gray-200 p-8"> <h2 class="text-2xl font-bold text-gray-800 mb-6">SDK & Libraries</h2> <div class="grid grid-cols-1 md:grid-cols-3 gap-6"> <div class="text-center p-6 bg-gray-50 rounded-lg"> <i data-feather="code" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800 mb-3">Python</h3> <div class="code-block mt-3"> <pre><code class="text-green-400">pip install ava-ai-sdk
from ava import Client
client = Client(api_key="your_api_key")result = client.execute_command( "Create a bar chart of monthly revenue")</code></pre> </div> </div> <div class="text-center p-6 bg-gray-50 rounded-lg"> <i data-feather="code" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800 mb-3">JavaScript</h3> <div class="code-block mt-3"> <pre><code class="text-green-400">npm install ava-ai-sdk
import { AVA } from 'ava-ai-sdk';
const ava = new AVA('your_api_key');const workflow = await ava.execute('Analyze Q3 data');</code></pre> </div> </div> <div class="text-center p-6 bg-gray-50 rounded-lg"> <i data-feather="code" class="w-8 h-8 text-purple-600 mx-auto mb-3"></i> <h3 class="font-semibold text-gray-800 mb-3">REST API</h3> <p class="text-sm text-gray-600 mt-2">Direct HTTP requests with any language</p> <div class="code-block mt-3"> <pre><code class="text-green-400">curl -X POST \ https://api.ava-ai.com/v1/commands/execute \ -H 'Authorization: Bearer your_api_key' \ -d '{"command": "Your natural language command"}'</code></pre> </div> </div> </div> </div> </main>
<!-- Footer --> <footer class="bg-white border-t border-gray-200 py-8 mt-8"> <div class="container mx-auto px-6"> <div class="flex flex-col md:flex-row justify-between items-center"> <p class="text-gray-600 text-sm">© 2023 AVA AI. All rights reserved.</p> <div class="flex space-x-6 mt-4 md:mt-0"> <a href="#" class="text-gray-400 hover:text-purple-600 transition-colors"> <i data-feather="github"></i> </a> <a href="#" class="text-gray-400 hover:text-purple-600 transition-colors"> <i data-feather="file-text"></i> </a> <a href="#" class="text-gray-400 hover:text-purple-600 transition-colors"> <i data-feather="download"></i> </a> </div> </div> </footer> </div>
<script> // Initialize feather icons feather.replace();
// Add copy functionality to code blocks document.addEventListener('DOMContentLoaded', function() { document.querySelectorAll('.code-block').forEach(block => { block.addEventListener('click', function() { const code = block.querySelector('code').textContent; navigator.clipboard.writeText(code).then(() => { // Show copied notification const notification = document.createElement('div'); notification.className = 'fixed top-4 right-4 p-4 rounded-lg shadow-lg z-50 bg-purple-600 text-white flex items-center space-x-3'; notification.innerHTML = ` <i data-feather="check" class="w-5 h-5"></i> <span>Code copied to clipboard!</span> '; document.body.appendChild(notification); feather.replace(); anime({ targets: notification, translateX: [100, 0], opacity: [0, 1], duration: 500, easing: 'easeOutExpo' }); setTimeout(() => { anime({ targets: notification, translateX: 100, opacity: 0, duration: 500, easing: 'easeInExpo', complete: function() { notification.remove(); } }); }, 2000); }); }); }); }); </script></body></html>38 unmodified lines3940414243444538 unmodified lines<a href="index.html" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Home</a><a href="index.html#features" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Features</a><a href="index.html#integrations" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Integrations</a><div class="flex items-center space-x-3"><span class="text-sm text-gray-600">Welcome back, User</span><div class="w-8 h-8 bg-purple-600 rounded-full flex items-center justify-center text-white text-sm font-medium">U</span></div>38 unmodified lines394041424344454638 unmodified lines<a href="index.html" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Home</a><a href="index.html#features" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Features</a><a href="index.html#integrations" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">Integrations</a><a href="backend.html" class="text-gray-600 hover:text-purple-600 font-medium transition-colors">API</a><div class="flex items-center space-x-3"><span class="text-sm text-gray-600">Welcome back, User</span><div class="w-8 h-8 bg-purple-600 rounded-full flex items-center justify-center text-white text-sm font-medium">U</span></div>
41 unmodified lines4243444546474841 unmodified lines<a href="#integrations" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Integrations</a><a href="#documentation" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Documentation</a><a href="dashboard.html" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Dashboard</a></nav><button class="md:hidden" onclick="toggleMobileMenu()"><i data-feather="menu" class="w-6 h-6 text-gray-700"></i></button>41 unmodified lines424344454647484941 unmodified lines<a href="#integrations" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Integrations</a><a href="#documentation" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Documentation</a><a href="dashboard.html" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">Dashboard</a><a href="backend.html" class="text-gray-700 hover:text-purple-600 font-medium transition-colors">API</a></nav><button class="md:hidden" onclick="toggleMobileMenu()"><i data-feather="menu" class="w-6 h-6 text-gray-700"></i></button>
backend.htmlAdded+350
dashboard.html+2-1
index.html+2-1