Help Center/ DataArts Insight/ API Reference/ Product Instances/ Listing a User's Enabled Product Instances
Updated on 2025-02-25 GMT+08:00

Listing a User's Enabled Product Instances

Function

This API is used to list a user's enabled product instances.

URI

GET /v1/{project_id}/instances

Table 1 URI parameter

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID.

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

Table 2 Query parameters

Parameter

Mandatory

Type

Description

offset

Yes

Integer

Offset of pagination. The value 0 indicates no offset, that is, the first page. The value 1 indicates that the offset is 1, that is, the second page.

limit

Yes

Integer

Maximum number of returned items allowed.

sort_key

No

String

Sorting field. The value is isOpen, indicating that whether to enable row and column permissions.

sort_dir

No

String

Sorting type. The options are desc and asc. desc indicates the descending order, and asc indicates the ascending order.

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Workspace-Id

Yes

String

Workspace ID. For how to obtain it, see Obtaining a Workspace ID.

X-Auth-Token

Yes

String

User token.

Content-Type

Yes

String

Request body type and character set, which have fixed values.

Response Parameters

Table 4 Response body parameters

Parameter

Type

Description

instances

Array of objects

Instance information. For details, see Table 5.

count

Integer

Number of data records.

page_data

Array of objects

Data on the current page.

Table 5 instances

Parameter

Type

Description

project_id

String

Project ID.

region_id

String

Region ID.

order_id

String

Order ID.

instance_id

String

Product instance ID.

instance_name

String

Product instance name.

resource_spec_code

String

Product specifications

order_type

String

Order type. The options include:

  • ON_DEMAND: Pay-per-use.
  • PERIOD: Yearly/Monthly.

status

Integer

Instance status. The options are:

  • 1: Not effective.
  • 2: In effect.
  • 3: Deleted (unsubscribed).
  • 4: In pretension period (frozen).
  • 5: In grace period.

domain_id

String

Account ID.

eps_id

String

Enterprise project ID.

Example Request

GET https://{endpoint}/v1/{project_id}/instances

Example Response

Enabled product instances are successfully listed.

{
  "count": 1,
  "page_data": [
    {
      "project_id": "9c3043ab4xxxx055888643b331a0xxxx",
      "region_id": "xxx",
      "order_id": "4xxxxd9517314ebbbe17258a9640xxxx",
      "instance_id": "4e7xxxx517314exxxx17258a9640c05f",
      "instance_name": "xxxx-4e7a0d9517314exxxx17258a9640c05f",
      "instance_spec_code": "DataArtsInsight.unit.enterprise.user",
      "order_type": "ON_DEMAND",
      "status": 2,
      "create_user": "***",
      "create_date": 169xxxx2604761,
      "domain_id": "d22f8acfxxxx428fb22606b64dc7xxxx",
      "eps_id": "0"
    }
  ]
}

Status Codes

Status Code

Description

200

Enabled product instances are successfully listed.

Error Codes

See Error Codes.