Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
  • Blog
  • Pricing
  • Documentation
Yandex project
© 2025 Yandex.Cloud LLC
Yandex Container Registry
  • Getting started
  • Yandex Container Solution
  • Access management
  • Pricing policy
  • Terraform reference
    • Authentication with the API
      • Overview
        • Overview
        • Get
        • GetByRegistry
        • Create
        • Update
        • Delete
  • Monitoring metrics
  • Audit Trails events
  • Troubleshooting
  • FAQ

In this article:

  • gRPC request
  • GetScanPolicyRequest
  • ScanPolicy
  • ScanRules
  • PushRule
  • ScheduledRule
  1. API reference
  2. gRPC
  3. ScanPolicy
  4. Get

Container Registry API, gRPC: ScanPolicyService.Get

Written by
Yandex Cloud
Updated at November 26, 2024
  • gRPC request
  • GetScanPolicyRequest
  • ScanPolicy
  • ScanRules
  • PushRule
  • ScheduledRule

Returns the specified scan policy.

gRPC requestgRPC request

rpc Get (GetScanPolicyRequest) returns (ScanPolicy)

GetScanPolicyRequestGetScanPolicyRequest

{
  "scan_policy_id": "string"
}

Field

Description

scan_policy_id

string

Required field. ID of the scan policy.

ScanPolicyScanPolicy

{
  "id": "string",
  "registry_id": "string",
  "name": "string",
  "description": "string",
  "rules": {
    "push_rule": {
      "repository_prefixes": [
        "string"
      ],
      "disabled": "bool"
    },
    "schedule_rules": [
      {
        "repository_prefixes": [
          "string"
        ],
        "rescan_period": "google.protobuf.Duration",
        "disabled": "bool"
      }
    ]
  },
  "created_at": "google.protobuf.Timestamp",
  "disabled": "bool"
}

Field

Description

id

string

Output only. ID of the scan policy.

registry_id

string

ID of the registry that the scan policy belongs to.
Required. The maximum string length in characters is 50.

name

string

Name of the scan policy.

description

string

Description of the scan policy.
The maximum string length in characters is 256.

rules

ScanRules

The rules of scan policy.

created_at

google.protobuf.Timestamp

Output only. Creation timestamp.

disabled

bool

Turns off scan policy.

ScanRulesScanRules

Field

Description

push_rule

PushRule

Description of on-push scan rule.

schedule_rules[]

ScheduledRule

Description of time based rescan rule.

PushRulePushRule

Field

Description

repository_prefixes[]

string

List of repositories that are scanned with rule. Child repositories are included into parent node. "*" - means all repositories in registry

disabled

bool

Turns off scan rule.

ScheduledRuleScheduledRule

Field

Description

repository_prefixes[]

string

List of repositories that are scanned with rule. Child repositories are included into parent node. "*" - means all repositories in registry

rescan_period

google.protobuf.Duration

Required field. Period of time since last scan to trigger automatic rescan.

disabled

bool

Turns off scan rule.

Was the article helpful?

Previous
Overview
Next
GetByRegistry
Yandex project
© 2025 Yandex.Cloud LLC