Managing Functions

Launching the First Function

To create a function:

  1. Log in to the Control panel.
  2. Go to the Cloud platform section.
  3. Create a project and go to the Functions tab.
  4. Click Create function.
  5. Specify a unique function name.
  6. Click Edit function on the Settings tab.
  7. Upload the code in the archive in the .tar * format and specify the path to the file with the code in the archive or upload only the file with the code in the .py format. Specify the function name from the code you want to create and environment variables if necessary.
  8. In addition to the file with the function, the tarballs should also contain the requirements.txt file (a list of libraries not included in the Python standard library) and setup.py (installation file). The maximum size for the entire archive is 10MB.
  9. Click Save and deploy.
  10. To get a URL link for calling a function, change your function type to public.

Editing Functions

To edit a function:

  1. Open a project with a function and go to the Functions tab.
  2. Select the desired function from the list.
  3. Click Edit function in the new window.
  4. Make the necessary changes and change the function name to a new unique one.
  5. Click Save and deploy.

When you edit the function, a new function is created. You need to copy the new URL.

Deleting Functions

To delete a function:

  1. Open a project with a function and go to the Functions tab.
  2. Select the desired function from the list.
  3. Click on the trash icon (Delete function).