The Get Span endpoint allows you to retrieve complete information about a specific span by its unique ID, including:
input and output fields)log_typelimit_info)Each span in the response includes:
input (string): JSON-serialized representation of the span’s input dataoutput (string): JSON-serialized representation of the span’s output datalog_type (string): Type of span ("chat", "embedding", "workflow", etc.)For log_type="chat", "completion", "text", or "response":
prompt_messages (array): Full input messages array (extracted from input)completion_message (object): Full output message object (extracted from output)For other span types (embedding, workflow, etc.), type-specific fields are extracted based on the log_type. See span types for details.
You should first get the span list, and based on the unique_id in the list, retrieve the specific span. Learn more about the span list endpoint.
Every span includes credit and budget check information in the respan_params.limit_info field (available in the detail endpoint only).
limit_info?When you make an LLM request, Respan checks:
The limit_info object shows the results of these checks.
is_allowed: Whether the request was allowed to proceed (all limits passed)limits: Array of individual limit check results
name: Type of limit - "org_credits" or "customer_budget"current_value: Balance before this request (USD)new_value: Balance after this request (USD)limit_value: Minimum required balance (USD)is_within_limit: Whether this specific check passedMonitor spending: Track credit usage per request
Debug rejections: Understand why a request was blocked
Customer analytics: Analyze per-customer spending patterns
Budget alerts: Build custom alerts when approaching limits
Example: Request Allowed
Request succeeded. Organization had 49.98 after this $0.02 request.
Example: Request Blocked
Request blocked. Customer has used 10 budget, not enough for this request.
unique_id string required: The unique ID of the log to get.API key authentication. Get your API key from https://platform.respan.ai/platform/api-keys