Help Center/ FunctionGraph/ API Reference/ APIs/ Function Templates/ Querying Function Template Tags
Updated on 2026-10-27 GMT+08:00

Querying Function Template Tags

Function

Querying Function Template Tags

Calling Method

For details, see Calling APIs.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions. For details about the required permissions, see Permissions Policies and Supported Actions.

URI

GET /v2/{project_id}/fgs/template-labels

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Parameter description:

Project ID. For details, see Obtaining a Project ID.

Constraints:

None

Value range:

32 characters, including letters and digits.

Default value:

None

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

marker

No

String

Definition

Start position of the current query.

Constraints

Only digits are allowed. The value is a string of 1 to 64 characters.

Range

N/A

Default value

'0'

limit

No

String

Definition

Maximum number of data records that can be returned in the current query.

Constraints

Only digits are allowed. The value is a string of 1 to 64 characters.

Range

N/A

Default value

'100'

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Parameter description:

User token.

The token can be obtained by calling the IAM API. The value of X-Subject-Token in the response header is the user token.

Constraints:

None

Value range:

None

Default value:

None

Content-Type

No

String

Parameter description:

Specifies the type (or format) of the message body.

Constraints:

None

Value range:

Only application/json is supported.

Default value:

application/json

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

runtime

Array of TemplateLabelItem objects

Definition

Template language.

Range

N/A

scene

Array of TemplateLabelItem objects

Definition

Template scenario.

Range

N/A

service

Array of TemplateLabelItem objects

Definition

Function template for a cloud service.

Range

N/A

Table 5 TemplateLabelItem

Parameter

Type

Description

type

String

Definition

Template tag type.

Range

N/A

display_name

String

Definition

Template tag name.

Range

N/A

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 403

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 500

Table 8 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Requests

Query function template tags.

GET /v2/{project_id}/fgs/template-labels

Example Responses

Status code: 200

{
  "runtime" : [ {
    "type" : "http",
    "display_name" : "Http"
  }, {
    "type" : "Node.js12.13",
    "display_name" : "Node.js 12.13"
  }, {
    "type" : "Node.js16.17",
    "display_name" : "Node.js 16.17"
  }, {
    "type" : "Node.js18.15",
    "display_name" : "Node.js 18.15"
  }, {
    "type" : "Node.js6.10",
    "display_name" : "Node.js 6.10"
  }, {
    "type" : "Node.js8.10",
    "display_name" : "Node.js 8.10"
  }, {
    "type" : "PHP7.3",
    "display_name" : "PHP 7.3"
  }, {
    "type" : "Python2.7",
    "display_name" : "Python 2.7"
  }, {
    "type" : "Python3.6",
    "display_name" : "Python 3.6"
  }, {
    "type" : "Python3.9",
    "display_name" : "Python 3.9"
  } ],
  "scene" : [ {
    "type" : "basic_function_usage",
    "display_name" : "Basic function usage"
  }, {
    "type" : "image_processing",
    "display_name" : "Image processing"
  }, {
    "type" : "data_synchronizing",
    "display_name" : "Data synchronization"
  }, {
    "type" : "data_processing",
    "display_name" : "Data processing"
  }, {
    "type" : "file_processing",
    "display_name" : "File processing"
  }, {
    "type" : "text_recognition",
    "display_name" : "Text recognition"
  }, {
    "type" : "message_processing",
    "display_name" : "Message processing"
  }, {
    "type" : "voice_analysis",
    "display_name" : "Language recognition"
  }, {
    "type" : "edge_computing",
    "display_name" : "Edge computing"
  } ],
  "service" : [ {
    "type" : "APIG",
    "display_name" : "APIG"
  }, {
    "type" : "CTS",
    "display_name" : "CTS"
  }, {
    "type" : "RDS",
    "display_name" : "RDS"
  }, {
    "type" : "LTS",
    "display_name" : "LTS"
  }, {
    "type" : "EVS",
    "display_name" : "EVS"
  }, {
    "type" : "VBS",
    "display_name" : "VBS"
  }, {
    "type" : "FRS",
    "display_name" : "FRS"
  }, {
    "type" : "CDN",
    "display_name" : "CDN"
  }, {
    "type" : "Moderation",
    "display_name" : "Content Moderation"
  }, {
    "type" : "FunctionGraph",
    "display_name" : "FunctionGraph"
  }, {
    "type" : "KAFKA",
    "display_name" : "DMS"
  }, {
    "type" : "IMAGE",
    "display_name" : "Image Recognition"
  }, {
    "type" : "OBS",
    "display_name" : "OBS"
  }, {
    "type" : "OMS",
    "display_name" : "OMS"
  }, {
    "type" : "ECS",
    "display_name" : "ECS"
  }, {
    "type" : "DEW",
    "display_name" : "Data Encryption Workshop (DEW)"
  }, {
    "type" : "DIS",
    "display_name" : "DIS"
  }, {
    "type" : "OCR",
    "display_name" : "OCR"
  }, {
    "type" : "SMN",
    "display_name" : "SMN"
  }, {
    "type" : "SIS",
    "display_name" : "SIS"
  } ]
}

Status Codes

Status Code

Description

200

OK

401

Unauthorized.

403

Forbidden.

500

Internal server error.

Error Codes

See Error Codes.