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

# 获取项目

> 通过 ID 或自定义 ID 检索项目

```
GET /openapi/memorylake/api/v3/workspaces/{workspaceId}/projects/{projectId}
```

从工作空间中检索单个项目。默认情况下，`projectId` 路径参数与内部项目 ID 匹配。设置 `by_custom_id=true` 可改为通过自定义标识符查找项目。

<Note>
  **所需权限：** `project:read`
</Note>

### 路径参数

<ParamField path="workspaceId" type="string" required>
  工作空间标识符
</ParamField>

<ParamField path="projectId" type="string" required>
  项目标识符。默认解释为内部 ID，当 `by_custom_id` 为 `true` 时解释为自定义 ID。
</ParamField>

### 查询参数

<ParamField query="by_custom_id" type="boolean">
  当设置为 `true` 时，`projectId` 路径参数将与项目的 `custom_id` 而非内部 `id` 进行匹配。
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET 'https://app.memorylake.ai/openapi/memorylake/api/v3/workspaces/ws_abc123/projects/proj_def456' \
    -H 'Authorization: Bearer sk_xxxxxx'
  ```
</RequestExample>

### 响应

<ResponseField name="data" type="object">
  <Expandable title="项目对象">
    <ResponseField name="id" type="string">项目唯一标识符</ResponseField>
    <ResponseField name="name" type="string">项目名称</ResponseField>
    <ResponseField name="description" type="string">项目描述</ResponseField>

    <ResponseField name="industries" type="array">
      分配给项目的行业分类

      <Expandable title="行业对象">
        <ResponseField name="id" type="string">行业标识符</ResponseField>
        <ResponseField name="name" type="string">行业名称</ResponseField>
        <ResponseField name="description" type="string">行业描述</ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="custom_id" type="string">用于外部系统集成的自定义标识符</ResponseField>
    <ResponseField name="created_at" type="string">创建时间戳</ResponseField>
    <ResponseField name="updated_at" type="string">最后更新时间戳</ResponseField>
  </Expandable>
</ResponseField>

<ResponseExample>
  ```json Success (200) theme={null}
  {
    "success": true,
    "data": {
      "id": "proj_def456",
      "name": "Customer Research",
      "description": "Interview transcripts and survey analysis",
      "industries": [
        {
          "id": "ind_tech01",
          "name": "Technology",
          "description": "Software and technology sector"
        }
      ],
      "custom_id": "research-2024-q1",
      "created_at": "2024-01-15T10:30:00Z",
      "updated_at": "2024-02-10T08:15:00Z"
    }
  }
  ```
</ResponseExample>
