Quickstart Guide
Get up and running with PrecogX in 5 minutes.
Prerequisites
- Python 3.8+ or Node.js 16+
- A PrecogX account (sign up free)
Step 1: Create Your Account
- Visit app.precogx.ai
- Click "Start Free"
- Complete the signup form (no credit card required)
- Verify your email address
Step 2: Get Your API Key
- Log into your PrecogX Dashboard
- Navigate to Settings → API Keys
- Click "Generate New Key"
- Copy your API key (you'll need this for the SDK)
Keep it secure
Store your API key securely. Never commit it to version control or share it publicly.
Step 3: Install the SDK
Python
pip install precogx-sdk
JavaScript/Node.js
npm install @precogx/sdk
Step 4: Initialize the Client
Python
from precogx_sdk import PrecogXClient
# Initialize the client
client = PrecogXClient(api_key="your_api_key_here")
JavaScript
import { PrecogXClient } from '@precogx/sdk';
// Initialize the client
const client = new PrecogXClient('your_api_key_here');
Step 5: Send Your First Telemetry
Python
# Send telemetry data
result = client.send_telemetry({
"agent_id": "my_first_agent",
"prompt": "Hello, how can I help you today?",
"response": "I'm here to assist you with any questions you might have.",
"tool_calls": []
})
# Check for threats
if result.flags:
print(f"🚨 Threat detected: {result.flags[0]}")
else:
print("✅ No threats detected")
print(f"Trust Score: {result.risk_score}")
JavaScript
// Send telemetry data
const result = await client.sendTelemetry({
agentId: 'my_first_agent',
prompt: 'Hello, how can I help you today?',
response: 'I\'m here to assist you with any questions you might have.',
toolCalls: []
});
// Check for threats
if (result.flags.length > 0) {
console.log(`🚨 Threat detected: ${result.flags[0]}`);
} else {
console.log('✅ No threats detected');
}
console.log(`Trust Score: ${result.riskScore}`);
Step 6: View Results in Dashboard
- Return to your PrecogX Dashboard
- Navigate to Detections to see your telemetry data
- Check Overview for trust score analytics
- Review Agents to see your agent's security status
Next Steps
- Installation Guide - Detailed setup instructions
- First Agent - Create your first protected agent
Need Help?
Congratulations! You've successfully set up PrecogX and sent your first telemetry data. Your AI agents are now protected by enterprise-grade security.