Query a list of available instances of a function.
Operation description
The ListInstances operation allows you to query available instances of a function.
Available instances are instances that are processing requests or can be scheduled to process requests. Available instances queried by the ListInstances operation are the same as the active instances queried by using the InvokeFunction operation if values of ServiceName
, FunctionName
, and Qualifier
are the same.
Debugging
Authorization information
Request syntax
GET /2021-04-06/services/{serviceName}/functions/{functionName}/instances
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
serviceName | string | Yes | The name of the service. | demoService |
functionName | string | Yes | The name of the function. | demoFunction |
qualifier | string | No | The version or alias. | dev |
instanceIds | array | No | The instance ID. | |
string | No | The instance ID. | ["1ef6b6ff-7f7b-485e-ab49-501ac681****", "04db0821-c6d2-4c10-970b-93e36f1a****"] | |
limit | integer | No | The maximum number of resources to return. Valid values: [0,1000]. The number of returned resources is less than or equal to the specified number. | 20 |
X-Fc-Account-Id | string | No | The ID of your Alibaba Cloud account. | 188077086902**** |
Response parameters
Examples
Sample success responses
JSON
format
{
"instances": [
{
"instanceId": "1ef6b6ff-7f7b-485e-ab49-501ac681****",
"versionId": "1"
}
]
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||
---|---|---|---|---|
2024-03-27 | The internal configuration of the API is changed, but the call is not affected | see changesets | ||
| ||||
2024-02-19 | The internal configuration of the API is changed, but the call is not affected | see changesets | ||
| ||||
2022-06-15 | Add Operation | see changesets |