Yandex Cloud
Search
Contact UsGet started
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • AI for business
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
© 2025 Direct Cursus Technology L.L.C.
Yandex Cloud Functions
  • Comparison with other Yandex Cloud services
    • Overview
    • Managing dependencies
    • Request handler
    • Logging
    • Handling errors
    • Using the SDK
  • Tools
  • Pricing policy
  • Access management
  • Terraform reference
  • Monitoring metrics
  • Audit Trails events
  • Public materials
  • Release notes
  • FAQ
  1. Developing in Bash
  2. Using the SDK

Using the SDK for Bash functions

Written by
Yandex Cloud
Updated at September 19, 2025

The runtime environment comes with the Yandex Cloud CLI utility installed by default to work with the Yandex Cloud API.

The user interacts with Yandex Cloud services using the service account specified in the Bash function. This does not require any additional actions from the user: the utility applies the service account automatically.

For example, you can get a list of cloud folders using the following script:

#!/bin/bash
set -e

HOME=/tmp yc --format json resource-manager folder list --cloud-id <cloud_ID> | jq -c  '{body:. | tostring}'

For the Yandex Cloud CLI commands to be executed successfully, use the --folder-id or --cloud-id parameters to specify the folder or cloud ID, respectively.

The runtime environment comes with pre-installed AWS CLI version 2 to support Yandex Cloud services compatible with the AWS API. To use it:

  1. Create a static access key for the service account.
  2. Save the static access key to a Yandex Lockbox secret.
  3. Provide the Yandex Lockbox secret to a function.

For more information and examples of commands, see AWS Command Line Interface and the relevant documentation of AWS-compatible Yandex Cloud services.

Was the article helpful?

Previous
Handling errors
Next
Overview
© 2025 Direct Cursus Technology L.L.C.