You can call this operation to view the list of triggers.

Request headers

This operation uses only common request headers. For more information, see Common parameters.

Request syntax

GET /services/{serviceName}/functions/{functionName}/triggers 

Request parameters

Parameter Type Position Required Example Description
serviceName String Path Yes service_name

The name of the service.

functionName String Path Yes function_name

The name of the function.

limit Integer Query No 20

The maximum number of resources to return. Default value: 20. Maximum value: 100. The number of returned resources is smaller than or equal to the specified number.

nextToken Integer Query No next_trigger

The token used to obtain more results. If the number of resources exceeds the limit, the nextToken parameter is returned. Include this parameter in subsequent invocations to obtain more results. You do not need to provide this parameter in the first invocation.

prefix String Query No prefix_text

The prefix that the names of returned resources must contain.

startKey String Query No start_key

The starting position of the result list. Results are sorted in the alphabetical order and those results following startKey (inclusive) are listed.

Response parameters

Parameter Type Example Description
nextToken String next_trigger

The token used to obtain more results. If this value is not returned, all results are returned.

triggers Array

The definition of the trigger.

createdTime String 2020-04-08T01:48:21Z

The time when the trigger was created.

invocationRole String acs:ram::198611****4430:role/aliyunosseventnotificationrole

The role required when the trigger source such as OSS invokes the function. For more information, see Overview.

lastModifiedTime String 2020-04-08T01:48:21Z

The last time when the trigger was updated.

qualifier String null

The version of the service. For more information, see Introduction to versions.

sourceArn String acs:oss:cn-shanghai:12345:mybucket

The Alibaba Cloud Resource Name (ARN) of the event source for the trigger.

triggerConfig String true

The configurations of the trigger. The configurations vary with trigger types.

triggerName String trigger_name

The name of the trigger.

triggerType String oss

The type of the trigger. Valid values:


Sample requests

GET /2016-08-15/services/service_name/functions/function_name/triggers HTTP/1.1 
Common request headers

Sample success responses

JSON format

  "triggers": [
      "triggerName": "trigger_name",
      "description": "test_description",
      "triggerId": "b883122b-6f86-4889-bb69-1729a4***",
      "sourceArn": "acs:oss:cn-shanghai:12345:mybucket",
      "triggerType": "oss",
      "invocationRole": "acs:ram::198611****4430:role/aliyunosseventnotificationrole",
      "triggerConfig": {
        "events": [
        "filter": {
          "key": {
            "prefix": "prefix_text",
            "suffix": ".zip"
      "createdTime": "2020-04-08T01:48:21Z",
      "lastModifiedTime": "2020-04-08T01:48:21Z"