Авторизация
Получить токен
Выдаёт пару JWT по почте и паролю аккаунта AiGenda.
POST
/
api
/
token
/
curl -X POST "https://api.aigenda.tech/api/token/" \
-H "Content-Type: application/json" \
-d '{
"username": "you@example.com",
"password": "ваш-пароль"
}'
import requests
response = requests.post(
"https://api.aigenda.tech/api/token/",
json={
"username": "you@example.com",
"password": "ваш-пароль",
},
timeout=30,
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.aigenda.tech/api/token/", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"username": "you@example.com",
"password": "ваш-пароль"
}),
});
const data = await response.json();
console.log(data);
{
"refresh": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoicmVmcmVzaCJ9.sig",
"access": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoiYWNjZXNzIn0.sig"
}
{
"detail": "No active account found with the given credentials"
}
Тело запроса
string
обязательно
Почта аккаунта. Поле называется
username, но в него кладётся почта.string
обязательно
Пароль аккаунта.
Ответ
string
Токен для заголовка
Authorization: Bearer. Живёт 30 дней.string
Токен для обновления
access. Живёт 1 сутки.curl -X POST "https://api.aigenda.tech/api/token/" \
-H "Content-Type: application/json" \
-d '{
"username": "you@example.com",
"password": "ваш-пароль"
}'
import requests
response = requests.post(
"https://api.aigenda.tech/api/token/",
json={
"username": "you@example.com",
"password": "ваш-пароль",
},
timeout=30,
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.aigenda.tech/api/token/", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"username": "you@example.com",
"password": "ваш-пароль"
}),
});
const data = await response.json();
console.log(data);
{
"refresh": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoicmVmcmVzaCJ9.sig",
"access": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoiYWNjZXNzIn0.sig"
}
{
"detail": "No active account found with the given credentials"
}
Последнее изменение 17 октября 2026 г.
⌘I
curl -X POST "https://api.aigenda.tech/api/token/" \
-H "Content-Type: application/json" \
-d '{
"username": "you@example.com",
"password": "ваш-пароль"
}'
import requests
response = requests.post(
"https://api.aigenda.tech/api/token/",
json={
"username": "you@example.com",
"password": "ваш-пароль",
},
timeout=30,
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.aigenda.tech/api/token/", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"username": "you@example.com",
"password": "ваш-пароль"
}),
});
const data = await response.json();
console.log(data);
{
"refresh": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoicmVmcmVzaCJ9.sig",
"access": "eyJhbGciOiJIUzI1NiJ9.eyJ0b2tlbl90eXBlIjoiYWNjZXNzIn0.sig"
}
{
"detail": "No active account found with the given credentials"
}