Generate your API key to integrate our powerful engagement agents
| Name | Created | Last Used | Status | Actions |
|---|---|---|---|---|
| rrr | 2025-03-21 02:46 | 2025-03-21 03:41 | Inactive | |
| Current | 2025-04-02 00:16 | Never | Inactive | |
| test | 2025-04-01 23:30 | Never | Inactive |
Test your API key with our sample endpoints
Complete POST URLs for all available endpoints
POST https://[your-domain]/api/v1/generate
POST https://[your-domain]/api/v1/analyze
POST https://[your-domain]/api/v1/agents/{agent_id}/interact
POST https://[your-domain]/api/v1/monitor/behavior
wss://api.openai.com/v1/realtime
model
Realtime model ID to connect to, like gpt-4o-realtime-preview-2024-12-17
Authorization: Bearer YOUR_API_KEY
OpenAI-Beta: realtime=v1
Substitute YOUR_API_KEY with a standard API key on the server, or an ephemeral token on insecure clients (note that WebRTC is recommended for this use case).
This header is required during the beta period.
import WebSocket from "ws";
const url = "wss://api.openai.com/v1/realtime?model=gpt-4o-realtime-preview-2024-12-17";
const ws = new WebSocket(url, {
headers: {
"Authorization": "Bearer " + process.env.OPENAI_API_KEY,
"OpenAI-Beta": "realtime=v1",
},
});
ws.on("open", function open() {
console.log("Connected to server.");
});
ws.on("message", function incoming(message) {
console.log(JSON.parse(message.toString()));
});
https://[your-domain]/api/v1/generate
agent
Agent type to use for generation (e.g., motivation_mapping, habit_formation)
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Substitute YOUR_API_KEY with the API key generated from your account.
import axios from 'axios';
const apiKey = 'YOUR_API_KEY';
const url = 'https://[your-domain]/api/v1/generate?agent=motivation_mapping';
async function generateResponse() {
try {
const response = await axios.post(url, {
prompt: 'What motivates successful community engagement?'
}, {
headers: {
'Authorization': `Bearer ${apiKey}`,
'Content-Type': 'application/json'
}
});
console.log(response.data);
} catch (error) {
console.error('Error:', error.response?.data || error.message);
}
}
generateResponse();
https://[your-domain]/api/v1/analyze
user_id
User identifier for engagement analysis
timeframe
Analysis timeframe (e.g., last_7_days, last_30_days)
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Substitute YOUR_API_KEY with the API key generated from your account.
import axios from 'axios';
const apiKey = 'YOUR_API_KEY';
const url = 'https://[your-domain]/api/v1/analyze?user_id=example_user&timeframe=last_7_days';
async function analyzeEngagement() {
try {
const response = await axios.post(url, {
metrics: ['participation', 'consistency']
}, {
headers: {
'Authorization': `Bearer ${apiKey}`,
'Content-Type': 'application/json'
}
});
console.log(response.data);
} catch (error) {
console.error('Error:', error.response?.data || error.message);
}
}
analyzeEngagement();
Include your API key in the Authorization header of your requests:
Authorization: Bearer YOUR_API_KEY