Function Templates

FunctionGraph provides templates to automatically complete code, and running environment configurations when you create a function, helping you quickly build applications.

Template Usage

Creating a Function

  1. Log in to the FunctionGraph console, and choose Templates in the navigation pane.
  2. On the page that is displayed, select the FunctionGraph service, select the context-class-introduction template for Python 2.7, and click Configure.
  3. After you select a function template, the built-in code and configurations of the template are automatically loaded. The Create Function page is displayed.
  4. Set the function name to context, retain the default settings for other parameters, and click Create Now.

Triggering a Function

  1. On the Code tab page of the context function, click Test in the upper right corner.
  2. In the Configure Test Event dialog box that is displayed, click Save and Test. After the test is complete, view the test result.