ListServiceInstances

Updated at:

Queries a list of service instances.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

computenestsupplier:ListServiceInstances

list

*ServiceInstance

acs:computenestsupplier:{#regionId}:{#accountId}:serviceinstance/*

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

No

The region ID.

cn-hangzhou

MaxResults

integer

No

The paging size for a paged query. Maximum value: 100. Default value: 20.

10

NextToken

string

No

The pagination token. Set the value to the NextToken value returned from the previous API call.

BBBAAfu+XtuBE55iRLHEYYuojI4=

Filter

array<object>

No

The filters.

object

No

The filters.

Value

array

No

The list of filter values.

string

No

The filter values. Valid values of N: 1 to 10.

value1

Name

string

No

The filter name. You can specify one or more names for the query. Valid values:

  • Name: queries by service name. For a fuzzy search, enter the value in the xxx format. For example, if the service name is My Service, you can enter My or Service for a fuzzy search.

  • ServiceInstanceId: the service instance ID

  • ServiceId: the service ID

  • UserId: the user ID

  • Version: the service version

  • Status: the service instance status

  • DeployType: the deployment type

  • ServiceType: the service type

  • OperationStartTimeBefore: before the start time of Alibaba Cloud Managed Services

  • OperationStartTimeAfter: after the start time of Alibaba Cloud Managed Services

  • OperationEndTimeBefore: before the end time of Alibaba Cloud Managed Services

  • OperationEndTimeAfter: after the end time of Alibaba Cloud Managed Services

  • OperatedServiceInstanceId: the instance ID of the Alibaba Cloud Managed Services instance under a privately deployed service

  • OperationServiceInstanceId: the service instance ID under pure Alibaba Cloud Managed Services

  • EnableInstanceOps: specifies whether the Alibaba Cloud Managed Services feature is enabled for the service instance

ServiceInstanceId

ShowDeleted

boolean

No

Specifies whether to display deleted instances. Valid values:

  • true: Displays deleted instances.

  • false: Does not display deleted instances.

false

Tag

array<object>

No

The custom tags.

object

No

The custom tags.

Key

string

No

The tag key.

key1

Value

string

No

The tag value.

value1

ResourceGroupId

string

No

The resource group ID.

rg-aekzkt5buxxxxxx

Response elements

Element

Type

Description

Example

object

NextToken

string

The pagination token for the next query.

AAAAAfu+XtuBE55iRLHEYYuojI4=

RequestId

string

The request ID.

E50287CB-AABF-4877-92C0-289B339A1546

TotalCount

integer

The total number of results.

100

MaxResults

integer

The paging size for a paged query. Maximum value: 100. Default value: 20.

20

ServiceInstances

array<object>

The service instance information.

array<object>

The service instance information.

Status

string

The service instance status. Valid values:

  • Created: The instance is created.

  • Deploying: The instance is being deployed.

  • DeployedFailed: The instance failed to be deployed.

  • Deployed: The instance is deployed.

  • Upgrading: The instance is being upgraded.

  • Deleting: The instance is being deleted.

  • Deleted: The instance is deleted.

Deployed

UpdateTime

string

The update time.

2021-05-20T00:00:00Z

Name

string

The service instance name.

TestName

ServiceInstanceId

string

The service instance ID.

si-d6ab3a63ccbb4b17****

CreateTime

string

The creation time.

2021-05-20T00:00:00Z

UserId

integer

The AliUid of the user.

1234567

Service

object

The service.

Status

string

The service status.

Online

PublishTime

string

The publish time.

2021-05-21T00:00:00Z

Version

string

The service version.

1.0

DeployType

string

The deployment type. Valid values:

  • ros: deployed by using Resource Orchestration Service (ROS)

  • terraform: deployed by using Terraform

  • ack: deployed by using Container Service for Kubernetes (ACK)

  • spi: deployed by using the invoke API of SPI

  • operation: deployed by using Alibaba Cloud Managed Services

ros

ServiceId

string

The service ID.

service-0e6fca6a51a54420****

SupplierUrl

string

The service provider URL.

http://example.com

ServiceType

string

The service type. Valid values:

  • private: deployment in the user account

  • managed: hosted in the service provider account

  • operation: Alibaba Cloud Managed Services

  • poc: proof of concept (POC) service instance

private

SupplierName

string

The service provider name.

Company A Co., Ltd

ServiceInfos

array<object>

The service information.

object

The service information.

Locale

string

The language of the service instance.

zh-CN

Image

string

The URL of the service icon.

https://example.com/service-image/c1c4a559-cc60-4af1-b976-98f356602462.png

Name

string

The service name.

Database B

ShortDescription

string

The service overview.

Database B is an open source distributed relational database independently designed and developed by Company A

VersionName

string

The custom version name defined by the service provider.

Version A

DeployMetadata

string

The information about the service deployment configuration. The stored information varies based on the deployment type. Different deployment types use different data formats. Therefore, the data is stored as a JSON string.

{ "EstimateTime": null, "SupplierDeployMetadata": { "DeployTimeout": null }, "TemplateConfigs": [ { "Name": "Template 1", "Url": "https://service-info-private.oss-cn-hangzhou.aliyuncs.com/130920852836****/template/af11ec5a-09a0-4aa7-970c-09b51e2a****.json", "PredefinedParameters": [], "AllowedRegions": [ "cn-hangzhou" ] } ] }

EnablePrivateVpcConnection

boolean

Specifies whether private network connection is enabled. Valid values:

  • true: Enabled.

  • false: Disabled.

false

SourceSupplierName

string

The name of the source service provider for distribution.

Company A Co., Ltd

Parameters

string

The parameter information of the service instance.

{"param":"value"}

Progress

integer

The deployment progress of the service instance. Unit: %.

90

StatusDetail

string

The description of the deployment information for the service instance.

deploy successfully

TemplateName

string

The template name.

Template 1

OperatedServiceInstanceId

string

The instance ID of the service managed by Alibaba Cloud Managed Services.

si-d6ab3a63ccbb4b17****

OperationStartTime

string

The start time of the managed service.

2021-12-29T06:48:56Z

OperationEndTime

string

The end time of the managed service.

2021-12-29T06:48:56Z

EnableInstanceOps

boolean

Specifies whether the service instance has the managed service feature. Valid values:

  • true: The service instance has the managed service feature.

  • false: The service instance does not have the managed service feature.

true

Tags

array<object>

The custom tags.

object

The custom tags.

Key

string

The tag key.

key1

Value

string

The tag value.

value1

Source

string

The creation source of the service instance.

Supplier

EndTime

string

The expiration time of the service instance.

2022-01-01T12:00:00

ServiceType

string

The service type. Valid values:

  • private: the service instance with deployment in the user account.

  • managed: the service instance hosted in the service provider account.

  • operation: the Alibaba Cloud Managed Services instance.

  • poc: the POC service instance.

private

PayType

string

The billing method. Valid values:

  • Permanent: permanent purchase

  • Subscription: subscription in Alibaba Cloud Marketplace

  • PayAsYouGo: pay-as-you-go in Alibaba Cloud Marketplace

  • CustomFixTime: custom fixed duration defined by the merchant

Subscription

IsOperated

boolean

Specifies whether the managed service feature is enabled for the service instance. Valid values:

  • true: The managed service feature is enabled for the service instance.

  • false: The managed service feature is disabled for the service instance.

true

ResourceGroupId

string

The resource group ID.

si-d6ab3a63ccxxxxxx

BizStatus

string

The business status of the service instance. Valid values:

  • Normal: Normal.

  • Renewing: Renewing.

  • RenewFoiled: Renewal failed.

  • Expired: Expired.

Normal

GrantedPermission

object

The granted permission information, including the authorization end time and policy names.

OperationEndTime

string

The end time of the managed service.

2026-11-11T00:00:00Z

PolicyNames

string

The authorization policy name. Multiple policy names are separated by commas (,).

AliyunComputeNestPolicyForTerminalLogin,AliyunComputeNestPolicyForAlarm,AliyunComputeNestPolicyForUpgrade

PolicyNames

string

The authorization policy name. Multiple policy names are separated by commas (,).

AliyunComputeNestPolicyForReadOnly,AliyunComputeNestPolicyForUpgrade

Examples

Success response

JSON format

{
  "NextToken": "AAAAAfu+XtuBE55iRLHEYYuojI4=",
  "RequestId": "E50287CB-AABF-4877-92C0-289B339A1546",
  "TotalCount": 100,
  "MaxResults": 20,
  "ServiceInstances": [
    {
      "Status": "Deployed",
      "UpdateTime": "2021-05-20T00:00:00Z",
      "Name": "TestName",
      "ServiceInstanceId": "si-d6ab3a63ccbb4b17****",
      "CreateTime": "2021-05-20T00:00:00Z",
      "UserId": 1234567,
      "Service": {
        "Status": "Online",
        "PublishTime": "2021-05-21T00:00:00Z",
        "Version": "1.0",
        "DeployType": "ros",
        "ServiceId": "service-0e6fca6a51a54420****",
        "SupplierUrl": "http://example.com",
        "ServiceType": "private",
        "SupplierName": "Company A Ltd.",
        "ServiceInfos": [
          {
            "Locale": "zh-CN",
            "Image": "https://example.com/service-image/c1c4a559-cc60-4af1-b976-98f356602462.png",
            "Name": "Database B",
            "ShortDescription": "B is an open-source distributed relational database independently designed and developed by Company A."
          }
        ],
        "VersionName": "Version A",
        "DeployMetadata": "{\n      \"EstimateTime\": null,\n      \"SupplierDeployMetadata\": {\n            \"DeployTimeout\": null\n      },\n      \"TemplateConfigs\": [\n            {\n                  \"Name\": \" template1\",\n                  \"Url\": \"https://service-info-private.oss-cn-hangzhou.aliyuncs.com/130920852836****/template/af11ec5a-09a0-4aa7-970c-09b51e2a****.json\",\n                  \"PredefinedParameters\": [],\n                  \"AllowedRegions\": [\n                        \"cn-hangzhou\"\n                  ]\n            }\n      ]\n}",
        "EnablePrivateVpcConnection": false,
        "SourceSupplierName": "Company A Ltd."
      },
      "Parameters": "{\"param\":\"value\"}",
      "Progress": 90,
      "StatusDetail": "deploy successfully",
      "TemplateName": "Template 1",
      "OperatedServiceInstanceId": "si-d6ab3a63ccbb4b17****",
      "OperationStartTime": "2021-12-29T06:48:56Z",
      "OperationEndTime": "2021-12-29T06:48:56Z",
      "EnableInstanceOps": true,
      "Tags": [
        {
          "Key": "key1",
          "Value": "value1"
        }
      ],
      "Source": "Supplier",
      "EndTime": "2022-01-01T12:00:00",
      "ServiceType": "private",
      "PayType": "Subscription",
      "IsOperated": true,
      "ResourceGroupId": "si-d6ab3a63ccxxxxxx",
      "BizStatus": "Normal",
      "GrantedPermission": {
        "OperationEndTime": "2026-11-11T00:00:00Z",
        "PolicyNames": "AliyunComputeNestPolicyForTerminalLogin,AliyunComputeNestPolicyForAlarm,AliyunComputeNestPolicyForUpgrade"
      },
      "PolicyNames": "AliyunComputeNestPolicyForReadOnly,AliyunComputeNestPolicyForUpgrade"
    }
  ]
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.