> ## Documentation Index
> Fetch the complete documentation index at: https://docs.signa.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Request Log

> Retrieve a single API request log by request ID

<Note>
  **Beta.** The request logs schema is new and may evolve. Field names should be stable, but we reserve the right to add fields or adjust response shape before general availability.
</Note>

## Overview

Returns a single request log entry by its `request_id`. Useful for looking up the full context of a request when a caller reports an error and includes the `request_id` header.

Per-plan access control limits how far back you can retrieve logs:

| Plan                        | Retention window |
| --------------------------- | ---------------- |
| `free`                      | Last 7 days      |
| `starter`                   | Last 30 days     |
| `beta`, `pro`, `enterprise` | Last 90 days     |

Requires the `billing:read` scope.

## Path Parameters

<ParamField path="request_id" type="string" required>
  Request identifier from the `X-Request-Id` response header (e.g. `req_01HXYZ...`).
</ParamField>

## Response

<ResponseField name="id" type="string">The logged request's identifier (matches the `request_id` path parameter).</ResponseField>
<ResponseField name="object" type="string">Always `"request_log"`.</ResponseField>
<ResponseField name="method" type="string">HTTP method.</ResponseField>
<ResponseField name="path" type="string">Request path.</ResponseField>
<ResponseField name="status_code" type="integer">HTTP status code returned.</ResponseField>
<ResponseField name="duration_ms" type="integer">Request duration in milliseconds.</ResponseField>
<ResponseField name="endpoint_type" type="string">Classified endpoint type (e.g. `search`, `read`, `utility`).</ResponseField>
<ResponseField name="credits" type="integer">Credits charged against your plan for this request.</ResponseField>
<ResponseField name="api_key_prefix" type="string">Prefix of the API key used.</ResponseField>
<ResponseField name="error_type" type="string">Error type slug (null on success).</ResponseField>
<ResponseField name="error_detail" type="string">Error detail message (null on success).</ResponseField>
<ResponseField name="created_at" type="string">ISO timestamp when the request was logged.</ResponseField>

<ResponseField name="request_id" type="string">
  The request ID of **this** lookup call (per the standard envelope convention). To identify the logged request being retrieved, use the top-level `id` field.
</ResponseField>

<ResponseExample>
  ```json theme={null}
  {
    "id": "req_01HXYA...",
    "object": "request_log",
    "method": "GET",
    "path": "/v1/trademarks/tm_bogus",
    "status_code": 404,
    "duration_ms": 18,
    "endpoint_type": "read",
    "credits": 0,
    "api_key_prefix": "sig_7kMn",
    "error_type": "not_found",
    "error_detail": "Trademark tm_bogus does not exist.",
    "created_at": "2026-04-18T10:11:05Z",
    "request_id": "req_01HXYZ_currentCall"
  }
  ```
</ResponseExample>

## Code Examples

<CodeGroup>
  ```bash cURL theme={null}
  curl "https://api.signa.so/v1/organization/logs/req_01HXYA..." \
    -H "Authorization: Bearer sig_xxxxxxxxxxxx"
  ```

  ```typescript TypeScript theme={null}
  import { Signa } from "@signa-so/sdk";

  const signa = new Signa({ api_key: "sig_xxxxxxxxxxxx" });

  const log = await signa.organization.logs.retrieve("req_01HXYA...");
  ```

  ```python Python theme={null}
  import requests

  resp = requests.get(
      "https://api.signa.so/v1/organization/logs/req_01HXYA...",
      headers={"Authorization": "Bearer sig_xxxxxxxxxxxx"},
  )
  log = resp.json()
  ```
</CodeGroup>

## Errors

| Status | Type           | Description                                                                                    |
| ------ | -------------- | ---------------------------------------------------------------------------------------------- |
| 401    | `unauthorized` | Missing or invalid API key                                                                     |
| 403    | `forbidden`    | API key lacks `billing:read`                                                                   |
| 404    | `not_found`    | Request log does not exist, belongs to another org, or is outside your plan's retention window |

## Related Endpoints

* [List Request Logs](/api-reference/administration/get-logs) -- paginated list with filters
* [Get Usage Summary](/api-reference/administration/get-usage-summary) -- aggregate usage rollups
