Updated on 2024-08-15 GMT+08:00

Using STS Token

  1. Log in to the FunctionGraph console, choose Functions > Function List, and click a function name to go to the function details page.
    Figure 1 Viewing function details
  2. Click the Code tab and replace context.getAccessKey() and context.getSecretKey() in the original code with context.getSecurityAccessKey(), context.getSecuritySecretKey(), and context.getSecurityToken(). (Python is used as an example. For details about other languages, see Other Languages.)
    Figure 2 Modifying code

    The STS token must contain the securityAccessKey, securitySecretKey, and securityToken parameters.

Other Languages

Java, Python, Go, Node.js, .Net, and PHP.