Yandex Cloud
Search
Discuss with expertTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • 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
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Yandex Identity and Access Management
  • Secure use of Yandex Cloud
  • Access management
  • Pricing policy
  • Role reference
  • Terraform reference
    • API authentication
      • Overview
        • Overview
        • Get
        • List
        • BatchGet
  • Monitoring metrics
  • Audit Trails events
  • Release notes

In this article:

  • gRPC request
  • GetSubjectRequest
  • Resource
  • GetSubjectResponse
  • Subject
  • Group
  • UserAccount
  • SubjectContainer
  • JobInfo
  • ServiceAccount
  • Cloud
  • Folder
  • ServiceAgent
  • Invitee
  1. API reference
  2. gRPC
  3. SubjectDetails
  4. Get

Identity and Access Management API, gRPC: SubjectDetailsService.Get

Written by
Yandex Cloud
Updated at June 23, 2026
  • gRPC request
  • GetSubjectRequest
  • Resource
  • GetSubjectResponse
  • Subject
  • Group
  • UserAccount
  • SubjectContainer
  • JobInfo
  • ServiceAccount
  • Cloud
  • Folder
  • ServiceAgent
  • Invitee

Returns the details of the specified subject.

gRPC requestgRPC request

rpc Get (GetSubjectRequest) returns (GetSubjectResponse)

GetSubjectRequestGetSubjectRequest

{
  "subject_id": "string",
  "field_mask": "google.protobuf.FieldMask",
  "resource_context": {
    "id": "string",
    "type": "string"
  }
}

Field

Description

subject_id

string

Required field. ID of the subject to return.

The maximum string length in characters is 100.

field_mask

google.protobuf.FieldMask

A mask that specifies which fields of the subject to return.

resource_context

Resource

The resource to which the returned subject has access. Can only be an organization or a folder.

ResourceResource

A Resource. For more information, see Resource.

Field

Description

id

string

Required field. ID of the resource.

The maximum string length in characters is 50.

type

string

Required field. The type of the resource, e.g. resource-manager.folder, billing.account, compute.snapshot, etc.

The maximum string length in characters is 64.

GetSubjectResponseGetSubjectResponse

{
  "subject": {
    "sub": "string",
    "type": "SubjectType",
    "created_at": "google.protobuf.Timestamp",
    "status": "SubjectStatus",
    "name": "string",
    "last_authenticated_at": "google.protobuf.Timestamp",
    "groups": [
      {
        "id": "string",
        "name": "string",
        "type": "GroupType"
      }
    ],
    // Includes only one of the fields `user_account`, `service_account`, `group`, `invitee`
    "user_account": {
      "given_name": "string",
      "family_name": "string",
      "preferred_username": "string",
      "email": "string",
      "phone_number": "string",
      "subject_container": {
        "id": "string",
        "name": "string",
        "container_type": "ContainerType"
      },
      "last_id_proof_at": "google.protobuf.Timestamp",
      "suspend_reason": "string",
      "job_info": {
        "company_name": "string",
        "department": "string",
        "job_title": "string",
        "employee_id": "string"
      },
      "expires_at": "google.protobuf.Timestamp",
      "modified_at": "google.protobuf.Timestamp"
    },
    "service_account": {
      "cloud": {
        "id": "string",
        "name": "string"
      },
      "folder": {
        "id": "string",
        "name": "string"
      },
      "service_agent": {
        "service_id": "string",
        "microservice_id": "string"
      }
    },
    "group": {
      "id": "string",
      "name": "string",
      "type": "GroupType"
    },
    "invitee": {
      "email": "string",
      "preferred_username": "string"
    },
    // end of the list of possible fields
    "external_id": "string"
  }
}

Field

Description

subject

Subject

The requested subject.

SubjectSubject

Field

Description

sub

string

Required field. Subject - Identifier for the End-User at the Issuer.

The maximum string length in characters is 100.

type

enum SubjectType

