메인 콘텐츠로 건너뛰기
GET
/
endpoints
/
{endpoint_id}
/
logs
로그 파일 목록 조회
curl --request GET \
  --url https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_PORT => "5007",
CURLOPT_URL => "https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$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://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://external.aieev.cloud:5007/external/api/v1/endpoints/{endpoint_id}/logs")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
[
  {
    "node_id": "<string>",
    "replica_id": "<string>",
    "filename": "<string>",
    "is_historical": true,
    "start_time": "2023-11-07T05:31:56Z",
    "end_time": "2023-11-07T05:31:56Z"
  }
]

인증

Authorization
string
header
필수

API Key를 Bearer 토큰으로 전달합니다. 프로젝트 개요의 API 키 메뉴에서 생성할 수 있습니다.

경로 매개변수

endpoint_id
string
필수

엔드포인트 고유 ID

쿼리 매개변수

replica_id
string

특정 레플리카의 로그만 필터링

include_history
boolean
기본값:true

false로 설정하면 현재 활성 로그만 반환하고 이전 로테이션된 로그는 제외

응답

200 - application/json

로그 파일 목록

node_id
string

로그가 저장된 노드 ID

replica_id
string

연결된 레플리카 ID

filename
string

로그 파일 경로. /logs/file API의 filename 파라미터에 사용

is_historical
boolean

이전 로테이션된(과거) 로그 파일 여부. true이면 종료된 레플리카의 로그

start_time
string<date-time> | null

로그 시작 시간. 이력 로그에서만 제공

end_time
string<date-time> | null

로그 종료 시간. 이력 로그에서만 제공