ExecuteAlias
Executes NodeAlias requests.
- TypeScript
- Python
import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";
const AliasExecutionRequest =
cloudApi.datasphere.node_service.AliasExecutionRequest;
(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.NodeServiceClient);
const result = await client.executeAlias(
AliasExecutionRequest.fromPartial({
// folderId: "folderId",
// aliasName: "aliasName",
// input: {}
})
);
console.log(result);
})();
import os
import grpc
import yandexcloud
from yandex.cloud.datasphere.v1.node_service_pb2 import AliasExecutionRequest
from yandex.cloud.datasphere.v1.node_service_pb2_grpc import NodeServiceStub
token = os.getenv("YC_OAUTH_TOKEN")
sdk = yandexcloud.SDK(token=token)
service = sdk.client(NodeServiceStub)
response = service.ExecuteAlias(
AliasExecutionRequest(
# folder_id = "folderId",
# alias_name = "aliasName",
# input = {}
)
)
print(response)
AliasExecutionRequest
folderId
: string
ID of the folder that will be matched with Alias ACL
aliasName
: string
Name of the Alias to perform request on
input
: google.protobuf.Struct
Input data for the execution
AliasExecutionResponse
output
: google.protobuf.Struct
Result of the execution