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

# マッピング済み URL の取得

> サイトに紐づくマッピング済み URL を取得するエンドポイントです。

## GET /sites/{siteId}/urls

特定サイトについて、生成処理で処理した URL とそのメタデータを一覧します。

### パスパラメーター

<ParamField path="siteId" type="string" required>
  サイトの ID。
</ParamField>

### クエリパラメーター

<ParamField query="page" type="number" default="1">
  ページ番号。
</ParamField>

<ParamField query="limit" type="number" default="50">
  1 ページあたりの URL 件数（最大 100）。
</ParamField>

<ParamField query="status" type="string">
  状態で絞り込み: `pending`、`scraped`、`failed`。
</ParamField>

### レスポンス

<ResponseField name="urls" type="array">
  マッピング済み URL オブジェクトの配列。

  <Expandable title="url のプロパティ">
    <ResponseField name="id" type="string">
      マッピング済み URL の一意な識別子。
    </ResponseField>

    <ResponseField name="url" type="string">
      URL。
    </ResponseField>

    <ResponseField name="title" type="string">
      ページタイトル。
    </ResponseField>

    <ResponseField name="description" type="string">
      ページの説明文（Enhanced 利用時は AI 強化）。
    </ResponseField>

    <ResponseField name="status" type="string">
      処理状態: `pending`、`scraped`、`failed`。
    </ResponseField>

    <ResponseField name="lastModified" type="string">
      サイトマップ由来の最終更新日時（取得できた場合）。
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="total" type="number">
  マッピング済み URL の総数。
</ResponseField>

<ResponseField name="page" type="number">
  現在のページ番号。
</ResponseField>

<ResponseField name="totalPages" type="number">
  総ページ数。
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://api.llmgenerator.com/api/v1/sites/550e8400-e29b-41d4-a716-446655440000/urls?limit=20" \
    -H "Authorization: Bearer YOUR_API_KEY"
  ```

  ```javascript Node.js theme={null}
  const response = await fetch(
    'https://api.llmgenerator.com/api/v1/sites/550e8400-e29b-41d4-a716-446655440000/urls',
    {
      headers: { 'Authorization': 'Bearer YOUR_API_KEY' }
    }
  );

  const data = await response.json();
  ```
</RequestExample>

<ResponseExample>
  ```json 成功 (200) theme={null}
  {
    "urls": [
      {
        "id": "url_abc123",
        "siteId": "550e8400-e29b-41d4-a716-446655440000",
        "url": "https://example.com/",
        "title": "Example Domain - Home",
        "description": "Welcome to Example Domain, your comprehensive resource for...",
        "status": "scraped",
        "lastModified": "2026-01-15T00:00:00.000Z"
      },
      {
        "id": "url_def456",
        "siteId": "550e8400-e29b-41d4-a716-446655440000",
        "url": "https://example.com/about",
        "title": "About Us",
        "description": "Learn about our mission and team.",
        "status": "scraped",
        "lastModified": null
      }
    ],
    "total": 47,
    "page": 1,
    "totalPages": 3
  }
  ```

  ```json 見つからない (404) theme={null}
  {
    "message": "Site not found"
  }
  ```
</ResponseExample>
