Skip to main content

Get

Returns the specified location.

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

const GetLocationRequest = cloudApi.ydb.location_service.GetLocationRequest;

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

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

GetLocationRequest

locationId : string

Required. ID of the location to return.

Location

id : string
description : string