Skip to main content
Infrastructure/Collects
POSTInfrastructureSince 1.0SynchronousAuth Required

TailQuery

TailQuery streams live log entries from VictoriaLogs tail.

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Request Inputs

Body Fields

  • queryStringRequired

    Log query expression to stream live entries from VictoriaLogs

    Example: level=error AND service=payment

Responses

200 OK

On success, this API returns the following response structure.

  • resultObject

    LogStreamEntry is a single log entry in a streaming response. Reusable by any RPC that streams log lines (tail, live-tail, etc.). The fields map contains all key-value pairs from the upstream log store (e.g. VictoriaLogs). Common keys include system fields (_time, _msg, _stream) and user-defined labels (hostname, service, level, etc.).

    • fieldsLinkedHashMap

      Field list to include in the response

      Example: (nested object)

  • errorObject

    错误码。操作成功时为 null,失败时返回具体错误信息。

    • codeString

      gRPC status code (e.g. NOT_FOUND, INVALID_ARGUMENT)

      Example: UNAUTHENTICATED

    • messageString

      Human-readable error message

      Example: invalid or missing token

Endpoint

POST/api/v1/collects/query/tail

/api/v1/collects/query/tail

Operation ID

TailQuery

Permalink

Request Example

curl -X POST '{host}/api/v1/collects/query/tail' -H 'Authorization: Bearer {token}' -H 'Content-Type: application/json' -d '{"query":"level=error AND service=payment"}'

Response Example

200
{
  "result": {},
  "error": {}
}

Change History

This API has no change history records yet.

View all change history