How to test a function
This page shows you how to execute Serverless Functions from the Scaleway console. The Test feature of a function allows you to run your code using a selection of methods to make sure it behaves as expected.
You may need certain IAM permissions to carry out some actions described on this page. This means:
- you are the Owner of the Scaleway Organization in which the actions will be carried out, or
- you are an IAM user of the Organization, with a policy granting you the necessary permission sets
- You have an account and are logged into the Scaleway console
- You have created a function
-
Click Functions in the Serverless section of the side menu. The functions page displays.
-
Click the relevant functions namespace. A list of your functions displays.
-
Click the name of the function you want to test.
-
Open the Test tab.
-
Select the method you want to use from the drop-down menu.
-
Enter the path to your function. Leave the default
/
value if your function is not located in a specific folder within a Zip package. -
Click + Advanced options to add any required HTTP header or parameter to your function.
-
Click Run.
The Output section displays the response from your function and the status code.