After creating a function, you can create a trigger to associate the function with an event source. The associated event source will trigger the function synchronously or asynchronously as specified when an event is generated, and the event will be passed to the entry function as an input parameter upon triggering.
A function trigger can be created in the console or on Serverless Cloud Framework CLI.
Only API Gateway triggers can be created for HTTP-triggered functions. For more information, see Creating and Testing Function.
Trigger alias/version: Switch to the desired trigger version. A trigger can be created on a specified version of a function. An event of the trigger created in this manner will trigger the code on the specified version. For more information, see Overview.
There are certain quota limits for the total number of triggers and number of triggers in each type for a function. Triggers created on different versions take up the quota of the function. To increase the limit, contact us for application.
Trigger method: The information to be entered varies by trigger method. For example, for a timer trigger, you need to enter the trigger name, cycle, and status. For a COS trigger, you need to enter the COS bucket, event type, and prefix/suffix filters. For more information, see Trigger Overview.
Before starting, install the Serverless Cloud Framework CLI tool first as instructed in Installation.
For local functions, add the trigger description in the
serverless.yml file. Then, run the
scf deploy command on Serverless Cloud Framework CLI to add a trigger to the function.
Contact our sales team or business advisors to help your business.
Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.
Was this page helpful?