NavigationContentFooter
Suggest an edit
Was this page helpful?

How to test a function

Reviewed on 10 October 2024Published on 25 September 2023

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.

Note

Testing Private Serverless Functions is not possible using the Scaleway console due to CORS limitations. Refer to the dedicated documentation for more information on how to secure and test a private function.

Before you startLink to this anchor

To complete the actions presented below, you must have:

  • A Scaleway account logged into the console
  • Owner status or IAM permissions allowing you to perform actions in the intended Organization
  • Created a function
  1. Click Functions in the Serverless section of the side menu. The functions page displays.

  2. Click the relevant functions namespace. A list of your functions displays.

  3. Click the name of the function you want to test.

  4. Open the Test tab.

  5. Select the method you want to use from the drop-down menu.

  6. Enter the path to your function. Leave the default / value if your function is not located in a specific folder within a Zip package.

  7. Click + Advanced options to add any required HTTP header or parameter to your function.

  8. Click Run.

The Output section displays the response from your function and the status code.

Note

If you encounter a message error while testing your function, refer to the dedicated troubleshooting for more information.

See also
How to create a functionHow to package function in a zip file
Was this page helpful?
API DocsScaleway consoleDedibox consoleScaleway LearningScaleway.comPricingBlogCareers
© 2023-2025 – Scaleway