Required field. Subject type.

  • USER_ACCOUNT: User account subject.
  • SERVICE_ACCOUNT: Service account subject.
  • GROUP: Group subject.
  • INVITEE: Invitee subject.

created_at

google.protobuf.Timestamp

Creation time

status

enum SubjectStatus

Status

  • ACTIVE: Subject is active.
  • SUSPENDED: Subject is suspended.

name

string

End-User's full name in displayable form including all name parts, possibly including titles and suffixes, ordered according to the End-User's locale and preferences.

last_authenticated_at

google.protobuf.Timestamp

Last time the access token was created. Filled only for federated users (not for global users).

groups[]

Group

Groups to which the subject belongs

user_account

UserAccount

Details of a user account subject. Set when the subject is a user account.

Includes only one of the fields user_account, service_account, group, invitee.

Subject type-specific details.

service_account

ServiceAccount

Details of a service account subject. Set when the subject is a service account.

Includes only one of the fields user_account, service_account, group, invitee.

Subject type-specific details.

group

Group

Details of a group subject. Set when the subject is a group.

Includes only one of the fields user_account, service_account, group, invitee.

Subject type-specific details.

invitee

Invitee

Details of an invitee subject. Set when the subject is an invitee.

Includes only one of the fields user_account, service_account, group, invitee.

Subject type-specific details.

external_id

string

Subject id in external container

GroupGroup

Field

Description

id

string

ID of the group.

name

string

Name of the group.

type

enum GroupType

Type of the group.

  • PUBLIC_ACCESS: Public group.
  • EXPLICIT: Regular group.
  • META: System group.

UserAccountUserAccount

Field

Description

given_name

string

Given name(s) or first name(s) of the End-User. Note that in some cultures, people can have multiple given names; all can be present, with the names being separated by space characters.

family_name

string

Surname(s) or last name(s) of the End-User. Note that in some cultures, people can have multiple family names or no family name; all can be present, with the names being separated by space characters.

preferred_username

string

Shorthand name by which the End-User wishes to be referred to at the RP, such as janedoe or j.doe.
This value MAY be any valid JSON string including special characters such as @, /, or whitespace.

email

string

End-User's preferred e-mail address. Its value MUST conform to the RFC 5322 [RFC5322] addr-spec syntax.

phone_number

string

End-User's preferred phone number.

subject_container

SubjectContainer

Subject container

last_id_proof_at

google.protobuf.Timestamp

Last time when subject identification was proofed.

suspend_reason

string

Reason of subject's suspension

job_info

JobInfo

Information about job

expires_at

google.protobuf.Timestamp

The subject will be suspended at the specified time

modified_at

google.protobuf.Timestamp

Last time when the user account attributes were modified

SubjectContainerSubjectContainer

Field

Description

id

string

ID of the subject container.

name

string

Name of the subject container.

container_type

enum ContainerType

Type of the subject container.

  • SAML: SAML federation container.
  • PASSPORT: Yandex Passport container.
  • USERPOOL: User pool container.

JobInfoJobInfo

Field

Description

company_name

string

Name of the company the user works for.

department

string

Department the user belongs to.

job_title

string

Job title of the user.

employee_id

string

Employee identifier of the user.

ServiceAccountServiceAccount

Field

Description

cloud

Cloud

Cloud the service account belongs to.

folder

Folder

Folder the service account belongs to.

service_agent

ServiceAgent

Service agent details. Set when the service account is a service agent.

CloudCloud

Field

Description

id

string

ID of the cloud.

name

string

Name of the cloud.

FolderFolder

Field

Description

id

string

ID of the folder.

name

string

Name of the folder.

ServiceAgentServiceAgent

Field

Description

service_id

string

ID of the service the service agent acts on behalf of.

microservice_id

string

ID of the microservice the service agent acts on behalf of.

InviteeInvitee

Field

Description

email

string

E-mail address of the invitee.

preferred_username

string

Preferred username of the invitee.

Was the article helpful?

Previous
Overview
Next
List
© 2026 Direct Cursus Technology L.L.C.