История генераций
curl --request GET \
--url https://api.example.com/api/v2/user/historyimport requests
url = "https://api.example.com/api/v2/user/history"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v2/user/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v2/user/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v2/user/history"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/v2/user/history")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v2/user/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyПользователь
История генераций
Список прошлых генераций с фильтрацией, избранным и оценками
GET
/
api
/
v2
/
user
/
history
История генераций
curl --request GET \
--url https://api.example.com/api/v2/user/historyimport requests
url = "https://api.example.com/api/v2/user/history"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v2/user/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v2/user/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v2/user/history"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/v2/user/history")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v2/user/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyПараметры запроса
integer
по умолчанию:"1"
Номер страницы.
integer
по умолчанию:"20"
Элементов на странице (макс. 100).
string
Фильтр:
text, image, video, tts, stt, toolstring
Фильтр по слагу модели.
string
Фильтр:
completed, pending, failedboolean
Только избранные генерации.
Запрос
curl "https://elumenta.ru/api/v2/user/history?category=image&limit=10" \
-H "Authorization: Bearer nb_ВАШ_API_КЛЮЧ"
Ответ
{
"items": [
{
"id": 18491,
"model_slug": "flux-1.1-pro",
"model_name": "Flux 1.1 Pro",
"category": "image",
"prompt": "Портрет CEO в современном офисе",
"status": "completed",
"result_url": "https://storage.elumenta.ru/generations/18491.webp",
"tokens_spent": 8,
"is_favorited": false,
"user_rating": null,
"created_at": "2026-03-08T12:02:30Z"
}
],
"total": 142,
"page": 1,
"limit": 10
}
Добавить в избранное
POST /api/v2/user/history/{generation_id}/favorite
Оценить генерацию
POST /api/v2/user/history/{generation_id}/rate
{"rating": 5}
Удалить
DELETE /api/v2/user/history/{generation_id}
⌘I

