</>Loading...
REST API для интеграции EasyAI в ваши приложения
Все запросы требуют API-ключ в заголовке Authorization:
/api/v1/auth/firebase/api/v1/auth/me/api/v1/agents//api/v1/agents//api/v1/agents/:id/api/v1/agents/:id/api/v1/agents/:id/api/v1/agents/:id/message/api/v1/agents/stats/api/v1/constructor/analyze/api/v1/integrations/skills/api/v1/billing/plans// Create an agent
const response = await fetch('https://api.easyai.life/api/v1/agents/', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Support Agent',
description: 'Answers customer questions 24/7',
skills: ['telegram', 'knowledge_base', 'escalation'],
model: 'gpt-4o',
}),
});
const agent = await response.json();
console.log(agent.id); // "agent_abc123"API доступен на тарифах Отдел и Корпорация.
Смотреть тарифы