Creating a skill for Alice using serverless technology via the management console, Yandex Cloud CLI, or API
To create a skill for Alice using serverless technology via the Yandex Cloud management console, CLI, or API:
To add a skill for Alice based on a function:
- Get your cloud ready.
- Prepare the skill code.
- Create a function and a function version.
- Add the function link to the Alice's skill.
- Test the skill.
If you no longer need the resources you created, delete them.
Learn more about developing a skill for Alice here
Getting started
Sign up for Yandex Cloud and create a billing account:
- Navigate to the management console
and log in to Yandex Cloud or create a new account. - On the Yandex Cloud Billing
page, make sure you have a billing account linked and it has theACTIVEorTRIAL_ACTIVEstatus. If you do not have a billing account, create one and link a cloud to it.
If you have an active billing account, you can create or select a folder for your infrastructure on the cloud page
Learn more about clouds and folders here.
Prepare the code for the Alice's skill
To create a function version, you can use one of the code upload formats. In this example, we will upload the code to Yandex Cloud Functions as a ZIP archive.
- Download the parrot.py
example file from the GitHub repo. - Create a ZIP archive named
parrot-py.zipwith theparrot.pyfile.
- Download the index.js
example file from the GitHub repo. - Create a ZIP archive named
parrot-js.zipwith theindex.jsfile.
Create a function and a function version
Once created, the function will contain only information about itself, i.e., its name, description, unique ID, etc. The actual skill code will be added to the function version.
-
In the management console
, select the folder to create your function in. -
Click
Create resource and select Function. -
Give the function a name, e.g.,
my-parrot-function. -
Click Create.
-
Create a function version:
PythonNode.js-
From the list of programming languages, select
Python 3.12. -
Disable Add files with code examples and click Continue.
-
Prepare the function code:
- In the Code source field, select
ZIP archiveand attach theparrot-py.ziparchive you created earlier. - In the Entry point field, specify
parrot.handler.
- In the Code source field, select
-
Configure the version:
- Timeout:
2. - Memory:
128 MB. - Leave the other settings at their defaults.
- Timeout:
-
Click Save changes.
-
In the list of programming languages, select
Node.js 18. -
Disable Add files with code examples and click Continue.
-
Prepare the function code:
- In the Code source field, select
ZIP archiveand attach theparrot-js.ziparchive you created earlier. - In the Entry point field, specify
index.handler.
- In the Code source field, select
-
Configure the version:
- Timeout:
2. - Memory:
128 MB. - Leave the other settings at their defaults.
- Timeout:
-
Click Save changes.
-
If you do not have the Yandex Cloud CLI yet, install and initialize it.
The folder used by default is the one specified when creating the CLI profile. To change the default folder, use the yc config set folder-id <folder_ID> command. You can also specify a different folder for any command using --folder-name or --folder-id. If you access a resource by its name, the search will be limited to the default folder. If you access a resource by its ID, the search will be global, i.e., through all folders based on access permissions.
-
To create a function, run this command:
yc serverless function create \ --name my-parrot-functionResult:
id: d4el0mi6ps6s******** folder_id: b1g5bhjofg7o******** created_at: "2026-06-15T08:16:02.695Z" name: my-parrot-function http_invoke_url: https://functions.yandexcloud.net/d4el0mi6ps6s******** status: ACTIVE -
To create a function version, run this command:
PythonNode.jsyc serverless function version create \ --function-name my-parrot-function \ --runtime python312 \ --entrypoint index.handler \ --memory 128m \ --execution-timeout 5s \ --source-path ./parrot-py.zipResult:
done (2s) id: d4easr8ok281******** function_id: d4el0mi6ps6s******** created_at: "2026-06-15T08:42:20.771Z" runtime: python312 entrypoint: index.handler resources: memory: "134217728" execution_timeout: 5s image_size: "4096" status: ACTIVE tags: - $latest concurrency: "1" log_options: folder_id: b1g5bhjofg7o********yc serverless function version create \ --function-name my-parrot-function \ --runtime nodejs18 \ --entrypoint index.handler \ --memory 128m \ --execution-timeout 5s \ --source-path ./parrot-js.zipResult:
done (2s) id: d4etv45m1vor******** function_id: d4el0mi6ps6s******** created_at: "2026-06-15T08:45:25.313Z" runtime: nodejs18 entrypoint: index.handler resources: memory: "134217728" execution_timeout: 5s image_size: "4096" status: ACTIVE tags: - $latest concurrency: "1" log_options: folder_id: b1g5bhjofg7o********
To create a function, use the create REST API method for the Function resource or the FunctionService/Create gRPC API call.
To create a function version, use the createVersion REST API method for the Function resource or the FunctionService/CreateVersion gRPC API call.
Add the function link to the Alice's skill
-
Go to the Alice skill page in your dashboard.
-
Click
Skill for Alice and do the following in the window that opens:-
In the Skill name field, specify a unique name for the skill you are creating.
-
In the Backend field, select Function in Yandex Cloud. Select the function you created earlier from the drop-down list.
Warning
The list shows the functions that you are allowed to view. To attach a function to a skill, you need permission to invoke the function. This permission comes with the functions.functionInvoker role or higher.
-
Leave all the other parameter values unchanged and click Save at the top of the page.
-
The functions.functionInvoker role allows you to invoke functions. For more information on access management in Yandex Cloud, see this guide.
Test the skill
- In your Yandex Dialogs account
, select Testing in the left-hand menu on the page with the skill you created earlier. - If everything is set up correctly, the Chat section will display a message inviting you to start a conversation:
Hello! I'll repeat anything you say to me.. - Send a message with any text and make sure the response contains the same text.
How to delete the resources you created
To stop the skill, delete the function.
With Yandex Cloud Functions functions, you can place your code in Yandex Cloud and run on request or trigger. For more information, see Function.
A folder is a logical space where you create and group your Yandex Cloud resources. Just like folders in your file system, Yandex Cloud folders make resource management simpler. For more information, see Folder.
The naming requirements are as follows:
- It must be between 3 and 63 characters in length.
- It can only contain lowercase Latin letters, numbers, and hyphens.
- It must start with a letter and cannot end with a hyphen.
A version contain the function code, execution parameters, as well as all required dependencies. You can use different versions of the same function at different development stages. For more information, see Function versions.
There are several ways to upload a function version code: in the editor in the management console, from local files and directories, or as an archive. For more information, see Code upload format.