Try Bifrost Enterprise free for 14 days. Explore now
curl --request GET \
--url http://localhost:8080/api/logs{
"logs": [
{
"id": "<string>",
"parent_request_id": "<string>",
"provider": "<string>",
"model": "<string>",
"status": "processing",
"object": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"number_of_retries": 123,
"fallback_index": 123,
"latency": 123,
"cost": 123,
"selected_key_id": "<string>",
"selected_key_name": "<string>",
"virtual_key_id": "<string>",
"virtual_key_name": "<string>",
"routing_engines_used": [
"<string>"
],
"routing_rule_id": "<string>",
"routing_rule_name": "<string>",
"stream": true,
"raw_request": "<string>",
"raw_response": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"token_usage": {
"prompt_tokens": 123,
"prompt_tokens_details": {
"text_tokens": 123,
"audio_tokens": 123,
"image_tokens": 123,
"cached_tokens": 123
},
"completion_tokens": 123,
"completion_tokens_details": {
"text_tokens": 123,
"accepted_prediction_tokens": 123,
"audio_tokens": 123,
"citation_tokens": 123,
"num_search_queries": 123,
"reasoning_tokens": 123,
"image_tokens": 123,
"rejected_prediction_tokens": 123,
"cached_tokens": 123
},
"total_tokens": 123,
"cost": {
"input_tokens_cost": 123,
"output_tokens_cost": 123,
"request_cost": 123,
"total_cost": 123
}
},
"error_details": {
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "openai",
"model_requested": "<string>",
"request_type": "<string>"
}
},
"input_history": [
{
"role": "assistant",
"name": "<string>",
"content": "<string>",
"tool_call_id": "<string>",
"refusal": "<string>",
"audio": {
"id": "<string>",
"data": "<string>",
"expires_at": 123,
"transcript": "<string>"
},
"reasoning": "<string>",
"reasoning_details": [
{
"id": "<string>",
"index": 123,
"type": "reasoning.summary",
"summary": "<string>",
"text": "<string>",
"signature": "<string>",
"data": "<string>"
}
],
"annotations": [
{
"type": "<string>",
"url_citation": {
"start_index": 123,
"end_index": 123,
"title": "<string>",
"url": "<string>",
"sources": {},
"type": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
]
}
],
"responses_input_history": [
{
"id": "<string>",
"type": "message",
"status": "in_progress",
"role": "assistant",
"content": "<string>",
"call_id": "<string>",
"name": "<string>",
"arguments": "<string>",
"output": {},
"action": {},
"error": "<string>",
"queries": [
"<string>"
],
"results": [
{}
],
"summary": [
{
"type": "summary_text",
"text": "<string>"
}
],
"encrypted_content": "<string>"
}
],
"output_message": {
"role": "assistant",
"name": "<string>",
"content": "<string>",
"tool_call_id": "<string>",
"refusal": "<string>",
"audio": {
"id": "<string>",
"data": "<string>",
"expires_at": 123,
"transcript": "<string>"
},
"reasoning": "<string>",
"reasoning_details": [
{
"id": "<string>",
"index": 123,
"type": "reasoning.summary",
"summary": "<string>",
"text": "<string>",
"signature": "<string>",
"data": "<string>"
}
],
"annotations": [
{
"type": "<string>",
"url_citation": {
"start_index": 123,
"end_index": 123,
"title": "<string>",
"url": "<string>",
"sources": {},
"type": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
]
},
"responses_output": [
{
"id": "<string>",
"type": "message",
"status": "in_progress",
"role": "assistant",
"content": "<string>",
"call_id": "<string>",
"name": "<string>",
"arguments": "<string>",
"output": {},
"action": {},
"error": "<string>",
"queries": [
"<string>"
],
"results": [
{}
],
"summary": [
{
"type": "summary_text",
"text": "<string>"
}
],
"encrypted_content": "<string>"
}
],
"embedding_output": [
[
123
]
],
"params": {},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {
"type": "<string>",
"description": "<string>",
"required": [
"<string>"
],
"properties": {},
"enum": [
"<string>"
],
"additionalProperties": true
},
"strict": true
},
"custom": {
"format": {
"type": "<string>",
"grammar": {
"definition": "<string>",
"syntax": "lark"
}
}
},
"cache_control": {
"type": "ephemeral",
"ttl": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
],
"speech_input": {},
"transcription_input": {},
"image_generation_input": {},
"speech_output": {},
"transcription_output": {},
"image_generation_output": {},
"cache_debug": {},
"selected_key": {},
"virtual_key": {}
}
],
"total": 123,
"offset": 123,
"limit": 123
}Retrieves logs with filtering, search, and pagination via query parameters.
curl --request GET \
--url http://localhost:8080/api/logs{
"logs": [
{
"id": "<string>",
"parent_request_id": "<string>",
"provider": "<string>",
"model": "<string>",
"status": "processing",
"object": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"number_of_retries": 123,
"fallback_index": 123,
"latency": 123,
"cost": 123,
"selected_key_id": "<string>",
"selected_key_name": "<string>",
"virtual_key_id": "<string>",
"virtual_key_name": "<string>",
"routing_engines_used": [
"<string>"
],
"routing_rule_id": "<string>",
"routing_rule_name": "<string>",
"stream": true,
"raw_request": "<string>",
"raw_response": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"token_usage": {
"prompt_tokens": 123,
"prompt_tokens_details": {
"text_tokens": 123,
"audio_tokens": 123,
"image_tokens": 123,
"cached_tokens": 123
},
"completion_tokens": 123,
"completion_tokens_details": {
"text_tokens": 123,
"accepted_prediction_tokens": 123,
"audio_tokens": 123,
"citation_tokens": 123,
"num_search_queries": 123,
"reasoning_tokens": 123,
"image_tokens": 123,
"rejected_prediction_tokens": 123,
"cached_tokens": 123
},
"total_tokens": 123,
"cost": {
"input_tokens_cost": 123,
"output_tokens_cost": 123,
"request_cost": 123,
"total_cost": 123
}
},
"error_details": {
"event_id": "<string>",
"type": "<string>",
"is_bifrost_error": true,
"status_code": 123,
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"event_id": "<string>"
},
"extra_fields": {
"provider": "openai",
"model_requested": "<string>",
"request_type": "<string>"
}
},
"input_history": [
{
"role": "assistant",
"name": "<string>",
"content": "<string>",
"tool_call_id": "<string>",
"refusal": "<string>",
"audio": {
"id": "<string>",
"data": "<string>",
"expires_at": 123,
"transcript": "<string>"
},
"reasoning": "<string>",
"reasoning_details": [
{
"id": "<string>",
"index": 123,
"type": "reasoning.summary",
"summary": "<string>",
"text": "<string>",
"signature": "<string>",
"data": "<string>"
}
],
"annotations": [
{
"type": "<string>",
"url_citation": {
"start_index": 123,
"end_index": 123,
"title": "<string>",
"url": "<string>",
"sources": {},
"type": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
]
}
],
"responses_input_history": [
{
"id": "<string>",
"type": "message",
"status": "in_progress",
"role": "assistant",
"content": "<string>",
"call_id": "<string>",
"name": "<string>",
"arguments": "<string>",
"output": {},
"action": {},
"error": "<string>",
"queries": [
"<string>"
],
"results": [
{}
],
"summary": [
{
"type": "summary_text",
"text": "<string>"
}
],
"encrypted_content": "<string>"
}
],
"output_message": {
"role": "assistant",
"name": "<string>",
"content": "<string>",
"tool_call_id": "<string>",
"refusal": "<string>",
"audio": {
"id": "<string>",
"data": "<string>",
"expires_at": 123,
"transcript": "<string>"
},
"reasoning": "<string>",
"reasoning_details": [
{
"id": "<string>",
"index": 123,
"type": "reasoning.summary",
"summary": "<string>",
"text": "<string>",
"signature": "<string>",
"data": "<string>"
}
],
"annotations": [
{
"type": "<string>",
"url_citation": {
"start_index": 123,
"end_index": 123,
"title": "<string>",
"url": "<string>",
"sources": {},
"type": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
]
},
"responses_output": [
{
"id": "<string>",
"type": "message",
"status": "in_progress",
"role": "assistant",
"content": "<string>",
"call_id": "<string>",
"name": "<string>",
"arguments": "<string>",
"output": {},
"action": {},
"error": "<string>",
"queries": [
"<string>"
],
"results": [
{}
],
"summary": [
{
"type": "summary_text",
"text": "<string>"
}
],
"encrypted_content": "<string>"
}
],
"embedding_output": [
[
123
]
],
"params": {},
"tools": [
{
"type": "function",
"function": {
"name": "<string>",
"description": "<string>",
"parameters": {
"type": "<string>",
"description": "<string>",
"required": [
"<string>"
],
"properties": {},
"enum": [
"<string>"
],
"additionalProperties": true
},
"strict": true
},
"custom": {
"format": {
"type": "<string>",
"grammar": {
"definition": "<string>",
"syntax": "lark"
}
}
},
"cache_control": {
"type": "ephemeral",
"ttl": "<string>"
}
}
],
"tool_calls": [
{
"function": {
"name": "<string>",
"arguments": "<string>"
},
"index": 123,
"type": "<string>",
"id": "<string>"
}
],
"speech_input": {},
"transcription_input": {},
"image_generation_input": {},
"speech_output": {},
"transcription_output": {},
"image_generation_output": {},
"cache_debug": {},
"selected_key": {},
"virtual_key": {}
}
],
"total": 123,
"offset": 123,
"limit": 123
}Comma-separated list of providers to filter by
Comma-separated list of models to filter by
Comma-separated list of statuses to filter by
Comma-separated list of object types to filter by
Comma-separated list of selected key IDs to filter by
Comma-separated list of virtual key IDs to filter by
Comma-separated list of routing rule IDs to filter by
Comma-separated list of routing engines to filter by (routing-rule, governance, or loadbalancing)
Start time filter (RFC3339 format)
End time filter (RFC3339 format)
Minimum latency filter
Maximum latency filter
Minimum tokens filter
Maximum tokens filter
Minimum cost filter
Maximum cost filter
Only show logs with missing cost
Search in request/response content
Number of logs to return (default 50, max 1000)
x <= 1000Number of logs to skip
Field to sort by
timestamp, latency, tokens, cost Sort order
asc, desc Was this page helpful?