Help Center> RES> API Reference> API> Scenario> Querying the Details of a Scenario

Querying the Details of a Scenario

Function

This API is used to query the details about a specified scenario.

URI

GET /v2.0/{project_id}/workspaces/{workspace_id}/scenes/{scene_id}

Table 1 Path parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID. For details on how to obtain the project ID, see Obtaining a Project ID.

scene_id

Yes

String

Scenario ID

workspace_id

Yes

String

Workspace ID

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

Content-Type

Yes

String

Content type. The value is application/json.

X-Auth-Token

Yes

String

User token. For details on how to obtain the user token, see Obtaining a User Token Through Password Authentication.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

is_success

Boolean

Whether the request is successful

scene

res_scene object

Scenario details

message

String

Response message (This field is not returned when the request is successful.)

error_code

String

Error code (This parameter is not returned when the request is successful.)

Table 4 res_scene

Parameter

Type

Description

category

String

Type

datasource_id

String

Data source ID

ds_config

DataConfig object

Data source settings

scene_id

String

Scenario ID

scene_name

String

Scenario name

type

String

Scenario type

service_type

String

Service type

status

String

Status

workspace_id

String

Workspace ID

created_at

String

Creation time

update_at

String

Update time

specs_config

SpecsConfig object

Computing specifications

Table 5 DataConfig

Parameter

Type

Description

offline

Offline object

Offline computing specifications

nearline

Nearline object

Nearline data source

Table 6 Offline

Parameter

Type

Description

user_url

String

User data URL

item_url

String

Item data URL

behavior_url

String

Behavior data URL

Table 7 Nearline

Parameter

Type

Description

item_topic

Topic object

Item topic

user_topic

Topic object

User topic

behavior_topic

Topic object

Behavior topic

Table 8 Topic

Parameter

Type

Description

name

String

Name

id

String

ID

Table 9 SpecsConfig

Parameter

Type

Description

offline

String

Offline computing specifications

nearline

String

Real-time computing specifications

rank

String

Deep learning computing specifications

online_tps

Integer

Max. number of concurrent online services

Example Requests

This API is used to query the details of a scenario.

/v2.0/testuuidxxxxxxxxxxxxxxxxxxxxxxxx/workspaces/testuuidxxxxxxxxxxxxxxxxxxxxxxxx/scenes/testuuidxxxxxxxxxxxxxxxxxxxxxxxx

-

Example Responses

Status code: 200

OK

{
  "scene" : {
    "type" : "UI",
    "service_type" : "rank",
    "ds_config" : {
      "time_interval" : 30
    },
    "specs_config" : {
      "offline" : "4CU",
      "nearline" : "2CU",
      "rank" : "8CU",
      "online_tps" : 10
    },
    "scene_name" : "jby-test-0227-4",
    "category" : "customize",
    "scene_id" : "f715e1c61f1f40489b2e4594650fffd8",
    "datasource_id" : "6a3475a7dd11492e8d14f73a3719333b",
    "status" : "INITIALIZED",
    "created_at" : 1584628346333,
    "update_at" : 1584628346333,
    "workspace_id" : "68887f2a855f45e7ab4850ecc7ca28c2"
  },
  "is_success" : true
}

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.