Skip to main content

Get

Returns the specified Repository resource.

To get the list of available Repository resources, make a List request.

import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";

const GetRepositoryRequest =
cloudApi.containerregistry.repository_service.GetRepositoryRequest;

(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.RepositoryServiceClient);

const result = await client.get(
GetRepositoryRequest.fromPartial({
repositoryId: "repositoryId",
})
);
console.log(result);
})();

GetRepositoryRequest

repositoryId : string

ID of the Repository resource to return.

To get the repository ID use a RepositoryService.List request.

Repository

A Repository resource. For more information, see Repository.

name : string

Name of the repository. The name is unique within the registry.

id : string

Output only. ID of the repository.