All Products
Search
Document Center

OpenSearch:GetFunctionResource

Last Updated:Dec 09, 2025

Retrieves the specified algorithm resource.

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

opensearch:DescribeFunction

get

*FunctionResource

acs:opensearch:{#regionId}:{#accountId}:apps/{#AppGroupId}

None None

Request syntax

GET /v4/openapi/app-groups/{appGroupIdentity}/functions/{functionName}/resources/{resourceName} HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

appGroupIdentity

string

Yes

The application ID.

my_app_group_name

functionName

string

Yes

The feature name.

rank

resourceName

string

Yes

The instance name.

fg_json

Request parameters

Parameter

Type

Required

Description

Example

output

string

No

The output level.

detail

Response elements

Element

Type

Description

Example

object

Status

string

The status code.

  • OK: The request was successful.

  • FAIL: The request failed.

OK

HttpCode

integer

The HTTP status code.

200

RequestId

string

The request ID.

E215C843-0795-5293-AC9A-14FE0723E890

Message

string

The returned error message.

Resource not exist.

Code

string

The returned error code. This is empty if no error occurred.

Resource.NotExist

Result

object

The returned result.

CreateTime

integer

The time when the resource was created. Unit: milliseconds.

1234

Data

object

The resource data. The structure of the data varies based on the resourceType.

Content

string

The content of the file for a resource of the raw_file type.

abc

Generators

array<object>

The list of feature generators for a resource of the feature_generator type.

array<object>

The description of the feature generator.

Generator

string

The type of the feature generator.

id

Input

object

The input.

Features

array<object>

The list of input features.

object

The input feature.

Name

string

The feature name.

system_item_id

Type

string

The feature type.

item

Output

string

The name of the output feature.

output_feature_name

Description

string

The description of the resource.

""

FunctionName

string

The feature name.

rank

ModifyTime

integer

The time when the resource was last modified. Unit: milliseconds.

1234

ReferencedInstances

array

The list of referenced algorithm instance names.

string

The instance name.

instance1

ResourceName

string

The resource name.

fg_json

ResourceType

string

The resource type.

raw_file

Latency

number

The time consumed by the API request. Unit: milliseconds.

123

Examples

Success response

JSON format

{
  "Status": "OK",
  "HttpCode": 200,
  "RequestId": "E215C843-0795-5293-AC9A-14FE0723E890",
  "Message": "Resource not exist.",
  "Code": "Resource.NotExist",
  "Result": {
    "CreateTime": 1234,
    "Data": {
      "Content": "abc",
      "Generators": [
        {
          "Generator": "id",
          "Input": {
            "Features": [
              {
                "Name": "system_item_id",
                "Type": "item"
              }
            ]
          },
          "Output": "output_feature_name"
        }
      ]
    },
    "Description": "\"\"",
    "FunctionName": "rank",
    "ModifyTime": 1234,
    "ReferencedInstances": [
      "instance1"
    ],
    "ResourceName": "fg_json",
    "ResourceType": "raw_file"
  },
  "Latency": 123
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.