获取notebook详情
功能介绍
获取notebook详情
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
URI
GET /v1/{project_id}/eihealth-projects/{eihealth_project_id}/notebooks/{notebook_id}
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
eihealth_project_id | 是 | String | 平台项目ID,您可以在平台单击所需的项目名称,进入项目设置页面查看。 最小长度:1 最大长度:128 |
notebook_id | 是 | String | notebook id 最小长度:1 最大长度:128 |
project_id | 是 | String | 华为云项目ID,您可以从获取项目ID中获取。 最小长度:1 最大长度:128 |
请求参数
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
X-Auth-Token | 是 | String | 用户Token。Token认证就是在调用API的时候将Token加到请求消息头,从而通过身份认证,获得操作API的权限,获取Token接口响应消息头中X-Subject-Token的值即为Token。 最小长度:1 最大长度:32768 |
响应参数
状态码: 200
参数 | 参数类型 | 描述 |
|---|---|---|
id | String | notebook ID |
name | String | notebook名称 |
description | String | notebook描述 |
creator | String | notebook所属用户 |
url | String | notebook访问URL |
flavor | FlavorInfo object | notebook规格 |
status | String | notebook状态 枚举值:
|
image | NotebookImage object | notebook镜像信息 |
storages | Array of NotebookStorage objects | notebook存储信息 |
create_time | String | notebook创建时间 |
update_time | String | notebook更新时间 |
failed_message | String | notebook失败信息 |
events | Array of TaskEventRsp objects | cce事件 |
参数 | 参数类型 | 描述 |
|---|---|---|
cpu | Float | notebook占用的cpu,0.1核为100m,单位为"C" 最小值:1 最大值:128 缺省值:1 |
gpu | Float | notebook占用的gpu,0.1为使用单卡10%,1为占满单个显卡,1+为使用多个显卡 最小值:0 最大值:16 缺省值:0 |
memory | Float | notebook占用的内存,单位为"G" 最小值:2 最大值:512 缺省值:2 |
参数 | 参数类型 | 描述 |
|---|---|---|
source_project_name | String | 源项目名 最小长度:1 最大长度:128 |
image_name | String | 镜像名 最小长度:1 最大长度:128 |
image_tag | String | 镜像tag名 最小长度:1 最大长度:64 |
profile | String | 系统镜像名 枚举值:
|
请求示例
获取notebook详情
https://eihealth.cn-north-4.myhuaweicloud.com/v1/{project_id}/eihealth-projects/{eihealth_project_id}/notebooks/{notebook_id} 响应示例
状态码: 200
OK
{
"id" : "DE-7d558ef8-c73d-11ea-964c-0255ac100033",
"name" : "notebook-example",
"description" : "notebook description in here",
"creator" : "notebook_creator",
"url" : "https://0.0.0.0:0000/0951eb641.../notebook/e4a3b97a.../services/notebook",
"flavor" : {
"cpu" : "1",
"gpu" : "0",
"memory" : "100"
},
"status" : "Running",
"image" : {
"image_type" : "SYSTEM",
"image_info" : {
"source_project_name" : "eihealth-project",
"image_name" : "eihealth-notebook",
"image_tag" : "3.1.0-latest",
"profile" : "PY3"
}
},
"storages" : [ {
"path" : "project_name:/example",
"mount_path" : "/example"
} ],
"create_time" : "2020-09-10T10:07:17Z",
"update_time" : "2020-09-10T10:07:17Z",
"failed_message" : "failed massage in here"
} 状态码
状态码 | 描述 |
|---|---|
200 | OK |
错误码
请参见错误码。

