Yandex Cloud
  • Services
  • Solutions
  • Why Yandex Cloud
  • Blog
  • Pricing
  • Documentation
  • Contact us
Get started
Language / Region
Yandex project
© 2023 Yandex.Cloud LLC
Yandex Cloud Functions
  • Comparison with other Yandex Cloud services
  • Getting started
  • Step-by-step instructions
    • All instructions
    • Using functions to get an IAM token for a service account
    • Connecting to managed databases from functions
    • Getting information about a function
    • Managing rights to access functions
      • Making a function public
      • Making a function private
      • Viewing roles assigned to a function
      • Assigning roles to a function
      • Revoking roles assigned to a function
    • Creating a function
    • Invoking a function
    • Managing functions
    • Getting information about a trigger
    • Creating a trigger
    • Managing triggers
  • Concepts
  • Developing in Node.js
  • Developing in Python
  • Developing in Go
  • Developing in PHP
  • Developing in Bash
  • Developing in Java
  • Developing in R
  • Developing in C#
  • Practical guidelines
  • Pricing policy
  • Access management
  • API Functions reference
  • API Triggers reference
  • Questions and answers
  1. Step-by-step instructions
  2. Managing rights to access functions
  3. Viewing roles assigned to a function

Viewing roles assigned to a function

Written by
Yandex Cloud
    CLI
    API

    If you don't have the Yandex Cloud command line interface yet, install and initialize it.

    The folder specified in the CLI profile is used by default. You can specify a different folder using the --folder-name or --folder-id parameter.

    To view roles assigned to a function, run the command:

    yc serverless function list-access-bindings <function name>
    

    Result:

    +------------------------------+--------------+-----------------------+
    |           ROLE ID            | SUBJECT TYPE |       SUBJECT ID      |
    +------------------------------+--------------+-----------------------+
    | serverless.functions.invoker | system       | allAuthenticatedUsers |
    +------------------------------+--------------+-----------------------+
    

    You can view roles assigned to a function using the listAccessBindings API method.

    Note

    Roles assigned to a folder or cloud are automatically inherited by the function. However, they don't appear in the list of assigned roles. Learn more about viewing roles.

    Was the article helpful?

    Language / Region
    Yandex project
    © 2023 Yandex.Cloud LLC