- Added comprehensive AI Assistant system (aiassist/ directory): * Vector search and embedding capabilities * Typebot proxy integration * Elastic search functionality * Message classification and chat history * MCP proxy for external integrations - Implemented Court Status API (GetCourtStatus.php): * Real-time court document status checking * Integration with external court systems * Comprehensive error handling and logging - Enhanced S3 integration: * Improved file backup system with metadata * Batch processing capabilities * Enhanced error logging and recovery * Copy operations with URL fixing - Added Telegram contact creation API - Improved error logging across all modules - Enhanced callback system for AI responses - Extensive backup file storage with timestamps - Updated documentation and README files - File storage improvements: * Thousands of backup files with proper metadata * Fix operations for broken file references * Project-specific backup and recovery systems * Comprehensive file integrity checking Total: 26,461+ files added/modified including AWS SDK, vendor dependencies, and extensive backup system.
57 lines
1.8 KiB
PHP
57 lines
1.8 KiB
PHP
<?php
|
||
|
||
// Определите ваш API токен и URL конечной точки
|
||
$api_token = '9e035384-daf6-4148-a4d4-e861af72cde3|I78jntkpPimu05MjOdao2yWq7PmWoP9Au5GdF14a40538e71';
|
||
$base_url = 'https://fr24api.flightradar24.com/api';
|
||
$endpoint = '/live/flight-positions/light';
|
||
|
||
// Постройте полный URL
|
||
$url = $base_url . $endpoint;
|
||
|
||
// Установите заголовки, включая авторизацию с использованием API токена
|
||
$headers = [
|
||
'Accept: application/json',
|
||
"Authorization: Bearer $api_token",
|
||
'Accept-Version: v1'
|
||
];
|
||
|
||
// Определите параметры запроса (при необходимости)
|
||
$params = http_build_query([
|
||
'bounds' => '50.682,46.218,14.422,22.243' // Пример координат
|
||
]);
|
||
|
||
// Добавьте параметры к URL
|
||
$url_with_params = $url . '?' . $params;
|
||
|
||
// Создайте cURL сессию
|
||
$ch = curl_init();
|
||
|
||
// Установите параметры cURL
|
||
curl_setopt($ch, CURLOPT_URL, $url_with_params);
|
||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
|
||
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
|
||
|
||
// Выполните запрос и получите ответ
|
||
$response = curl_exec($ch);
|
||
|
||
// Проверьте на ошибки
|
||
if (curl_errno($ch)) {
|
||
echo 'Ошибка cURL: ' . curl_error($ch);
|
||
} else {
|
||
// Проверьте HTTP-код ответа
|
||
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
|
||
if ($http_code === 200) {
|
||
// Распарсьте JSON ответ
|
||
$data = json_decode($response, true);
|
||
echo "Live Flight Positions:\n";
|
||
print_r($data);
|
||
} else {
|
||
echo "Error: HTTP code $http_code\n";
|
||
echo "Response: $response\n";
|
||
}
|
||
}
|
||
|
||
// Закройте cURL сессию
|
||
curl_close($ch);
|
||
?>
|